basic objects - LeFreq/Singularity GitHub Wiki

This is out-of-date or needs updated. See all objects

Basic "objects" are quasi objects store take no data, but just are there to re-present data. (??calculating a simple function (like addition)?).

Objects have an identity besides their immediate object name. They inherit the name, separated by ".", of every node enclosing it. The ultimate node, implicit, is "Singularity".

Initiating an object: Object(parameter list) or initlist > Object? The OS can check if the parameters meet type requirement at initiatialization. the latter might be preferred if we want to use the () syntax to group objects together. ObjectGroup(Object1, Object2). This would add Object1 and 2 to a list of subobject in OBjevtGroup without needing to write any codfe at all. A policy, then, for what happens when data is sent in > to such an object. Default polices for 1 subobjevct, multiple subojbecvts of the smae type, multiples of different types, or no sub objects. With no subobjevt, data is stored as a special _state_ variable. We don't have the experience or wisdom to decide these policies at this time. Like, when the data is a homgeneous list and the subobjects are homogeneous.

The OS queues messages to an object can queue messages that come in from using the object name. These messages are then automatically sent to the in<< function for processing when the object is not busy(?). Data that is generated then get sent out the out>> function.

Basic objects are the minimal set of objects or semantics which allow the EpistemicsOfData. A dictionary is like the first GROUP + DATA

 These can be called ''literals'', a "string", number, or even a file.  When a basic object is RUN, it outputs its basic type:  number, float-point number, name (string), 3-element structure (really three basic objects floating freely), a 5-node graph.  The basic object called a graph can be connected to other graph basic objects by linking them.   Once an object changes, the linkded nodes "feel" it.

Base objects are connected to other objects by a LINKs!!. Basic objects have a color or distinct/unique symbol.

Base objects:

  • ? Reveal DATA: show state by outputting any held variable(s).
  • % make GROUP
  • >> output the intput (echo) LINK
  • << RUN the object. If there's no code to run, output NULL.
It's possible that expressions on the command line (and elsewhere?) need parsed with a hierarchy defined so that data1 >> Object << data2 can be done. Alternative answer, define a "parallel container": ([list1], [list2]) >> Object.

XXXNEWBASE(BASE1 BASE2 ... OP) will create a new base object NEWBASE that is the combination of BASE values after applying the OP operation on them. OPS:

  • arithmetic operators (+, -, *, /)
  • database operators (row
  • sorting and string processing operators (LEFT(2), SORT(index=LastName), etc.)
  • language operators (AddTitle "Mr." FIRST LAST)
Base types:
  • string-ons, building bigger types like sentences, paragraphs, chapters, and books.
  • numbers
  • file
XXX POSTALADDRESS(NAME, HOUSESTRING(First) STRING(Address) STRING(LastName) OR STRING("Smith") A set of characters with double-quotes is considered a STRING base object.

TABLE(ROW ROW2 SORT(Index=LastName))

BaseSUM(Base1 Base2 +) will create a new base object "BaseSUM" that is the combination of values from base1 and base2).

⚠️ **GitHub.com Fallback** ⚠️