Click here to Skip to main content
11,408,708 members (64,164 online)
Click here to Skip to main content
Add your own
alternative version

The platform-independent code with Mono: Client-server application sample

, 24 Mar 2010 CPOL
This article shows how we can develop the platform-independent software with Mono usage
InfoCenter.zip
InfoCenter
ConfigSamples
InfoCenter.Agent
Agent.pidb
Agent.userprefs
bin
Debug
Agent.exe
Agent.exe.mdb
Agent.pdb
Entities
Helpers
ObjectSerializer.cs~
obj
x86
Debug
TempPE
Service
InfoCenterService.wsdl
InfoCenter.Logic
Agent
Entities
Helpers
bin
Debug
Antlr3.Runtime.dll
Iesi.Collections.dll
InfoCenter.Logic.dll
InfoCenter.Logic.dll.mdb
InfoCenter.Logic.pdb
InfoCenter.Persistence.dll
InfoCenter.Persistence.dll.mdb
InfoCenter.Persistence.pdb
log4net.dll
Release
InfoCenter.Logic.pidb
obj
Debug
InfoCenter.Logic.dll
InfoCenter.Logic.pdb
ResolveAssemblyReference.cache
TempPE
Properties
InfoCenter.Logic.Tests
bin
Debug
Antlr3.Runtime.dll
Castle.Core.dll
Castle.DynamicProxy2.dll
Iesi.Collections.dll
InfoCenter.Logic.dll
InfoCenter.Logic.dll.mdb
InfoCenter.Logic.pdb
InfoCenter.Logic.Tests.dll
InfoCenter.Logic.Tests.dll.mdb
InfoCenter.Logic.Tests.pdb
InfoCenter.Persistence.dll
InfoCenter.Persistence.dll.mdb
InfoCenter.Persistence.pdb
log4net.dll
MySql.Data.dll
NHibernate.ByteCode.Castle.dll
nunit.framework.dll
Release
InfoCenter.Logic.Tests.pidb
obj
Debug
InfoCenter.Logic.Tests.dll
InfoCenter.Logic.Tests.pdb
ResolveAssemblyReference.cache
TempPE
Properties
test-results
InfoCenter.Logic.Tests.csproj.test-cache
InfoCenter.Persistence
bin
Debug
Antlr3.Runtime.dll
Iesi.Collections.dll
InfoCenter.Persistence.dll
InfoCenter.Persistence.dll.mdb
InfoCenter.Persistence.pdb
log4net.dll
Release
Core
Entities
InfoCenter.Persistence.pidb
Mapping
obj
Debug
InfoCenter.Persistence.dll
InfoCenter.Persistence.pdb
ResolveAssemblyReference.cache
TempPE
Properties
InfoCenter.Persistence.Test
bin
Debug
Antlr3.Runtime.dll
Castle.Core.dll
Castle.DynamicProxy2.dll
Iesi.Collections.dll
InfoCenter.Persistence.dll
InfoCenter.Persistence.dll.mdb
InfoCenter.Persistence.pdb
InfoCenter.Persistence.Tests.dll
InfoCenter.Persistence.Tests.dll.mdb
InfoCenter.Persistence.Tests.pdb
log4net.dll
MySql.Data.dll
NHibernate.ByteCode.Castle.dll
NHibernate.dll
nunit.framework.dll
Release
InfoCenter.Persistence.Tests.pidb
obj
Debug
InfoCenter.Persistence.Test.dll
InfoCenter.Persistence.Test.pdb
InfoCenter.Persistence.Tests.dll
InfoCenter.Persistence.Tests.pdb
ResolveAssemblyReference.cache
TempPE
Properties
test-results
InfoCenter.Persistence.Tests.csproj.test-cache
InfoCenter.userprefs
InfoCenter.WebConsole
bin
Antlr3.Runtime.dll
Castle.Core.dll
Castle.DynamicProxy2.dll
Iesi.Collections.dll
InfoCenter.Logic.dll
InfoCenter.Logic.dll.mdb
InfoCenter.Logic.pdb
InfoCenter.Persistence.dll
InfoCenter.Persistence.dll.mdb
InfoCenter.Persistence.pdb
InfoCenter.WebConsole.dll
InfoCenter.WebConsole.dll.mdb
InfoCenter.WebConsole.pdb
log4net.dll
MySql.Data.dll
NHibernate.ByteCode.Castle.dll
Global.asax
InfoCenter.WebConsole.pidb
InfoCenter.WebConsole.userprefs
SharedLibs
Antlr3.Runtime.dll
Castle.Core.dll
Castle.DynamicProxy2.dll
Iesi.Collections.dll
log4net.dll
MySql.Data.dll
NHibernate.ByteCode.Castle.dll
NHibernate.dll
nunit.framework.dll
test-results
// ------------------------------------------------------------------------------
//  <autogenerated>
//      This code was generated by a tool.
//      Mono Runtime Version: 2.0.50727.1433
// 
//      Changes to this file may cause incorrect behavior and will be lost if 
//      the code is regenerated.
//  </autogenerated>
// ------------------------------------------------------------------------------

