
Service Builder generates the classes for Annotation Provider Class (APC) once you generate the project. APC will be generated only for the projects of type Annotation Model for Referenced Service.
| Class | Description | Naming Convention |
|---|---|---|
| Base Class | Generated by the system during the generation process. Do not modify this class manually | CL_<Project Name>_APC |
| Extension Class | This is the Implementation class that inherits the Base class. This class can be modified manually. | CL_<Project Name>_APC_EXT |
lo_reference = vocab_anno_model->create_vocabulary_reference( iv_vocab_id = '/IWBEP/VOC_CORE'
iv_vocab_version = '0001').
lo_reference->create_include( iv_namespace = 'Org.OData.Core.V1' ).lo_ann_target = vocab_anno_model->create_annotations_target( 'Musical/lyrics' ). lo_annotation = lo_ann_target->create_annotation( iv_term = 'Org.OData.Core.V1.MediaType' ). lo_simp_value = lo_annotation->create_simple_value( ). lo_simp_value->set_string( 'test Desciption' ).
lo_ann_target = vocab_anno_model->create_annotations_target( 'E1/P1' ). lo_annotation = lo_ann_target->create_annotation( iv_term = 'Org.Mv.Core.V9.PropPath' ). lo_simp_value = lo_annotation->create_simple_value( ). lo_simp_value->set_property_path( 'TEST' ).
lo_ann_target = vocab_anno_model->create_annotations_target( 'Musical' ). lo_annotation = lo_ann_target->create_annotation( iv_term = 'Org.OData.Core.V1.AcceptableMediaTypes' ). lo_collection = lo_annotation->create_collection( ). lo_simp_value = lo_collection->create_simple_value( ). lo_simp_value->set_string( 'entry1' ).
lo_ann_target = vocab_anno_model->create_annotations_target( 'MusicalCollection' ). lo_annotation = lo_ann_target->create_annotation( iv_term = 'Org.OData.Record.REC.UnitRecord' ). lo_record = lo_annotation->create_record( ). lo_property = lo_record->create_property( 'UnitRecord1' ). lo_simp_value = lo_property->create_simple_value( ). lo_simp_value->set_path( '32812387213987218232' ).
lo_ann_target = vocab_anno_model->create_annotations_target( 'Musical/homepage' ). lo_annotation = lo_ann_target->create_annotation( iv_term = 'Org.OData.Core.V1.Permissions' ). lo_simp_value = lo_annotation->create_simple_value( ). lo_simp_value->set_enum_member_by_name( 'Read' ).
lo_ann_target = vocab_anno_model->create_annotations_target( 'Musical/MusicalID' ). lo_annotation = lo_ann_target->create_annotation( iv_term = 'Org.OData.Core.V1.IsURL' ). lo_simp_value = lo_annotation->create_simple_value( ). lo_simp_value->set_boolean( ' ' ).