Package net.jini.core.lookup

Examples of net.jini.core.lookup.ServiceID


     *  appropriate transition mask; along with a handback containing the
     *  service ID .
     */
    public void setup(QAConfig sysConfig) throws Exception {
        int i;
        ServiceID curSrvcID;
  EventRegistration[] evntRegs;
        int regTransitions =   ServiceRegistrar.TRANSITION_MATCH_MATCH
                             | ServiceRegistrar.TRANSITION_MATCH_NOMATCH;
  super.setup(sysConfig);

View Full Code Here


     *  transition mask; along with a handback containing the service ID .
     */
    public void setup(QAConfig sysConfig) throws Exception {

        int i,j,k;
        ServiceID curSrvcID;
  EventRegistration[] evntRegs;
        int regTransitions =   ServiceRegistrar.TRANSITION_MATCH_MATCH
                             | ServiceRegistrar.TRANSITION_MATCH_NOMATCH;
  super.setup(sysConfig);

View Full Code Here

            throw new TestException("# of Events Received ("+
                                             eventVector.size()+
                                             ") != # of Events Expected ("+
                                             nExpectedEvnts+")");
  } else {
            ServiceID evntSrvcID;
            ServiceID expdSrvcID;
            ServiceID handbackSrvcID;
      for(int i=0; i<eventVector.size(); i++) {
                evnt = (ServiceEvent)eventVector.elementAt(i);
                if (evnt == null) {
                    throw new TestException
                             ("null Event returned from Vector at element "+i);
       } else {
                    if (evnt.getTransition() != expectedTransition) {
      dumpEventIDs(eventVector, serviceRegs);
                        throw new TestException("Unexpected Transition returned ("+
            evnt.getTransition()+")");
        } else {
                        evntSrvcID = evnt.getServiceID();
                        expdSrvcID = serviceRegs[i].getServiceID();
                        if ( !(evntSrvcID.equals(expdSrvcID)) ) {
                            throw new TestException("Service ID Received ("+
                evntSrvcID+
                ") != Service ID Expected ("+
                expdSrvcID+")");
      } else {
          handbackSrvcID =
        (ServiceID)(evnt.getRegistrationObject().get());

          if ( !(handbackSrvcID.equals(expdSrvcID)) ) {
        throw new TestException
            ("Handback Service ID ("+
             handbackSrvcID+
             ") != Service ID Expected ("+
             expdSrvcID+")");
View Full Code Here

    public static void dumpEventIDs(Vector eventVector,
                                    ServiceRegistration[] serviceRegs)
    {
        ServiceEvent evnt = null;
  ServiceID evntSrvcID;
  ServiceID expdSrvcID;
  ServiceID handbackSrvcID;
  for(int i=0; i<eventVector.size(); i++) {
      evnt = (ServiceEvent)eventVector.elementAt(i);
      evntSrvcID = evnt.getServiceID();
      expdSrvcID = serviceRegs[i].getServiceID();
      System.out.println("Expected ID = " + expdSrvcID + ", received ID = " + evntSrvcID);
View Full Code Here

     *  and the appropriate transition mask; along with a callback containing
     *  the service ID.
     */
    public void setup(QAConfig sysConfig) throws Exception {
        int i;
        ServiceID curSrvcID;
  EventRegistration[] evntRegs;
        int regTransitions =   ServiceRegistrar.TRANSITION_MATCH_MATCH
                             | ServiceRegistrar.TRANSITION_MATCH_NOMATCH;
  super.setup(sysConfig);

View Full Code Here

     @exception QATestException will usually indicate an "unresolved"
     *  condition because at this point the test has not yet begun.
     */
    public void setup(QAConfig sysConfig) throws Exception {
        int i,j,k;
        ServiceID curSrvcID;
  EventRegistration[] evntRegs;
        int regTransitions =   ServiceRegistrar.TRANSITION_MATCH_MATCH
                             | ServiceRegistrar.TRANSITION_MATCH_NOMATCH;
        /* create the lookup service */
  super.setup(sysConfig);
 
View Full Code Here

     *  the service ID .
     */
    public void setup(QAConfig sysConfig) throws Exception {

        int i,j,k;
        ServiceID curSrvcID;
        EventRegistration[] evntRegs;
        int regTransitions =   ServiceRegistrar.TRANSITION_MATCH_MATCH
                             | ServiceRegistrar.TRANSITION_MATCH_NOMATCH;
        super.setup(sysConfig);

View Full Code Here

                synchronized(regInfo) {
                    boolean oneDiscovered = false;
                    for(int i=0;i<regs.length;i++) {
                        /* care only about the generators the test started */
                        if( !lookupList.contains(regs[i]) ) continue;
                        ServiceID srvcID = regs[i].getServiceID();
                        logger.log(Level.FINE, "registration_"+regInfo.handback
                                      +" -- discovered service ID = "+srvcID);
                        logDebugEventText(evnt);
                        try {
                            String[] groups = (String[])groupsMap.get(srvcID);
View Full Code Here

            ServiceRegistrar[] regs = regTuple.regs;
            Map groupsMap = regTuple.groupsMap;
            if(regs != null) {
                synchronized(regInfo) {
                    for(int i=0;i<regs.length;i++) {
                        ServiceID srvcID = regs[i].getServiceID();
                        if(regInfo.discoveredMap.remove(regs[i]) != null) {
                            logger.log(Level.FINE, "registration_"+regInfo.handback
                                      +" -- discarded service ID = "+srvcID);
                            logDebugEventText(evnt);
                            String[] groups = (String[])groupsMap.get(srvcID);
View Full Code Here

                logger.log(Level.FINE, "  registrars that were "
                                            +"successfully un-marshalled --");
                if(regs.length > 0) {
                    for(int i=0;i<regs.length;i++) {
                        try {
                            ServiceID srvcID = regs[i].getServiceID();
                            String[] groups = (String[])groupsMap.get(srvcID);
                            LocatorsUtil.displayLocator(QAConfig.getConstrainedLocator(regs[i].getLocator()),
                                                        "    locator ",
                                                        Level.FINE);
                            String displayGroups
View Full Code Here

TOP

Related Classes of net.jini.core.lookup.ServiceID

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.