Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

projectstructure and writing projects #42

Closed
tmays opened this issue Sep 28, 2012 · 2 comments
Closed

projectstructure and writing projects #42

tmays opened this issue Sep 28, 2012 · 2 comments
Assignees
Milestone

Comments

@tmays
Copy link
Member

tmays commented Sep 28, 2012

I've been working quite a bit on the collecting of project data defined by the contents of the system::projectstructure key in order to write a project, and I have arrived at something that is very functional and flexible, that I think yo will like. It goes much farther that what would simply be needed for tapemovie, so that the functions are powerful enough to satisfy the many different ways of working with span that we want to anticipate.

here's the syntax:

inside the system::projectstructure

  1. keys that are empty dictionaries will cause the entire key to be written to the projectfile

i.e. :

    "projectstructure" :        {
        "projectinfo" :             {

        },

        "paths" :           {

        }
    }

This will put the entire projectinfo and paths keys into the projectfile.

  1. if a projectstructure key contains subkeys, the contents of the subkeys will determine what will be written, and not the entire projectstructure key:

i.e. :

    "projectstructure" :        {
        "nodes" :           {
            "del" :                 {

            }

        }
    }

This will write the entire contents of nodes::del, since "del" here is an empty key.

  1. If a subkey is not a dictionary but just contains referenced data, that data represents the keys that will be saved of that subkey.

i.e. :

    "projectstructure" :        {
        "namespace" :       {
            "filt" : "2",
            "mouse" : [ "2", "3" ]
        }
    }

This will write the entire contents of namespace::filt::2 as well as the entire contents of "namespace::mouse::2" and "namespace::mouse::3"

  1. This logic can be continued indefinitely, recursively. If you want to save certain keys (params) of a sub key of a sub key:
    "projectstructure" :        {
        "nodes" :           {
            "del" : [ "quantity", "tags" ],
            "filt" : [ "active" ]
        }

    }

This will write nodes::del::quantity (value), nodes::del::tags (value), and nodes::filt::active (value) to the projectfile.

another example:

        "namespace" :           {
            "del" :                 {
                "1" :                   {
                    "time" :                        {

                    }

                }
            }
            "ctlmap" :              {
                "1" :                   {
                    "sw" : "value"
                }

            }
        }

This will write the entire contents of the namespace::del::1::time parameter, and only the value parameter of the parameter namespace::ctlmap::1::sw

  1. wildcard ()
    For now, I have enabled ONE use of the wildcard. This could be expanded (with care). If you use "
    " as a subkey of a key of projectstructure, the "*" will be replaced with all subkeys of that named key.

I.e.

    "projectstructure" :        {
        "nodes" :           {
            "*" : [ "quantity", "tags" ]
        }

    }

Here, the quantity and tags values of all subkeys of "nodes" will be written.

  1. CURRENT example for tapemovie
    Currently, the contents of projectstructure for tapemovie are :
    "projectstructure" :        {
        "projectinfo" :             {

        },

        "paths" :           {

        },

        "nodes" :           {
            "*" : [ "quantity", "tags", "filename", "description" ]

        },

        "events" :          {

        }

    }

Which simply gets all of projectinfo, paths and events, but only the "quantity", "tags", "filename" and "description" subkeys of all subkeys of nodes (name of each module).

@ghost ghost assigned reno- Sep 28, 2012
@tmays
Copy link
Member Author

tmays commented Sep 28, 2012

I think it's necessary to include "system::projectstructure" in the projectfile. This way, when we open a project it tells the system how it should be re-saved. When we "create" a project, we can first open a "template" projectfile which will then define the system::projectstructure.

I believe this fits with what we have already discussed.

@tmays tmays mentioned this issue Sep 30, 2012
@reno-
Copy link
Member

reno- commented Jul 18, 2013

create issue #69 for making a wiki page for the project workflow

@reno- reno- closed this as completed Jul 18, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants