Examples of SetRequest


Examples of org.apache.muse.ws.resource.properties.set.SetRequest

        Element[] children = XmlUtils.getAllElements(request, WsrpConstants.NAMESPACE_URI);
       
        if (children.length == 0)
            throw new InvalidMessageFormatFault(_MESSAGES.get("EmptySetRequest"));
       
        SetRequest set = new SimpleSetRequest();
       
        //
        // build the different types of sets from XML. don't bother with a
        // table, we only have three command types
        //
        for (int n = 0; n < children.length; ++n)
        {
            String type = children[n].getLocalName();
           
            SetRequestComponent operation = null;
           
            if (type.equals(DeleteRequest.OPERATION))
                operation = new DeleteRequest(children[n]);
           
            else if (type.equals(InsertRequest.OPERATION))
                operation = new InsertRequest(children[n]);
           
            else if (type.equals(UpdateRequest.OPERATION))
                operation = new UpdateRequest(children[n]);
           
            else
            {
                Object[] filler = { type };
                throw new InvalidMessageFormatFault(_MESSAGES.get("InvalidSet", filler));
            }
           
            set.addRequestComponent(operation);
        }
       
        return set;
    }
View Full Code Here

Examples of org.apache.muse.ws.resource.properties.set.SetRequest

        return set;
    }
   
    public SetRequest createUpdate(QName qname, Object[] values)
    {
        SetRequest set = new SimpleSetRequest();
        set.addRequestComponent(new UpdateRequest(qname, values));
        return set;
    }
View Full Code Here

Examples of org.apache.muse.ws.resource.properties.set.SetRequest

    {
        //
        // Process each top level property from root of doc
        //
        Element[] properties = XmlUtils.getAllElements(newDoc);
        SetRequest set = new SimpleSetRequest();

        for (int i = 0; i < properties.length; i++)
        {
            QName propQName = XmlUtils.getElementQName(properties[i]);
           
            if (getMetadata().isReadOnlyExternal(propQName))
            {
                Object[] filler = { propQName };
                throw new UnableToPutResourcePropertyDocumentFault(_MESSAGES.get("PutRPDocReadOnlyError", filler));
            }
           
            SetRequestComponent insertComp = new InsertRequest(propQName, properties[i]);
            set.addRequestComponent(insertComp);        
        }
       
        return set;
    }
View Full Code Here

Examples of org.apache.muse.ws.resource.properties.set.SetRequest

            deleteMutableProperties()
         
            //
            // break the operation down into multiple set request insert components
            //
            SetRequest insertRequests = createInsertRequests(newDoc);    
            setResourceProperties(insertRequests);
        }
       
        catch (BaseFault fault)
        {
View Full Code Here

Examples of org.apache.muse.ws.resource.properties.set.SetRequest

    {
        //
        // Process each top level property from root of doc
        //
        Element[] properties = XmlUtils.getAllElements(newDoc);
        SetRequest set = new SimpleSetRequest();

        for (int i = 0; i < properties.length; i++)
        {
            QName propQName = XmlUtils.getElementQName(properties[i]);
           
            if (getMetadata().isReadOnlyExternal(propQName))
            {
                Object[] filler = { propQName };
                throw new UnableToPutResourcePropertyDocumentFault(_MESSAGES.get("PutRPDocReadOnlyError", filler));
            }
           
            SetRequestComponent insertComp = new InsertRequest(propQName, properties[i]);
            set.addRequestComponent(insertComp);        
        }
       
        return set;
    }
View Full Code Here

Examples of org.apache.muse.ws.resource.properties.set.SetRequest

            deleteMutableProperties()
         
            //
            // break the operation down into multiple set request insert components
            //
            SetRequest insertRequests = createInsertRequests(newDoc);    
            setResourceProperties(insertRequests);
        }
       
        catch (BaseFault fault)
        {
View Full Code Here

Examples of org.dmd.dmp.server.extended.SetRequest

  @Override
  public SetResponseDMO set(SetRequestDMO setRequest) {
    // All requests are immediately wrapped for use on the server. This includes
    // associating the request with the originating HttpServletRequest.
    SetRequest request = new SetRequest(setRequest, getThreadLocalRequest());
    SetResponse response = null;
   
    if (request.isTrackingEnabled())
      logger.trace("Received by DMP servlet:\n" + request.toOIF());
   
    if (request.getModifyIsEmpty()){
      // There aren't any modifications in the request - that's an error
      response = (SetResponse) request.getErrorResponse();
      response.setResponseText("No modifications were found in the SetRequest");
    }
    else{

      try {
        response = (SetResponse) pluginManager.getSecurityManager().validateSession(request);
       
        if (response == null){
          SessionRI session = pluginManager.getSecurityManager().getSession(request);
 
          response = session.handleSetRequest(request);
        }
      } catch (DmcValueException e) {
        response = (SetResponse) request.getErrorResponse();
        response.setResponseText(e.toString());
       
        logger.error(e.toString());
     
    }
View Full Code Here

Examples of org.dmd.dmp.server.extended.SetRequest

        super(new SetRequestDMO(mods), org.dmd.dmp.server.generated.DmpSchemaAG._SetRequest);
    }

    // Generated from: org.dmd.dmg.generators.BaseDMWGeneratorNewest.dumpWrapper(BaseDMWGeneratorNewest.java:470)
    public SetRequest getModificationRecorder(){
        SetRequest rc = new SetRequest();
        rc.setModifier(new DmcTypeModifierMV(MetaDMSAG.__modify));
        return(rc);
    }
View Full Code Here

Examples of org.dmd.dmp.server.extended.SetRequest

    public SetRequestDMW(SetRequestDMO obj) {
        super(obj, org.dmd.dmp.server.generated.DmpSchemaAG._SetRequest);
    }

    public SetRequest cloneIt() {
        SetRequest rc = new SetRequest();
        rc.setDmcObject(getDMO().cloneIt());
        return(rc);
    }
View Full Code Here

Examples of org.eclipse.gmf.runtime.emf.type.core.requests.SetRequest

      EAttribute feature, Object value) {
    value = getValidNewValue(feature, value);
    if (value instanceof InvalidValue) {
      return UnexecutableCommand.INSTANCE;
    }
    SetRequest request = new SetRequest(element, feature, value);
    return new SetValueCommand(request);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.