------------------------------------------------------------------------------ ------------------------------------------------------------------------------ -- This Ada package was automatically generated by the software engineering tool Platypus -- see http://dossen.univ-brest.fr/apl -- -- Any modification of this file will be lost. -- Please see the "platypus" directory instead : it contains the Cheddar's -- model and its meta-model. ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ -- Cheddar is a free real time scheduling tool. -- This program provides services to automatically check temporal constraints -- of real time tasks. -- -- Copyright (C) 2002-2009 Frank Singhoff -- Cheddar is developed by the LAB-STICC Team, University of Brest -- -- This program is free software; you can redistribute it and/or modify -- it under the terms of the GNU General Public License as published by -- the Free Software Foundation; either version 2 of the License, or -- (at your option) any later version. -- -- This program is distributed in the hope that it will be useful, -- but WITHOUT ANY WARRANTY; without even the implied warranty of -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -- GNU General Public License for more details. -- -- You should have received a copy of the GNU General Public License -- along with this program; if not, write to the Free Software -- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -- -- -- Contact : cheddar@listes.univ-brest.fr -- To post to this mailing list, you must be subscribed -- (see http//beru.univ-brest.fr/~singhoff/cheddar for details) -- ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ with Ada.Strings.Unbounded; use Ada.Strings.Unbounded; with Framework_Config; use Framework_Config; use Framework_Config.Priority_Io; with id_generators; use id_generators; with Objects; use Objects; with Parameters; use Parameters; use parameters.User_Defined_Parameters_Table_Package; with Offsets; use Offsets; use offsets.Offsets_Table_Package; with Convert_Strings; with Convert_Unbounded_Strings; with text_io; use text_io; with Unbounded_Strings; use Unbounded_Strings; use unbounded_strings.Unbounded_String_List_Package; with standards_io; use standards_io; use standards_io.boolean_io; use standards_io.natural_io; with Ada.Finalization; with Unchecked_Deallocation; with Primitive_XML_Strings; use Primitive_XML_Strings; with Lists; with ada.strings.unbounded.text_io; use ada.strings.unbounded.text_io; Package Tasks is type Tasks_Type is ( Periodic_Type, Aperiodic_Type, Sporadic_Type, Poisson_Type, Parametric_Type, Scheduling_Task_Type, Frame_Task_Type); procedure To_Tasks_Type is new Convert_Strings(Tasks_Type, Periodic_Type); procedure To_Tasks_Type is new Convert_Unbounded_Strings(Tasks_Type, Periodic_Type); function XML_String (obj : in Tasks_Type; level : in natural := 0) return Unbounded_String; function XML_Ref_String (obj : in Tasks_Type; level : in natural := 0) return Unbounded_String; package Tasks_Type_io is new text_io.enumeration_io(Tasks_Type); use Tasks_Type_io; type Policies is ( Sched_Fifo, Sched_Rr, Sched_Others); procedure To_Policies is new Convert_Strings(Policies, Sched_Fifo); procedure To_Policies is new Convert_Unbounded_Strings(Policies, Sched_Fifo); function XML_String (obj : in Policies; level : in natural := 0) return Unbounded_String; function XML_Ref_String (obj : in Policies; level : in natural := 0) return Unbounded_String; package Policies_io is new text_io.enumeration_io(Policies); use Policies_io; -- --------= Generic_Task =-------- type Generic_Task; type Generic_Task_Ptr is access all Generic_Task'Class; type Generic_Task is new Named_Object with record task_type : Tasks_Type; cpu_name : Unbounded_String; address_space_name : Unbounded_String; capacity : Natural; deadline : Natural; start_time : Natural; priority : Priority_Range; blocking_time : Natural; policy : Policies; offsets : Offsets_Table; text_memory_size : Natural; stack_memory_size : Natural; parameters : User_Defined_Parameters_Table; criticality : Natural; context_switch_overhead : Natural; end record; procedure Initialize(obj : in out Generic_Task); procedure Put(obj : in Generic_Task); procedure Put(obj : in Generic_Task_Ptr); procedure Put_Name(obj : in Generic_Task_Ptr); procedure Build_Attributes_XML_String(obj : in Generic_Task; level : in natural := 0; result : in out Unbounded_String); function XML_String(obj : in Generic_Task; level : in natural := 0) return Unbounded_String; function XML_String(obj : in Generic_Task_Ptr; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Generic_Task; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Generic_Task_Ptr; level : in natural := 0) return Unbounded_String; function Get_Name (obj : in Generic_Task) return Unbounded_String; function Get_Name (obj : in Generic_Task_Ptr) return Unbounded_String; function Copy(obj : in Generic_Task_Ptr) return Generic_Task_Ptr; function Copy(obj : in Generic_Task) return Generic_Task_Ptr; function type_of(obj : in Generic_Task) return unbounded_string_list; function type_of(obj : in Generic_Task_Ptr) return unbounded_string_list; procedure Free is new Unchecked_Deallocation (Generic_Task'Class, Generic_Task_Ptr); package Generic_Task_List_Package is new Lists(Generic_Task_Ptr, Put, Free, XML_Ref_String); use Generic_Task_List_Package; subtype Generic_Task_Iterator is Generic_Task_List_Package.iterator; subtype Generic_Task_Iterator_Ptr is Generic_Task_List_Package.iterator_Ptr; subtype Generic_Task_List is Generic_Task_List_Package.List; subtype Generic_Task_List_Ptr is Generic_Task_List_Package.List_Ptr; -- --------= Periodic_Task =-------- type Periodic_Task; type Periodic_Task_Ptr is access all Periodic_Task'Class; type Periodic_Task is new Generic_Task with record period : Natural; jitter : Natural; end record; procedure Initialize(obj : in out Periodic_Task); procedure Put(obj : in Periodic_Task); procedure Put(obj : in Periodic_Task_Ptr); procedure Put_Name(obj : in Periodic_Task_Ptr); procedure Build_Attributes_XML_String(obj : in Periodic_Task; level : in natural := 0; result : in out Unbounded_String); function XML_String(obj : in Periodic_Task; level : in natural := 0) return Unbounded_String; function XML_String(obj : in Periodic_Task_Ptr; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Periodic_Task; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Periodic_Task_Ptr; level : in natural := 0) return Unbounded_String; function Get_Name (obj : in Periodic_Task) return Unbounded_String; function Get_Name (obj : in Periodic_Task_Ptr) return Unbounded_String; function Copy(obj : in Periodic_Task_Ptr) return Generic_Task_Ptr; function Copy(obj : in Periodic_Task) return Generic_Task_Ptr; function type_of(obj : in Periodic_Task) return unbounded_string_list; function type_of(obj : in Periodic_Task_Ptr) return unbounded_string_list; procedure Free is new Unchecked_Deallocation (Periodic_Task'Class, Periodic_Task_Ptr); -- --------= Aperiodic_Task =-------- type Aperiodic_Task; type Aperiodic_Task_Ptr is access all Aperiodic_Task'Class; type Aperiodic_Task is new Generic_Task with null record; procedure Initialize(obj : in out Aperiodic_Task); procedure Put(obj : in Aperiodic_Task); procedure Put(obj : in Aperiodic_Task_Ptr); procedure Put_Name(obj : in Aperiodic_Task_Ptr); procedure Build_Attributes_XML_String(obj : in Aperiodic_Task; level : in natural := 0; result : in out Unbounded_String); function XML_String(obj : in Aperiodic_Task; level : in natural := 0) return Unbounded_String; function XML_String(obj : in Aperiodic_Task_Ptr; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Aperiodic_Task; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Aperiodic_Task_Ptr; level : in natural := 0) return Unbounded_String; function Get_Name (obj : in Aperiodic_Task) return Unbounded_String; function Get_Name (obj : in Aperiodic_Task_Ptr) return Unbounded_String; function Copy(obj : in Aperiodic_Task_Ptr) return Generic_Task_Ptr; function Copy(obj : in Aperiodic_Task) return Generic_Task_Ptr; function type_of(obj : in Aperiodic_Task) return unbounded_string_list; function type_of(obj : in Aperiodic_Task_Ptr) return unbounded_string_list; procedure Free is new Unchecked_Deallocation (Aperiodic_Task'Class, Aperiodic_Task_Ptr); -- --------= Poisson_Task =-------- type Poisson_Task; type Poisson_Task_Ptr is access all Poisson_Task'Class; type Poisson_Task is new Periodic_Task with record seed : Natural; predictable : Boolean; end record; procedure Initialize(obj : in out Poisson_Task); procedure Put(obj : in Poisson_Task); procedure Put(obj : in Poisson_Task_Ptr); procedure Put_Name(obj : in Poisson_Task_Ptr); procedure Build_Attributes_XML_String(obj : in Poisson_Task; level : in natural := 0; result : in out Unbounded_String); function XML_String(obj : in Poisson_Task; level : in natural := 0) return Unbounded_String; function XML_String(obj : in Poisson_Task_Ptr; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Poisson_Task; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Poisson_Task_Ptr; level : in natural := 0) return Unbounded_String; function Get_Name (obj : in Poisson_Task) return Unbounded_String; function Get_Name (obj : in Poisson_Task_Ptr) return Unbounded_String; function Copy(obj : in Poisson_Task_Ptr) return Generic_Task_Ptr; function Copy(obj : in Poisson_Task) return Generic_Task_Ptr; function type_of(obj : in Poisson_Task) return unbounded_string_list; function type_of(obj : in Poisson_Task_Ptr) return unbounded_string_list; procedure Free is new Unchecked_Deallocation (Poisson_Task'Class, Poisson_Task_Ptr); -- --------= Sporadic_Task =-------- type Sporadic_Task; type Sporadic_Task_Ptr is access all Sporadic_Task'Class; type Sporadic_Task is new Poisson_Task with null record; procedure Initialize(obj : in out Sporadic_Task); procedure Put(obj : in Sporadic_Task); procedure Put(obj : in Sporadic_Task_Ptr); procedure Put_Name(obj : in Sporadic_Task_Ptr); procedure Build_Attributes_XML_String(obj : in Sporadic_Task; level : in natural := 0; result : in out Unbounded_String); function XML_String(obj : in Sporadic_Task; level : in natural := 0) return Unbounded_String; function XML_String(obj : in Sporadic_Task_Ptr; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Sporadic_Task; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Sporadic_Task_Ptr; level : in natural := 0) return Unbounded_String; function Get_Name (obj : in Sporadic_Task) return Unbounded_String; function Get_Name (obj : in Sporadic_Task_Ptr) return Unbounded_String; function Copy(obj : in Sporadic_Task_Ptr) return Generic_Task_Ptr; function Copy(obj : in Sporadic_Task) return Generic_Task_Ptr; function type_of(obj : in Sporadic_Task) return unbounded_string_list; function type_of(obj : in Sporadic_Task_Ptr) return unbounded_string_list; procedure Free is new Unchecked_Deallocation (Sporadic_Task'Class, Sporadic_Task_Ptr); -- --------= Parametric_Task =-------- type Parametric_Task; type Parametric_Task_Ptr is access all Parametric_Task'Class; type Parametric_Task is new Poisson_Task with record activation_rule : Unbounded_String; end record; procedure Initialize(obj : in out Parametric_Task); procedure Put(obj : in Parametric_Task); procedure Put(obj : in Parametric_Task_Ptr); procedure Put_Name(obj : in Parametric_Task_Ptr); procedure Build_Attributes_XML_String(obj : in Parametric_Task; level : in natural := 0; result : in out Unbounded_String); function XML_String(obj : in Parametric_Task; level : in natural := 0) return Unbounded_String; function XML_String(obj : in Parametric_Task_Ptr; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Parametric_Task; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Parametric_Task_Ptr; level : in natural := 0) return Unbounded_String; function Get_Name (obj : in Parametric_Task) return Unbounded_String; function Get_Name (obj : in Parametric_Task_Ptr) return Unbounded_String; function Copy(obj : in Parametric_Task_Ptr) return Generic_Task_Ptr; function Copy(obj : in Parametric_Task) return Generic_Task_Ptr; function type_of(obj : in Parametric_Task) return unbounded_string_list; function type_of(obj : in Parametric_Task_Ptr) return unbounded_string_list; procedure Free is new Unchecked_Deallocation (Parametric_Task'Class, Parametric_Task_Ptr); -- --------= Scheduling_Task =-------- type Scheduling_Task; type Scheduling_Task_Ptr is access all Scheduling_Task'Class; type Scheduling_Task is new Poisson_Task with null record; procedure Initialize(obj : in out Scheduling_Task); procedure Put(obj : in Scheduling_Task); procedure Put(obj : in Scheduling_Task_Ptr); procedure Put_Name(obj : in Scheduling_Task_Ptr); procedure Build_Attributes_XML_String(obj : in Scheduling_Task; level : in natural := 0; result : in out Unbounded_String); function XML_String(obj : in Scheduling_Task; level : in natural := 0) return Unbounded_String; function XML_String(obj : in Scheduling_Task_Ptr; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Scheduling_Task; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Scheduling_Task_Ptr; level : in natural := 0) return Unbounded_String; function Get_Name (obj : in Scheduling_Task) return Unbounded_String; function Get_Name (obj : in Scheduling_Task_Ptr) return Unbounded_String; function Copy(obj : in Scheduling_Task_Ptr) return Generic_Task_Ptr; function Copy(obj : in Scheduling_Task) return Generic_Task_Ptr; function type_of(obj : in Scheduling_Task) return unbounded_string_list; function type_of(obj : in Scheduling_Task_Ptr) return unbounded_string_list; procedure Free is new Unchecked_Deallocation (Scheduling_Task'Class, Scheduling_Task_Ptr); -- --------= Frame_Task =-------- type Frame_Task; type Frame_Task_Ptr is access all Frame_Task'Class; type Frame_Task is new Periodic_Task with record interarrival : Natural; end record; procedure Initialize(obj : in out Frame_Task); procedure Put(obj : in Frame_Task); procedure Put(obj : in Frame_Task_Ptr); procedure Put_Name(obj : in Frame_Task_Ptr); procedure Build_Attributes_XML_String(obj : in Frame_Task; level : in natural := 0; result : in out Unbounded_String); function XML_String(obj : in Frame_Task; level : in natural := 0) return Unbounded_String; function XML_String(obj : in Frame_Task_Ptr; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Frame_Task; level : in natural := 0) return Unbounded_String; function XML_Ref_String(obj : in Frame_Task_Ptr; level : in natural := 0) return Unbounded_String; function Get_Name (obj : in Frame_Task) return Unbounded_String; function Get_Name (obj : in Frame_Task_Ptr) return Unbounded_String; function Copy(obj : in Frame_Task_Ptr) return Generic_Task_Ptr; function Copy(obj : in Frame_Task) return Generic_Task_Ptr; function type_of(obj : in Frame_Task) return unbounded_string_list; function type_of(obj : in Frame_Task_Ptr) return unbounded_string_list; procedure Free is new Unchecked_Deallocation (Frame_Task'Class, Frame_Task_Ptr); End Tasks;