TReader class
Generic reader object which reads component data from any given source.
Declaration
TReader = class(TFiler)Inheritance
Descends from it: TDelphiReader
Description
The TReader class is a reader class that implements generic
component streaming capabilities, independent of the format of the data in
the stream. It uses a driver class TAbstractObjectReader to
do the actual reading of data. The interface of the TReader class
should be identical to the interface in Delphi.
Note that the TReader design is such that it can read a single
component from a stream. It will read all children of this component, but
it is not designed to read multiple components in succession from one stream.
It should never be necessary to create an instance of this class directly. Instead, the ReadComponent call should be used.
See also
Properties
PropName | protected | Name of the property being read at this moment. |
CanHandleExceptions | protected | Indicates whether the reader is handling exceptions at this stage. |
Driver | public | The driver in use for streaming the data. |
Owner | public | Owner of the component being read. |
Parent | public | Parent of the component being read. |
RawMode | public | |
DelphiCompatible | public |
Methods
Error | protected | Calls an installed error handler and passes it Message. |
FindMethod | protected | Return the address of a published method. |
ReadProperty | protected | Read and process a property name. |
ReadPropValue | protected | Reads a property value for PropInfo. |
PropertyError | protected | Skips a property value and raises an exception. |
ReadData | protected | Reads the components data after it has been created. |
DoReadString | protected | |
SetName | protected | |
CreateDriver | protected | |
Create | public | Creates a new reader class. |
Destroy | public | Destroys a reader class. |
FlushBuffer | public | Flush the buffer. |
BeginReferences | public | Initializes the component referencing mechanism. |
CheckValue | public | Raises an exception if the next value in the stream is not of type Value. |
DefineProperty | public | Reads a user-defined property from the stream. |
DefineBinaryProperty | public | Reads a user-defined binary property from the stream. |
EndOfList | public | Returns true if the stream contains an end-of-list marker. |
EndReferences | public | Finalizes the component referencing mechanism. |
FixupReferences | public | Tries to resolve all unresolved component references. |
SkipValue | public | |
NextValue | public | Returns the type of the next value. |
Read | public | Read raw data from stream. |
ReadPrefix | public | |
ReadBoolean | public | Reads a boolean from the stream. |
ReadChar | public | Reads a character from the stream. |
ReadWideChar | public | Read widechar from the stream. |
ReadUnicodeChar | public | Read Unicode character. |
ReadCollection | public | Reads a collection from the stream. |
ReadComponent | public | Starts reading a component from the stream. |
ReadComponents | public | Starts reading child components from the stream. |
ReadFloat | public | Reads a float from the stream. |
ReadSingle | public | Reads a single-type real from the stream. |
ReadDouble | public | |
ReadDate | public | Reads a date from the stream. |
ReadCurrency | public | Read a currency value from the stream. |
ReadIdent | public | Reads an identifier from the stream. |
ReadInteger | public | Reads an integer from the stream. |
ReadInt64 | public | Reads a 64-bit integer from the stream. |
ReadSet | public | Read a set value from the stream. |
ReadListBegin | public | Checks for the beginning of a list. |
ReadListEnd | public | Checks for the end of a list. |
ReadRootComponent | public | Starts reading a root component. |
ReadComponentDeltaRes | public | |
ReadVariant | public | Read a variant from the stream. |
ReadSignature | public | Read stream signature from the stream. |
ReadStr | public | |
ReadString | public | Reads a string from the stream. |
ReadWideString | public | Read a WideString value from the stream. |
ReadUnicodeString | public | Read a UnicodeString value from the stream. |
ReadValue | public | Reads the next value type from the stream. |
CopyValue | public | Copy a value to a writer. |
Events
OnError | public | Handler called when an error occurs. |
OnPropertyNotFound | public | Handler for treating missing properties. |
OnFindMethod | public | Handler to find or change a method address. |
OnSetMethodProperty | public | Handler for setting method properties. |
OnSetName | public | Handler called when setting a component name. |
OnReferenceName | public | Handler called when another component is referenced. |
OnAncestorNotFound | public | Handler called when the ancestor component cannot be found. |
OnCreateComponent | public | Handler called when a component needs to be created. |
OnFindComponentClass | public | Handler called when a component class reference needs to be found. |
OnFindComponentClassEx | public | |
OnReadStringProperty | public | Handler for translating strings when read from the stream. |
Inherited
From TFiler (5)
From TObject (40)
AfterConstruction BeforeDestruction CheckDisposed ClassInfo ClassName ClassNameIs ClassParent ClassType CleanupInstance DefaultHandler DefaultHandlerStr Dispatch DispatchStr Disposed DisposeOf Equals FieldAddress Free FreeInstance GetDisposed GetHashCode GetInterface GetInterfaceByStr GetInterfaceEntry GetInterfaceEntryByStr GetInterfaceTable GetInterfaceWeak GetLastCastErrorInfo InheritsFrom InitInstance InstanceSize MethodAddress MethodName newinstance QualifiedClassName SafeCallException StringMessageTable SystemHasExtendedRTTI ToString UnitName
An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
