Type.registerNamespace('bokCM.Services');
bokCM.Services.EmailGateway=function() {
bokCM.Services.EmailGateway.initializeBase(this);
this._timeout = 0;
this._userContext = null;
this._succeeded = null;
this._failed = null;
}
bokCM.Services.EmailGateway.prototype={
_get_path:function() {
 var p = this.get_path();
 if (p) return p;
 else return bokCM.Services.EmailGateway._staticInstance.get_path();},
SendEmail:function(mail,succeededCallback, failedCallback, userContext) {
/// <param name="mail" type="bokCM.Objects.MailItem">bokCM.Objects.MailItem</param>
/// <param name="succeededCallback" type="Function" optional="true" mayBeNull="true"></param>
/// <param name="failedCallback" type="Function" optional="true" mayBeNull="true"></param>
/// <param name="userContext" optional="true" mayBeNull="true"></param>
return this._invoke(this._get_path(), 'SendEmail',false,{mail:mail},succeededCallback,failedCallback,userContext); }}
bokCM.Services.EmailGateway.registerClass('bokCM.Services.EmailGateway',Sys.Net.WebServiceProxy);
bokCM.Services.EmailGateway._staticInstance = new bokCM.Services.EmailGateway();
bokCM.Services.EmailGateway.set_path = function(value) {
bokCM.Services.EmailGateway._staticInstance.set_path(value); }
bokCM.Services.EmailGateway.get_path = function() { 
/// <value type="String" mayBeNull="true">The service url.</value>
return bokCM.Services.EmailGateway._staticInstance.get_path();}
bokCM.Services.EmailGateway.set_timeout = function(value) {
bokCM.Services.EmailGateway._staticInstance.set_timeout(value); }
bokCM.Services.EmailGateway.get_timeout = function() { 
/// <value type="Number">The service timeout.</value>
return bokCM.Services.EmailGateway._staticInstance.get_timeout(); }
bokCM.Services.EmailGateway.set_defaultUserContext = function(value) { 
bokCM.Services.EmailGateway._staticInstance.set_defaultUserContext(value); }
bokCM.Services.EmailGateway.get_defaultUserContext = function() { 
/// <value mayBeNull="true">The service default user context.</value>
return bokCM.Services.EmailGateway._staticInstance.get_defaultUserContext(); }
bokCM.Services.EmailGateway.set_defaultSucceededCallback = function(value) { 
 bokCM.Services.EmailGateway._staticInstance.set_defaultSucceededCallback(value); }
bokCM.Services.EmailGateway.get_defaultSucceededCallback = function() { 
/// <value type="Function" mayBeNull="true">The service default succeeded callback.</value>
return bokCM.Services.EmailGateway._staticInstance.get_defaultSucceededCallback(); }
bokCM.Services.EmailGateway.set_defaultFailedCallback = function(value) { 
bokCM.Services.EmailGateway._staticInstance.set_defaultFailedCallback(value); }
bokCM.Services.EmailGateway.get_defaultFailedCallback = function() { 
/// <value type="Function" mayBeNull="true">The service default failed callback.</value>
return bokCM.Services.EmailGateway._staticInstance.get_defaultFailedCallback(); }
bokCM.Services.EmailGateway.set_path("/services/EmailGateway.asmx");
bokCM.Services.EmailGateway.SendEmail= function(mail,onSuccess,onFailed,userContext) {
/// <param name="mail" type="bokCM.Objects.MailItem">bokCM.Objects.MailItem</param>
/// <param name="succeededCallback" type="Function" optional="true" mayBeNull="true"></param>
/// <param name="failedCallback" type="Function" optional="true" mayBeNull="true"></param>
/// <param name="userContext" optional="true" mayBeNull="true"></param>
bokCM.Services.EmailGateway._staticInstance.SendEmail(mail,onSuccess,onFailed,userContext); }
var gtc = Sys.Net.WebServiceProxy._generateTypedConstructor;
Type.registerNamespace('bokCM.Objects');
if (typeof(bokCM.Objects.MailItem) === 'undefined') {
bokCM.Objects.MailItem=gtc("bokCM.Objects.MailItem");
bokCM.Objects.MailItem.registerClass('bokCM.Objects.MailItem');
}
