Search in sources :

Example 21 with PropertyInfo

use of org.ksoap2.serialization.PropertyInfo in project ETSMobile-Android2 by ApplETS.

the class SignetsMobileSoap method echo.

public String echo(final String chaine) throws Exception {
    return (String) execute(new IWcfMethod() {

        @Override
        public ExtendedSoapSerializationEnvelope CreateSoapEnvelope() {
            ExtendedSoapSerializationEnvelope __envelope = createEnvelope();
            SoapObject __soapReq = new SoapObject("http://etsmtl.ca/", "echo");
            __envelope.setOutputSoapObject(__soapReq);
            PropertyInfo __info = null;
            __info = new PropertyInfo();
            __info.namespace = "http://etsmtl.ca/";
            __info.name = "chaine";
            __info.type = PropertyInfo.STRING_CLASS;
            __info.setValue(chaine);
            __soapReq.addProperty(__info);
            return __envelope;
        }

        @Override
        public Object ProcessResult(ExtendedSoapSerializationEnvelope __envelope, SoapObject __result) throws Exception {
            Object obj = __result.getProperty("echoResult");
            if (obj != null && obj.getClass().equals(SoapPrimitive.class)) {
                SoapPrimitive j = (SoapPrimitive) __result.getProperty("echoResult");
                return j.toString();
            }
            return null;
        }
    }, "http://etsmtl.ca/echo");
}
Also used : SoapObject(org.ksoap2.serialization.SoapObject) SoapObject(org.ksoap2.serialization.SoapObject) PropertyInfo(org.ksoap2.serialization.PropertyInfo) SoapPrimitive(org.ksoap2.serialization.SoapPrimitive)

Example 22 with PropertyInfo

use of org.ksoap2.serialization.PropertyInfo in project ETSMobile-Android2 by ApplETS.

the class SignetsMobileSoap method HelloWorld.

public String HelloWorld() throws Exception {
    return (String) execute(new IWcfMethod() {

        @Override
        public ExtendedSoapSerializationEnvelope CreateSoapEnvelope() {
            ExtendedSoapSerializationEnvelope __envelope = createEnvelope();
            SoapObject __soapReq = new SoapObject("http://etsmtl.ca/", "HelloWorld");
            __envelope.setOutputSoapObject(__soapReq);
            PropertyInfo __info = null;
            return __envelope;
        }

        @Override
        public Object ProcessResult(ExtendedSoapSerializationEnvelope __envelope, SoapObject __result) throws Exception {
            Object obj = __result.getProperty("HelloWorldResult");
            if (obj != null && obj.getClass().equals(SoapPrimitive.class)) {
                SoapPrimitive j = (SoapPrimitive) __result.getProperty("HelloWorldResult");
                return j.toString();
            }
            return null;
        }
    }, "http://etsmtl.ca/HelloWorld");
}
Also used : SoapObject(org.ksoap2.serialization.SoapObject) SoapObject(org.ksoap2.serialization.SoapObject) PropertyInfo(org.ksoap2.serialization.PropertyInfo) SoapPrimitive(org.ksoap2.serialization.SoapPrimitive)

Example 23 with PropertyInfo

use of org.ksoap2.serialization.PropertyInfo in project ETSMobile-Android2 by ApplETS.

the class SignetsMobileSoap method infoEtudiant.

/**
	 * Information de base sur l'��tudiant: nom, pr��nom, code permanent, solde
	 */
public Etudiant infoEtudiant(final String codeAccesUniversel, final String motPasse) throws Exception {
    return (Etudiant) execute(new IWcfMethod() {

        @Override
        public ExtendedSoapSerializationEnvelope CreateSoapEnvelope() {
            ExtendedSoapSerializationEnvelope __envelope = createEnvelope();
            SoapObject __soapReq = new SoapObject("http://etsmtl.ca/", "infoEtudiant");
            __envelope.setOutputSoapObject(__soapReq);
            PropertyInfo __info = null;
            __info = new PropertyInfo();
            __info.namespace = "http://etsmtl.ca/";
            __info.name = "codeAccesUniversel";
            __info.type = PropertyInfo.STRING_CLASS;
            __info.setValue(codeAccesUniversel);
            __soapReq.addProperty(__info);
            __info = new PropertyInfo();
            __info.namespace = "http://etsmtl.ca/";
            __info.name = "motPasse";
            __info.type = PropertyInfo.STRING_CLASS;
            __info.setValue(motPasse);
            __soapReq.addProperty(__info);
            return __envelope;
        }

        @Override
        public Object ProcessResult(ExtendedSoapSerializationEnvelope __envelope, SoapObject __result) throws Exception {
            return (Etudiant) getResult(Etudiant.class, __result, "infoEtudiantResult", __envelope);
        }
    }, "http://etsmtl.ca/infoEtudiant");
}
Also used : Etudiant(ca.etsmtl.applets.etsmobile.model.Etudiant) SoapObject(org.ksoap2.serialization.SoapObject) PropertyInfo(org.ksoap2.serialization.PropertyInfo)

