176 lines
6.5 KiB
C#
176 lines
6.5 KiB
C#
//----------------------------------------------------------------------------
|
|
//
|
|
// Copyright (c) Intel Corporation, 2003 - 2012 All Rights Reserved.
|
|
//
|
|
// File: CIM_ConcreteComponent.cs
|
|
//
|
|
// Contents: CIM_ConcreteComponent is a generic association used to establish 'part of' relationships between ManagedElements. It is defined as a concrete subclass of the abstract CIM_Component class, to be used in place of many specific subclasses of Component that add no semantics, that is subclasses that do not clarify the type of composition, update cardinalities, or add or remove qualifiers. Note that when you define additional semantics for Component, this class must not be subclassed. Specific semantics continue to be defined as subclasses of the abstract CIM_Component. ConcreteComponent is limited in its use as a concrete form of a general composition.
|
|
//
|
|
// It was deemed more prudent to create this concrete subclass than to change Component from an abstract to a concrete class. Industry usage and impact could not be anticipated.
|
|
// This file was automatically generated from CIM_ConcreteComponent.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
|
|
{
|
|
/// <summary>
|
|
///CIM_ConcreteComponent is a generic association used to establish 'part of' relationships between ManagedElements. It is defined as a concrete subclass of the abstract CIM_Component class, to be used in place of many specific subclasses of Component that add no semantics, that is subclasses that do not clarify the type of composition, update cardinalities, or add or remove qualifiers. Note that when you define additional semantics for Component, this class must not be subclassed. Specific semantics continue to be defined as subclasses of the abstract CIM_Component. ConcreteComponent is limited in its use as a concrete form of a general composition.
|
|
///It was deemed more prudent to create this concrete subclass than to change Component from an abstract to a concrete class. Industry usage and impact could not be anticipated.
|
|
/// </summary>
|
|
[System.SerializableAttribute()]
|
|
[System.Xml.Serialization.XmlTypeAttribute(Namespace="http://schemas.dmtf.org/wbem/wscim/1/cim-schema/2/CIM_ConcreteComponent")]
|
|
[System.Xml.Serialization.XmlRootAttribute("CIM_ConcreteComponent", Namespace="http://schemas.dmtf.org/wbem/wscim/1/cim-schema/2/CIM_ConcreteComponent", IsNullable=false)]
|
|
public class CIM_ConcreteComponent : CIM_Component
|
|
{
|
|
/// <summary>
|
|
/// Default constructor.
|
|
/// </summary>
|
|
public CIM_ConcreteComponent() :base()
|
|
{
|
|
}
|
|
/// <summary>
|
|
/// Constructor that recieves an xml string for deserialization.
|
|
/// </summary>
|
|
/// <param name="xml">xml string to deserialize</param>
|
|
public CIM_ConcreteComponent(string xml): base((IWSManClient)null)
|
|
{
|
|
this.Deserialize(xml);
|
|
}
|
|
/// <summary>
|
|
/// Constructor which recieves a Ws-Management client object.
|
|
/// </summary>
|
|
/// <param name="client">Ws-Management client</param>
|
|
public CIM_ConcreteComponent(IWSManClient client): base(client)
|
|
{
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
/// Required, The parent element in the association.
|
|
/// </summary>
|
|
[CimField(true, false)]
|
|
public override CimReference GroupComponent
|
|
{
|
|
get
|
|
{
|
|
string innerXML = this.GetField("GroupComponent")[0];
|
|
CimReference epr = new CimReference("GroupComponent", XmlNamespace, innerXML);
|
|
return epr;
|
|
}
|
|
set
|
|
{
|
|
this.SetOrAddField("GroupComponent",value.Serialize(false));
|
|
}
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
/// Required, The child element in the association.
|
|
/// </summary>
|
|
[CimField(true, false)]
|
|
public override CimReference PartComponent
|
|
{
|
|
get
|
|
{
|
|
string innerXML = this.GetField("PartComponent")[0];
|
|
CimReference epr = new CimReference("PartComponent", XmlNamespace, innerXML);
|
|
return epr;
|
|
}
|
|
set
|
|
{
|
|
this.SetOrAddField("PartComponent",value.Serialize(false));
|
|
}
|
|
}
|
|
|
|
/// <summary>
|
|
/// Enumerate instances of CIM_ConcreteComponent class at an endpoint.
|
|
/// </summary>
|
|
/// <param name="client">WS-Management client</param>
|
|
/// <param name="cimKeys">Keys for selecting the instances</param>
|
|
/// <returns>Collection of CIM_ConcreteComponent objects</returns>
|
|
public static new Collection<CIM_ConcreteComponent> Enumerate(IWSManClient client, CimBase.CimKeys cimKeys)
|
|
{
|
|
List<CIM_ConcreteComponent> ret = CimBase.Enumerate<CIM_ConcreteComponent>(client, cimKeys);
|
|
return new Collection<CIM_ConcreteComponent>(ret);
|
|
}
|
|
|
|
/// <summary>
|
|
/// Enumerate instances of CIM_ConcreteComponent class at an endpoint.
|
|
/// </summary>
|
|
/// <param name="client">WS-Management client</param>
|
|
/// <returns>Collection of CIM_ConcreteComponent objects</returns>
|
|
public static new Collection<CIM_ConcreteComponent> Enumerate(IWSManClient client)
|
|
{
|
|
List<CIM_ConcreteComponent> ret = CimBase.Enumerate<CIM_ConcreteComponent>(client);
|
|
return new Collection<CIM_ConcreteComponent>(ret);
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
/// Delete the instance of CIM_ConcreteComponent if it is singular.
|
|
/// Note: This method will succeed only if a single instance of the class exists.
|
|
/// </summary>
|
|
/// <param name="client">WS-Management client</param>
|
|
public static new void Delete(IWSManClient client)
|
|
{
|
|
CimBase.Delete<CIM_ConcreteComponent>(client);
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
/// Represents the keys of the CIM_ConcreteComponent class.
|
|
/// </summary>
|
|
|
|
public new class CimKeys : CIM_Component.CimKeys
|
|
{
|
|
/// <summary>
|
|
/// Required, The parent element in the association.
|
|
/// </summary>
|
|
|
|
public virtual CimReference GroupComponent
|
|
{
|
|
get
|
|
{
|
|
string innerXML = GetKey("GroupComponent");
|
|
CimReference epr = new CimReference("GroupComponent", "http://schemas.dmtf.org/wbem/wscim/1/cim-schema/2/CIM_ConcreteComponent", innerXML);
|
|
return epr;
|
|
}
|
|
set
|
|
{
|
|
SetOrAddKey("GroupComponent", value);
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// Required, The child element in the association.
|
|
/// </summary>
|
|
|
|
public virtual CimReference PartComponent
|
|
{
|
|
get
|
|
{
|
|
string innerXML = GetKey("PartComponent");
|
|
CimReference epr = new CimReference("PartComponent", "http://schemas.dmtf.org/wbem/wscim/1/cim-schema/2/CIM_ConcreteComponent", innerXML);
|
|
return epr;
|
|
}
|
|
set
|
|
{
|
|
SetOrAddKey("PartComponent", value);
|
|
}
|
|
}
|
|
}
|
|
|
|
}
|
|
}
|
|
|