Smallworld Geometry

Basic Geometry Information

Topology

Queries

Styles

Dataless RWO Transactions

You can use dataset_transactions to create/join dataless records. Below is an example.

record_transaction.new_insert(
    dl_rwo_coll,
    property_list.new_with(
        :geom_fld_name,geom,
        :parent_rwo_field_name,parent_rwo))

(gotcha) Note that the geometry requires a world or you will get the following useless error:

**** Error: The insert transaction on dataset gis has failed as there are no proposed field values
     dataset_transaction_api_no_fields(operation=:insert, dataset=:gis, transaction=a sw:record_transaction)

The Other Way
You can use this way to from the parent object…

record_transaction.new_update(
    the_rec,
    property_list.new_with(
        :dataless_fld_name,{{_unset,geom1},{_unset,geom2}}))

I don't know why you need the simple vector where the 1st element is unset, but that is how the editors work. You probably need the world set on the geometries, like above…

Pseudo Geometry from Geomtery

You would think this is a basic function, but here it is. Note the setting of the world is required…

_pragma(classify_level=basic, topic={smp,lightning})
_method top_level_geometry.fcsi_as_pseudo_geometry()
    ## Parameters  : none
    ## Returns     : pseudo geometry (memory_exemplar of self) with
    ## self's world.
    ## Function    : 
    ## Methodology : 
    #---------------- HISTORY ---------------------
    # (2017/11/01 - Mark Field (FCSI)): Created.
    #----------------------------------------------
    _local pg << _self.memory_exemplar.new_with(_self)
    pg.world << _self.world
    _return pg
_endmethod
$
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License