note
	description: "Serialize and deserialize objects to and from SED_READER_WRITER instances."
	legal: "See notice at end of class."
	status: "See notice at end of class."
	date: "$Date: 2017-09-25 15:53:33 +0000 (Mon, 25 Sep 2017) $"
	revision: "$Revision: 100789 $"

class interface
	SED_STORABLE_FACILITIES

create 
	default_create

feature -- Serialization routines

	session_store (an_object: ANY; a_writer: SED_READER_WRITER; a_optimized_for_retrieval: BOOLEAN)
			-- Serialization of an_object using a_writer.
			-- Object stored can only be retrieved during current program execution.
		require
			an_object_not_void: an_object /= Void
			a_writer_not_void: a_writer /= Void
			a_writer_ready: a_writer.is_ready_for_writing

	basic_store (an_object: ANY; a_writer: SED_READER_WRITER; a_optimized_for_retrieval: BOOLEAN)
			-- Serialization of an_object using a_writer.
			-- Object stored can only be retrieved by execution of same program executable.
		require
			an_object_not_void: an_object /= Void
			a_writer_not_void: a_writer /= Void
			a_writer_ready: a_writer.is_ready_for_writing

	store (an_object: ANY; a_writer: SED_READER_WRITER)
			-- Serialization of an_object using a_writer.
			-- Object stored can only be retrieved by programs having the same set of types.
		require
			an_object_not_void: an_object /= Void
			a_writer_not_void: a_writer /= Void
			a_writer_ready: a_writer.is_ready_for_writing

	store_in_medium (an_object: ANY; a_medium: IO_MEDIUM)
			-- Serialization of an_object in a_medium
			-- Object stored can only be retrieved by programs having the same set of types.
		require
			an_object_not_void: an_object /= Void
			a_medium_not_void: a_medium /= Void
			a_medium_writable: a_medium.is_open_write
			a_medium_support_storable: a_medium.support_storable

	retrieved (a_reader: SED_READER_WRITER; a_is_gc_enabled: BOOLEAN): detachable ANY
			-- Deserialization of object from a_reader.
			-- Garbage collection will be enabled if a_is_gc_enabled.
		require
			a_reader_not_void: a_reader /= Void
			a_reader_ready: a_reader.is_ready_for_reading

	retrieved_from_medium (a_medium: IO_MEDIUM): detachable ANY
			-- Deserialization of object from a_reader.
		require
			a_medium_not_void: a_medium /= Void
			a_medium_open_for_reading: a_medium.is_open_read
			a_medium_support_storable: a_medium.support_storable

	retrieved_errors: detachable ARRAYED_LIST [SED_ERROR]
			-- Errors set from last call to retrieved.		
	
feature -- Storable type

	Eiffel_session_store: NATURAL_32 = 1

	Eiffel_basic_store: NATURAL_32 = 2

	Eiffel_independent_store: NATURAL_32 = 3

	Eiffel_recoverable_store: NATURAL_32 = 4
			-- Various type of storable mechanism.
	
note
	library: "EiffelBase: Library of reusable components for Eiffel."
	copyright: "Copyright (c) 1984-2017, Eiffel Software and others"
	license: "Eiffel Forum License v2 (see http://www.eiffel.com/licensing/forum.txt)"
	source: "[
		Eiffel Software
		5949 Hollister Ave., Goleta, CA 93117 USA
		Telephone 805-685-1006, Fax 805-685-6869
		Website http://www.eiffel.com
		Customer support http://support.eiffel.com
	]"

end -- class SED_STORABLE_FACILITIES

Generated by ISE EiffelStudio