Hallo, dies ist ein Test.
PWD: /www/data-lst1/unixsoft/unixsoft/kaempfer/.public_html
Running in File Mode
Relative path: ./../../../../../../usr/include/rad/adr_object.h
Real path: /usr/include/rad/adr_object.h
Zurück
/* * Copyright (c) 2012, 2018, Oracle and/or its affiliates. All rights reserved. */ /* * ADR Object Model * * These are a set of interfaces for defining a basic object model, * built using ADR types. */ #ifndef _ADR_OBJECT_H #define _ADR_OBJECT_H #include <sys/types.h> #include <stdio.h> #include <rad/adr.h> #include <rad/adr_name.h> #include <rad/adr_version.h> #ifdef __cplusplus extern "C" { #endif /* Number of stability classes: 2 (private, committed) */ #define NSTABILITY 2 /* A method parameter */ typedef struct adr_parameter { const char *ap_name; /* argument's name */ adr_type_t *ap_type; /* argument's type */ boolean_t ap_nullable; /* can this argument be "null"? */ } adr_parameter_t; /* An object method */ typedef struct adr_method { const char *am_name; /* method's name */ adr_stability_t am_stability; /* method stability classification */ int am_nargs; /* number of arguments */ adr_type_t *am_result; /* result type */ adr_type_t *am_error; /* error type */ boolean_t am_nullable; /* can the result be "null"? */ boolean_t am_error_nullable; /* can defined error be "null"? */ adr_parameter_t *am_args; /* method's arguments */ } adr_method_t; /* An object attribute */ typedef struct adr_attribute { const char *aa_name; /* attribute's name */ adr_stability_t aa_stability; /* attribute stability classification */ adr_type_t *aa_type; /* attribute's type */ adr_type_t *aa_read_error; /* attribute's read error type */ adr_type_t *aa_write_error; /* attribute's write error type */ boolean_t aa_nullable; /* can this attribute be "null"? */ boolean_t aa_re_nullable; /* can the read error "null"? */ boolean_t aa_we_nullable; /* can the write error "null"? */ boolean_t aa_readable; /* can this attribute be read */ boolean_t aa_writeable; /* can this attribute be written */ } adr_attribute_t; /* An object event */ typedef struct adr_event { const char *ae_name; /* event's name */ adr_stability_t ae_stability; /* event's stability classification */ adr_type_t *ae_type; /* event's type */ } adr_event_t; /* An object, consisting of attributes and methods */ typedef struct adr_object { const char *ao_aname; /* name of api */ const char *ao_ifname; /* name of interface */ adr_version_t ao_versions[NSTABILITY]; /* versions */ int ao_nattributes; /* # attributes */ int ao_nmethods; /* # methods */ int ao_nevents; /* # events */ int ao_nname_keys; /* number of name keys defined */ adr_attribute_t **ao_attributes; /* attributes */ adr_method_t **ao_methods; /* methods */ adr_event_t *ao_events; /* events */ const char **ao_name_keys; /* defined name keys */ const char **ao_name_keys_ord; /* defined name keys ordered for REST */ const char *ao_collection_name; /* defined collection name for REST */ } adr_object_t; int adr_lookup_attr_index(adr_object_t *, const char *); adr_attribute_t *adr_lookup_attr(adr_object_t *, const char *); adr_attribute_t *adr_get_attr(adr_object_t *, int); int adr_lookup_method_index(adr_object_t *, const char *); adr_method_t *adr_lookup_method(adr_object_t *, const char *); adr_method_t *adr_get_method(adr_object_t *, int); int adr_lookup_event_index(adr_object_t *, const char *); adr_event_t *adr_lookup_event(adr_object_t *, const char *); adr_event_t *adr_get_event(adr_object_t *, int); adr_type_t *adr_object_find_type_by_id(int); int adr_object_get_type_id(adr_type_t *); boolean_t adr_object_verify_name(const adr_object_t *, const adr_name_t *); #ifdef __cplusplus } #endif #endif /* _ADR_OBJECT_H */