Search in sources :

Example 6 with Frame

use of org.w3._2007.rif.Frame in project hale by halestudio.

the class ModelRifToRifTranslator method createBindingSlot.

private void createBindingSlot(RifVariable child, Frame frame) {
    SlotFrameType slot = factory.createSlotFrameType();
    // $NON-NLS-1$
    slot.setOrdered("yes");
    Const const1 = factory.createConst();
    const1.getContent().add(child.getPropertyName());
    // $NON-NLS-1$
    const1.setType("rif:iri");
    slot.getContent().add(const1);
    Var var1 = factory.createVar();
    var1.getContent().add(child.getName());
    slot.getContent().add(var1);
    frame.getSlot().add(slot);
}
Also used : SlotFrameType(org.w3._2007.rif.SlotFrameType) ActionVar(org.w3._2007.rif.Do.ActionVar) Var(org.w3._2007.rif.Var) Const(org.w3._2007.rif.Const)

Example 7 with Frame

use of org.w3._2007.rif.Frame in project hale by halestudio.

the class ModelRifToRifTranslator method createStaticAssignmentSlot.

private void createStaticAssignmentSlot(StaticAssignment staticAssignment, Frame frame) {
    SlotFrameType slot = factory.createSlotFrameType();
    // $NON-NLS-1$
    slot.setOrdered("yes");
    Const const1 = factory.createConst();
    const1.getContent().add(staticAssignment.getTarget().getPropertyName());
    // $NON-NLS-1$
    const1.setType("rif:iri");
    slot.getContent().add(const1);
    Const const2 = factory.createConst();
    // $NON-NLS-1$
    const2.setType("http://www.w3.org/2001/XMLSchema#string");
    const2.getContent().add(staticAssignment.getContent());
    slot.getContent().add(const2);
    frame.getSlot().add(slot);
}
Also used : SlotFrameType(org.w3._2007.rif.SlotFrameType) Const(org.w3._2007.rif.Const)

Aggregations

ActionVar (org.w3._2007.rif.Do.ActionVar)4 Frame (org.w3._2007.rif.Frame)4 Var (org.w3._2007.rif.Var)4 Const (org.w3._2007.rif.Const)3 SlotFrameType (org.w3._2007.rif.SlotFrameType)3 RifVariable (com.onespatial.jrc.tns.oml_to_rif.translate.context.RifVariable)2 Formula (org.w3._2007.rif.Formula)2 ModelRifMappingCondition (com.onespatial.jrc.tns.oml_to_rif.model.rif.ModelRifMappingCondition)1 PropertyMapping (com.onespatial.jrc.tns.oml_to_rif.model.rif.PropertyMapping)1 StaticAssignment (com.onespatial.jrc.tns.oml_to_rif.model.rif.StaticAssignment)1 LinkedHashMap (java.util.LinkedHashMap)1 And (org.w3._2007.rif.And)1 Assert (org.w3._2007.rif.Assert)1 Target (org.w3._2007.rif.Assert.Target)1 Actions (org.w3._2007.rif.Do.Actions)1