Histórico da Página
...
Retorna um array com o objeto Attribute de cada uma das propriedades que possuem a annotation Annotation do objeto enviado.
Sintaxe
...
Nome | Tipo | Descrição | Obrigatório | Referência |
---|---|---|---|---|
oObj | objeto | Objeto onde a busca será realizada | X | |
cAnnotationName | caractere | Nome da annotation Annotation a ser procurada | X |
Retorno
Nome | Tipo | Descrição |
---|---|---|
aRet | Array | Retorna um array com contendo os objetos do tipo Attribute. |
Exemplos
Bloco de código | ||||||||
---|---|---|---|---|---|---|---|---|
| ||||||||
#include "tlpp-objectcore.th" @annotation attr @end Class GetAttributesByAnnotation @attr() Public Data cAttr as Character Public Method New() EndClass Method New() class GetAttributesByAnnotation ::cAttr := "initialized" Return self Function u_testGetAttributesByAnnotation() Local aAttr as Array local obj as Object obj := GetAttributesByAnnotation():New() aAttr := Reflection.getAttributesByAnnotation(obj, "attr") ConOut(aAttr[1]:cAttributeName) ConOut(aAttr[1]:cAttributeType) Return |
...
Visão Geral
Import HTML Content
Conteúdo das Ferramentas
Tarefas