/[classpath]/classpath/org/omg/PortableServer/ServantLocatorHelper.java
ViewVC logotype

Diff of /classpath/org/omg/PortableServer/ServantLocatorHelper.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.1.2.2 by gnu_andrew, Sat Sep 10 15:32:06 2005 UTC revision 1.1.2.3 by gnu_andrew, Wed Nov 2 00:44:14 2005 UTC
# Line 38  exception statement from your version. * Line 38  exception statement from your version. *
38    
39  package org.omg.PortableServer;  package org.omg.PortableServer;
40    
41    import gnu.CORBA.Minor;
42    
43  import org.omg.CORBA.Any;  import org.omg.CORBA.Any;
44  import org.omg.CORBA.BAD_OPERATION;  import org.omg.CORBA.BAD_OPERATION;
45  import org.omg.CORBA.MARSHAL;  import org.omg.CORBA.MARSHAL;
# Line 108  public abstract class ServantLocatorHelp Line 110  public abstract class ServantLocatorHelp
110      catch (ClassCastException ex)      catch (ClassCastException ex)
111        {        {
112          BAD_OPERATION bad = new BAD_OPERATION();          BAD_OPERATION bad = new BAD_OPERATION();
113            bad.minor = Minor.ClassCast;
114          bad.initCause(ex);          bad.initCause(ex);
115          throw bad;          throw bad;
116        }        }
117    }    }
118      
119      /**
120       * Narrow the given object to the ServantLocator. For the objects that are
121       * always local, this operation does not differ from the ordinary
122       * {@link #narrow} (ClassCastException will be thrown if narrowing something
123       * different).
124       *
125       * @param obj the object to cast.
126       *
127       * @return the casted ServantLocator.
128       *
129       * @since 1.5
130       *
131       * @see OMG issue 4158.
132       */
133      public static ServantLocator unchecked_narrow(org.omg.CORBA.Object obj)
134      {
135        return narrow(obj);
136      }    
137    
138    /**    /**
139     * This should read the servant locator, but it cannot be transferred     * This should read the servant locator, but it cannot be transferred
# Line 125  public abstract class ServantLocatorHelp Line 147  public abstract class ServantLocatorHelp
147     */     */
148    public static ServantLocator read(InputStream input)    public static ServantLocator read(InputStream input)
149    {    {
150      throw new MARSHAL();      MARSHAL m = new MARSHAL("Inappropriate");
151        m.minor = Minor.Inappropriate;
152        throw m;
153    }    }
154    
155    /**    /**
# Line 140  public abstract class ServantLocatorHelp Line 164  public abstract class ServantLocatorHelp
164     */     */
165    public static void write(OutputStream output, ServantLocator value)    public static void write(OutputStream output, ServantLocator value)
166    {    {
167      throw new MARSHAL();      MARSHAL m = new MARSHAL("Inappropriate");
168        m.minor = Minor.Inappropriate;
169        throw m;
170    }    }
171  }  }

Legend:
Removed from v.1.1.2.2  
changed lines
  Added in v.1.1.2.3

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26