// 
// This source code was auto-generated by Web Services Description Language Utility
//Mono Framework v2.0.50727.1433
//


/// <remarks/>
[System.Web.Services.WebServiceBinding(Name="InfoCenterServiceSoap", Namespace="http://tempuri.org/")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class InfoCenterService : System.Web.Services.Protocols.SoapHttpClientProtocol {
    
    private System.Threading.SendOrPostCallback AddInfoOperationCompleted;
    
    private System.Threading.SendOrPostCallback AddProcessesOperationCompleted;
    
    public InfoCenterService() {
        this.Url = "http://localhost/InfoCenter/InfoCenterService.asmx";
    }
    
    public event AddInfoCompletedEventHandler AddInfoCompleted;
    
    public event AddProcessesCompletedEventHandler AddProcessesCompleted;
    
    /// <remarks>
///This method insert information about computer
///</remarks>
    [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/AddInfo", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped, Use=System.Web.Services.Description.SoapBindingUse.Literal)]
    public void AddInfo(string compressedXml) {
        this.Invoke("AddInfo", new object[] {
                    compressedXml});
    }
    
    public System.IAsyncResult BeginAddInfo(string compressedXml, System.AsyncCallback callback, object asyncState) {
        return this.BeginInvoke("AddInfo", new object[] {
                    compressedXml}, callback, asyncState);
    }
    
    public void EndAddInfo(System.IAsyncResult asyncResult) {
        this.EndInvoke(asyncResult);
    }
    
    public void AddInfoAsync(string compressedXml) {
        this.AddInfoAsync(compressedXml, null);
    }
    
    public void AddInfoAsync(string compressedXml, object userState) {
        if ((this.AddInfoOperationCompleted == null)) {
            this.AddInfoOperationCompleted = new System.Threading.SendOrPostCallback(this.OnAddInfoCompleted);
        }
        this.InvokeAsync("AddInfo", new object[] {
                    compressedXml}, this.AddInfoOperationCompleted, userState);
    }
    
    private void OnAddInfoCompleted(object arg) {
        if ((this.AddInfoCompleted != null)) {
            System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
            this.AddInfoCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
        }
    }
    
    /// <remarks>
///This method insert processes from a computer
///</remarks>
    [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/AddProcesses", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped, Use=System.Web.Services.Description.SoapBindingUse.Literal)]
    public void AddProcesses(string compName, string compressedXml) {
        this.Invoke("AddProcesses", new object[] {
                    compName,
                    compressedXml});
    }
    
    public System.IAsyncResult BeginAddProcesses(string compName, string compressedXml, System.AsyncCallback callback, object asyncState) {
        return this.BeginInvoke("AddProcesses", new object[] {
                    compName,
                    compressedXml}, callback, asyncState);
    }
    
    public void EndAddProcesses(System.IAsyncResult asyncResult) {
        this.EndInvoke(asyncResult);
    }
    
    public void AddProcessesAsync(string compName, string compressedXml) {
        this.AddProcessesAsync(compName, compressedXml, null);
    }
    
    public void AddProcessesAsync(string compName, string compressedXml, object userState) {
        if ((this.AddProcessesOperationCompleted == null)) {
            this.AddProcessesOperationCompleted = new System.Threading.SendOrPostCallback(this.OnAddProcessesCompleted);
        }
        this.InvokeAsync("AddProcesses", new object[] {
                    compName,
                    compressedXml}, this.AddProcessesOperationCompleted, userState);
    }
    
    private void OnAddProcessesCompleted(object arg) {
        if ((this.AddProcessesCompleted != null)) {
            System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
            this.AddProcessesCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
        }
    }
}

public delegate void AddInfoCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs args);

public delegate void AddProcessesCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs args);

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

Ilya Builuk
Software Developer (Senior) Nokia
Germany Germany
Interested in design/development of framework functionality using the best patterns and practices.

| Advertise | Privacy | Terms of Use | Mobile
Web03 | 2.8.150414.5 | Last Updated 24 Mar 2010
Article Copyright 2010 by Ilya Builuk
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid