Unserialize. Object.
@waring. Unserializing a resource will generate a new resource
545712
public function unserialize($data)
    {
        $connectionSettings = new ConnectionSettings( json_decode( $data, true ) );
        $this->__construct( $connectionSettings );
    }
338131
def clean_unserializable_data(data, stack = [])
      return "[possible infinite recursion halted]" if stack.any?{|item| item == data.object_id }

      if data.respond_to?(:to_hash)
        data.to_hash.inject({}) do |result, (key, value)|
          result.merge(key => clean_unserializable_data(value, stack + [data.object_id]))
        end
      elsif data.respond_to?(:to_ary)
        data.collect do |value|
          clean_unserializable_data(value, stack + [data.object_id])
        end
      else
        data.to_s
      end
    end
192361
private static void serialize(Serializable object, OutputStream output) throws IOException {
        BufferedOutputStream bos = new BufferedOutputStream(output);
        ObjectOutputStream oos = new ObjectOutputStream(bos);
        oos.writeObject(object);
        bos.flush();
    }
1313965
public static function toSerialize($resource) {
		if (!self::isArray($resource)) {
			$resource = self::toArray($resource);
		}

		return serialize($resource);
	}
1179762
@Override
    public byte[] serialize(Object theObject)
    {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
        {
            Tr.entry(tc, "serialize = " + theObject.getClass());
        }

        byte[] idBytes = null;

        if (theObject instanceof WrapperProxy) // F58064
        {
            WrapperProxyState state = WrapperProxyState.getWrapperProxyState(theObject);
            idBytes = state.getSerializerBytes();

            if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
                Tr.debug(tc, "serialized a WrapperProxy for " + state);
        }
        else
        {
            EJSWrapperBase wrapper = null;
            if (theObject instanceof EJSWrapperBase)
            {
                wrapper = (EJSWrapperBase) theObject;
            }
            else if (theObject instanceof LocalBeanWrapper) // d609263
            {
                wrapper = EJSWrapperCommon.getLocalBeanWrapperBase((LocalBeanWrapper) theObject);
            }
            else
            {
                throw new IllegalArgumentException(" theObject parameter must be a EJB_LOCAL, EJB_LOCAL_HOME"
                                                   + ", EJB_BUSINESS_LOCAL, or EJB_BUSINESS_REMOTE ObjectType. Use the getObjectType"
                                                   + " to obtain the ObjectType.");
            }

            // Get the BeanId and WrapperInterface from the wrapper.
            BeanId beanId = wrapper.beanId;
            WrapperInterface wrapperInterface = wrapper.ivInterface;
            BeanMetaData bmd = wrapper.bmd;

            // Use type of wrapper interface to determine whether to
            // serialize a WrapperId or a BeanId object.
            if (wrapperInterface == WrapperInterface.BUSINESS_LOCAL)
            {
                // Serialize a WrapperId for local business interface.
                int interfaceIndex = wrapper.ivBusinessInterfaceIndex;
                String interfaceName;
                if (interfaceIndex == EJSWrapperBase.AGGREGATE_LOCAL_INDEX) { // F743-34304
                    interfaceName = EJSWrapperBase.AGGREGATE_EYE_CATCHER; // d677413
                } else {
                    Class<?> biClass = bmd.ivBusinessLocalInterfaceClasses[interfaceIndex];
                    interfaceName = biClass.getName();
                }
                WrapperId wrapperId = new WrapperId(beanId.getByteArrayBytes() //d458325
                , interfaceName
                                , interfaceIndex);
                idBytes = wrapperId.getBytes();
                if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
                {
                    Tr.debug(tc, "serialized a WrapperId for BeanId = " + beanId
                                 + ", local business interface = " + interfaceName);
                }
            }
            else if (wrapperInterface == WrapperInterface.BUSINESS_REMOTE)
            {
                // Serialize a WrapperId for remote business interface.
                int interfaceIndex = wrapper.ivBusinessInterfaceIndex;
                Class<?> biClass = bmd.ivBusinessRemoteInterfaceClasses[interfaceIndex];
                String interfaceName = biClass.getName();
                WrapperId wrapperId = new WrapperId(beanId.getByteArrayBytes() //d458325
                , interfaceName
                                , interfaceIndex);
                idBytes = wrapperId.getBytes();
                if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
                {
                    Tr.debug(tc, "serialized a WrapperId for BeanId = " + beanId
                                 + ", remote business interface = " + interfaceName);
                }
            }
            else if (wrapperInterface == WrapperInterface.BUSINESS_RMI_REMOTE)
            {
                // Serialize a WrapperId for a RMI remote business interface.
                int interfaceIndex = wrapper.ivBusinessInterfaceIndex;
                Class<?> biClass = bmd.ivBusinessRemoteInterfaceClasses[interfaceIndex];
                String interfaceName = biClass.getName();
                WrapperId wrapperId = new WrapperId(beanId.getByteArrayBytes() //d458325
                , interfaceName
                                , interfaceIndex);
                idBytes = wrapperId.getBytes();
                if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
                {
                    Tr.debug(tc, "serialized a WrapperId for BeanId = " + beanId
                                 + ", RMI remote business interface = " + interfaceName);
                }
            }
            else
            {
                // Not a business interface, so must be a local or remote interface of
                // a 2.1 bean or a 2.1 view of a EJB 3 bean.  Either case, we only need
                // to save the BeanId for this kind of wrapper.
                idBytes = beanId.getByteArrayBytes(); //d466573
                if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
                {
                    Tr.debug(tc, "serialized a BeanId = " + beanId);
                }
            }
        }

        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
        {
            Tr.exit(tc, "serialize");
        }

        return idBytes;
    }
