Class TypeProjection

java.lang.Object
nz.org.riskscape.engine.projection.TypeProjection
All Implemented Interfaces:
nz.org.riskscape.engine.projection.Projection

public class TypeProjection extends Object implements nz.org.riskscape.engine.projection.Projection

Projects from one type of tuple to another. Differs from select mostly in that a select is free form and creates a type, whereas the TypeProjection imposes a type on a type.

  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    protected static class 
     
    protected static class 
     
    static enum 
     
    protected class 
     
  • Field Summary

    Fields inherited from interface nz.org.riskscape.engine.projection.Projection

    IDENTITY
  • Constructor Summary

    Constructors
    Constructor
    Description
    TypeProjection(nz.org.riskscape.engine.types.Struct targetType, Map<String,nz.org.riskscape.rl.ast.Expression> mapAttributes, EnumSet<TypeCheckingOptions> options, nz.org.riskscape.engine.rl.RealizationContext realizationContext)
     
    TypeProjection(nz.org.riskscape.engine.types.Struct targetType, Map<String,nz.org.riskscape.rl.ast.Expression> attributeMap, nz.org.riskscape.engine.rl.RealizationContext realizationContext)
     
    TypeProjection(nz.org.riskscape.engine.types.Struct targetType, nz.org.riskscape.engine.rl.RealizationContext realizationContext)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected nz.org.riskscape.problem.ResultOrProblems<TypeProjection.Mapping>
    buildMemberList(nz.org.riskscape.engine.types.Struct sourceType)
     
    nz.org.riskscape.problem.ResultOrProblems<nz.org.riskscape.engine.projection.Projector>
    getProjectionFunction(nz.org.riskscape.engine.types.Struct sourceType)
     
    nz.org.riskscape.problem.ResultOrProblems<nz.org.riskscape.engine.types.Struct>
    projectType(nz.org.riskscape.engine.types.Struct source)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • TypeProjection

      public TypeProjection(nz.org.riskscape.engine.types.Struct targetType, nz.org.riskscape.engine.rl.RealizationContext realizationContext)
    • TypeProjection

      public TypeProjection(nz.org.riskscape.engine.types.Struct targetType, Map<String,nz.org.riskscape.rl.ast.Expression> attributeMap, nz.org.riskscape.engine.rl.RealizationContext realizationContext)
    • TypeProjection

      public TypeProjection(nz.org.riskscape.engine.types.Struct targetType, Map<String,nz.org.riskscape.rl.ast.Expression> mapAttributes, EnumSet<TypeCheckingOptions> options, nz.org.riskscape.engine.rl.RealizationContext realizationContext)
  • Method Details

    • projectType

      public nz.org.riskscape.problem.ResultOrProblems<nz.org.riskscape.engine.types.Struct> projectType(nz.org.riskscape.engine.types.Struct source)
      Specified by:
      projectType in interface nz.org.riskscape.engine.projection.Projection
    • getProjectionFunction

      public nz.org.riskscape.problem.ResultOrProblems<nz.org.riskscape.engine.projection.Projector> getProjectionFunction(nz.org.riskscape.engine.types.Struct sourceType)
      Specified by:
      getProjectionFunction in interface nz.org.riskscape.engine.projection.Projection
    • buildMemberList

      protected nz.org.riskscape.problem.ResultOrProblems<TypeProjection.Mapping> buildMemberList(nz.org.riskscape.engine.types.Struct sourceType)