FUNCTION acyclic_composite_text

(* SCHEMA technical_data_packaging; *)
  FUNCTION acyclic_composite_text(
               start_composite: composite_text;
               child_text: SET [1:?] OF text_or_character
      ): LOGICAL;

    LOCAL
      i                     : INTEGER;
      local_annotation_text : SET [0:?] OF annotation_text;
      local_composite_text  : SET [0:?] OF composite_text;
      local_children        : SET [0:?] OF text_or_character;
    END_LOCAL;
    local_composite_text := QUERY ( child <* child_text | (
        'TECHNICAL_DATA_PACKAGING.COMPOSITE_TEXT' IN TYPEOF(child)) );
    IF SIZEOF(local_composite_text) > 0 THEN
      REPEAT i := 1 TO HIINDEX(local_composite_text) BY 1;
        IF start_composite :=: local_composite_text[i] THEN
          RETURN(FALSE);
        END_IF;
      END_REPEAT;
    END_IF;
    local_children := child_text;
    IF SIZEOF(local_composite_text) > 0 THEN
      REPEAT i := 1 TO HIINDEX(local_composite_text) BY 1;
        local_children := local_children + local_composite_text[i].
            collected_text;
      END_REPEAT;
    END_IF;
    local_annotation_text := QUERY ( child <* child_text | (
        'TECHNICAL_DATA_PACKAGING.ANNOTATION_TEXT' IN TYPEOF(child)) );
    IF SIZEOF(local_annotation_text) > 0 THEN
      REPEAT i := 1 TO HIINDEX(local_annotation_text) BY 1;
        local_children := local_children + QUERY ( item <* 
            local_annotation_text[i]\mapped_item.mapping_source.
            mapped_representation.items | (SIZEOF([
            'TECHNICAL_DATA_PACKAGING.ANNOTATION_TEXT',
            'TECHNICAL_DATA_PACKAGING.COMPOSITE_TEXT'] * TYPEOF(item)) > 0) );
      END_REPEAT;
    END_IF;
    IF local_children :<>: child_text THEN
      RETURN(acyclic_composite_text(start_composite,local_children));
    ELSE
      RETURN(TRUE);
    END_IF;

  END_FUNCTION; -- acyclic_composite_text

Referenced By

Defintion acyclic_composite_text is references by the following definitions:
DefinitionType
 composite_text ENTITY


[Top Level Definitions] [Exit]

Generated by STEP Tools® EXPRESS to HTML Converter
2012-03-27T17:18:35-04:00