Package java.io

Examples of java.io.Externalizable


                        activeRecursionMgr.addObject(offset, currentObject);

                        // Read format version
                        readFormatVersion();

                        Externalizable ext = (Externalizable)currentObject;
                        ext.readExternal(this);
                    }
                } catch (InvocationTargetException e) {
                    InvalidClassException exc = new InvalidClassException(
                        currentClass.getName(),
                        "InvocationTargetException accessing no-arg constructor");
View Full Code Here


        Object neColumn = row[arrayPosition];

        if (neColumn instanceof Externalizable)
                {

          Externalizable exColumn = (Externalizable) neColumn;

          inUserCode = true;
          exColumn.readExternal(logicalDataIn);
          inUserCode = false;

          arrayPosition++;
          continue;
        }
View Full Code Here

        }
      }
    }
    else if (obj instanceof Externalizable && (!Proxy.isProxyClass(cls)))
    {
      Externalizable extObj = (Externalizable)obj;
      try
      {
        extObj.writeExternal(new ObjectOutputAdaptor()
        {
          private int count = 0;

          public void writeObject(Object streamObj) throws IOException
          {
View Full Code Here

      Cache[] nonOwners = getNonOwners("diffkey", 1);
      assert owners.length == 1;
      assert nonOwners.length == 1;
      Cache ownerCache = owners[0];
      Cache nonOwnerCache = nonOwners[0];
      ownerCache.put("diffkey", new Externalizable() {
         private static final long serialVersionUID = -483939825697574242L;

         public void writeExternal(ObjectOutput out) throws IOException {
            throw new UnknownError();
         }
View Full Code Here

        }
      }
    }
    else if (obj instanceof Externalizable && (!Proxy.isProxyClass(cls)))
    {
      Externalizable extObj = (Externalizable)obj;
      try
      {
        extObj.writeExternal(new ObjectOutputAdaptor()
        {
          private int count = 0;

          public void writeObject(Object streamObj) throws IOException
          {
View Full Code Here

                        activeRecursionMgr.addObject(offset, currentObject);

                        // Read format version
                        readFormatVersion();

                        Externalizable ext = (Externalizable)currentObject;
                        ext.readExternal(this);
                }
            } catch (InvocationTargetException e) {
                InvalidClassException exc = new InvalidClassException(
                    currentClass.getName(),
                    "InvocationTargetException accessing no-arg constructor");
View Full Code Here

                        activeRecursionMgr.addObject(offset, currentObject);

                        // Read format version
                        readFormatVersion();

                        Externalizable ext = (Externalizable)currentObject;
                        ext.readExternal(this);
                    }
                } catch (InvocationTargetException e) {
                    InvalidClassException exc = new InvalidClassException(
                        currentClass.getName(),
                        "InvocationTargetException accessing no-arg constructor");
View Full Code Here

        }
      }
    }
    else if (obj instanceof Externalizable && (!Proxy.isProxyClass(cls)))
    {
      Externalizable extObj = (Externalizable)obj;
      try
      {
        extObj.writeExternal(new ObjectOutputAdaptor()
        {
          private int count = 0;

          public void writeObject(Object streamObj) throws IOException
          {
View Full Code Here

            String value = source.getText();
            ByteArrayInputStream bis = new ByteArrayInputStream(Base64Binary.decode(value));
            ObjectInputStream ois = new ObjectInputStream(bis);
            Object obj = ois.readObject();
            ois.close();
            Externalizable aReference = (Externalizable) obj;
            return aReference;
        } catch (Exception e) {
            throw new TransformationException(e);
        }
    }
View Full Code Here

      }
   }

   private Object readExternal (Kryo kryo, Input input, Class type) {
      try {
        Externalizable object = (Externalizable)type.newInstance();
        object.readExternal(getObjectInput(kryo, input));
        return object;
      } catch (ClassCastException e) {
        throw new KryoException(e);
      } catch (ClassNotFoundException e) {
        throw new KryoException(e);
View Full Code Here

TOP

Related Classes of java.io.Externalizable

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.