Ejemplo n.º 1
0
		/// <summary>
		/// Creates a new Policy with the specified arguments.
		/// </summary>
		/// <param name="id">The policy id.</param>
		/// <param name="description">THe policy description.</param>
		/// <param name="target">THe policy target.</param>
		/// <param name="rules">THe rules for this policy.</param>
		/// <param name="ruleCombiningAlgorithm">THe rule combining algorithm.</param>
		/// <param name="obligations">The Obligations for this policy.</param>
		/// <param name="xpathVersion">The XPath version supported.</param>
		/// <param name="combinerParameters">The combiner parameters in this policy.</param>
		/// <param name="ruleCombinerParameters">The rule parameters in this policy.</param>
		/// <param name="variableDefinitions">The variable definitions of this policy.</param>
		/// <param name="schemaVersion">The version of the schema that was used to validate.</param>
		public PolicyElement( string id, string description, TargetElementReadWrite target, RuleReadWriteCollection rules, 
			string ruleCombiningAlgorithm, ObligationReadWriteCollection obligations, string xpathVersion, ArrayList combinerParameters, 
			ArrayList ruleCombinerParameters, IDictionary variableDefinitions, XacmlVersion schemaVersion )
			: base( id, description, target, rules, ruleCombiningAlgorithm, obligations, xpathVersion, 
			combinerParameters, ruleCombinerParameters, variableDefinitions, schemaVersion )
		{
		}
Ejemplo n.º 2
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="obligations"></param>
        public Obligations(pol.ObligationReadWriteCollection obligations)
        {
            // This call is required by the Windows.Forms Form Designer.
            InitializeComponent();

            LoadingData = true;

            _obligations = obligations;

            cmbEffect.Items.Add(pol.Effect.Deny);
            cmbEffect.Items.Add(pol.Effect.Permit);

            lstAttributeAssignments.DisplayMember = "AttributeId";

            lstObligations.DisplayMember = "ObligationId";
            foreach (pol.ObligationElementReadWrite obligation in obligations)
            {
                lstObligations.Items.Add(obligation);
            }

            if (obligations.Count != 0)
            {
                lstObligations.SelectedIndex = 0;
            }

            LoadingData = false;
        }
Ejemplo n.º 3
0
        /// <summary>
        /// 
        /// </summary>
        /// <param name="obligations"></param>
        public Obligations( pol.ObligationReadWriteCollection obligations )
        {
            // This call is required by the Windows.Forms Form Designer.
            InitializeComponent();

            LoadingData = true;

            _obligations = obligations;

            cmbEffect.Items.Add( pol.Effect.Deny );
            cmbEffect.Items.Add( pol.Effect.Permit );

            lstAttributeAssignments.DisplayMember = "AttributeId";

            lstObligations.DisplayMember = "ObligationId";
            foreach( pol.ObligationElementReadWrite obligation in obligations )
            {
                lstObligations.Items.Add( obligation );
            }

            if( obligations.Count != 0 )
            {
                lstObligations.SelectedIndex = 0;
            }

            LoadingData = false;
        }
Ejemplo n.º 4
0
 /// <summary>
 /// Creates a new Policy with the specified arguments.
 /// </summary>
 /// <param name="id">The policy id.</param>
 /// <param name="description">THe policy description.</param>
 /// <param name="target">THe policy target.</param>
 /// <param name="rules">THe rules for this policy.</param>
 /// <param name="ruleCombiningAlgorithm">THe rule combining algorithm.</param>
 /// <param name="obligations">The Obligations for this policy.</param>
 /// <param name="xpathVersion">The XPath version supported.</param>
 /// <param name="combinerParameters">The combiner parameters in this policy.</param>
 /// <param name="ruleCombinerParameters">The rule parameters in this policy.</param>
 /// <param name="variableDefinitions">The variable definitions of this policy.</param>
 /// <param name="schemaVersion">The version of the schema that was used to validate.</param>
 public PolicyElement(string id, string description, TargetElementReadWrite target, RuleReadWriteCollection rules,
                      string ruleCombiningAlgorithm, ObligationReadWriteCollection obligations, string xpathVersion, ArrayList combinerParameters,
                      ArrayList ruleCombinerParameters, IDictionary variableDefinitions, XacmlVersion schemaVersion)
     : base(id, description, target, rules, ruleCombiningAlgorithm, obligations, xpathVersion,
            combinerParameters, ruleCombinerParameters, variableDefinitions, schemaVersion)
 {
 }
