LaKraven / LKSL

LaKraven Studios Standard Library
http://otapi.com
Other
51 stars 15 forks source link

Separate "Streamables" requirement from TLKEvent #12

Closed LaKraven closed 9 years ago

LaKraven commented 9 years ago

It has become apparent that TLKEvent itself should NOT implement TLKStreamable.

The engine should not assume that ALL Events may need to be serialized into or read back from a Stream.

A separate type of "TLKEventStreamable" should be provided to handle the Streaming of Events (on an as-needed basis) where a "TLKEventStreamable" descendant is defined alongside each TLKEvent type for which the implementing developer wishes to have Streaming capability.

This is a significant interface-breaking change (depressingly) but drastically reduces the amount of code needing to be produced by the implementing developer where they do not require Streamable behavior on Events.

"TLKEventStreamable" will essentially describe the operations to be performed when its associated TLKEvent type is being deleted or read from, written or inserted into a Stream.

Any TLKEvent type described by a corresponding "TLKEventStreamable" descendant will not realistically be able to use pointers or references as part of its operative parameters (as this information is inconsistent between executions).

NOTE: This change also reduces a certain degree of operational overhead in that only TLKEvent types described by a corresponding "TLKEventStreamable" descendant will be passed over to Event Transmitters or Event Recorders.

LaKraven commented 9 years ago

Completed in Merge #17