Examples of WSResource


Examples of org.apache.muse.ws.resource.WsResource

    }
   
    public Element toXML(Object result)
        throws SoapFault
    {
        WsResource sub = (WsResource)result;
       
        //
        // add termination time to the response, if it exists
        //
        ScheduledTermination wsrl = (ScheduledTermination)sub.getCapability(WsrlConstants.SCHEDULED_TERMINATION_URI);
        Date time = null;
       
        if (wsrl != null)
            time = wsrl.getTerminationTime();
       
View Full Code Here

Examples of org.apache.muse.ws.resource.WsResource

       
        //
        // create the resource to represent the pullpoint
        //
        String endpoint = getPullPointContextPath();
        WsResource pullPoint = null;
       
        try
        {
            pullPoint = (WsResource)manager.createResource(endpoint);
        }
       
        catch (SoapFault error)
        {
            throw new UnableToCreatePullPointFault(error);
        }
       
        EndpointReference epr = pullPoint.getEndpointReference();
       
        PullPoint pullPointCap = (PullPoint)pullPoint.getCapability(WsnConstants.PULL_POINT_URI);
        Filter filter = pullPointCap.getFilter();
       
        //
        // create subscription that will send messages to the pullpoint
        //
        NotificationProducer wsn = (NotificationProducer)getResource().getCapability(WsnConstants.PRODUCER_URI);
        WsResource sub = null;
       
        try
        {
            sub = wsn.subscribe(epr, filter, null, null);
        }
View Full Code Here

Examples of org.apache.muse.ws.resource.WsResource

    public void initialize()
        throws SoapFault
    {
        super.initialize();
       
        WsResource resource = getWsResource();
        ResourcePropertyCollection props = resource.getPropertyCollection();
        MetadataDescriptor metadata = props.getMetadata();
       
        //
        // load all of the metric data from the RMD
        //
View Full Code Here

Examples of org.apache.muse.ws.resource.WsResource

        return _serviceGroup;
    }
   
    public EndpointReference getServiceGroupEPR()
    {
        WsResource sg = getServiceGroup();
        return sg == null ? null : sg.getEndpointReference();
    }
View Full Code Here

Examples of org.apache.muse.ws.resource.WsResource

       
        //
        // find the entry resource, use the Entry capability to set the
        // member EPR and service group property values
        //
        WsResource entryResource = (WsResource)getResourceManager().getResource(entryEPR);       
        Entry entryCap = (Entry)entryResource.getCapability(WssgConstants.ENTRY_URI);
       
        WsResource sgResource = getServiceGroup();
       
        entryCap.setServiceGroup(sgResource);
        entryCap.setMemberEPR(memberEPR);
       
        ServiceGroup sgCap = (ServiceGroup)sgResource.getCapability(WssgConstants.SERVICE_GROUP_URI);
        sgCap.addEntry(memberEPR, entryResource);
       
        return entryResource;
    }
View Full Code Here

Examples of org.apache.muse.ws.resource.WsResource

                               Element content,
                               Date termination)
        throws AddRefusedFault,
               BaseFault
    {
        WsResource entry = createEntry(memberEPR, content, termination);
        return addEntry(memberEPR, entry);
    }
View Full Code Here

Examples of org.apache.ws.resource.WSResource

      EndpointReferenceType returnEPR = EndpointReferenceType.Factory.newInstance(  );

      if ( subscription != null )
      {
         // Find the subscription WSResource in the registry
         WSResource resource =
            RegistrationManagerFactory.getManager(  ).find( SUBSCRIPTION_MANAGER_SERVICE,
                                                            subscription.getSubscriptionId(  ) );

         if ( resource != null )
         {
            EndpointReference subscriptionEPR = resource.getEndpointReference(  );
            AttributedURI     address = returnEPR.addNewAddress(  );
            address.setStringValue( subscriptionEPR.getAddress(  ).toString(  ) );

            // Setup the port type
            AttributedQName portType = returnEPR.addNewPortType(  );
View Full Code Here

Examples of org.apache.ws.resource.WSResource

   {
      if ( sub != null )
      {
         try
         {
            WSResource wsResource =
               SubscriptionManagerWSResourceFactory.createSubscriptionManagerWSResource( sub, this );

            RegistrationManagerFactory.getManager(  ).register( wsResource );
         }
         catch ( Exception e )
View Full Code Here

Examples of org.apache.ws.resource.WSResource

   {
      if ( doomedSub != null )
      {
         try
         {
            WSResource doomed =
               RegistrationManagerFactory.getManager(  ).find( "SubscriptionManagerPort",
                                                               doomedSub.getSubscriptionId(  ) );

            RegistrationManagerFactory.getManager(  ).unregister( doomed );
         }
View Full Code Here

Examples of org.apache.ws.resource.WSResource

          RegistrationFailureException
   {
      registerTestAsResource(  );

      // Check to see if null returns all resources
      WSResource resultList = m_manager.find( null, null );
      Assert.assertNull( resultList );

      resultList = m_manager.find( null, "doesnotmatterwhatID" );
      Assert.assertNull( resultList );

      // Check that we can find a disk resource
      WSResource diskResource = m_manager.find( "disk", "1234" );
      Assert.assertNotNull( diskResource );
      Assert.assertEquals( "1234",
                           diskResource.getId(  ) );
   }
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.