Ejemplo n.º 5
0
		/// <summary>
		/// Creates a ObligationCollection, with the items contained in a ReadWriteObligationCollection
		/// </summary>
		/// <param name="items"></param>
		public ObligationCollection(ObligationReadWriteCollection items)
		{
			if (items == null) throw new ArgumentNullException("items");
			foreach (ObligationElementReadWrite item in items)
			{
				base.Add(new ObligationElement(item.ObligationId, item.FulfillOn, item.AttributeAssignment));
			}
		}
Ejemplo n.º 6
0
 /// <summary>
 /// Creates a ObligationCollection, with the items contained in a ReadWriteObligationCollection
 /// </summary>
 /// <param name="items"></param>
 public ObligationCollection(ObligationReadWriteCollection items)
 {
     if (items == null)
     {
         throw new ArgumentNullException("items");
     }
     foreach (ObligationElementReadWrite item in items)
     {
         base.Add(new ObligationElement(item.ObligationId, item.FulfillOn, item.AttributeAssignment));
     }
 }
Ejemplo n.º 7
0
 /// <summary>
 /// Creates a new policySet using the arguments provided.
 /// </summary>
 /// <param name="id">The policy set id.</param>
 /// <param name="description">The description of the policy set.</param>
 /// <param name="target">The target for this policy set.</param>
 /// <param name="policies">All the policies inside this policy set.</param>
 /// <param name="policyCombiningAlgorithm">The policy combining algorithm for this policy set.</param>
 /// <param name="obligations">The obligations.</param>
 /// <param name="xpathVersion">The XPath version supported.</param>
 /// <param name="schemaVersion">The version of the schema that was used to validate.</param>
 public PolicySetElementReadWrite(string id, string description, TargetElementReadWrite target, ArrayList policies, string policyCombiningAlgorithm,
                                  ObligationReadWriteCollection obligations, string xpathVersion, XacmlVersion schemaVersion)
     : base(XacmlSchema.Policy, schemaVersion)
 {
     _id          = id;
     _description = description;
     _target      = target;
     _policies    = policies;
     _policyCombiningAlgorithm = policyCombiningAlgorithm;
     _obligations  = obligations;
     _xpathVersion = xpathVersion;
 }
 /// <summary>
 /// Creates a new policySet using the arguments provided.
 /// </summary>
 /// <param name="id">The policy set id.</param>
 /// <param name="description">The description of the policy set.</param>
 /// <param name="target">The target for this policy set.</param>
 /// <param name="policies">All the policies inside this policy set.</param>
 /// <param name="policyCombiningAlgorithm">The policy combining algorithm for this policy set.</param>
 /// <param name="obligations">The obligations.</param>
 /// <param name="xpathVersion">The XPath version supported.</param>
 /// <param name="schemaVersion">The version of the schema that was used to validate.</param>
 public PolicySetElementReadWrite(string id, string description, TargetElementReadWrite target, ArrayList policies, string policyCombiningAlgorithm,
     ObligationReadWriteCollection obligations, string xpathVersion, XacmlVersion schemaVersion)
     : base(XacmlSchema.Policy, schemaVersion)
 {
     _id = id;
     _description = description;
     _target = target;
     _policies = policies;
     _policyCombiningAlgorithm = policyCombiningAlgorithm;
     _obligations = obligations;
     _xpathVersion = xpathVersion;
 }
Ejemplo n.º 9
0
 /// <summary>
 /// Creates a new Policy with the specified arguments.
 /// </summary>
 /// <param name="id">The policy id.</param>
 /// <param name="description">The policy description.</param>
 /// <param name="target">The policy target.</param>
 /// <param name="rules">The rules for this policy.</param>
 /// <param name="ruleCombiningAlgorithm">The rule combining algorithm.</param>
 /// <param name="obligations">The Obligations for this policy.</param>
 /// <param name="xpathVersion">The XPath version supported.</param>
 /// <param name="combinerParameters">The combiner parameters in this policy.</param>
 /// <param name="ruleCombinerParameters">The rule parameters in this policy.</param>
 /// <param name="variableDefinitions">The variable definitions of this policy.</param>
 /// <param name="schemaVersion">The version of the schema that was used to validate.</param>
 public PolicyElementReadWrite(string id, string description, TargetElementReadWrite target, RuleReadWriteCollection rules, string ruleCombiningAlgorithm, 
     ObligationReadWriteCollection obligations, string xpathVersion, ArrayList combinerParameters, ArrayList ruleCombinerParameters, IDictionary variableDefinitions, XacmlVersion schemaVersion)
     : base(XacmlSchema.Policy, schemaVersion)
 {
     _id = id;
     _description = description;
     _target = target;
     _rules = rules;
     _ruleCombiningAlgorithm = ruleCombiningAlgorithm;
     _obligations = obligations;
     _combinerParameters = combinerParameters;
     _ruleCombinerParameters = ruleCombinerParameters;
     _variableDefinitions = variableDefinitions;
     _xpathVersion = xpathVersion;
 }
