示例#1
0
class Invoker(Context):
    '''
    The invoker context.
    '''
    # ---------------------------------------------------------------- Required
    call = requires(TypeCall)
    location = requires(str)
示例#2
0
class Match(Context):
    '''
    The match context.
    '''
    # ---------------------------------------------------------------- Required
    gateway = requires(Context)
    groupsURI = requires(tuple)
示例#3
0
class Repository(Context):
    '''
    The repository context.
    '''
    # ---------------------------------------------------------------- Required
    children = requires(list)
    actions = requires(list)
示例#4
0
class Request(Context):
    '''
    The request context.
    '''
    # ---------------------------------------------------------------- Required
    decoderHeader = requires(IDecoderHeader)
    converter = requires(Converter)
示例#5
0
文件: base.py 项目: vivienney/Ally-Py
class Request(Context):
    '''
    The request context.
    '''
    # ---------------------------------------------------------------- Required
    decoder = requires(Callable)
    decoderData = requires(dict)
示例#6
0
class Decoding(Context):
    '''
    The decoding context.
    '''
    # ---------------------------------------------------------------- Defined
    parent = defines(Context, doc='''
    @rtype: Context
    The parent decoding that this decoding is based on.
    ''')
    doDecode = defines(IDo, doc='''
    @rtype: callable(target, value)
    Decodes the value into the provided target.
    @param target: Context
        Target context object used for decoding.
    @param value: dictionary{object: object}
        The dictionary value to be decoded.
    ''')
    isMandatory = defines(bool, doc='''
    @rtype: boolean
    Indicates that the decoding needs to have a value provided.
    ''')
    # ---------------------------------------------------------------- Optional
    doBegin = optional(IDo)
    doEnd = optional(IDo)
    # ---------------------------------------------------------------- Required
    type = requires(Type)
    doSet = requires(IDo)
    doGet = requires(IDo)
class PermissionFilter(Context):
    '''
    The permission context.
    '''
    # ---------------------------------------------------------------- Required
    path = requires(Path)
    filtersModels = requires(list)
示例#8
0
class Decoding(Context):
    '''
    The model decoding context.
    '''
    # ---------------------------------------------------------------- Defined
    name = defines(str,
                   doc='''
    @rtype: string
    The decoder name.
    ''')
    parent = defines(Context,
                     doc='''
    @rtype: Context
    The parent decoding that this decoding is based on.
    ''')
    children = defines(dict,
                       doc='''
    @rtype: dictionary{string: Context}
    The decoding children indexed by the decoding name.
    ''')
    doDecode = defines(IDo,
                       doc='''
    @rtype: callable(target, value)
    Decodes the value into the provided target.
    @param target: Context
        Target context object used for decoding.
    @param value: object
        The value to be decoded.
    ''')
    # ---------------------------------------------------------------- Required
    type = requires(Type)
    property = requires(TypeProperty)
    doSet = requires(IDo)
    doGet = requires(IDo)
示例#9
0
class Document(Context):
    '''
    The document context.
    '''
    # ---------------------------------------------------------------- Required
    loader = requires(BaseLoader)
    data = requires(dict)
示例#10
0
class Gateway(Context):
    '''
    The gateway context.
    '''
    # ---------------------------------------------------------------- Required
    navigate = requires(str)
    putHeaders = requires(dict)
示例#11
0
class RepositoryRight(Repository):
    '''
    The repository context.
    '''
    # ---------------------------------------------------------------- Required
    rightName = requires(str)
    rightId = requires(int)
示例#12
0
class Response(Context):
    '''
    The response context.
    '''
    # ---------------------------------------------------------------- Required
    obj = requires(object)
    errorInput = requires(InputError)
示例#13
0
class RequestTarget(Context):
    '''
    The request context.
    '''
    # ---------------------------------------------------------------- Required
    nodesValues = requires(dict)
    converterPath = requires(Converter)
