Package net.opengis.wps10

Examples of net.opengis.wps10.DescriptionType


    }
   
    void processOutputs( ProcessOutputsType outputs, ProcessFactory pf, Name name) {
        Map<String,Parameter<?>> outs = pf.getResultInfo(name, null);
        for ( Parameter p : outs.values() ) {
            OutputDescriptionType output = wpsf.createOutputDescriptionType();
            outputs.getOutput().add( output );
           
            output.setIdentifier( Ows11Util.code( p.key ) );
            output.setTitle( Ows11Util.languageString( p.title ) );
           
            List<ProcessParameterIO> ppios = ProcessParameterIO.findAll( p, context);
            if ( ppios.isEmpty() ) {
                throw new WPSException( "Could not find process parameter for type " + p.key + "," + p.type );
            }
           
            //handle the literal case
            if ( ppios.size() == 1 && ppios.get( 0 ) instanceof LiteralPPIO ) {
                LiteralPPIO lppio = (LiteralPPIO) ppios.get( 0 );
               
                LiteralOutputType literal = wpsf.createLiteralOutputType();
                output.setLiteralOutput(literal);
               
                //map the java class to an xml type name
                if ( !String.class.equals( lppio.getType() ) ) {
                    Name typeName = xsp.name( lppio.getType() );
                    if ( typeName != null ) {
                        literal.setDataType( Ows11Util.type( typeName.getLocalPart() ) );       
                    }   
                }
            }
            else {
                //handle the complex data case
                SupportedComplexDataType complex = wpsf.createSupportedComplexDataType();
                output.setComplexOutput( complex );
               
                complex.setSupported( wpsf.createComplexDataCombinationsType() );
                for ( ProcessParameterIO ppio : ppios ) {
                    ComplexPPIO cppio = (ComplexPPIO) ppio;
View Full Code Here


            final Object o = result.get( key );
            ProcessParameterIO ppio = ppios.get( key );
           
            if ( ppio instanceof ReferencePPIO ) {
                //encode as a reference
                OutputReferenceType ref = f.createOutputReferenceType();
                output.setReference( ref );
               
                //TODO: mime type
                ref.setHref( ((ReferencePPIO) ppio).encode(o).toString() );
            }
            else {
                //encode as data
                DataType data = f.createDataType();
                output.setData( data );
View Full Code Here

     * <!-- begin-user-doc -->
     * <!-- end-user-doc -->
     * @generated
     */
    public NotificationChain basicSetReference(OutputReferenceType newReference, NotificationChain msgs) {
        OutputReferenceType oldReference = reference;
        reference = newReference;
        if (eNotificationRequired()) {
            ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, Wps10Package.OUTPUT_DATA_TYPE__REFERENCE, oldReference, newReference);
            if (msgs == null) msgs = notification; else msgs.add(notification);
        }
View Full Code Here

        ExecuteResponseType response = f.createExecuteResponseType();
        response.setLang("en");
        response.setServiceInstance(ResponseUtils.appendQueryString(ResponseUtils.buildURL(request.getBaseUrl(), "ows", null, URLType.SERVICE), ""));
      
        //process
        final ProcessBriefType process = f.createProcessBriefType();
        response.setProcess( process );
        process.setIdentifier(ct);
        process.setProcessVersion(pf.getVersion(processName));
        process.setTitle( Ows11Util.languageString( pf.getTitle(processName).toString() ) );
        process.setAbstract( Ows11Util.languageString( pf.getDescription(processName).toString() ) );
      
        //status
        response.setStatus( f.createStatusType() );
        response.getStatus().setCreationTime( Converters.convert( started, XMLGregorianCalendar.class ));
       
View Full Code Here

        ProcessOfferingsType po = wpsf.createProcessOfferingsType();
        caps.setProcessOfferings( po );
       
        for(ProcessFactory pf : Processors.getProcessFactories()) {
            for (Name name : pf.getNames()) {
                ProcessBriefType p = wpsf.createProcessBriefType();
                p.setProcessVersion(pf.getVersion(name));
                po.getProcess().add( p );
               
                p.setIdentifier(Ows11Util.code(name));
                p.setTitle(Ows11Util.languageString( pf.getTitle(name).toString()));
                p.setAbstract(Ows11Util.languageString( pf.getDescription(name).toString()));
            }
           
        }

        LanguagesType1 languages = wpsf.createLanguagesType1();
View Full Code Here

     * <!-- begin-user-doc -->
     * <!-- end-user-doc -->
     * @generated
     */
    public NotificationChain basicSetProcess(ProcessBriefType newProcess, NotificationChain msgs) {
        ProcessBriefType oldProcess = process;
        process = newProcess;
        if (eNotificationRequired()) {
            ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, Wps10Package.EXECUTE_RESPONSE_TYPE__PROCESS, oldProcess, newProcess);
            if (msgs == null) msgs = notification; else msgs.add(notification);
        }
View Full Code Here

        ProcessFactory pf = Processors.createProcessFactory(name);
        if ( pf == null ) {
            throw new WPSException( "No such process: " + id.getValue() );
        }
       
        ProcessDescriptionType pd = wpsf.createProcessDescriptionType();
        pds.getProcessDescription().add( pd );
       
        pd.setProcessVersion( "1.0.0" );
        pd.setIdentifier( Ows11Util.code( id.getValue() ) );
        pd.setTitle( Ows11Util.languageString(pf.getTitle(name)) );
        pd.setAbstract( Ows11Util.languageString(pf.getDescription(name)) );
       
        //data inputs
        DataInputsType inputs = wpsf.createDataInputsType();
        pd.setDataInputs(inputs);
        dataInputs( inputs, pf, name );
       
        //process outputs
        ProcessOutputsType outputs = wpsf.createProcessOutputsType();
        pd.setProcessOutputs( outputs );
        processOutputs( outputs, pf, name );
     }
View Full Code Here

        xsp = new XSProfile();
    }

    public ProcessDescriptionsType run(DescribeProcessType request) {
       
        ProcessDescriptionsType pds = wpsf.createProcessDescriptionsType();
       
        for ( Iterator i = request.getIdentifier().iterator(); i.hasNext(); ) {
            CodeType id = (CodeType) i.next();
            processDescription( id, pds );
        }
View Full Code Here

        //status
        response.setStatus( f.createStatusType() );
        response.getStatus().setCreationTime( Converters.convert( started, XMLGregorianCalendar.class ));
       
        if ( error != null ) {
            ProcessFailedType failure = f.createProcessFailedType();
            response.getStatus().setProcessFailed( failure );
           
            failure.setExceptionReport( Ows11Util.exceptionReport( new ServiceException( error ), wps.getGeoServer().getGlobal().isVerboseExceptions()) );
        }
        else {
            response.getStatus().setProcessSucceeded( "Process succeeded.");
        }
     
View Full Code Here

     * <!-- begin-user-doc -->
     * <!-- end-user-doc -->
     * @generated
     */
    public NotificationChain basicSetProcessFailed(ProcessFailedType newProcessFailed, NotificationChain msgs) {
        ProcessFailedType oldProcessFailed = processFailed;
        processFailed = newProcessFailed;
        if (eNotificationRequired()) {
            ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, Wps10Package.STATUS_TYPE__PROCESS_FAILED, oldProcessFailed, newProcessFailed);
            if (msgs == null) msgs = notification; else msgs.add(notification);
        }
View Full Code Here

TOP

Related Classes of net.opengis.wps10.DescriptionType

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.