//----------------------------------------------------------------------------
//
// Copyright (c) Intel Corporation, 2003 - 2012 All Rights Reserved.
//
// File: AMT_SystemPowerScheme.cs
//
// Contents: Represents a system power scheme
// This file was automatically generated from AMT_SystemPowerScheme.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
{
///
///Represents a system power scheme
///
[System.SerializableAttribute()]
[System.Xml.Serialization.XmlTypeAttribute(Namespace="http://intel.com/wbem/wscim/1/amt-schema/1/AMT_SystemPowerScheme")]
[System.Xml.Serialization.XmlRootAttribute("AMT_SystemPowerScheme", Namespace="http://intel.com/wbem/wscim/1/amt-schema/1/AMT_SystemPowerScheme", IsNullable=false)]
public class AMT_SystemPowerScheme : CIM_SettingData
{
///
/// Default constructor.
///
public AMT_SystemPowerScheme() :base()
{
}
///
/// Constructor that recieves an xml string for deserialization.
///
/// xml string to deserialize
public AMT_SystemPowerScheme(string xml): base((IWSManClient)null)
{
this.Deserialize(xml);
}
///
/// Constructor which recieves a Ws-Management client object.
///
/// Ws-Management client
public AMT_SystemPowerScheme(IWSManClient client): base(client)
{
}
///
/// Required, The user friendly name for this instance of SettingData. In addition, the user friendly name can be used as a index property for a search of query. (Note: Name does not have to be unique within a namespace.)
///
[CimField(false, true)]
public override string ElementName
{
get
{
return this.GetField("ElementName")[0];
}
set
{
this.SetOrAddField("ElementName",value);
}
}
///
/// Key, Required, Within the scope of the instantiating Namespace, InstanceID opaquely and uniquely identifies an instance of this class. In order to ensure uniqueness within the NameSpace, the value of InstanceID SHOULD be constructed using the following 'preferred' algorithm:
/// <OrgID>:<LocalID>
/// Where <OrgID> and <LocalID> are separated by a colon ':', and where <OrgID> MUST include a copyrighted, trademarked or otherwise unique name that is owned by the business entity creating/defining the InstanceID, or is a registered ID that is assigned to the business entity by a recognized global authority (This is similar to the <Schema Name>_<Class Name> structure of Schema class names.) In addition, to ensure uniqueness <OrgID> MUST NOT contain a colon (':'). When using this algorithm, the first colon to appear in InstanceID MUST appear between <OrgID> and <LocalID>.
/// <LocalID> is chosen by the business entity and SHOULD not be re-used to identify different underlying (real-world) elements. If the above 'preferred' algorithm is not used, the defining entity MUST assure that the resultant InstanceID is not re-used across any InstanceIDs produced by this or other providers for this instance's NameSpace.
/// For DMTF defined instances, the 'preferred' algorithm MUST be used with the <OrgID> set to 'CIM'.
///
[CimField(true, true)]
public override string InstanceID
{
get
{
return this.GetField("InstanceID")[0];
}
set
{
this.SetOrAddField("InstanceID",value);
}
}
///
/// Key, Required, A unique configuration identifier for the power package encoded as Base64.
///
[CimField(true, true)]
public virtual string SchemeGUID
{
get
{
return this.GetField("SchemeGUID")[0];
}
set
{
this.SetOrAddField("SchemeGUID",value);
}
}
///
///This method activates this scheme. The IsCurrent property of CIM_ElementSettingData class that is associated to this scheme will be changed. All other schemes will be deactivated. The method returns zero on success, a positive number on failure.
///
[System.SerializableAttribute()]
[System.Xml.Serialization.XmlTypeAttribute(AnonymousType=true)]
[System.Xml.Serialization.XmlRootAttribute(Namespace="http://intel.com/wbem/wscim/1/amt-schema/1/AMT_SystemPowerScheme", IsNullable=false)]
private class SetPowerScheme_INPUT : CimParams
{
public SetPowerScheme_INPUT(string ns) : base(ns)
{
}
}
///
///This method activates this scheme. The IsCurrent property of CIM_ElementSettingData class that is associated to this scheme will be changed. All other schemes will be deactivated. The method returns zero on success, a positive number on failure.
///
[System.SerializableAttribute()]
[System.Xml.Serialization.XmlTypeAttribute(AnonymousType=true)]
[System.Xml.Serialization.XmlRootAttribute(Namespace="http://intel.com/wbem/wscim/1/amt-schema/1/AMT_SystemPowerScheme", IsNullable=false)]
private class SetPowerScheme_OUTPUT : CimParams
{
public SetPowerScheme_OUTPUT() : base("")
{
}
}
///
///This method activates this scheme. The IsCurrent property of CIM_ElementSettingData class that is associated to this scheme will be changed. All other schemes will be deactivated. The method returns zero on success, a positive number on failure.
///
///
/// Legal values:
/// PT_STATUS_SUCCESS : 0
/// PT_STATUS_INTERNAL_ERROR : 1
/// PT_STATUS_FLASH_WRITE_LIMIT_EXCEEDED : 38
/// PT_STATUS_AUDIT_FAIL : 2075
///
public virtual uint SetPowerScheme()
{
SetPowerScheme_INPUT input = new SetPowerScheme_INPUT(this.XmlNamespace);
SetPowerScheme_OUTPUT output = new SetPowerScheme_OUTPUT();
uint returnValue = base.Invoke("SetPowerScheme",input,out output);
return returnValue;
}
///
/// Enumerate instances of AMT_SystemPowerScheme class at an endpoint.
///
/// WS-Management client
/// Keys for selecting the instances
/// Collection of AMT_SystemPowerScheme objects
public static new Collection Enumerate(IWSManClient client, CimBase.CimKeys cimKeys)
{
List ret = CimBase.Enumerate(client, cimKeys);
return new Collection(ret);
}
///
/// Enumerate instances of AMT_SystemPowerScheme class at an endpoint.
///
/// WS-Management client
/// Collection of AMT_SystemPowerScheme objects
public static new Collection Enumerate(IWSManClient client)
{
List ret = CimBase.Enumerate(client);
return new Collection(ret);
}
///
/// Delete the instance of AMT_SystemPowerScheme if it is singular.
/// Note: This method will succeed only if a single instance of the class exists.
///
/// WS-Management client
public static new void Delete(IWSManClient client)
{
CimBase.Delete(client);
}
///
/// Represents the keys of the AMT_SystemPowerScheme class.
///
public new class CimKeys : CIM_SettingData.CimKeys
{
///
/// Key, Required, Within the scope of the instantiating Namespace, InstanceID opaquely and uniquely identifies an instance of this class. In order to ensure uniqueness within the NameSpace, the value of InstanceID SHOULD be constructed using the following 'preferred' algorithm:
/// <OrgID>:<LocalID>
/// Where <OrgID> and <LocalID> are separated by a colon ':', and where <OrgID> MUST include a copyrighted, trademarked or otherwise unique name that is owned by the business entity creating/defining the InstanceID, or is a registered ID that is assigned to the business entity by a recognized global authority (This is similar to the <Schema Name>_<Class Name> structure of Schema class names.) In addition, to ensure uniqueness <OrgID> MUST NOT contain a colon (':'). When using this algorithm, the first colon to appear in InstanceID MUST appear between <OrgID> and <LocalID>.
/// <LocalID> is chosen by the business entity and SHOULD not be re-used to identify different underlying (real-world) elements. If the above 'preferred' algorithm is not used, the defining entity MUST assure that the resultant InstanceID is not re-used across any InstanceIDs produced by this or other providers for this instance's NameSpace.
/// For DMTF defined instances, the 'preferred' algorithm MUST be used with the <OrgID> set to 'CIM'.
///
public virtual string InstanceID
{
get
{
return GetKey("InstanceID");
}
set
{
SetOrAddKey("InstanceID", value);
}
}
///
/// Key, Required, A unique configuration identifier for the power package encoded as Base64.
///
public virtual string SchemeGUID
{
get
{
return GetKey("SchemeGUID");
}
set
{
SetOrAddKey("SchemeGUID", value);
}
}
}
}
}