Examples of IORInfoExt


Examples of com.sun.corba.ee.spi.legacy.interceptor.IORInfoExt

     *    service to query applicable policies and add components to be
     *    included in the generated IORs.
     */
    public void establish_components(org.omg.PortableInterceptor.IORInfo iorInfo) {
        try {
            IORInfoExt iorInfoExt = (IORInfoExt) iorInfo;
            int port = iorInfoExt.getServerPort(ORBSocketFactory.IIOP_CLEAR_TEXT);

            ArrayList allInetAddress = getAllInetAddresses();
            addAddressComponents(iorInfo, allInetAddress, port);
            com.sun.corba.ee.internal.corba.ORB orb =
                    (com.sun.corba.ee.internal.corba.ORB)((IORInfoImpl)iorInfo).getORB();
View Full Code Here

Examples of org.jacorb.orb.portableInterceptor.IORInfoExt

{
   public List alternateAddresses = IIOPAddressInterceptor.alternateAddresses;

    public void establish_components(IORInfo info)
    {
       IORInfoExt infoExt = (IORInfoExt) info;
       // ORB should have added already 1 profile with IOP tag
       int nrOfProf = infoExt.get_number_of_profiles(TAG_INTERNET_IOP.value);
       if( nrOfProf != 1 )
       {
          throw new RuntimeException ("unexpected number of IOP Profiles: " + nrOfProf);
       }

       IIOPProfile primaryProf =
           (IIOPProfile) infoExt.get_profile(TAG_INTERNET_IOP.value, 0);
       try
       {
          IIOPProfile cloneOfPrimary = (IIOPProfile) primaryProf.clone();

          // now add alternate addresses to primary profile
           for (Iterator i = alternateAddresses.iterator(); i.hasNext();) {

             IIOPAddress addr = (IIOPAddress)i.next();
             primaryProf.addComponent( TAG_ALTERNATE_IIOP_ADDRESS.value, addr.toCDR() );
          }

           // now add a secondary and third profile like used e.g. by
           // Visibroker 4.5
          for (Iterator i = alternateAddresses.iterator(); i.hasNext();)
          {
              IIOPAddress addr = (IIOPAddress)i.next();

              IIOPProfile additionalProfile =
                  (IIOPProfile) primaryProf.clone();

              additionalProfile.patchPrimaryAddress(addr);

              infoExt.add_profile(additionalProfile);
          }
       }
       catch ( CloneNotSupportedException ex )
       {
          throw new RuntimeException ("Exception during cloning of profile: "
                                      + ex);
       }

       nrOfProf = infoExt.get_number_of_profiles(TAG_INTERNET_IOP.value);
       if( nrOfProf != 1 + alternateAddresses.size())
       {
          throw new RuntimeException ("unexpected number of IOP Profiles after addition: "
                                      + nrOfProf
                                      + ", where number of alternates was: "
                                      + alternateAddresses.size());
       }

       // check access functions
       primaryProf =
           (IIOPProfile) infoExt.get_profile(TAG_INTERNET_IOP.value, 0);
       IIOPProfile primaryProf2 =
           (IIOPProfile) infoExt.get_profile(TAG_INTERNET_IOP.value);
       // they should be equal to primary
       if ( ! primaryProf.equals(primaryProf2) )
       {
          throw new RuntimeException ("difference between "
                                      + "get_profile(tag, idx) and "
View Full Code Here

Examples of org.jacorb.orb.portableInterceptor.IORInfoExt

{
   public List alternateAddresses = IIOPAddressInterceptor.alternateAddresses;

    public void establish_components(IORInfo info)
    {
       IORInfoExt infoExt = (IORInfoExt) info;
       // ORB should have added already 1 profile with IOP tag
       int nrOfProf = infoExt.get_number_of_profiles(TAG_INTERNET_IOP.value);
       if( nrOfProf != 1 )
       {
          throw new RuntimeException ("unexpected number of IOP Profiles: " + nrOfProf);
       }

       IIOPProfile primaryProf =
           (IIOPProfile) infoExt.get_profile(TAG_INTERNET_IOP.value, 0);
       try
       {
          IIOPProfile cloneOfPrimary = (IIOPProfile) primaryProf.clone();

          // now add alternate addresses to primary profile
           for (Iterator i = alternateAddresses.iterator(); i.hasNext();) {

             IIOPAddress addr = (IIOPAddress)i.next();
             primaryProf.addComponent( TAG_ALTERNATE_IIOP_ADDRESS.value, addr.toCDR() );
          }

           // now add a secondary and third profile like used e.g. by
           // Visibroker 4.5
          for (Iterator i = alternateAddresses.iterator(); i.hasNext();)
          {
              IIOPAddress addr = (IIOPAddress)i.next();

              IIOPProfile additionalProfile =
                  (IIOPProfile) primaryProf.clone();

              additionalProfile.patchPrimaryAddress(addr);

              infoExt.add_profile(additionalProfile);
          }
       }
       catch ( CloneNotSupportedException ex )
       {
          throw new RuntimeException ("Exception during cloning of profile: "
                                      + ex);
       }

       nrOfProf = infoExt.get_number_of_profiles(TAG_INTERNET_IOP.value);
       if( nrOfProf != 1 + alternateAddresses.size())
       {
          throw new RuntimeException ("unexpected number of IOP Profiles after addition: "
                                      + nrOfProf
                                      + ", where number of alternates was: "
                                      + alternateAddresses.size());
       }

       // check access functions
       primaryProf =
           (IIOPProfile) infoExt.get_profile(TAG_INTERNET_IOP.value, 0);
       IIOPProfile primaryProf2 =
           (IIOPProfile) infoExt.get_profile(TAG_INTERNET_IOP.value);
       // they should be equal to primary
       if ( ! primaryProf.equals(primaryProf2) )
       {
          throw new RuntimeException ("difference between "
                                      + "get_profile(tag, idx) and "
View Full Code Here

Examples of org.jacorb.orb.portableInterceptor.IORInfoExt

{
   public List<IIOPAddress> alternateAddresses = IIOPAddressInterceptor.alternateAddresses;

    public void establish_components(IORInfo info)
    {
       IORInfoExt infoExt = (IORInfoExt) info;
       // ORB should have added already 1 profile with IOP tag
       int nrOfProf = infoExt.get_number_of_profiles(TAG_INTERNET_IOP.value);
       if( nrOfProf != 1 )
       {
          throw new RuntimeException ("unexpected number of IOP Profiles: " + nrOfProf);
       }

       IIOPProfile primaryProf =
           (IIOPProfile) infoExt.get_profile(TAG_INTERNET_IOP.value, 0);
       try
       {
          // now add alternate addresses to primary profile
           for (Iterator<IIOPAddress> i = alternateAddresses.iterator(); i.hasNext();) {

             IIOPAddress addr = i.next();
             primaryProf.addComponent( TAG_ALTERNATE_IIOP_ADDRESS.value, addr.toCDR() );
          }

           // now add a secondary and third profile like used e.g. by
           // Visibroker 4.5
          for (Iterator<IIOPAddress> i = alternateAddresses.iterator(); i.hasNext();)
          {
              IIOPAddress addr = i.next();

              IIOPProfile additionalProfile =
                  (IIOPProfile) primaryProf.clone();

              additionalProfile.patchPrimaryAddress(addr);

              infoExt.add_profile(additionalProfile);
          }
       }
       catch ( CloneNotSupportedException ex )
       {
          throw new RuntimeException ("Exception during cloning of profile: "
                                      + ex);
       }

       nrOfProf = infoExt.get_number_of_profiles(TAG_INTERNET_IOP.value);
       if( nrOfProf != 1 + alternateAddresses.size())
       {
          throw new RuntimeException ("unexpected number of IOP Profiles after addition: "
                                      + nrOfProf
                                      + ", where number of alternates was: "
                                      + alternateAddresses.size());
       }

       // check access functions
       primaryProf =
           (IIOPProfile) infoExt.get_profile(TAG_INTERNET_IOP.value, 0);
       IIOPProfile primaryProf2 =
           (IIOPProfile) infoExt.get_profile(TAG_INTERNET_IOP.value);
       // they should be equal to primary
       if ( ! primaryProf.equals(primaryProf2) )
       {
          throw new RuntimeException ("difference between "
                                      + "get_profile(tag, idx) and "
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.