999257
protected void unsetSerializationService(ServiceReference<SerializationService> ref) {
        if (TraceComponent.isAnyTracingEnabled() && LoggingUtil.SESSION_LOGGER_WAS.isLoggable(Level.FINE)) {
            LoggingUtil.SESSION_LOGGER_WAS.logp(Level.FINE, methodClassName, "unsetSerializationService", "unsetting " + ref);
        }
        serializationServiceRef.unsetReference(ref);
    }
930410
public function unserialize($data)
    {
        $object = @unserialize($data);
        if($object === false) {
            throw new SerializerException("Unable to unserialize data: " . $data);
        }

        return $object;
    }
631032
def create
      @object = resource.new(object_params)
      authorize_for(action: :create,
                    resource: resource.name.underscore.to_sym,
                    object: @object)
      if @object.save
        render json: @object.to_json, status: :created
      else
        render json: @object.errors, status: :unprocessable_entity
      end
    end
104845
function(json){
  
  // Protect against forgetting the new keyword when calling the constructor
  if(!(this instanceof ResourceReference)){
    return new ResourceReference(json);
  }
  
  // If the given object is already an instance then just return it. DON'T copy it.
  if(ResourceReference.isInstance(json)){
    return json;
  }
  
  this.init(json);
}
863763
def unserialize(cls, string):
        
        id_s, created_s = string.split('_')
        return cls(int(id_s, 16),
                   datetime.utcfromtimestamp(int(created_s, 16)))
285058
function serialize(model) {
    var data = model.toJSON();
    Object.keys(data).forEach(function serializeRecur(key) {
        var value = data[key];
        // if any value can be serialized toJSON() then do it
        if (value && value.toJSON) {
            data[key] = data[key].toJSON();
        }
    });
    return data;
}
1318466
public function unserializeAttributes()
    {
        foreach ($this->attributes as $key => $attribute) {
            $default = is_numeric($key) ? [] : $attribute;
            $attribute = is_numeric($key) ? $attribute : $key;
            $value = $this->owner->getAttribute($attribute);
            if (is_array($value)) {
                continue;
            }
            switch ($this->type) {
                case static::TYPE_JSON :
                    $value = $value ? json_decode($value, true) : [];
                    break;
                case static::TYPE_PHP :
                    $value = $value ? unserialize($value) : [];
                    break;
                default: throw new Exception("Unknown type: ". $this->type);
            }
            $value = (!$value && $this->owner->isNewRecord) ? $default : $value;
            $this->owner->setAttribute($attribute, $value);
        }
    }
702450
private Object serializationClone(Object source) {
		ObjectOutputStream oos = null;
		ObjectInputStream ois = null;
		try {
			ByteArrayOutputStream bos = new ByteArrayOutputStream();
			oos = new ObjectOutputStream(bos);
			oos.writeObject(source);
			oos.flush();
			ByteArrayInputStream bin = new ByteArrayInputStream(bos.toByteArray());
			ois = new ObjectInputStream(bin);
			return ois.readObject();
		} catch (Exception e) {
			throw new RuntimeException(e);
		} finally {
			close(oos);
			close(ois);
		}
	}
1018028
public static Resource create(@NotNull ResourceResolver resourceResolver, @NotNull ValueMap valueMap) {
    return create(resourceResolver, null, JcrConstants.NT_UNSTRUCTURED, valueMap);
  }
999288
@JsonProperty
    public Serializable getSerializable()
    {
        return new Serializable(type, value == null ? null : Utils.nativeValueToBlock(type, value));
    }
330368
def unserialize(self, data):
        

        # copy activity attributes into object
        if "author" not in data["object"]:
            data["object"]["author"] = data["actor"]
        for key in ["to", "cc", "bto", "bcc"]:
            if key not in data["object"] and key in data:
                data["object"][key] = data[key]

        Mapper(pypump=self._pump).parse_map(self, data=data)
        self._add_links(data)

        return self
1295513
@SuppressWarnings("unchecked")
	public static <T> T unserialize(byte[] bytes) {
		ObjectInputStream ois = null;
		try {
			ByteArrayInputStream bais = new ByteArrayInputStream(bytes);
			ois = new ObjectInputStream(bais);
			return (T) ois.readObject();
		} catch (Exception e) {
			throw new UtilException(e);
		}
	}