Example 24 with PropertyInfo

use of org.ksoap2.serialization.PropertyInfo in project ETSMobile-Android2 by ApplETS.

the class WebServiceSoap method GetFicheData.

public FicheEmploye GetFicheData(final String Id) throws Exception {
    return (FicheEmploye) execute(new IWcfMethod() {

        @Override
        public ExtendedSoapSerializationEnvelope CreateSoapEnvelope() {
            ExtendedSoapSerializationEnvelope __envelope = createEnvelope();
            SoapObject __soapReq = new SoapObject("http://etsmtl.ca/", "GetFicheData");
            __envelope.setOutputSoapObject(__soapReq);
            PropertyInfo __info = null;
            __info = new PropertyInfo();
            __info.namespace = "http://etsmtl.ca/";
            __info.name = "Id";
            __info.type = PropertyInfo.STRING_CLASS;
            __info.setValue(Id);
            __soapReq.addProperty(__info);
            return __envelope;
        }

        @Override
        public Object ProcessResult(ExtendedSoapSerializationEnvelope __envelope, SoapObject __result) throws Exception {
            return (FicheEmploye) getResult(FicheEmploye.class, __result, "GetFicheDataResult", __envelope);
        }
    }, "http://etsmtl.ca/GetFicheData");
}
Also used : SoapObject(org.ksoap2.serialization.SoapObject) ArrayOfFicheEmploye(ca.etsmtl.applets.etsmobile.model.ArrayOfFicheEmploye) FicheEmploye(ca.etsmtl.applets.etsmobile.model.FicheEmploye) PropertyInfo(org.ksoap2.serialization.PropertyInfo)

Aggregations

PropertyInfo (org.ksoap2.serialization.PropertyInfo)23 SoapObject (org.ksoap2.serialization.SoapObject)22 SoapPrimitive (org.ksoap2.serialization.SoapPrimitive)4 ArrayOfFicheEmploye (ca.etsmtl.applets.etsmobile.model.ArrayOfFicheEmploye)2 ListeDeCours (ca.etsmtl.applets.etsmobile.model.ListeDeCours)2 ArrayOfFicheEmployeDate (ca.etsmtl.applets.etsmobile.model.ArrayOfFicheEmployeDate)1 ArrayOfService (ca.etsmtl.applets.etsmobile.model.ArrayOfService)1 Etudiant (ca.etsmtl.applets.etsmobile.model.Etudiant)1 FicheEmploye (ca.etsmtl.applets.etsmobile.model.FicheEmploye)1 ListeDeSessions (ca.etsmtl.applets.etsmobile.model.ListeDeSessions)1 ListeDesElementsEvaluation (ca.etsmtl.applets.etsmobile.model.ListeDesElementsEvaluation)1 ca.etsmtl.applets.etsmobile.model.listeCoursHoraire (ca.etsmtl.applets.etsmobile.model.listeCoursHoraire)1 ca.etsmtl.applets.etsmobile.model.listeDesActivitesEtProf (ca.etsmtl.applets.etsmobile.model.listeDesActivitesEtProf)1 ca.etsmtl.applets.etsmobile.model.listeDesCoequipiers (ca.etsmtl.applets.etsmobile.model.listeDesCoequipiers)1 ca.etsmtl.applets.etsmobile.model.listeDesProgrammes (ca.etsmtl.applets.etsmobile.model.listeDesProgrammes)1 ca.etsmtl.applets.etsmobile.model.listeHoraireExamensFinaux (ca.etsmtl.applets.etsmobile.model.listeHoraireExamensFinaux)1 ca.etsmtl.applets.etsmobile.model.listeJoursRemplaces (ca.etsmtl.applets.etsmobile.model.listeJoursRemplaces)1 ca.etsmtl.applets.etsmobile.model.listeSeances (ca.etsmtl.applets.etsmobile.model.listeSeances)1 InvocationTargetException (java.lang.reflect.InvocationTargetException)1 Method (java.lang.reflect.Method)1