Cannot create Relation subkind.

I've run into a problem with the new Data Layer. I'm trying to make a new Relation type, but I cannot extend the default Relation kind as it's private. I also can't make an entirely new kind though, because enyo.RelationalModel checks it's attributes for instances of Relation.

Is there a way to get the constructor of the Relation super-kind of of one of the Relation subkinds?


  • To be more specific, in my enyo 2.4 based data layer I can make api calls that return composite data types. These composite data objects contain the requested model as well as some other associated models. These associated models don't necessarily need to be direct relations of the requested model.

    For instance, I have a "WatchedVideo" model that can be requested with an associate Video, Season, Series and User. The WatchedVideo references the video directly, but not the season, and not the series. The season is referenced through the video, and the series is referensed through the season.

    In my curent api, I can define a relation that is "import only", which adds or merges the associated models into the enyo.Store so I can find them later on.

    The same thing applies to nested collections. I can request programs as composite and receive an array of series, an array of seasons, and an array of episodes. They're all imported into the store and once requested I can retrieve multiple levels of relations from the store easily.

    I would like to be able to create such an "import only" relation kind.
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!