Ferreteria/v0.4/frame

From Woozle Writes Code
Jump to navigation Jump to search

The framework class-set handles collections of objects, some of which may be creatable on demand. It is a fixed-depth hierarchy consisting of the following class families:

  • Piece - a handler or "box" for an object which may or may not yet be present. Some Pieces can create their objects on demand.
  • Space - a collection of Pieces defined by a particular code-module (e.g. Ferreteria, or a Ferreteria dropin)
  • Volume - a collection of Spaces used more broadly, with each Space having a fixed and unique access method
    • Not yet sure if different Volumes will be created during the same session.

Data Space

The concept was originally developed in order to solve the specific problem of needing to share information among certain data-class families:

  • Databases need to be accessible by various created objects
  • Tables need to be accessible by various objects they create, and also need access to their parent Database
  • Rowsets need to have access to their parent Database and Table
  • Records need to have access to their parent Database and Table and sometimes their source Rowset

At first, I thought it should follow the pattern of only being introduced to rows and rowsets at the point where they start to need the Database and Table, but then I realized that part of the point of using Frames is that you can have a uniform construction interface without necessarily including any objects at all.

Fields

The framework concept was soon expanded to handle Field Collective objects, which eventually led to the realization of needing two layers of collection (Spaces and Volumes), so that access methodology would be uniform regardless of what combination of Pieces were needed.