//----------------------------------------------------------------------------
//
// Copyright (c) Intel Corporation, 2003 - 2012 All Rights Reserved.
//
// File: CIM_RoleLimitedToTarget.cs
//
// Contents: The Role object class is used to represent a position or set of responsibilities within an organization, organizational unit or other scope. When explicitly restricting the target elements that may be accessed from this Role, this association MUST be used.
// This file was automatically generated from CIM_RoleLimitedToTarget.mof
//
//----------------------------------------------------------------------------
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Text;
using System.Globalization;
using System.Xml.Serialization;
using System.IO;
using Intel.Manageability.WSManagement;
using Intel.Manageability.Cim.Untyped;
namespace Intel.Manageability.Cim.Typed
{
///
///The Role object class is used to represent a position or set of responsibilities within an organization, organizational unit or other scope. When explicitly restricting the target elements that may be accessed from this Role, this association MUST be used.
///
[System.SerializableAttribute()]
[System.Xml.Serialization.XmlTypeAttribute(Namespace="http://schemas.dmtf.org/wbem/wscim/1/cim-schema/2/CIM_RoleLimitedToTarget")]
[System.Xml.Serialization.XmlRootAttribute("CIM_RoleLimitedToTarget", Namespace="http://schemas.dmtf.org/wbem/wscim/1/cim-schema/2/CIM_RoleLimitedToTarget", IsNullable=false)]
public class CIM_RoleLimitedToTarget : CimBase
{
///
/// Default constructor.
///
public CIM_RoleLimitedToTarget() :base()
{
}
///
/// Constructor that recieves an xml string for deserialization.
///
/// xml string to deserialize
public CIM_RoleLimitedToTarget(string xml): base((IWSManClient)null)
{
this.Deserialize(xml);
}
///
/// Constructor which recieves a Ws-Management client object.
///
/// Ws-Management client
public CIM_RoleLimitedToTarget(IWSManClient client): base(client)
{
}
///
/// Key, Required, The Role whose target set is explicitly defined.
///
[CimField(true, false)]
public virtual CimReference DefiningRole
{
get
{
string innerXML = this.GetField("DefiningRole")[0];
CimReference epr = new CimReference("DefiningRole", XmlNamespace, innerXML);
return epr;
}
set
{
this.SetOrAddField("DefiningRole",value.Serialize(false));
}
}
///
/// Key, Required, Reference to the target set that can be accessed from the Role.
///
[CimField(true, false)]
public virtual CimReference TargetElement
{
get
{
string innerXML = this.GetField("TargetElement")[0];
CimReference epr = new CimReference("TargetElement", XmlNamespace, innerXML);
return epr;
}
set
{
this.SetOrAddField("TargetElement",value.Serialize(false));
}
}
///
/// Enumerate instances of CIM_RoleLimitedToTarget class at an endpoint.
///
/// WS-Management client
/// Keys for selecting the instances
/// Collection of CIM_RoleLimitedToTarget objects
public static Collection Enumerate(IWSManClient client, CimBase.CimKeys cimKeys)
{
List ret = CimBase.Enumerate(client, cimKeys);
return new Collection(ret);
}
///
/// Enumerate instances of CIM_RoleLimitedToTarget class at an endpoint.
///
/// WS-Management client
/// Collection of CIM_RoleLimitedToTarget objects
public static Collection Enumerate(IWSManClient client)
{
List ret = CimBase.Enumerate(client);
return new Collection(ret);
}
///
/// Delete the instance of CIM_RoleLimitedToTarget if it is singular.
/// Note: This method will succeed only if a single instance of the class exists.
///
/// WS-Management client
public static void Delete(IWSManClient client)
{
CimBase.Delete(client);
}
///
/// Represents the keys of the CIM_RoleLimitedToTarget class.
///
public new class CimKeys : CimBase.CimKeys
{
///
/// Key, Required, The Role whose target set is explicitly defined.
///
public virtual CimReference DefiningRole
{
get
{
string innerXML = GetKey("DefiningRole");
CimReference epr = new CimReference("DefiningRole", "http://schemas.dmtf.org/wbem/wscim/1/cim-schema/2/CIM_RoleLimitedToTarget", innerXML);
return epr;
}
set
{
SetOrAddKey("DefiningRole", value);
}
}
///
/// Key, Required, Reference to the target set that can be accessed from the Role.
///
public virtual CimReference TargetElement
{
get
{
string innerXML = GetKey("TargetElement");
CimReference epr = new CimReference("TargetElement", "http://schemas.dmtf.org/wbem/wscim/1/cim-schema/2/CIM_RoleLimitedToTarget", innerXML);
return epr;
}
set
{
SetOrAddKey("TargetElement", value);
}
}
}
}
}