// Copyright (C) Intel Corporation, 2010 All Rights Reserved.
using System;
using System.Collections.Generic;
using System.Runtime.InteropServices;
using System.Text;
namespace Intel.Management.Wsman
{
///
/// Represents object instance data exchanged with a Wsman Service
///
[InterfaceType(ComInterfaceType.InterfaceIsDual)]
[Guid("D9E2A225-6E6F-499a-854B-1CC49B609771")]
[ComVisible(true)]
public interface IManagedInstance
{
///
/// Gets the connection object associated with the instance data
///
IWsmanConnection Connection { get;}
///
/// Gets the XML representation of the instance data
///
string Xml { get; set; }
///
/// Gets resourceUri of the reference
///
string ResourceUri { get;}
///
/// Get The simple name of the resource
///
/// Returns the last component of the ResourceUri
string SimpleName { get; }
///
/// Get method name if the instance data is representing method input parameters
///
string MethodName { get;}
///
/// Gets the value of a property associated with the instance
///
/// The name of a property associated with the instance
/// Returns an object containing the property value
IWsmanItem GetProperty(string name);
///
/// Sets the value of a property associated with the instance
///
/// The name of a property associated with the instance
/// The property value
void SetProperty(string name, object value);
///
/// Adds a property to the instance
///
/// The name of a property associated with the instance
/// The property value
void AddProperty(string name, object value);
///
/// Removes a property from the instance
///
/// The name of a property associated with the instance
void RemoveProperty(string name);
///
/// Returns the property names currently associated with the instance data
///
/// Returns an object containing the array property names
IWsmanItem GetPropertyNames();
///
/// Creates the instance data on the remote server
///
/// Returns a reference to the newly created instance data
IManagedReference Create();
///
/// Gets or set the text data contained in the instance
///
string Text { get; set; }
///
/// Converts the instance to a reference
///
///A space delimited array of property names to include in the reference
IManagedReference ToReference(string keynames);
}
}