/** {@inheritDoc} */ public int readUnsignedByte() throws IOException { return input.readUnsignedByte(); }
/** {@inheritDoc} */ public int readUnsignedByte() throws IOException { return unmarshaller.readUnsignedByte(); }
public int readUnsignedByte() throws IOException { return unmarshaller.readUnsignedByte(); }
@Override public Class<?> readClass(final Unmarshaller unmarshaller) throws IOException, ClassNotFoundException { int idx = unmarshaller.readUnsignedByte(); if (idx >= classes.length) { throw new ClassNotFoundException("ClassTable " + this.getClass().getName() + " cannot find a class for class index " + idx); } return classes[idx]; }
public Object readObject(final Unmarshaller unmarshaller) throws IOException, ClassNotFoundException { int idx = unmarshaller.readUnsignedByte(); if (idx >= objects.length) { throw new InvalidObjectException("ObjectTable " + this.getClass().getName() + " cannot find an object for object index " + idx); } return objects[idx]; } }
public Object readObject(final Unmarshaller unmarshaller) throws IOException, ClassNotFoundException { int idx = unmarshaller.readUnsignedByte(); if (idx >= objects.length) { throw new InvalidObjectException("ObjectTable " + this.getClass().getName() + " cannot find an object for object index " + idx); } return objects[idx]; }
public Object readObject(final Unmarshaller unmarshaller) throws IOException, ClassNotFoundException { int idx = unmarshaller.readUnsignedByte(); if (idx >= extById.length) { throw new InvalidObjectException("ObjectTable " + this.getClass().getName() + " cannot find an object for object index " + idx); } return extById[idx].createExternal(Object.class, unmarshaller); } }
void handleUnbind(final MessageInputStream message, final int messageId, final int id) throws IOException { try (MessageInputStream mis = message) { if (version == 1) { try (Unmarshaller unmarshaller = createUnmarshaller(mis, configuration)) { final int parameterType = unmarshaller.readUnsignedByte(); if (parameterType != Protocol.P_NAME) { Messages.log.unexpectedParameterType(Protocol.P_NAME, parameterType); } final Name name = unmarshaller.readObject(Name.class); localContext.unbind(name); } catch (ClassNotFoundException e) { throw new IOException(e); } } else { mis.readInt(); // consume authId final String name = mis.readUTF(); localContext.unbind(name); } } catch (NamingException e) { writeExceptionResponse(e, messageId, id); return; } writeSuccessResponse(messageId, id); }
if (version == 1) { try (Unmarshaller unmarshaller = createUnmarshaller(mis, configuration)) { int parameterType = unmarshaller.readUnsignedByte(); if (parameterType != Protocol.P_NAME) { Messages.log.unexpectedParameterType(Protocol.P_NAME, parameterType); parameterType = unmarshaller.readUnsignedByte(); if (parameterType != Protocol.P_OBJECT) { Messages.log.unexpectedParameterType(Protocol.P_OBJECT, parameterType);
if (version == 1) { try (Unmarshaller unmarshaller = createUnmarshaller(mis, configuration)) { final int parameterType = unmarshaller.readUnsignedByte(); if (parameterType != Protocol.P_NAME) { Messages.log.unexpectedParameterType(Protocol.P_NAME, parameterType);
void handleRename(final MessageInputStream message, final int messageId, final int id) throws IOException { try (MessageInputStream mis = message) { if (version == 1) { try (Unmarshaller unmarshaller = createUnmarshaller(mis, configuration)) { int parameterType = unmarshaller.readUnsignedByte(); if (parameterType != Protocol.P_NAME) { Messages.log.unexpectedParameterType(Protocol.P_NAME, parameterType); } final Name oldName = unmarshaller.readObject(Name.class); parameterType = unmarshaller.readUnsignedByte(); if (parameterType != Protocol.P_NAME) { Messages.log.unexpectedParameterType(Protocol.P_NAME, parameterType); } final Name newName = unmarshaller.readObject(Name.class); localContext.rename(oldName, newName); } catch (ClassNotFoundException e) { throw new IOException(e); } } else { mis.readInt(); // consume authId final String oldName = mis.readUTF(); final String newName = mis.readUTF(); localContext.rename(oldName, newName); } } catch (NamingException e) { writeExceptionResponse(e, messageId, id); return; } writeSuccessResponse(messageId, id); }
void handleCreateSubcontext(final MessageInputStream message, final int messageId, final int id) throws IOException { final Object result; try (MessageInputStream mis = message) { if (version == 1) { try (Unmarshaller unmarshaller = createUnmarshaller(mis, configuration)) { final int parameterType = unmarshaller.readUnsignedByte(); if (parameterType != Protocol.P_NAME) { Messages.log.unexpectedParameterType(Protocol.P_NAME, parameterType); } final Name name = unmarshaller.readObject(Name.class); result = localContext.createSubcontext(name); } catch (ClassNotFoundException e) { throw new IOException(e); } } else { mis.readInt(); // consume authId final String name = mis.readUTF(); result = localContext.createSubcontext(name); } } catch (NamingException e) { writeExceptionResponse(e, messageId, id); return; } writeSuccessResponse(messageId, id, result); }
void handleDestroySubcontext(final MessageInputStream message, final int messageId, final int id) throws IOException { try (MessageInputStream mis = message) { if (version == 1) { try (Unmarshaller unmarshaller = createUnmarshaller(mis, configuration)) { final int parameterType = unmarshaller.readUnsignedByte(); if (parameterType != Protocol.P_NAME) { Messages.log.unexpectedParameterType(Protocol.P_NAME, parameterType); } final Name name = unmarshaller.readObject(Name.class); localContext.destroySubcontext(name); } catch (ClassNotFoundException e) { throw new IOException(e); } } else { mis.readInt(); // consume authId final String name = mis.readUTF(); localContext.destroySubcontext(name); } } catch (NamingException e) { writeExceptionResponse(e, messageId, id); return; } writeSuccessResponse(messageId, id); }
unmarshaller.start(response); result = unmarshaller.readObject(); int attachments = unmarshaller.readUnsignedByte(); final EJBClientInvocationContext clientInvocationContext = receiverInvocationContext.getClientInvocationContext(); for (int i = 0; i < attachments; i ++) {
if (version == 1) { try (Unmarshaller unmarshaller = createUnmarshaller(mis, configuration)) { final int parameterType = unmarshaller.readUnsignedByte(); if (parameterType != Protocol.P_NAME) { Messages.log.unexpectedParameterType(Protocol.P_NAME, parameterType);
if (version == 1) { try (Unmarshaller unmarshaller = createUnmarshaller(mis, configuration)) { final int parameterType = unmarshaller.readUnsignedByte(); if (parameterType != Protocol.P_NAME) { Messages.log.unexpectedParameterType(Protocol.P_NAME, parameterType);
weakAffinity = unmarshaller.readObject(Affinity.class); if (weakAffinity == null) weakAffinity = Affinity.NONE; int flags = unmarshaller.readUnsignedByte(); responseCompressLevel = flags & Protocol.COMPRESS_RESPONSE; transactionSupplier = readTransaction(unmarshaller);
try (Unmarshaller unmarshaller = createUnmarshaller(is, configuration)) { for (int i = 0; i < listSize; i++) { final int b = unmarshaller.readUnsignedByte(); if (b == Protocol.P_CONTEXT) { CompositeName prefix = (CompositeName) compositeName.clone();
if (version < 3) { int attachments = unmarshaller.readUnsignedByte(); for (int i = 0; i < attachments; i ++) { unmarshaller.readObject();
@Override public Class<?> readClass(final Unmarshaller unmarshaller) throws IOException, ClassNotFoundException { int idx = unmarshaller.readUnsignedByte(); if (idx >= classes.length) { throw new ClassNotFoundException("ClassTable " + this.getClass().getName() + " cannot find a class for class index " + idx); } return classes[idx]; }