Automatic generation produced by ISE Eiffel

Classes Clusters Cluster hierarchy Chart Relations Text Flat Contracts Flat contracts Go to:
indexing description: "[ Objects that may be stored and retrieved along with all their dependents. This class may be used as ancestor by classes needing its facilities. ]" status: "See notice at end of class" date: "$Date: 2001-11-16 20:32:23 +0000 (Fri, 16 Nov 2001) $" revision: "$Revision: 51435 $" class STORABLE feature -- Access Check_instruction: INTEGER is 7 -- Exception code for violated check -- (from EXCEP_CONST) Class_invariant: INTEGER is 6 -- Exception code for violated class invariant -- (from EXCEP_CONST) Com_exception: INTEGER is 28 -- Exception code for a COM error. -- (from EXCEP_CONST) Developer_exception: INTEGER is 24 -- Exception code for developer exception -- (from EXCEP_CONST) External_exception: INTEGER is 18 -- Exception code for operating system error -- which does not set the errno variable -- (Unix-specific) -- (from EXCEP_CONST) Floating_point_exception: INTEGER is 5 -- Exception code for floating point exception -- (from EXCEP_CONST) Incorrect_inspect_value: INTEGER is 9 -- Exception code for inspect value which is not one -- of the inspect constants, if there is no Else_part -- (from EXCEP_CONST) Io_exception: INTEGER is 21 -- Exception code for I/O error -- (from EXCEP_CONST) Loop_invariant: INTEGER is 11 -- Exception code for violated loop invariant -- (from EXCEP_CONST) Loop_variant: INTEGER is 10 -- Exception code for non-decreased loop variant -- (from EXCEP_CONST) No_more_memory: INTEGER is 2 -- Exception code for failed memory allocation -- (from EXCEP_CONST) Operating_system_exception: INTEGER is 22 -- Exception code for operating system error -- which sets the errno variable -- (Unix-specific) -- (from EXCEP_CONST) Postcondition: INTEGER is 4 -- Exception code for violated postcondition -- (from EXCEP_CONST) Precondition: INTEGER is 3 -- Exception code for violated precondition -- (from EXCEP_CONST) Rescue_exception: INTEGER is 14 -- Exception code for exception in rescue clause -- (from EXCEP_CONST) retrieve_by_name (file_name: STRING): ANY is -- Retrieve object structure, from external -- representation previously stored in a file -- called file_name. -- To access resulting object under correct type, -- use assignment attempt. -- Will raise an exception (code Retrieve_exception) -- if file content is not a stored Eiffel structure. -- Will return Void if the file does not exist or -- is not readable. require file_name_exists: file_name /= void file_name_meaningful: not file_name.is_empty local file: RAW_FILE do create file.make (file_name) if file.exists and then file.is_readable then file.open_read Result := file.retrieved file.close end end Retrieve_exception: INTEGER is 23 -- Exception code for retrieval error -- may be raised by retrieved in IO_MEDIUM. -- (from EXCEP_CONST) retrieved (medium: IO_MEDIUM): ANY is -- Retrieved object structure, from external -- representation previously stored in medium. -- To access resulting object under correct type, -- use assignment attempt. -- Will raise an exception (code Retrieve_exception) -- if medium content is not a stored Eiffel structure. require medium_not_void: medium /= void medium_exists: medium.exists medium_is_open_read: medium.is_open_read medium_supports_storable: medium.support_storable do Result := medium.retrieved ensure result_exists: Result /= void end Routine_failure: INTEGER is 8 -- Exception code for failed routine -- (from EXCEP_CONST) Runtime_io_exception: INTEGER is 27 -- Exception code for I/O error raised by runtime functions -- such as store/retrieve, file access... -- (from EXCEP_CONST) Signal_exception: INTEGER is 12 -- Exception code for operating system signal -- (from EXCEP_CONST) Void_assigned_to_expanded: INTEGER is 19 -- Exception code for assignment of void value -- to expanded entity -- (from EXCEP_CONST) Void_call_target: INTEGER is 1 -- Exception code for feature applied to void reference -- (from EXCEP_CONST) feature -- Status report assertion_violation: BOOLEAN is -- Is last exception originally due to a violated -- assertion or non-decreasing variant? -- (from EXCEPTIONS) do Result := (original_exception = check_instruction) or else (original_exception = class_invariant) or else (original_exception = loop_invariant) or else (original_exception = loop_variant) or else (original_exception = postcondition) or else (original_exception = precondition) end class_name: STRING is -- Name of the class that includes the recipient -- of original form of last exception -- (from EXCEPTIONS) external "C | %"eif_except.h%"" alias "eelclass" end developer_exception_name: STRING is -- Name of last developer-raised exception -- (from EXCEPTIONS) require -- from EXCEPTIONS applicable: is_developer_exception do Result := original_tag_name end exception: INTEGER is -- Code of last exception that occurred -- (from EXCEPTIONS) external "C | %"eif_except.h%"" alias "eelcode" end exception_trace: STRING is -- String representation of the exception trace -- (from EXCEPTIONS) external "C | %"eif_except.h%"" alias "stack_trace_string" end is_developer_exception: BOOLEAN is -- Is the last exception originally due to -- a developer exception? -- (from EXCEPTIONS) do Result := (original_exception = developer_exception) end is_developer_exception_of_name (name: STRING): BOOLEAN is -- Is the last exception originally due to a developer -- exception of name name? -- (from EXCEPTIONS) do Result := is_developer_exception and then equal (name, developer_exception_name) end is_signal: BOOLEAN is -- Is last exception originally due to an external -- event (operating system signal)? -- (from EXCEPTIONS) do Result := (original_exception = signal_exception) end is_system_exception: BOOLEAN is -- Is last exception originally due to an -- external event (operating system error)? -- (from EXCEPTIONS) do Result := (original_exception = external_exception) or else (original_exception = operating_system_exception) end meaning (except: INTEGER): STRING is -- A message in English describing what except is -- (from EXCEPTIONS) external "C | %"eif_except.h%"" alias "eename" end original_class_name: STRING is -- Name of the class that includes the recipient -- of original form of last exception -- (from EXCEPTIONS) external "C | %"eif_except.h%"" alias "eeoclass" end original_exception: INTEGER is -- Original code of last exception that triggered -- current exception -- (from EXCEPTIONS) external "C | %"eif_except.h%"" alias "eeocode" end original_recipient_name: STRING is -- Name of the routine whose execution was -- interrupted by original form of last exception -- (from EXCEPTIONS) external "C | %"eif_except.h%"" alias "eeorout" end original_tag_name: STRING is -- Assertion tag for original form of last -- assertion violation. -- (from EXCEPTIONS) external "C | %"eif_except.h%"" alias "eeotag" end recipient_name: STRING is -- Name of the routine whose execution was -- interrupted by last exception -- (from EXCEPTIONS) external "C | %"eif_except.h%"" alias "eelrout" end tag_name: STRING is -- Tag of last violated assertion clause -- (from EXCEPTIONS) external "C | %"eif_except.h%"" alias "eeltag" end feature -- Status setting catch (code: INTEGER) is -- Make sure that any exception of code code will be -- caught. This is the default. -- (from EXCEPTIONS) external "C | %"eif_except.h%"" alias "eecatch" end die (code: INTEGER) is -- Terminate execution with exit status code, -- without triggering an exception. -- (from EXCEPTIONS) external "C | %"eif_except.h%"" alias "esdie" end ignore (code: INTEGER) is -- Make sure that any exception of code code will be -- ignored. This is not the default. -- (from EXCEPTIONS) external "C | %"eif_except.h%"" alias "eeignore" end message_on_failure is -- Print an exception history table -- in case of failure. -- This is the default. -- (from EXCEPTIONS) do c_trace_exception (True) end new_die (code: INTEGER) is obsolete "Use ``die''" -- (from EXCEPTIONS) external "C | %"eif_except.h%"" alias "esdie" end no_message_on_failure is -- Do not print an exception history table -- in case of failure. -- (from EXCEPTIONS) do c_trace_exception (False) end raise (name: STRING) is -- Raise a developer exception of name name. -- (from EXCEPTIONS) local str: ANY do if name /= void then str := name.to_c end exclear eraise ($str, developer_exception) end feature -- Element change basic_store (medium: IO_MEDIUM) is -- Produce on medium an external representation of the -- entire object structure reachable from current object. -- Retrievable within current system only. require medium_not_void: medium /= void medium_exists: medium.exists medium_is_open_write: medium.is_open_write medium_supports_storable: medium.support_storable do medium.basic_store (Current) end general_store (medium: IO_MEDIUM) is -- Produce on medium an external representation of the -- entire object structure reachable from current object. -- Retrievable from other systems for same platform -- (machine architecture). require medium_not_void: medium /= void medium_exists: medium.exists medium_is_open_write: medium.is_open_write medium_supports_storable: medium.support_storable do medium.general_store (Current) end independent_store (medium: IO_MEDIUM) is -- Produce on medium an external representation of the -- entire object structure reachable from current object. -- Retrievable from other systems for the same or other -- platform (machine architecture). require medium_not_void: medium /= void medium_exists: medium.exists medium_is_open_write: medium.is_open_write medium_supports_storable: medium.support_storable do medium.independent_store (Current) end store_by_name (file_name: STRING) is -- Produce on file called file_name an external -- representation of the entire object structure -- reachable from current object. -- Retrievable from other systems for same platform -- (machine architecture). require file_name_not_void: file_name /= void file_name_meaningful: not file_name.is_empty local file: RAW_FILE a: ANY do create file.make (file_name) if (file.exists and then file.is_writable) or else (file.is_creatable) then file.open_write file.independent_store (Current) file.close else a := ("write permission failure").to_c eraise ($a, io_exception) end end feature {NONE} -- Implementation c_trace_exception (b: BOOLEAN) is -- (from EXCEPTIONS) external "C | %"eif_except.h%"" alias "eetrace" end eraise (str: POINTER; code: INTEGER) is -- Raise an exception -- (from EXCEPTIONS) external "C | %"eif_except.h%"" end exclear is -- (from EXCEPTIONS) external "C | %"eif_except.h%"" end feature -- Setting set_discard_pointers (v: BOOLEAN) is -- If v it will discard POINTER values and replace them by -- the default_pointer pointer. Otherwise it keeps the original value. external "C macro signature (EIF_BOOLEAN) use %"eif_retrieve.h%"" alias "eif_set_discard_pointer_values" end set_new_independent_format (v: BOOLEAN) is -- If v it will use ISE Eiffel 5.0 storable format for -- storing. external "C macro signature (EIF_BOOLEAN) use %"eif_store.h%"" alias "eif_set_new_independent_format" end invariant -- from ANY reflexive_equality: standard_is_equal (Current) reflexive_conformance: conforms_to (Current) indexing library: "[ EiffelBase: Library of reusable components for Eiffel. ]" status: "[ Copyright 1986-2001 Interactive Software Engineering (ISE). For ISE customers the original versions are an ISE product covered by the ISE Eiffel license and support agreements. ]" license: "[ EiffelBase may now be used by anyone as FREE SOFTWARE to develop any product, public-domain or commercial, without payment to ISE, under the terms of the ISE Free Eiffel Library License (IFELL) at http://eiffel.com/products/base/license.html. ]" source: "[ Interactive Software Engineering Inc. ISE Building 360 Storke Road, Goleta, CA 93117 USA Telephone 805-685-1006, Fax 805-685-6869 Electronic mail <info@eiffel.com> Customer support http://support.eiffel.com ]" info: "[ For latest info see award-winning pages: http://eiffel.com ]" end -- class STORABLE
Classes Clusters Cluster hierarchy Chart Relations Text Flat Contracts Flat contracts Go to:

-- Generated by ISE Eiffel --
For more details: www.eiffel.com