#pragma warning disable 1591, 0114, 0108
// ------------------------------------------------------------------------------
//
// Generated by Xsd2Code. Version 3.3.0.33001
// OSGeo.MapGuide.ObjectModels.CommonBindingListCSharpTrueFalseTrueTrueTrueFalseTrueFalseNet20SerializeDeserializeSaveToFileLoadFromFileTrueFalseFalseFalseFalse
//
// ------------------------------------------------------------------------------
namespace OSGeo.MapGuide.ObjectModels.Common {
using System;
using System.Diagnostics;
using System.Xml.Serialization;
using System.Collections;
using System.Xml.Schema;
using System.ComponentModel;
using System.IO;
///
/// Site Information
///
[System.CodeDom.Compiler.GeneratedCodeAttribute("Xsd2Code", "3.3.0.33572")]
[System.SerializableAttribute()]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
[System.Xml.Serialization.XmlTypeAttribute(AnonymousType=true)]
[System.Xml.Serialization.XmlRootAttribute(Namespace="", IsNullable=false)]
public partial class SiteInformation : System.ComponentModel.INotifyPropertyChanged {
[EditorBrowsable(EditorBrowsableState.Never)]
private SiteInformationSiteServer siteServerField;
[EditorBrowsable(EditorBrowsableState.Never)]
private SiteInformationStatistics statisticsField;
private static System.Xml.Serialization.XmlSerializer serializer;
public SiteInformationSiteServer SiteServer {
get {
return this.siteServerField;
}
set {
if ((this.siteServerField != null)) {
if ((siteServerField.Equals(value) != true)) {
this.siteServerField = value;
this.OnPropertyChanged("SiteServer");
}
}
else {
this.siteServerField = value;
this.OnPropertyChanged("SiteServer");
}
}
}
public SiteInformationStatistics Statistics {
get {
return this.statisticsField;
}
set {
if ((this.statisticsField != null)) {
if ((statisticsField.Equals(value) != true)) {
this.statisticsField = value;
this.OnPropertyChanged("Statistics");
}
}
else {
this.statisticsField = value;
this.OnPropertyChanged("Statistics");
}
}
}
private static System.Xml.Serialization.XmlSerializer Serializer {
get {
if ((serializer == null)) {
serializer = new System.Xml.Serialization.XmlSerializer(typeof(SiteInformation));
}
return serializer;
}
}
public event System.ComponentModel.PropertyChangedEventHandler PropertyChanged;
public virtual void OnPropertyChanged(string info) {
System.ComponentModel.PropertyChangedEventHandler handler = this.PropertyChanged;
if ((handler != null)) {
handler(this, new System.ComponentModel.PropertyChangedEventArgs(info));
}
}
#region Serialize/Deserialize
///
/// Serializes current SiteInformation object into an XML document
///
/// string XML value
public virtual string Serialize() {
System.IO.StreamReader streamReader = null;
System.IO.MemoryStream memoryStream = null;
try {
memoryStream = new System.IO.MemoryStream();
Serializer.Serialize(memoryStream, this);
memoryStream.Seek(0, System.IO.SeekOrigin.Begin);
streamReader = new System.IO.StreamReader(memoryStream);
return streamReader.ReadToEnd();
}
finally {
if ((streamReader != null)) {
streamReader.Dispose();
}
if ((memoryStream != null)) {
memoryStream.Dispose();
}
}
}
///
/// Deserializes workflow markup into an SiteInformation object
///
/// string workflow markup to deserialize
/// Output SiteInformation object
/// output Exception value if deserialize failed
/// true if this XmlSerializer can deserialize the object; otherwise, false
public static bool Deserialize(string xml, out SiteInformation obj, out System.Exception exception) {
exception = null;
obj = default(SiteInformation);
try {
obj = Deserialize(xml);
return true;
}
catch (System.Exception ex) {
exception = ex;
return false;
}
}
public static bool Deserialize(string xml, out SiteInformation obj) {
System.Exception exception = null;
return Deserialize(xml, out obj, out exception);
}
public static SiteInformation Deserialize(string xml) {
System.IO.StringReader stringReader = null;
try {
stringReader = new System.IO.StringReader(xml);
return ((SiteInformation)(Serializer.Deserialize(System.Xml.XmlReader.Create(stringReader))));
}
finally {
if ((stringReader != null)) {
stringReader.Dispose();
}
}
}
///
/// Serializes current SiteInformation object into file
///
/// full path of outupt xml file
/// output Exception value if failed
/// true if can serialize and save into file; otherwise, false
public virtual bool SaveToFile(string fileName, out System.Exception exception) {
exception = null;
try {
SaveToFile(fileName);
return true;
}
catch (System.Exception e) {
exception = e;
return false;
}
}
public virtual void SaveToFile(string fileName) {
System.IO.StreamWriter streamWriter = null;
try {
string xmlString = Serialize();
System.IO.FileInfo xmlFile = new System.IO.FileInfo(fileName);
streamWriter = xmlFile.CreateText();
streamWriter.WriteLine(xmlString);
streamWriter.Close();
}
finally {
if ((streamWriter != null)) {
streamWriter.Dispose();
}
}
}
///
/// Deserializes xml markup from file into an SiteInformation object
///
/// string xml file to load and deserialize
/// Output SiteInformation object
/// output Exception value if deserialize failed
/// true if this XmlSerializer can deserialize the object; otherwise, false
public static bool LoadFromFile(string fileName, out SiteInformation obj, out System.Exception exception) {
exception = null;
obj = default(SiteInformation);
try {
obj = LoadFromFile(fileName);
return true;
}
catch (System.Exception ex) {
exception = ex;
return false;
}
}
public static bool LoadFromFile(string fileName, out SiteInformation obj) {
System.Exception exception = null;
return LoadFromFile(fileName, out obj, out exception);
}
public static SiteInformation LoadFromFile(string fileName) {
System.IO.FileStream file = null;
System.IO.StreamReader sr = null;
try {
file = new System.IO.FileStream(fileName, FileMode.Open, FileAccess.Read);
sr = new System.IO.StreamReader(file);
string xmlString = sr.ReadToEnd();
sr.Close();
file.Close();
return Deserialize(xmlString);
}
finally {
if ((file != null)) {
file.Dispose();
}
if ((sr != null)) {
sr.Dispose();
}
}
}
#endregion
#region Clone method
///
/// Create a clone of this SiteInformation object
///
public virtual SiteInformation Clone() {
return ((SiteInformation)(this.MemberwiseClone()));
}
#endregion
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("Xsd2Code", "3.3.0.33572")]
[System.SerializableAttribute()]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
[System.Xml.Serialization.XmlTypeAttribute(AnonymousType=true)]
public partial class SiteInformationSiteServer : System.ComponentModel.INotifyPropertyChanged {
[EditorBrowsable(EditorBrowsableState.Never)]
private string displayNameField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string statusField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string versionField;
[EditorBrowsable(EditorBrowsableState.Never)]
private SiteInformationSiteServerOperatingSystem operatingSystemField;
private static System.Xml.Serialization.XmlSerializer serializer;
public string DisplayName {
get {
return this.displayNameField;
}
set {
if ((this.displayNameField != null)) {
if ((displayNameField.Equals(value) != true)) {
this.displayNameField = value;
this.OnPropertyChanged("DisplayName");
}
}
else {
this.displayNameField = value;
this.OnPropertyChanged("DisplayName");
}
}
}
public string Status {
get {
return this.statusField;
}
set {
if ((this.statusField != null)) {
if ((statusField.Equals(value) != true)) {
this.statusField = value;
this.OnPropertyChanged("Status");
}
}
else {
this.statusField = value;
this.OnPropertyChanged("Status");
}
}
}
public string Version {
get {
return this.versionField;
}
set {
if ((this.versionField != null)) {
if ((versionField.Equals(value) != true)) {
this.versionField = value;
this.OnPropertyChanged("Version");
}
}
else {
this.versionField = value;
this.OnPropertyChanged("Version");
}
}
}
public SiteInformationSiteServerOperatingSystem OperatingSystem {
get {
return this.operatingSystemField;
}
set {
if ((this.operatingSystemField != null)) {
if ((operatingSystemField.Equals(value) != true)) {
this.operatingSystemField = value;
this.OnPropertyChanged("OperatingSystem");
}
}
else {
this.operatingSystemField = value;
this.OnPropertyChanged("OperatingSystem");
}
}
}
private static System.Xml.Serialization.XmlSerializer Serializer {
get {
if ((serializer == null)) {
serializer = new System.Xml.Serialization.XmlSerializer(typeof(SiteInformationSiteServer));
}
return serializer;
}
}
public event System.ComponentModel.PropertyChangedEventHandler PropertyChanged;
public virtual void OnPropertyChanged(string info) {
System.ComponentModel.PropertyChangedEventHandler handler = this.PropertyChanged;
if ((handler != null)) {
handler(this, new System.ComponentModel.PropertyChangedEventArgs(info));
}
}
#region Serialize/Deserialize
///
/// Serializes current SiteInformationSiteServer object into an XML document
///
/// string XML value
public virtual string Serialize() {
System.IO.StreamReader streamReader = null;
System.IO.MemoryStream memoryStream = null;
try {
memoryStream = new System.IO.MemoryStream();
Serializer.Serialize(memoryStream, this);
memoryStream.Seek(0, System.IO.SeekOrigin.Begin);
streamReader = new System.IO.StreamReader(memoryStream);
return streamReader.ReadToEnd();
}
finally {
if ((streamReader != null)) {
streamReader.Dispose();
}
if ((memoryStream != null)) {
memoryStream.Dispose();
}
}
}
///
/// Deserializes workflow markup into an SiteInformationSiteServer object
///
/// string workflow markup to deserialize
/// Output SiteInformationSiteServer object
/// output Exception value if deserialize failed
/// true if this XmlSerializer can deserialize the object; otherwise, false
public static bool Deserialize(string xml, out SiteInformationSiteServer obj, out System.Exception exception) {
exception = null;
obj = default(SiteInformationSiteServer);
try {
obj = Deserialize(xml);
return true;
}
catch (System.Exception ex) {
exception = ex;
return false;
}
}
public static bool Deserialize(string xml, out SiteInformationSiteServer obj) {
System.Exception exception = null;
return Deserialize(xml, out obj, out exception);
}
public static SiteInformationSiteServer Deserialize(string xml) {
System.IO.StringReader stringReader = null;
try {
stringReader = new System.IO.StringReader(xml);
return ((SiteInformationSiteServer)(Serializer.Deserialize(System.Xml.XmlReader.Create(stringReader))));
}
finally {
if ((stringReader != null)) {
stringReader.Dispose();
}
}
}
///
/// Serializes current SiteInformationSiteServer object into file
///
/// full path of outupt xml file
/// output Exception value if failed
/// true if can serialize and save into file; otherwise, false
public virtual bool SaveToFile(string fileName, out System.Exception exception) {
exception = null;
try {
SaveToFile(fileName);
return true;
}
catch (System.Exception e) {
exception = e;
return false;
}
}
public virtual void SaveToFile(string fileName) {
System.IO.StreamWriter streamWriter = null;
try {
string xmlString = Serialize();
System.IO.FileInfo xmlFile = new System.IO.FileInfo(fileName);
streamWriter = xmlFile.CreateText();
streamWriter.WriteLine(xmlString);
streamWriter.Close();
}
finally {
if ((streamWriter != null)) {
streamWriter.Dispose();
}
}
}
///
/// Deserializes xml markup from file into an SiteInformationSiteServer object
///
/// string xml file to load and deserialize
/// Output SiteInformationSiteServer object
/// output Exception value if deserialize failed
/// true if this XmlSerializer can deserialize the object; otherwise, false
public static bool LoadFromFile(string fileName, out SiteInformationSiteServer obj, out System.Exception exception) {
exception = null;
obj = default(SiteInformationSiteServer);
try {
obj = LoadFromFile(fileName);
return true;
}
catch (System.Exception ex) {
exception = ex;
return false;
}
}
public static bool LoadFromFile(string fileName, out SiteInformationSiteServer obj) {
System.Exception exception = null;
return LoadFromFile(fileName, out obj, out exception);
}
public static SiteInformationSiteServer LoadFromFile(string fileName) {
System.IO.FileStream file = null;
System.IO.StreamReader sr = null;
try {
file = new System.IO.FileStream(fileName, FileMode.Open, FileAccess.Read);
sr = new System.IO.StreamReader(file);
string xmlString = sr.ReadToEnd();
sr.Close();
file.Close();
return Deserialize(xmlString);
}
finally {
if ((file != null)) {
file.Dispose();
}
if ((sr != null)) {
sr.Dispose();
}
}
}
#endregion
#region Clone method
///
/// Create a clone of this SiteInformationSiteServer object
///
public virtual SiteInformationSiteServer Clone() {
return ((SiteInformationSiteServer)(this.MemberwiseClone()));
}
#endregion
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("Xsd2Code", "3.3.0.33572")]
[System.SerializableAttribute()]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
[System.Xml.Serialization.XmlTypeAttribute(AnonymousType=true)]
public partial class SiteInformationSiteServerOperatingSystem : System.ComponentModel.INotifyPropertyChanged {
[EditorBrowsable(EditorBrowsableState.Never)]
private string availablePhysicalMemoryField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string totalPhysicalMemoryField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string availableVirtualMemoryField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string totalVirtualMemoryField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string versionField;
private static System.Xml.Serialization.XmlSerializer serializer;
[System.Xml.Serialization.XmlElementAttribute(DataType="integer")]
public string AvailablePhysicalMemory {
get {
return this.availablePhysicalMemoryField;
}
set {
if ((this.availablePhysicalMemoryField != null)) {
if ((availablePhysicalMemoryField.Equals(value) != true)) {
this.availablePhysicalMemoryField = value;
this.OnPropertyChanged("AvailablePhysicalMemory");
}
}
else {
this.availablePhysicalMemoryField = value;
this.OnPropertyChanged("AvailablePhysicalMemory");
}
}
}
[System.Xml.Serialization.XmlElementAttribute(DataType="integer")]
public string TotalPhysicalMemory {
get {
return this.totalPhysicalMemoryField;
}
set {
if ((this.totalPhysicalMemoryField != null)) {
if ((totalPhysicalMemoryField.Equals(value) != true)) {
this.totalPhysicalMemoryField = value;
this.OnPropertyChanged("TotalPhysicalMemory");
}
}
else {
this.totalPhysicalMemoryField = value;
this.OnPropertyChanged("TotalPhysicalMemory");
}
}
}
[System.Xml.Serialization.XmlElementAttribute(DataType="integer")]
public string AvailableVirtualMemory {
get {
return this.availableVirtualMemoryField;
}
set {
if ((this.availableVirtualMemoryField != null)) {
if ((availableVirtualMemoryField.Equals(value) != true)) {
this.availableVirtualMemoryField = value;
this.OnPropertyChanged("AvailableVirtualMemory");
}
}
else {
this.availableVirtualMemoryField = value;
this.OnPropertyChanged("AvailableVirtualMemory");
}
}
}
[System.Xml.Serialization.XmlElementAttribute(DataType="integer")]
public string TotalVirtualMemory {
get {
return this.totalVirtualMemoryField;
}
set {
if ((this.totalVirtualMemoryField != null)) {
if ((totalVirtualMemoryField.Equals(value) != true)) {
this.totalVirtualMemoryField = value;
this.OnPropertyChanged("TotalVirtualMemory");
}
}
else {
this.totalVirtualMemoryField = value;
this.OnPropertyChanged("TotalVirtualMemory");
}
}
}
public string Version {
get {
return this.versionField;
}
set {
if ((this.versionField != null)) {
if ((versionField.Equals(value) != true)) {
this.versionField = value;
this.OnPropertyChanged("Version");
}
}
else {
this.versionField = value;
this.OnPropertyChanged("Version");
}
}
}
private static System.Xml.Serialization.XmlSerializer Serializer {
get {
if ((serializer == null)) {
serializer = new System.Xml.Serialization.XmlSerializer(typeof(SiteInformationSiteServerOperatingSystem));
}
return serializer;
}
}
public event System.ComponentModel.PropertyChangedEventHandler PropertyChanged;
public virtual void OnPropertyChanged(string info) {
System.ComponentModel.PropertyChangedEventHandler handler = this.PropertyChanged;
if ((handler != null)) {
handler(this, new System.ComponentModel.PropertyChangedEventArgs(info));
}
}
#region Serialize/Deserialize
///
/// Serializes current SiteInformationSiteServerOperatingSystem object into an XML document
///
/// string XML value
public virtual string Serialize() {
System.IO.StreamReader streamReader = null;
System.IO.MemoryStream memoryStream = null;
try {
memoryStream = new System.IO.MemoryStream();
Serializer.Serialize(memoryStream, this);
memoryStream.Seek(0, System.IO.SeekOrigin.Begin);
streamReader = new System.IO.StreamReader(memoryStream);
return streamReader.ReadToEnd();
}
finally {
if ((streamReader != null)) {
streamReader.Dispose();
}
if ((memoryStream != null)) {
memoryStream.Dispose();
}
}
}
///
/// Deserializes workflow markup into an SiteInformationSiteServerOperatingSystem object
///
/// string workflow markup to deserialize
/// Output SiteInformationSiteServerOperatingSystem object
/// output Exception value if deserialize failed
/// true if this XmlSerializer can deserialize the object; otherwise, false
public static bool Deserialize(string xml, out SiteInformationSiteServerOperatingSystem obj, out System.Exception exception) {
exception = null;
obj = default(SiteInformationSiteServerOperatingSystem);
try {
obj = Deserialize(xml);
return true;
}
catch (System.Exception ex) {
exception = ex;
return false;
}
}
public static bool Deserialize(string xml, out SiteInformationSiteServerOperatingSystem obj) {
System.Exception exception = null;
return Deserialize(xml, out obj, out exception);
}
public static SiteInformationSiteServerOperatingSystem Deserialize(string xml) {
System.IO.StringReader stringReader = null;
try {
stringReader = new System.IO.StringReader(xml);
return ((SiteInformationSiteServerOperatingSystem)(Serializer.Deserialize(System.Xml.XmlReader.Create(stringReader))));
}
finally {
if ((stringReader != null)) {
stringReader.Dispose();
}
}
}
///
/// Serializes current SiteInformationSiteServerOperatingSystem object into file
///
/// full path of outupt xml file
/// output Exception value if failed
/// true if can serialize and save into file; otherwise, false
public virtual bool SaveToFile(string fileName, out System.Exception exception) {
exception = null;
try {
SaveToFile(fileName);
return true;
}
catch (System.Exception e) {
exception = e;
return false;
}
}
public virtual void SaveToFile(string fileName) {
System.IO.StreamWriter streamWriter = null;
try {
string xmlString = Serialize();
System.IO.FileInfo xmlFile = new System.IO.FileInfo(fileName);
streamWriter = xmlFile.CreateText();
streamWriter.WriteLine(xmlString);
streamWriter.Close();
}
finally {
if ((streamWriter != null)) {
streamWriter.Dispose();
}
}
}
///
/// Deserializes xml markup from file into an SiteInformationSiteServerOperatingSystem object
///
/// string xml file to load and deserialize
/// Output SiteInformationSiteServerOperatingSystem object
/// output Exception value if deserialize failed
/// true if this XmlSerializer can deserialize the object; otherwise, false
public static bool LoadFromFile(string fileName, out SiteInformationSiteServerOperatingSystem obj, out System.Exception exception) {
exception = null;
obj = default(SiteInformationSiteServerOperatingSystem);
try {
obj = LoadFromFile(fileName);
return true;
}
catch (System.Exception ex) {
exception = ex;
return false;
}
}
public static bool LoadFromFile(string fileName, out SiteInformationSiteServerOperatingSystem obj) {
System.Exception exception = null;
return LoadFromFile(fileName, out obj, out exception);
}
public static SiteInformationSiteServerOperatingSystem LoadFromFile(string fileName) {
System.IO.FileStream file = null;
System.IO.StreamReader sr = null;
try {
file = new System.IO.FileStream(fileName, FileMode.Open, FileAccess.Read);
sr = new System.IO.StreamReader(file);
string xmlString = sr.ReadToEnd();
sr.Close();
file.Close();
return Deserialize(xmlString);
}
finally {
if ((file != null)) {
file.Dispose();
}
if ((sr != null)) {
sr.Dispose();
}
}
}
#endregion
#region Clone method
///
/// Create a clone of this SiteInformationSiteServerOperatingSystem object
///
public virtual SiteInformationSiteServerOperatingSystem Clone() {
return ((SiteInformationSiteServerOperatingSystem)(this.MemberwiseClone()));
}
#endregion
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("Xsd2Code", "3.3.0.33572")]
[System.SerializableAttribute()]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
[System.Xml.Serialization.XmlTypeAttribute(AnonymousType=true)]
public partial class SiteInformationStatistics : System.ComponentModel.INotifyPropertyChanged {
[EditorBrowsable(EditorBrowsableState.Never)]
private string adminOperationsQueueCountField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string clientOperationsQueueCountField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string siteOperationsQueueCountField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string averageOperationTimeField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string cpuUtilizationField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string totalOperationTimeField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string activeConnectionsField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string totalConnectionsField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string totalOperationsProcessedField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string totalOperationsReceivedField;
[EditorBrowsable(EditorBrowsableState.Never)]
private string uptimeField;
private static System.Xml.Serialization.XmlSerializer serializer;
[System.Xml.Serialization.XmlElementAttribute(DataType="integer")]
public string AdminOperationsQueueCount {
get {
return this.adminOperationsQueueCountField;
}
set {
if ((this.adminOperationsQueueCountField != null)) {
if ((adminOperationsQueueCountField.Equals(value) != true)) {
this.adminOperationsQueueCountField = value;
this.OnPropertyChanged("AdminOperationsQueueCount");
}
}
else {
this.adminOperationsQueueCountField = value;
this.OnPropertyChanged("AdminOperationsQueueCount");
}
}
}
[System.Xml.Serialization.XmlElementAttribute(DataType="integer")]
public string ClientOperationsQueueCount {
get {
return this.clientOperationsQueueCountField;
}
set {
if ((this.clientOperationsQueueCountField != null)) {
if ((clientOperationsQueueCountField.Equals(value) != true)) {
this.clientOperationsQueueCountField = value;
this.OnPropertyChanged("ClientOperationsQueueCount");
}
}
else {
this.clientOperationsQueueCountField = value;
this.OnPropertyChanged("ClientOperationsQueueCount");
}
}
}
[System.Xml.Serialization.XmlElementAttribute(DataType="integer")]
public string SiteOperationsQueueCount {
get {
return this.siteOperationsQueueCountField;
}
set {
if ((this.siteOperationsQueueCountField != null)) {
if ((siteOperationsQueueCountField.Equals(value) != true)) {
this.siteOperationsQueueCountField = value;
this.OnPropertyChanged("SiteOperationsQueueCount");
}
}
else {
this.siteOperationsQueueCountField = value;
this.OnPropertyChanged("SiteOperationsQueueCount");
}
}
}
[System.Xml.Serialization.XmlElementAttribute(DataType="integer")]
public string AverageOperationTime {
get {
return this.averageOperationTimeField;
}
set {
if ((this.averageOperationTimeField != null)) {
if ((averageOperationTimeField.Equals(value) != true)) {
this.averageOperationTimeField = value;
this.OnPropertyChanged("AverageOperationTime");
}
}
else {
this.averageOperationTimeField = value;
this.OnPropertyChanged("AverageOperationTime");
}
}
}
[System.Xml.Serialization.XmlElementAttribute(DataType="integer")]
public string CpuUtilization {
get {
return this.cpuUtilizationField;
}
set {
if ((this.cpuUtilizationField != null)) {
if ((cpuUtilizationField.Equals(value) != true)) {
this.cpuUtilizationField = value;
this.OnPropertyChanged("CpuUtilization");
}
}
else {
this.cpuUtilizationField = value;
this.OnPropertyChanged("CpuUtilization");
}
}
}
[System.Xml.Serialization.XmlElementAttribute(DataType="integer")]
public string TotalOperationTime {
get {
return this.totalOperationTimeField;
}
set {
if ((this.totalOperationTimeField != null)) {
if ((totalOperationTimeField.Equals(value) != true)) {
this.totalOperationTimeField = value;
this.OnPropertyChanged("TotalOperationTime");
}
}
else {
this.totalOperationTimeField = value;
this.OnPropertyChanged("TotalOperationTime");
}
}
}
[System.Xml.Serialization.XmlElementAttribute(DataType="integer")]
public string ActiveConnections {
get {
return this.activeConnectionsField;
}
set {
if ((this.activeConnectionsField != null)) {
if ((activeConnectionsField.Equals(value) != true)) {
this.activeConnectionsField = value;
this.OnPropertyChanged("ActiveConnections");
}
}
else {
this.activeConnectionsField = value;
this.OnPropertyChanged("ActiveConnections");
}
}
}
[System.Xml.Serialization.XmlElementAttribute(DataType="integer")]
public string TotalConnections {
get {
return this.totalConnectionsField;
}
set {
if ((this.totalConnectionsField != null)) {
if ((totalConnectionsField.Equals(value) != true)) {
this.totalConnectionsField = value;
this.OnPropertyChanged("TotalConnections");
}
}
else {
this.totalConnectionsField = value;
this.OnPropertyChanged("TotalConnections");
}
}
}
[System.Xml.Serialization.XmlElementAttribute(DataType="integer")]
public string TotalOperationsProcessed {
get {
return this.totalOperationsProcessedField;
}
set {
if ((this.totalOperationsProcessedField != null)) {
if ((totalOperationsProcessedField.Equals(value) != true)) {
this.totalOperationsProcessedField = value;
this.OnPropertyChanged("TotalOperationsProcessed");
}
}
else {
this.totalOperationsProcessedField = value;
this.OnPropertyChanged("TotalOperationsProcessed");
}
}
}
[System.Xml.Serialization.XmlElementAttribute(DataType="integer")]
public string TotalOperationsReceived {
get {
return this.totalOperationsReceivedField;
}
set {
if ((this.totalOperationsReceivedField != null)) {
if ((totalOperationsReceivedField.Equals(value) != true)) {
this.totalOperationsReceivedField = value;
this.OnPropertyChanged("TotalOperationsReceived");
}
}
else {
this.totalOperationsReceivedField = value;
this.OnPropertyChanged("TotalOperationsReceived");
}
}
}
[System.Xml.Serialization.XmlElementAttribute(DataType="integer")]
public string Uptime {
get {
return this.uptimeField;
}
set {
if ((this.uptimeField != null)) {
if ((uptimeField.Equals(value) != true)) {
this.uptimeField = value;
this.OnPropertyChanged("Uptime");
}
}
else {
this.uptimeField = value;
this.OnPropertyChanged("Uptime");
}
}
}
private static System.Xml.Serialization.XmlSerializer Serializer {
get {
if ((serializer == null)) {
serializer = new System.Xml.Serialization.XmlSerializer(typeof(SiteInformationStatistics));
}
return serializer;
}
}
public event System.ComponentModel.PropertyChangedEventHandler PropertyChanged;
public virtual void OnPropertyChanged(string info) {
System.ComponentModel.PropertyChangedEventHandler handler = this.PropertyChanged;
if ((handler != null)) {
handler(this, new System.ComponentModel.PropertyChangedEventArgs(info));
}
}
#region Serialize/Deserialize
///
/// Serializes current SiteInformationStatistics object into an XML document
///
/// string XML value
public virtual string Serialize() {
System.IO.StreamReader streamReader = null;
System.IO.MemoryStream memoryStream = null;
try {
memoryStream = new System.IO.MemoryStream();
Serializer.Serialize(memoryStream, this);
memoryStream.Seek(0, System.IO.SeekOrigin.Begin);
streamReader = new System.IO.StreamReader(memoryStream);
return streamReader.ReadToEnd();
}
finally {
if ((streamReader != null)) {
streamReader.Dispose();
}
if ((memoryStream != null)) {
memoryStream.Dispose();
}
}
}
///
/// Deserializes workflow markup into an SiteInformationStatistics object
///
/// string workflow markup to deserialize
/// Output SiteInformationStatistics object
/// output Exception value if deserialize failed
/// true if this XmlSerializer can deserialize the object; otherwise, false
public static bool Deserialize(string xml, out SiteInformationStatistics obj, out System.Exception exception) {
exception = null;
obj = default(SiteInformationStatistics);
try {
obj = Deserialize(xml);
return true;
}
catch (System.Exception ex) {
exception = ex;
return false;
}
}
public static bool Deserialize(string xml, out SiteInformationStatistics obj) {
System.Exception exception = null;
return Deserialize(xml, out obj, out exception);
}
public static SiteInformationStatistics Deserialize(string xml) {
System.IO.StringReader stringReader = null;
try {
stringReader = new System.IO.StringReader(xml);
return ((SiteInformationStatistics)(Serializer.Deserialize(System.Xml.XmlReader.Create(stringReader))));
}
finally {
if ((stringReader != null)) {
stringReader.Dispose();
}
}
}
///
/// Serializes current SiteInformationStatistics object into file
///
/// full path of outupt xml file
/// output Exception value if failed
/// true if can serialize and save into file; otherwise, false
public virtual bool SaveToFile(string fileName, out System.Exception exception) {
exception = null;
try {
SaveToFile(fileName);
return true;
}
catch (System.Exception e) {
exception = e;
return false;
}
}
public virtual void SaveToFile(string fileName) {
System.IO.StreamWriter streamWriter = null;
try {
string xmlString = Serialize();
System.IO.FileInfo xmlFile = new System.IO.FileInfo(fileName);
streamWriter = xmlFile.CreateText();
streamWriter.WriteLine(xmlString);
streamWriter.Close();
}
finally {
if ((streamWriter != null)) {
streamWriter.Dispose();
}
}
}
///
/// Deserializes xml markup from file into an SiteInformationStatistics object
///
/// string xml file to load and deserialize
/// Output SiteInformationStatistics object
/// output Exception value if deserialize failed
/// true if this XmlSerializer can deserialize the object; otherwise, false
public static bool LoadFromFile(string fileName, out SiteInformationStatistics obj, out System.Exception exception) {
exception = null;
obj = default(SiteInformationStatistics);
try {
obj = LoadFromFile(fileName);
return true;
}
catch (System.Exception ex) {
exception = ex;
return false;
}
}
public static bool LoadFromFile(string fileName, out SiteInformationStatistics obj) {
System.Exception exception = null;
return LoadFromFile(fileName, out obj, out exception);
}
public static SiteInformationStatistics LoadFromFile(string fileName) {
System.IO.FileStream file = null;
System.IO.StreamReader sr = null;
try {
file = new System.IO.FileStream(fileName, FileMode.Open, FileAccess.Read);
sr = new System.IO.StreamReader(file);
string xmlString = sr.ReadToEnd();
sr.Close();
file.Close();
return Deserialize(xmlString);
}
finally {
if ((file != null)) {
file.Dispose();
}
if ((sr != null)) {
sr.Dispose();
}
}
}
#endregion
#region Clone method
///
/// Create a clone of this SiteInformationStatistics object
///
public virtual SiteInformationStatistics Clone() {
return ((SiteInformationStatistics)(this.MemberwiseClone()));
}
#endregion
}
}