Ejemplo n.º 10
0
 /// <summary>
 /// Creates a new Policy with the specified arguments.
 /// </summary>
 /// <param name="id">The policy id.</param>
 /// <param name="description">The policy description.</param>
 /// <param name="target">The policy target.</param>
 /// <param name="rules">The rules for this policy.</param>
 /// <param name="ruleCombiningAlgorithm">The rule combining algorithm.</param>
 /// <param name="obligations">The Obligations for this policy.</param>
 /// <param name="xpathVersion">The XPath version supported.</param>
 /// <param name="combinerParameters">The combiner parameters in this policy.</param>
 /// <param name="ruleCombinerParameters">The rule parameters in this policy.</param>
 /// <param name="variableDefinitions">The variable definitions of this policy.</param>
 /// <param name="schemaVersion">The version of the schema that was used to validate.</param>
 public PolicyElementReadWrite(string id, string description, TargetElementReadWrite target, RuleReadWriteCollection rules, string ruleCombiningAlgorithm,
                               ObligationReadWriteCollection obligations, string xpathVersion, ArrayList combinerParameters, ArrayList ruleCombinerParameters, IDictionary variableDefinitions, XacmlVersion schemaVersion)
     : base(XacmlSchema.Policy, schemaVersion)
 {
     _id                     = id;
     _description            = description;
     _target                 = target;
     _rules                  = rules;
     _ruleCombiningAlgorithm = ruleCombiningAlgorithm;
     _obligations            = obligations;
     _combinerParameters     = combinerParameters;
     _ruleCombinerParameters = ruleCombinerParameters;
     _variableDefinitions    = variableDefinitions;
     _xpathVersion           = xpathVersion;
 }
Ejemplo n.º 11
0
 /// <summary>
 /// Creates a new policySet using the arguments provided.
 /// </summary>
 /// <param name="id">The policy set id.</param>
 /// <param name="description">The description of the policy set.</param>
 /// <param name="target">The target for this policy set.</param>
 /// <param name="policies">All the policies inside this policy set.</param>
 /// <param name="policyCombiningAlgorithm">The policy combining algorithm for this policy set.</param>
 /// <param name="obligations">The obligations.</param>
 /// <param name="xpathVersion">The XPath version supported.</param>
 /// <param name="schemaVersion">The version of the schema that was used to validate.</param>
 public PolicySetElement(string id, string description, TargetElementReadWrite target, ArrayList policies, string policyCombiningAlgorithm,
                         ObligationReadWriteCollection obligations, string xpathVersion, XacmlVersion schemaVersion)
     : base(id, description, target, policies, policyCombiningAlgorithm, obligations, xpathVersion, schemaVersion)
 {
 }
Ejemplo n.º 12
0
 /// <summary>
 /// Creates a new policySet using the arguments provided.
 /// </summary>
 /// <param name="id">The policy set id.</param>
 /// <param name="description">The description of the policy set.</param>
 /// <param name="target">The target for this policy set.</param>
 /// <param name="policies">All the policies inside this policy set.</param>
 /// <param name="policyCombiningAlgorithm">The policy combining algorithm for this policy set.</param>
 /// <param name="obligations">The obligations.</param>
 /// <param name="xpathVersion">The XPath version supported.</param>
 /// <param name="schemaVersion">The version of the schema that was used to validate.</param>
 public PolicySetElement(string id, string description, TargetElementReadWrite target, ArrayList policies, string policyCombiningAlgorithm,
     ObligationReadWriteCollection obligations, string xpathVersion, XacmlVersion schemaVersion)
     : base(id, description, target, policies, policyCombiningAlgorithm, obligations, xpathVersion, schemaVersion)
 {
 }
Ejemplo n.º 13
0
        /// <summary>
        /// 
        /// </summary>
        /// <param name="obligations"></param>
        public Obligations( pol.ObligationReadWriteCollection obligations )
        {
            _obligations = obligations;

            this.Text = "Obligations";
        }
Ejemplo n.º 14
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="obligations"></param>
        public Obligations(pol.ObligationReadWriteCollection obligations)
        {
            _obligations = obligations;

            this.Text = "Obligations";
        }