Refine search
private synchronized void readObject(java.io.ObjectInputStream in) throws IOException, ClassNotFoundException { ObjectInputStream.GetField gfields = in.readFields(); @SuppressWarnings("unchecked") Hashtable<String, BundlePermission> hashtable = (Hashtable<String, BundlePermission>) gfields.get("permissions", null); permissions = new HashMap<String, BundlePermission>(hashtable); all_allowed = gfields.get("all_allowed", false); } }
private synchronized void readObject(java.io.ObjectInputStream in) throws IOException, ClassNotFoundException { ObjectInputStream.GetField gfields = in.readFields(); @SuppressWarnings("unchecked") Hashtable<String, AdminPermission> hashtable = (Hashtable<String, AdminPermission>) gfields.get("permissions", null); permissions = new HashMap<String, AdminPermission>(hashtable); all_allowed = gfields.get("all_allowed", false); } }
@SuppressWarnings("unchecked") // we have to trust that keys are Ks and values are Vs private void readObject(ObjectInputStream stream) throws IOException, ClassNotFoundException { GetField fields = stream.readFields(); comparator = (Comparator<? super K>) fields.get("comparator", null); if (comparator == null) { comparator = (Comparator<? super K>) NATURAL_ORDER; } int size = stream.readInt(); for (int i = 0; i < size; i++) { putInternal((K) stream.readObject(), (V) stream.readObject()); } }
/** * Reconstitutes the instance from a stream (that is, deserializes it). */ private void readObject(java.io.ObjectInputStream s) throws java.io.IOException, ClassNotFoundException, java.io.InvalidObjectException { // Note: This must be changed if any additional fields are defined Object a = s.readFields().get("array", null); if (a == null || !a.getClass().isArray()) throw new java.io.InvalidObjectException("Not array type"); if (a.getClass() != Object[].class) a = Arrays.copyOf((Object[])a, Array.getLength(a), Object[].class); unsafe.putObjectVolatile(this, arrayFieldOffset, a); }
private synchronized void readObject(java.io.ObjectInputStream in) throws IOException, ClassNotFoundException { ObjectInputStream.GetField gfields = in.readFields(); permissions = (HashMap<String, EndpointPermission>) gfields.get("permissions", new HashMap<String, EndpointPermission>()); all_allowed = gfields.get("all_allowed", false); } }
private synchronized void readObject(java.io.ObjectInputStream in) throws IOException, ClassNotFoundException { ObjectInputStream.GetField gfields = in.readFields(); Hashtable<String, TopicPermission> hashtable = (Hashtable<String, TopicPermission>) gfields.get("permissions", null); permissions = new HashMap<String, TopicPermission>(hashtable); all_allowed = gfields.get("all_allowed", false); } }
private synchronized void readObject(java.io.ObjectInputStream in) throws IOException, ClassNotFoundException { ObjectInputStream.GetField gfields = in.readFields(); @SuppressWarnings("unchecked") HashMap<String, AdaptPermission> p = (HashMap<String, AdaptPermission>) gfields.get("permissions", null); permissions = p; all_allowed = gfields.get("all_allowed", false); } }
private synchronized void readObject(java.io.ObjectInputStream in) throws IOException, ClassNotFoundException { ObjectInputStream.GetField gfields = in.readFields(); permissions = (HashMap<String, CoordinationPermission>) gfields.get("permissions", null); all_allowed = gfields.get("all_allowed", false); } }
private synchronized void readObject(java.io.ObjectInputStream in) throws IOException, ClassNotFoundException { ObjectInputStream.GetField gfields = in.readFields(); HashMap<String, SubsystemPermission> p = (HashMap<String, SubsystemPermission>) gfields.get("permissions", null); permissions = p; all_allowed = gfields.get("all_allowed", false); } }
private synchronized void readObject(java.io.ObjectInputStream in) throws IOException, ClassNotFoundException { ObjectInputStream.GetField gfields = in.readFields(); @SuppressWarnings("unchecked") Hashtable<String, ServicePermission> hashtable = (Hashtable<String, ServicePermission>) gfields.get("permissions", null); permissions = new HashMap<String, ServicePermission>(hashtable); all_allowed = gfields.get("all_allowed", false); @SuppressWarnings("unchecked") HashMap<String, ServicePermission> fp = (HashMap<String, ServicePermission>) gfields.get("filterPermissions", null); filterPermissions = fp; } }
private synchronized void readObject(java.io.ObjectInputStream in) throws IOException, ClassNotFoundException { ObjectInputStream.GetField gfields = in.readFields(); @SuppressWarnings("unchecked") Hashtable<String, PackagePermission> hashtable = (Hashtable<String, PackagePermission>) gfields.get("permissions", null); permissions = new HashMap<String, PackagePermission>(hashtable); all_allowed = gfields.get("all_allowed", false); @SuppressWarnings("unchecked") HashMap<String, PackagePermission> fp = (HashMap<String, PackagePermission>) gfields.get("filterPermissions", null); filterPermissions = fp; } }
@SuppressWarnings("unchecked") private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException { ObjectInputStream.GetField readFields = in.readFields(); sourceBean = readFields.get("source", null); listeners = new CopyOnWriteArrayList<PropertyChangeListener>(); Map<String, PropertyChangeSupport> children = (Map<String, PropertyChangeSupport>) readFields.get("children", null); if (children != null) { for (Map.Entry<String, PropertyChangeSupport> entry : children.entrySet()) { for (PropertyChangeListener p : entry.getValue().listeners) { listeners.add(new PropertyChangeListenerProxy(entry.getKey(), p)); } } } PropertyChangeListener listener; while ((listener = (PropertyChangeListener) in.readObject()) != null) { listeners.add(listener); } }
private synchronized void readObject(java.io.ObjectInputStream in) throws IOException, ClassNotFoundException { ObjectInputStream.GetField gfields = in.readFields(); boolean hasElement = gfields.get("hasElement", false); if (hasElement) { // old format permissions = new HashMap<String, ConfigurationPermission>(); permissions.put("*", new ConfigurationPermission("*", ConfigurationPermission.CONFIGURE)); all_allowed = true; } else { permissions = (HashMap<String, ConfigurationPermission>) gfields.get("permissions", new HashMap<String, ConfigurationPermission>()); all_allowed = gfields.get("all_allowed", false); } } }
private synchronized void readObject(java.io.ObjectInputStream in) throws IOException, ClassNotFoundException { ObjectInputStream.GetField gfields = in.readFields(); @SuppressWarnings("unchecked") HashMap<String, CapabilityPermission> p = (HashMap<String, CapabilityPermission>) gfields.get("permissions", null); permissions = p; all_allowed = gfields.get("all_allowed", false); @SuppressWarnings("unchecked") HashMap<String, CapabilityPermission> fp = (HashMap<String, CapabilityPermission>) gfields.get("filterPermissions", null); filterPermissions = fp; } }
private void readObject(ObjectInputStream stream) throws IOException, ClassNotFoundException { ObjectInputStream.GetField fields = stream.readFields(); countryCode = (String) fields.get("country", ""); languageCode = (String) fields.get("language", ""); variantCode = (String) fields.get("variant", ""); } }
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException { ObjectInputStream.GetField fields = in.readFields(); int count = fields.get("count", 0); char[] value = (char[]) fields.get("value", null); set(value, count); } }
private void readObject(ObjectInputStream stream) throws IOException, ClassNotFoundException { ObjectInputStream.GetField fields = stream.readFields(); int version = fields.get("serialVersionOnStream", 0); Date date; if (version > 0) { date = (Date) fields.get("defaultCenturyStart", new Date()); } else { date = new Date(); } set2DigitYearStart(date); formatData = (DateFormatSymbols) fields.get("formatData", null); pattern = (String) fields.get("pattern", ""); } }
private void readObject(ObjectInputStream stream) throws IOException, ClassNotFoundException { ObjectInputStream.GetField fields = stream.readFields(); argumentNumbers = (int[]) fields.get("argumentNumbers", null); formats = (Format[]) fields.get("formats", null); locale = (Locale) fields.get("locale", null); maxOffset = fields.get("maxOffset", 0); int[] offsets = (int[]) fields.get("offsets", null); String pattern = (String) fields.get("pattern", null); int length; if (maxOffset < 0) { length = pattern.length() > 0 ? 1 : 0; } else { length = maxOffset + (offsets[maxOffset] == pattern.length() ? 1 : 2); } strings = new String[length]; int last = 0; for (int i = 0; i <= maxOffset; i++) { strings[i] = pattern.substring(last, offsets[i]); last = offsets[i]; } if (maxOffset + 1 < strings.length) { strings[strings.length - 1] = pattern.substring(last, pattern .length()); } }
private void readObject(ObjectInputStream stream) throws IOException, ClassNotFoundException { ObjectInputStream.GetField fields = stream.readFields(); int addr = fields.get("address", 0); ipaddress = new byte[4]; Memory.pokeInt(ipaddress, 0, addr, ByteOrder.BIG_ENDIAN); hostName = (String) fields.get("hostName", null); family = fields.get("family", 2); }
private void readObject(ObjectInputStream ois) throws ClassNotFoundException, IOException { final ObjectInputStream.GetField fields = ois.readFields(); try { final Object identifierObj = fields.get("identifier", null); // if not null, the old *Name fields will share backreferences with the fields of the identifier at a cost of 4 bytes final EJBIdentifier identifier = identifierObj != null ? (EJBIdentifier) identifierObj : new EJBIdentifier( (String) fields.get("appName", null), (String) fields.get("moduleName", null), (String) fields.get("beanName", null), (String) fields.get("distinctName", null) ); viewTypeSetter.set(this, fields.get("viewType", null)); identifierSetter.set(this, identifier); affinitySetter.set(this, fields.get("affinity", Affinity.NONE)); } catch ( IOException | RuntimeException | Error e) { throw e; } catch (Throwable t) { throw new UndeclaredThrowableException(t); } }