Documente Academic
Documente Profesional
Documente Cultură
model_internal::initialize();
}
public function agregarCabecera(username:String,password:String):XML{
var x:XML=
<wsse:Security xmlns:wsse={wsse}>
<wsse:UsernameToken xmlns:wsse={wsse}>
<wsse:Username xmlns:wss
e={wsse}>{username}</wsse:Username>
<wsse:Password xmlns:wss
e={wsse}>{password}</wsse:Password>
</wsse:UsernameToken>
</wsse:Security>
return x;
}
public function agregarCabecera2(username:String,password:String):XML{
var x:XML=
<soapenv:Header xmlns:soapenv="http://schemas.xmlsoap.or
g/soap/envelope/" xmlns:ser="http://service.sunat.gob.pe" xmlns:wsse="http://doc
s.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd">
<wsse:Security xmlns:wsse={wsse}>
<wsse:UsernameToken xmlns:wsse={wsse}>
<wsse:Username x
mlns:wsse={wsse}>{username}</wsse:Username>
<wsse:Password x
mlns:wsse={wsse}>{password}</wsse:Password>
</wsse:UsernameToken>
</wsse:Security>
</soapenv:Header>
return x;
}
/**
* This method is a generated wrapper used to call the 'sendBill' opera
tion. It returns an mx.rpc.AsyncToken whose
* result property will be populated with the result of the operation w
hen the server response is received.
* To use this result from MXML code, define a CallResponder component
and assign its token property to this method's return value.
* You can then bind to CallResponder.lastResult or listen for the Call
Responder.result or fault events.
*
* @see mx.rpc.AsyncToken
* @see mx.rpc.CallResponder
*
* @return an mx.rpc.AsyncToken whose result property will be populated wit
h the result of the operation when the server response is received.
*/
public function sendBill(fileName:String, contentFile:ByteArray) : mx.rp
c.AsyncToken
{
model_internal::loadWSDLIfNecessary();
var _internal_operation:mx.rpc.AbstractOperation = _serviceContr
ol.getOperation("sendBill");
var _internal_token:mx.rpc.AsyncToken = _internal_operation.send
(fileName,contentFile) ;
return _internal_token;
}
}
}