示例#14
0
class Invoker(Context):
    '''
    The invoker context.
    '''
    # ---------------------------------------------------------------- Defined
    target = defines(TypeModel, doc='''
    @rtype: TypeModel
    The target model of the caller.
    ''')
    isCollection = defines(bool, doc='''
    @rtype: boolean
    If True it means that the invoker provides a collection.
    ''')
    isModel = defines(bool, doc='''
    @rtype: boolean
    If True it means that the invoker provides a full model, attention the model can be in a collection.
    ''')
    modelInput = defines(Input, doc='''
    @rtype: Input
    The input that is expected to receive a model object, this is only available for INSERT or UPDATE methods.
    ''')
    # ---------------------------------------------------------------- Required
    method = requires(int)
    inputs = requires(tuple)
    output = requires(Type)
    location = requires(str)
示例#15
0
class WithTracking(Context):
    '''
    Container for the tracking information.
    '''
    lineNumber = requires(int)
    colNumber = requires(int)
    uri = requires(str)
示例#16
0
class Invoker(Context):
    '''
    The invoker context.
    '''
    # ---------------------------------------------------------------- Required
    target = requires(TypeModel)
    doEncodePath = requires(IDo)
示例#17
0
class DecodingItem(Context):
    '''
    The decoding context.
    '''
    # ---------------------------------------------------------------- Defined
    isMandatory = defines(bool, doc='''
    @rtype: boolean
    Indicates that the decoding needs to have a value provided.
    ''')
    doBegin = defines(IDo, doc='''
    @rtype: callable(target)
    Required to be triggered in order to begin the decoding.
    @param target: Context
        Target context object that the decoding begins on.
    ''')
    doDecode = defines(IDo, doc='''
    @rtype: callable(target, value)
    Decodes the value into the provided target.
    @param target: Context
        Target context object used for decoding.
    @param value: tuple(object, object)
        The dictionary item value to be decoded.
    ''')
    doEnd = defines(IDo, doc='''
    @rtype: callable(target)
    Required to be triggered in order to end the decoding.
    @param target: Context
        Target context object that the decoding ends on.
    ''')
    doGet = defines(IDo)
    # ---------------------------------------------------------------- Required
    parent = requires(Context)
    type = requires(Type)
    doSet = requires(IDo)
示例#18
0
class RequestContent(Context):
    '''
    The request content context.
    '''
    # ---------------------------------------------------------------- Required
    type = requires(str)
    charSet = requires(str)
示例#19
0
class Request(Context):
    '''
    The request context.
    '''
    # ---------------------------------------------------------------- Required
    scheme = requires(str)
    decoderHeader = requires(IDecoderHeader)
示例#20
0
class Mapping(Context):
    '''
    The index mapping context.
    '''
    # ---------------------------------------------------------------- Required
    blockId = requires(int)
    block = requires(Block)
class SolicitationPutHeader(Context):
    '''
    The solicitation context.
    '''
    # ---------------------------------------------------------------- Required
    userId = requires(int)
    permissions = requires(Iterable)
class Node(Context):
    '''
    The node context.
    '''
    # ---------------------------------------------------------------- Required
    parent = requires(Context)
    invokersGet = requires(dict)
示例#23
0
class Element(Context):
    '''
    The element context.
    '''
    # ---------------------------------------------------------------- Required
    name = requires(str)
    property = requires(TypeProperty)
class Invoker(Context):
    '''
    The invoker context.
    '''
    # ---------------------------------------------------------------- Required
    node = requires(Context)
    doEncodePath = requires(IDo)
示例#25
0
class Decoding(Context):
    '''
    The decoding context.
    '''
    # ---------------------------------------------------------------- Required
    type = requires(Type)
    doDecode = requires(IDo)
示例#26
0
class Element(Context):
    '''
    The element context.
    '''
    # ---------------------------------------------------------------- Required
    node = requires(Context)
    input = requires(Input)
示例#27
0
class Request(Context):
    '''
    The request context.
    '''
    # ---------------------------------------------------------------- Required
    invoker = requires(Context)
    arguments = requires(dict)
示例#28
0
class Create(Context):
    '''
    The create decode context.
    '''
    # ---------------------------------------------------------------- Required
    decodings = requires(list)
    pathInjected = requires(dict)
示例#29
0
class Register(Context):
    '''
    The register context.
    '''
    # ---------------------------------------------------------------- Required
    invokers = requires(list)
    root = requires(Context)
示例#30
0
class ResponseEncode(Context):
    '''
    The response context.
    '''
    # ---------------------------------------------------------------- Required
    encoderHeader = requires(IEncoderHeader)
    language = requires(str)