hexsha
stringlengths 40
40
| size
int64 3
1.05M
| ext
stringclasses 163
values | lang
stringclasses 53
values | max_stars_repo_path
stringlengths 3
945
| max_stars_repo_name
stringlengths 4
112
| max_stars_repo_head_hexsha
stringlengths 40
78
| max_stars_repo_licenses
sequencelengths 1
10
| max_stars_count
float64 1
191k
⌀ | max_stars_repo_stars_event_min_datetime
stringlengths 24
24
⌀ | max_stars_repo_stars_event_max_datetime
stringlengths 24
24
⌀ | max_issues_repo_path
stringlengths 3
945
| max_issues_repo_name
stringlengths 4
113
| max_issues_repo_head_hexsha
stringlengths 40
78
| max_issues_repo_licenses
sequencelengths 1
10
| max_issues_count
float64 1
116k
⌀ | max_issues_repo_issues_event_min_datetime
stringlengths 24
24
⌀ | max_issues_repo_issues_event_max_datetime
stringlengths 24
24
⌀ | max_forks_repo_path
stringlengths 3
945
| max_forks_repo_name
stringlengths 4
113
| max_forks_repo_head_hexsha
stringlengths 40
78
| max_forks_repo_licenses
sequencelengths 1
10
| max_forks_count
float64 1
105k
⌀ | max_forks_repo_forks_event_min_datetime
stringlengths 24
24
⌀ | max_forks_repo_forks_event_max_datetime
stringlengths 24
24
⌀ | content
stringlengths 3
1.05M
| avg_line_length
float64 1
966k
| max_line_length
int64 1
977k
| alphanum_fraction
float64 0
1
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1d97917287be9f6ff35d99049ceea68f3e66b116 | 7,343 | adb | Ada | ada_gui-gnoga-gui-view-grid.adb | jrcarter/Ada_GUI | 65a829c55dec91fd48a0b72f88d76137768bf4fb | [
"BSD-3-Clause"
] | 19 | 2018-03-18T18:07:14.000Z | 2022-03-30T03:10:12.000Z | ada_gui-gnoga-gui-view-grid.adb | jrcarter/Ada_GUI | 65a829c55dec91fd48a0b72f88d76137768bf4fb | [
"BSD-3-Clause"
] | 4 | 2021-08-23T12:52:06.000Z | 2022-03-31T10:48:43.000Z | ada_gui-gnoga-gui-view-grid.adb | jrcarter/Ada_GUI | 65a829c55dec91fd48a0b72f88d76137768bf4fb | [
"BSD-3-Clause"
] | null | null | null | -- Ada_GUI implementation based on Gnoga. Adapted 2021
-- --
-- GNOGA - The GNU Omnificent GUI for Ada --
-- --
-- G N O G A . G U I . V I E W . G R I D --
-- --
-- B o d y --
-- --
-- --
-- Copyright (C) 2014 David Botton --
-- --
-- This library is free software; you can redistribute it and/or modify --
-- it under terms of the GNU General Public License as published by the --
-- Free Software Foundation; either version 3, or (at your option) any --
-- later version. This library 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. --
-- --
-- As a special exception under Section 7 of GPL version 3, you are --
-- granted additional permissions described in the GCC Runtime Library --
-- Exception, version 3.1, as published by the Free Software Foundation. --
-- --
-- You should have received a copy of the GNU General Public License and --
-- a copy of the GCC Runtime Library Exception along with this program; --
-- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
-- <http://www.gnu.org/licenses/>. --
-- --
-- As a special exception, if other files instantiate generics from this --
-- unit, or you link this unit with other files to produce an executable, --
-- this unit does not by itself cause the resulting executable to be --
-- covered by the GNU General Public License. This exception does not --
-- however invalidate any other reasons why the executable file might be --
-- covered by the GNU Public License. --
-- --
-- For more information please go to http://www.gnoga.com --
------------------------------------------------------------------------------
with Ada.Strings.Unbounded;
with Ada_GUI.Gnoga.Server.Connection;
with Ada_GUI.Gnoga.Gui.Window;
package body Ada_GUI.Gnoga.Gui.View.Grid is
------------
-- Create --
------------
procedure Create
(Grid : in out Grid_View_Type;
Parent : in out Gnoga.Gui.Base_Type'Class;
Layout : in Grid_Rows_Type;
Fill_Parent : in Boolean := True;
Set_Sizes : in Boolean := True;
ID : in String := "")
is
use Ada.Strings.Unbounded;
C : Unbounded_String;
CID : constant String := Gnoga.Server.Connection.New_GID;
N : Natural;
Span_Size : Natural;
Column : Positive;
P_Height : constant String :=
Left_Trim (Integer (100 / Layout'Length (1))'Img) & "%";
P_Width : constant String :=
Left_Trim (Integer (100 / Layout'Length (2))'Img) & "%";
Column_Object : View_Base_Access := null;
function TD_Width return String;
function TD_Width return String is
begin
if Set_Sizes then
return " width:" & P_Width & ";";
else
return "";
end if;
end TD_Width;
begin
if Parent in Gnoga.Gui.Window.Window_Type'Class then
C := To_Unbounded_String ("<div style='position:relative'>");
end if;
C := C & "<table style='" &
" position:relative;" &
" border-spacing: 0px; border-collapse: collapse;";
if Fill_Parent then
C := C & " width:100%; height:100%;'>";
else
C := C & "'>";
end if;
N := 0;
for Row in Layout'Range (1) loop
C := C & "<tr>";
Column := Layout'First (2);
Span_Size := 0;
loop
if Layout (Row, Column) = COL then
N := N + 1;
C := C & "<td style='" &
TD_Width &
" position:relative;" &
" padding:0; text-align: left; vertical-align: top;" &
"' id='" & CID & "_" & Left_Trim (N'Img) & "'";
Span_Size := 1;
elsif Layout (Row, Column) = SPN then
Span_Size := Span_Size + 1;
end if;
Column := Column + 1;
if Column > Layout'Last (2) or else Layout (Row, Column) = COL then
if Span_Size > 0 then
if Span_Size > 1 then
C := C & " colspan=" & Left_Trim (Span_Size'Img);
end if;
C := C & " />";
end if;
end if;
exit when Column > Layout'Last (2);
end loop;
C := C & "</tr>";
end loop;
C := C & "</table>";
if Parent in Gnoga.Gui.Window.Window_Type'Class then
C := C & "</div>";
end if;
Grid.Create_From_HTML (Parent, Escape_Quotes (To_String (C)), ID);
N := 0;
for Row in Layout'Range (1) loop
Column := Layout'First (2);
Span_Size := 0;
loop
if Layout (Row, Column) = COL then
N := N + 1;
Span_Size := 1;
Column_Object := new View_Base_Type;
Column_Object.Auto_Place (False);
Column_Object.Dynamic (True);
Column_Object.Attach_Using_Parent
(Grid, CID & "_" & Left_Trim (N'Img));
Column_Object.Parent (Grid);
if Column = Layout'First (2) and Row = Layout'First (1) then
Column_Object.Box_Height (P_Height);
end if;
elsif Layout (Row, Column) = SPN then
Span_Size := Span_Size + 1;
end if;
declare
Address : constant String := Left_Trim (Row'Img) & "_" &
Left_Trim (Column'Img);
begin
Grid.Add_Element (Address, Gnoga.Gui.Element.Pointer_To_Element_Class (Column_Object));
end;
Column := Column + 1;
exit when Column > Layout'Last (2);
end loop;
end loop;
end Create;
-----------
-- Panel --
-----------
function Panel (Grid : Grid_View_Type; Row, Column : Positive)
return Pointer_To_View_Base_Class
is
Address : constant String :=
Left_Trim (Row'Img) & "_" & Left_Trim (Column'Img);
begin
return Pointer_To_View_Base_Class (Grid.Element (Address));
end Panel;
end Ada_GUI.Gnoga.Gui.View.Grid;
| 37.65641 | 102 | 0.46003 |
122532f57232cd7cf0e4c7b66c88493e34dc12e4 | 4,457 | adb | Ada | source/base/incr-debug.adb | reznikmm/increment | 0edff267d468f005f28b5d2c0c0fe23f4ff3164c | [
"MIT"
] | 5 | 2017-10-20T08:40:59.000Z | 2021-05-15T16:55:39.000Z | source/base/incr-debug.adb | reznikmm/increment | 0edff267d468f005f28b5d2c0c0fe23f4ff3164c | [
"MIT"
] | null | null | null | source/base/incr-debug.adb | reznikmm/increment | 0edff267d468f005f28b5d2c0c0fe23f4ff3164c | [
"MIT"
] | null | null | null | -- Copyright (c) 2015-2017 Maxim Reznik <[email protected]>
--
-- SPDX-License-Identifier: MIT
-- License-Filename: LICENSE
-------------------------------------------------------------
with League.Strings;
with XML.SAX.Attributes;
with Incr.Nodes.Tokens;
with Incr.Nodes;
with Incr.Version_Trees;
package body Incr.Debug is
function "+" (Text : Wide_Wide_String)
return League.Strings.Universal_String
renames League.Strings.To_Universal_String;
Nil_Attributes : XML.SAX.Attributes.SAX_Attributes;
----------
-- Dump --
----------
procedure Dump
(Doc : Incr.Documents.Document'Class;
Provider : P.Parser_Data_Provider'Class;
Output : in out XML.SAX.Writers.SAX_Writer'Class)
is
procedure Dump (Node : Incr.Nodes.Node_Access);
procedure Dump (Node : Incr.Nodes.Node_Access)
is
function Now return Incr.Version_Trees.Version is
(Node.Document.History.Changing);
function Prev return Incr.Version_Trees.Version is
(Node.Document.History.Parent (Node.Document.History.Parent (Now)));
function Common_Attributes return XML.SAX.Attributes.SAX_Attributes;
function Common_Attributes return XML.SAX.Attributes.SAX_Attributes is
Result : XML.SAX.Attributes.SAX_Attributes;
begin
Result.Set_Value
(Qualified_Name => +"kind",
Value => +Provider.Kind_Image (Node.Kind));
if Node.Nested_Changes (Prev, Now) then
Result.Set_Value
(Qualified_Name => +"nc",
Value => +"y");
end if;
if Node.Local_Changes (Prev, Now) then
Result.Set_Value
(Qualified_Name => +"lc",
Value => +"y");
end if;
if Node.Nested_Errors (Now) then
Result.Set_Value
(Qualified_Name => +"ne",
Value => +"y");
end if;
if Node.Local_Errors (Now) then
Result.Set_Value
(Qualified_Name => +"le",
Value => +"y");
end if;
return Result;
end Common_Attributes;
Ok : Boolean := True;
begin
if Node in null then
Output.Start_Element
(Namespace_URI => +"",
Local_Name => +"null",
Qualified_Name => +"null",
Attributes => Nil_Attributes,
Success => Ok);
Output.End_Element
(Namespace_URI => +"",
Local_Name => +"null",
Qualified_Name => +"null");
return;
elsif Node.Is_Token then
declare
Token : constant Incr.Nodes.Tokens.Token_Access :=
Incr.Nodes.Tokens.Token_Access (Node);
Text : constant League.Strings.Universal_String :=
Token.Text (Now);
begin
Output.Start_Element
(Namespace_URI => +"",
Local_Name => +"token",
Qualified_Name => +"token",
Attributes => Common_Attributes,
Success => Ok);
if not Text.Is_Empty then
Output.Characters
(Text => Text,
Success => Ok);
end if;
Output.End_Element
(Namespace_URI => +"",
Local_Name => +"token",
Qualified_Name => +"token",
Success => Ok);
end;
else
Output.Start_Element
(Namespace_URI => +"",
Local_Name => +"node",
Qualified_Name => +"node",
Attributes => Common_Attributes,
Success => Ok);
for J in 1 .. Node.Arity loop
Dump (Node.Child (J, Now));
end loop;
Output.End_Element
(Namespace_URI => +"",
Local_Name => +"node",
Qualified_Name => +"node",
Success => Ok);
end if;
end Dump;
begin
Output.Start_Document;
Dump (Doc.Ultra_Root);
Output.End_Document;
end Dump;
end Incr.Debug;
| 31.167832 | 79 | 0.483958 |
2f96fba736a917af406b66372305ffe9447f6b61 | 865 | ads | Ada | source/asis/spec/ada-strings-wide_wide_fixed-wide_wide_hash.ads | faelys/gela-asis | 48a3bee90eda9f0c9d958b4e3c80a5a9b1c65253 | [
"BSD-3-Clause"
] | 4 | 2016-02-05T15:51:56.000Z | 2022-03-25T20:38:32.000Z | source/asis/spec/ada-strings-wide_wide_fixed-wide_wide_hash.ads | faelys/gela-asis | 48a3bee90eda9f0c9d958b4e3c80a5a9b1c65253 | [
"BSD-3-Clause"
] | null | null | null | source/asis/spec/ada-strings-wide_wide_fixed-wide_wide_hash.ads | faelys/gela-asis | 48a3bee90eda9f0c9d958b4e3c80a5a9b1c65253 | [
"BSD-3-Clause"
] | null | null | null | ------------------------------------------------------------------------------
-- A d a r u n - t i m e s p e c i f i c a t i o n --
-- ASIS implementation for Gela project, a portable Ada compiler --
-- http://gela.ada-ru.org --
-- - - - - - - - - - - - - - - - --
-- Read copyright and license at the end of ada.ads file --
------------------------------------------------------------------------------
-- $Revision: 209 $ $Date: 2013-11-30 21:03:24 +0200 (Сб., 30 нояб. 2013) $
with Ada.Containers, Ada.Strings.Wide_Wide_Hash;
function Ada.Strings.Wide_Wide_Fixed.Wide_Wide_Hash (Key : in Wide_Wide_String)
return Ada.Containers.Hash_Type
renames Ada.Strings.Wide_Wide_Hash;
pragma Pure (Wide_Wide_Hash);
| 54.0625 | 79 | 0.428902 |
12c0c7bf42920e31838ecfb3d67d345e7b034a24 | 2,797 | adb | Ada | gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/vect1.adb | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 7 | 2020-05-02T17:34:05.000Z | 2021-10-17T10:15:18.000Z | gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/vect1.adb | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | null | null | null | gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/vect1.adb | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 2 | 2020-07-27T00:22:36.000Z | 2021-04-01T09:41:02.000Z | -- { dg-do compile { target i?86-*-* x86_64-*-* } }
-- { dg-options "-O3 -msse2 -fno-vect-cost-model -fdump-tree-vect-details" }
package body Vect1 is
function "+" (X, Y : Varray) return Varray is
R : Varray (X'Range);
begin
for I in X'Range loop
R(I) := X(I) + Y(I);
end loop;
return R;
end;
procedure Add (X, Y : Varray; R : out Varray) is
begin
for I in X'Range loop
R(I) := X(I) + Y(I);
end loop;
end;
procedure Add (X, Y : not null access Varray; R : not null access Varray) is
begin
for I in X'Range loop
R(I) := X(I) + Y(I);
end loop;
end;
function "+" (X, Y : Sarray) return Sarray is
R : Sarray;
begin
for I in Sarray'Range loop
R(I) := X(I) + Y(I);
end loop;
return R;
end;
procedure Add (X, Y : Sarray; R : out Sarray) is
begin
for I in Sarray'Range loop
R(I) := X(I) + Y(I);
end loop;
end;
procedure Add (X, Y : not null access Sarray; R : not null access Sarray) is
begin
for I in Sarray'Range loop
R(I) := X(I) + Y(I);
end loop;
end;
function "+" (X, Y : Darray1) return Darray1 is
R : Darray1;
begin
for I in Darray1'Range loop
R(I) := X(I) + Y(I);
end loop;
return R;
end;
procedure Add (X, Y : Darray1; R : out Darray1) is
begin
for I in Darray1'Range loop
R(I) := X(I) + Y(I);
end loop;
end;
procedure Add (X, Y : not null access Darray1; R : not null access Darray1) is
begin
for I in Darray1'Range loop
R(I) := X(I) + Y(I);
end loop;
end;
function "+" (X, Y : Darray2) return Darray2 is
R : Darray2;
begin
for I in Darray2'Range loop
R(I) := X(I) + Y(I);
end loop;
return R;
end;
procedure Add (X, Y : Darray2; R : out Darray2) is
begin
for I in Darray2'Range loop
R(I) := X(I) + Y(I);
end loop;
end;
procedure Add (X, Y : not null access Darray2; R : not null access Darray2) is
begin
for I in Darray2'Range loop
R(I) := X(I) + Y(I);
end loop;
end;
function "+" (X, Y : Darray3) return Darray3 is
R : Darray3;
begin
for I in Darray3'Range loop
R(I) := X(I) + Y(I);
end loop;
return R;
end;
procedure Add (X, Y : Darray3; R : out Darray3) is
begin
for I in Darray3'Range loop
R(I) := X(I) + Y(I);
end loop;
end;
procedure Add (X, Y : not null access Darray3; R : not null access Darray3) is
begin
for I in Darray3'Range loop
R(I) := X(I) + Y(I);
end loop;
end;
end Vect1;
-- { dg-final { scan-tree-dump-times "vectorized 1 loops" 15 "vect" } }
| 21.851563 | 81 | 0.520558 |
064d768cf9df853b584bfb050d13047c5997917d | 1,515 | adb | Ada | tests/simple/src/dds-request_reply-tests-simple-driver.adb | persan/dds-requestreply | 226ce4fdeb4cdc65fdb90ea73baf9f012c31b42a | [
"MIT"
] | null | null | null | tests/simple/src/dds-request_reply-tests-simple-driver.adb | persan/dds-requestreply | 226ce4fdeb4cdc65fdb90ea73baf9f012c31b42a | [
"MIT"
] | null | null | null | tests/simple/src/dds-request_reply-tests-simple-driver.adb | persan/dds-requestreply | 226ce4fdeb4cdc65fdb90ea73baf9f012c31b42a | [
"MIT"
] | 2 | 2020-04-06T19:34:15.000Z | 2020-04-06T19:50:03.000Z | -------------------------------------------------------------------------------
--
-- This file is only for conviniece to be able to build and run with
-- one click
--
-------------------------------------------------------------------------------
with Ada.Command_Line;
with Ada.Directories;
with Ada.Text_IO;
with GNAT.OS_Lib;
procedure DDS.Request_Reply.Tests.Simple.Driver is
use Ada.Text_IO;
Args : constant GNAT.OS_Lib.Argument_List :=
(new Standard.String'("-j0"),
new Standard.String'("-k"),
new Standard.String'("-s"));
procedure Non_Blocking_Spawn (Name : Standard.String) is
Full_Name : constant Standard.String := "bin/dds-request_reply-tests-simple-" & Name;
Pid : GNAT.OS_Lib.Process_Id;
begin
if Ada.Directories.Exists (Full_Name) then
Put ("Spawning:" & Full_Name);
Pid := GNAT.OS_Lib.Non_Blocking_Spawn (Full_Name, Args);
Put_Line (" | Pid ->" & GNAT.OS_Lib.Pid_To_Integer (Pid)'Img);
delay 0.4;
else
Put_Line (Full_Name & ": does not exists.");
Ada.Command_Line.Set_Exit_Status (Ada.Command_Line.Failure);
end if;
end;
Gprbuild : constant GNAT.OS_Lib.String_Access := GNAT.OS_Lib.Locate_Exec_On_Path ("gprbuild");
begin
if GNAT.OS_Lib.Spawn (Gprbuild.all, Args) = 0 then -- Dont try to run if the build fails
Non_Blocking_Spawn ("replier_main");
Non_Blocking_Spawn ("requester_main");
end if;
end;
| 36.071429 | 99 | 0.572937 |
a1017a46bb1e6a5e907b6677a730648ae2991d9c | 737 | ads | Ada | ada/src/afrl/cmasi/afrl-cmasi-abstractgeometry.ads | joffreyhuguet/LmcpGen | 3a75248e536f1147d9208ec021cc5105206c3477 | [
"NASA-1.3"
] | null | null | null | ada/src/afrl/cmasi/afrl-cmasi-abstractgeometry.ads | joffreyhuguet/LmcpGen | 3a75248e536f1147d9208ec021cc5105206c3477 | [
"NASA-1.3"
] | null | null | null | ada/src/afrl/cmasi/afrl-cmasi-abstractgeometry.ads | joffreyhuguet/LmcpGen | 3a75248e536f1147d9208ec021cc5105206c3477 | [
"NASA-1.3"
] | null | null | null | with afrl.cmasi.object; use afrl.cmasi.object;
with afrl.cmasi.enumerations; use afrl.cmasi.enumerations;
with avtas.lmcp.types; use avtas.lmcp.types;
package afrl.cmasi.abstractGeometry is
type AbstractGeometry is new afrl.cmasi.object.Object with private;
type AbstractGeometry_Acc is access all AbstractGeometry;
type AbstractGeometry_Class_Acc is access all AbstractGeometry'Class;
function getFullLmcpTypeName(this : AbstractGeometry) return String;
function getLmcpTypeName(this : AbstractGeometry) return String;
function getLmcpType(this : AbstractGeometry) return UInt32_t;
private
type AbstractGeometry is new afrl.cmasi.object.Object with null record;
end afrl.cmasi.abstractGeometry;
| 36.85 | 74 | 0.796472 |
31f8f117da56b923b5caae0a9fd0d5640df8bdb4 | 2,823 | adb | Ada | main.adb | 97kovacspeter/ADA | 8fd8915a23fb21c09ef952b5e8f64e81f5eceb3d | [
"MIT"
] | null | null | null | main.adb | 97kovacspeter/ADA | 8fd8915a23fb21c09ef952b5e8f64e81f5eceb3d | [
"MIT"
] | null | null | null | main.adb | 97kovacspeter/ADA | 8fd8915a23fb21c09ef952b5e8f64e81f5eceb3d | [
"MIT"
] | null | null | null | with Text_IO, Aircraft, Coords, Card_Dir;
use Text_IO, Card_Dir;
procedure main is
package ACrafts is new Aircraft(Integer);
use ACrafts;
procedure ACraft_Info (A: Aircraft_Type) is
begin
Put("Name: ");
Put_Line(Integer'Image(GetName(A)));
Put("coordiantes:");
Put(Integer'Image(Coords.Get_X(Get_Coord(A))));
Put(",");
Put(Integer'Image(Coords.Get_Y(Get_Coord(A))));Put_Line("");
if Get_Is_In_The_Air(A) then
Put_Line("In the air.");Put_Line("");
else
Put_Line("Not in the air.");Put_Line("");
end if;
end ACraft_Info;
procedure Set_Inside(Name: out Integer; Position: out Coords.Coord; Is_In_The_Air: out Boolean) is
begin
Name:=0;
Coords.Set_X(Position,0);
Coords.Set_Y(Position,0);
Is_In_The_Air:= False;
end Set_Inside;
procedure Initialiser is new Action(Set_Inside);
procedure Comparing (A1: Aircraft_Type; A2: Aircraft_Type) is
Is_Greater: Boolean;
begin
Is_Greater:=Compare(A1,A2);
if Is_Greater then
Put(Integer'Image(GetName(A1)));
Put(" is greater, than ");
Put(Integer'Image(GetName(A2)));
else
Put(Integer'Image(GetName(A1)));
Put(" is not greater, than ");
Put(Integer'Image(GetName(A2)));
end if;
end Comparing;
procedure Measuring (A1: Aircraft_Type; A2: Aircraft_Type) is
begin
Put("Distance: ");
Put(Integer'Image(Get_Distance(A1,A2)));
end Measuring;
A1: Aircraft_Type(9);
A2: Aircraft_Type(23);
begin
Put_Line("Current state (start): ");Put_Line("");
Start(A1);
Start(A2);
ACraft_Info(A1);
ACraft_Info(A2);
Put_Line("Comparing them");Put_Line("");
Comparing(A1,A2);
Put_Line("A1 reset");Put_Line("");
Initialiser(A1);
ACraft_Info(A1);
ACraft_Info(A2);
Put_Line("A2 reset");Put_Line("");
Initialiser(A2);
ACraft_Info(A1);
ACraft_Info(A2);
Put_Line("Ascend both");Put_Line("");
Ascend(A1);
Ascend(A2);
ACraft_Info(A1);
ACraft_Info(A2);
Put_Line("A1 going to N direction, A2 going to S direction");Put_Line("");
Set_Card_Dir_Coord(A1,N);
Set_Card_Dir_Coord(A2,S);
ACraft_Info(A1);
ACraft_Info(A2);
Put_Line("A1 going to E direction, A2 going to W direction");Put_Line("");
Set_Card_Dir_Coord(A1,E);
Set_Card_Dir_Coord(A2,W);
ACraft_Info(A1);
ACraft_Info(A2);
Put_Line("A1 going to NE direction, A2 going to SE direction");Put_Line("");
Set_Card_Dir_Coord(A1,NE);
Set_Card_Dir_Coord(A2,SE);
ACraft_Info(A1);
ACraft_Info(A2);
Put_Line("A1 going to NW direction, A2 going to SW direction");Put_Line("");
Set_Card_Dir_Coord(A1,NW);
Set_Card_Dir_Coord(A2,SW);
ACraft_Info(A1);
ACraft_Info(A2);
Put_Line("Distance between them (the real distance is the square root of the answer for easier computing)");Put_Line("");
Measuring(A1,A2);Put_Line("");
Put_Line("Landing");Put_Line("");
Land(A1);
Land(A2);
ACraft_Info(A1);
ACraft_Info(A2);
end main; | 24.336207 | 122 | 0.700319 |
2f1cf472861be5553329e4792038065872899339 | 834 | adb | Ada | gdb/testsuite/gdb.ada/array_of_variant/pck.adb | greyblue9/binutils-gdb | 05377632b124fe7600eea7f4ee0e9a35d1b0cbdc | [
"BSD-3-Clause"
] | 1 | 2020-10-14T03:24:35.000Z | 2020-10-14T03:24:35.000Z | gdb/testsuite/gdb.ada/array_of_variant/pck.adb | greyblue9/binutils-gdb | 05377632b124fe7600eea7f4ee0e9a35d1b0cbdc | [
"BSD-3-Clause"
] | null | null | null | gdb/testsuite/gdb.ada/array_of_variant/pck.adb | greyblue9/binutils-gdb | 05377632b124fe7600eea7f4ee0e9a35d1b0cbdc | [
"BSD-3-Clause"
] | null | null | null | -- Copyright 2020-2021 Free Software Foundation, Inc.
--
-- 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 3 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, see <http://www.gnu.org/licenses/>.
package body Pck is
procedure Do_Nothing (A : System.Address) is
begin
null;
end Do_Nothing;
end Pck;
| 34.75 | 73 | 0.727818 |
a1cb1c7751a38cbfae0781d3abca18ef54cde9b9 | 3,072 | ads | Ada | src/semantica-gci.ads | alvaromb/Compilemon | de5f88f084705868d38e301d95bb4a19a46a1156 | [
"MIT"
] | 1 | 2018-08-11T01:51:27.000Z | 2018-08-11T01:51:27.000Z | src/semantica-gci.ads | alvaromb/Compilemon | de5f88f084705868d38e301d95bb4a19a46a1156 | [
"MIT"
] | null | null | null | src/semantica-gci.ads | alvaromb/Compilemon | de5f88f084705868d38e301d95bb4a19a46a1156 | [
"MIT"
] | null | null | null | with Semantica.Declsc3a,
Pilas,
Decls.Dgenerals;
use Semantica.Declsc3a;
package Semantica.gci is
Camp_Nul : constant Camp := (Const, Var_Nul);
type T_Param is record
Base, Despl : num_Var;
end record;
procedure Genera
(Instr : in tInstruccio;
C1 : in Camp := Camp_Nul;
C2 : in Camp := Camp_Nul;
C3 : in Camp := Camp_Nul);
procedure Inicia_Generacio
(nomFitxer : in String);
procedure Gci_Decprocediment
(A : in Pnode);
procedure gci_Programa
(A : in Pnode);
procedure Gci_Encap
(A : in Pnode;
I : in Id_Nom);
procedure gci_Pencap
(A : in Pnode);
procedure gci_Param
(A : in Pnode);
procedure gci_Declaracions
(A : in Pnode);
procedure gci_Decvar
(A : in Pnode);
procedure gci_Declsvar
(A : in Pnode);
procedure gci_Decconst
(A : in Pnode);
procedure gci_Deccol
(A : in Pnode);
procedure gci_Pcoleccio
(A : in Pnode;
base: in out Valor;
Idarray : out Id_nom);
procedure gci_Bloc
(A : in Pnode);
procedure Gci_Assignacio
(Idref, Iddref, Idrexp, Iddexp: in num_var);
--Procediments
procedure gci_Referencia_Proc
(A : in Pnode;
Idproc : out num_proc);
procedure gci_Ref_Pri
(A : in Pnode;
Idproc : out num_proc);
procedure gci_Identificador
(A : in Pnode;
Idres, Iddesp: out num_var;
Idtipus : out Id_Nom);
procedure gci_Constant
(A : in Pnode;
Idres : out Num_var);
procedure gci_Expressio
(A : in Pnode;
Idr, Idd: out num_var);
procedure gci_Expressioc
(A : in Pnode;
Idres,Idresdesp: out num_var);
procedure gci_Exp_Relacional
(IdResE, IdResD, IddespE, IddespD : in num_var;
IdResultExp, IddespExp : out num_var;
Op : in Operacio);
procedure gci_Exp_Logica
(IdResE, IdResD, IddespE, IddespD : in num_var;
IdResultExp, IddespExp : out num_var;
Op : in Operacio);
procedure gci_Exp_Aritmetica
(IdResE, IdResD, IddespE, IddespD : in num_var;
IdResultExp, IddespExp : out num_var;
Op : in Operacio);
procedure gci_Expressiou
(A : in Pnode;
Idr, Idd : out num_var);
procedure gci_Exp_Negacio
(idRes, Iddesp : in num_var;
IdresultExp, IddespExp : out num_var);
procedure gci_Exp_Neglogica
(idRes, Iddesp : in num_var;
IdresultExp, IddespExp : out num_var);
procedure gci_Referencia_Var
(A : in Pnode;
Idres, Iddesp: out Num_Var;
Idtipus : out Id_Nom);
--Arrays
procedure gci_Ref_Pri
(A : in Pnode;
Idres, Iddesp, Idbase : out Num_var;
Idtipus : out Id_Nom;
It_Idx : out Cursor_Idx);
procedure gci_Ref_Rec
(A : in Pnode;
Idres, Iddesp: out num_var;
Idtipus : out Id_Nom);
procedure gci_Sconds
(A : in Pnode);
procedure gci_Scondc
(A : in Pnode);
procedure gci_Srep
(A : in Pnode);
procedure Calcula_Despls;
private
Nprofunditat : nprof;
end Semantica.gci;
| 20.210526 | 52 | 0.625651 |
2f2053c362b947e1c573aacbb26313c008300924 | 3,442 | ads | Ada | src/kvflyweights/kvflyweights-protected_hashtables.ads | jhumphry/auto_counters | bc7dfabf82febd09facf90371c8c11a628a06266 | [
"0BSD"
] | 5 | 2016-02-22T10:29:26.000Z | 2021-12-18T08:20:12.000Z | src/kvflyweights/kvflyweights-protected_hashtables.ads | jhumphry/auto_counters | bc7dfabf82febd09facf90371c8c11a628a06266 | [
"0BSD"
] | 1 | 2022-02-16T03:38:08.000Z | 2022-02-20T21:11:30.000Z | src/kvflyweights/kvflyweights-protected_hashtables.ads | jhumphry/auto_counters | bc7dfabf82febd09facf90371c8c11a628a06266 | [
"0BSD"
] | null | null | null | -- kvflyweights-basic_hashtables.ads
-- A package of non-task-safe hash tables for the KVFlyweights packages
-- Copyright (c) 2016, James Humphry
--
-- Permission to use, copy, modify, and/or distribute this software for any
-- purpose with or without fee is hereby granted, provided that the above
-- copyright notice and this permission notice appear in all copies.
--
-- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
-- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
-- AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
-- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
-- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
-- OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
-- PERFORMANCE OF THIS SOFTWARE.
pragma Profile (No_Implementation_Extensions);
with Ada.Containers;
with KVFlyweights_Lists_Spec;
with KVFlyweights_Hashtables_Spec;
generic
type Key(<>) is private;
type Key_Access is access Key;
type Value(<>) is limited private;
type Value_Access is access Value;
with function Hash (K : Key) return Ada.Containers.Hash_Type;
with package KVLists_Spec is
new KVFlyweights_Lists_Spec(Key => Key,
Key_Access => Key_Access,
Value_Access => Value_Access,
others => <>);
Capacity : Ada.Containers.Hash_Type := 256;
package KVFlyweights.Protected_Hashtables is
use type Ada.Containers.Hash_Type;
type List_Array is array (Ada.Containers.Hash_Type range <>) of KVLists_Spec.List;
protected type KVFlyweight is
procedure Insert (Bucket : out Ada.Containers.Hash_Type;
K : in Key;
Key_Ptr : out Key_Access;
Value_Ptr : out Value_Access);
procedure Increment (Bucket : in Ada.Containers.Hash_Type;
Key_Ptr : in Key_Access);
procedure Remove (Bucket : in Ada.Containers.Hash_Type;
Key_Ptr : in Key_Access);
private
Lists : List_Array (0..(Capacity-1))
:= (others => KVLists_Spec.Empty_List);
end KVFlyweight;
procedure Insert (F : aliased in out KVFlyweight;
Bucket : out Ada.Containers.Hash_Type;
K : in Key;
Key_Ptr : out Key_Access;
Value_Ptr : out Value_Access)
with Inline;
procedure Increment (F : aliased in out KVFlyweight;
Bucket : in Ada.Containers.Hash_Type;
Key_Ptr : in Key_Access)
with Inline;
procedure Remove (F : in out KVFlyweight;
Bucket : in Ada.Containers.Hash_Type;
Key_Ptr : in Key_Access)
with Inline;
package Hashtables_Spec is
new KVFlyweights_Hashtables_Spec(Key => Key,
Key_Access => Key_Access,
Value_Access => Value_Access,
KVFlyweight => KVFlyweight,
Insert => Insert,
Increment => Increment,
Remove => Remove);
end KVFlyweights.Protected_Hashtables;
| 39.113636 | 85 | 0.603719 |
2f4355b46249375e4b02c5feab663adfa1496e28 | 6,441 | adb | Ada | include/sf-network-http.adb | Fabien-Chouteau/ASFML | 52a013554bcfb6150e0d6391871356c1443a6b93 | [
"Zlib"
] | null | null | null | include/sf-network-http.adb | Fabien-Chouteau/ASFML | 52a013554bcfb6150e0d6391871356c1443a6b93 | [
"Zlib"
] | null | null | null | include/sf-network-http.adb | Fabien-Chouteau/ASFML | 52a013554bcfb6150e0d6391871356c1443a6b93 | [
"Zlib"
] | null | null | null | --//////////////////////////////////////////////////////////
-- //
-- // SFML - Simple and Fast Multimedia Library
-- // Copyright (C) 2007-2009 Laurent Gomila ([email protected])
-- //
-- // This software is provided 'as-is', without any express or implied warranty.
-- // In no event will the authors be held liable for any damages arising from the use of this software.
-- //
-- // Permission is granted to anyone to use this software for any purpose,
-- // including commercial applications, and to alter it and redistribute it freely,
-- // subject to the following restrictions:
-- //
-- // 1. The origin of this software must not be misrepresented;
-- // you must not claim that you wrote the original software.
-- // If you use this software in a product, an acknowledgment
-- // in the product documentation would be appreciated but is not required.
-- //
-- // 2. Altered source versions must be plainly marked as such,
-- // and must not be misrepresented as being the original software.
-- //
-- // 3. This notice may not be removed or altered from any source distribution.
-- //
--//////////////////////////////////////////////////////////
--//////////////////////////////////////////////////////////
--//////////////////////////////////////////////////////////
with Interfaces.C.Strings;
package body Sf.Network.Http is
use Interfaces.C.Strings;
package body Request is
--//////////////////////////////////////////////////////////
--/ Set the value of a field; the field is added if it doesn't exist
--/
--/ @param HttpRequest Http request to modify
--/ @param Field Name of the field to set (case-insensitive)
--/ @param Value Value of the field
--/
--//////////////////////////////////////////////////////////
procedure SetField (HttpRequest : sfHttpRequest_Ptr; Field : String; Value : String) is
procedure Internal (HttpRequest : sfHttpRequest_Ptr; Field : chars_ptr; Value : chars_ptr);
pragma Import (C, Internal, "sfHttpRequest_setField");
Temp1 : chars_ptr := New_String (Field);
Temp2 : chars_ptr := New_String (Value);
begin
Internal (HttpRequest, Temp1, Temp2);
Free (Temp1);
Free (Temp2);
end SetField;
--//////////////////////////////////////////////////////////
--/ Set the target URI of the request.
--/ This parameter is "/" by default
--/
--/ @param HttpRequest Http request to modify
--/ @param URI URI to request, local to the host
--/
--//////////////////////////////////////////////////////////
procedure SetURI (HttpRequest : sfHttpRequest_Ptr; URI : String) is
procedure Internal (HttpRequest : sfHttpRequest_Ptr; URI : chars_ptr);
pragma Import (C, Internal, "sfHttpRequest_setUri");
Temp : chars_ptr := New_String (URI);
begin
Internal (HttpRequest, Temp);
Free (Temp);
end SetURI;
--//////////////////////////////////////////////////////////
--/ Set the body of the request. This parameter is optional and
--/ makes sense only for POST requests.
--/ This parameter is empty by default
--/
--/ @param HttpRequest Http request to modify
--/ @param Body Content of the request body
--/
--//////////////////////////////////////////////////////////
procedure SetBody (HttpRequest : sfHttpRequest_Ptr; httpBody : String) is
procedure Internal (HttpRequest : sfHttpRequest_Ptr; httpBody : chars_ptr);
pragma Import (C, Internal, "sfHttpRequest_setBody");
Temp : chars_ptr := New_String (httpBody);
begin
Internal (HttpRequest, Temp);
Free (Temp);
end SetBody;
end Request;
package body Response is
--//////////////////////////////////////////////////////////
--/ Get the value of a field; returns NULL if the field doesn't exist
--/
--/ @param HttpResponse Http response
--/ @param Field Field to get
--/
--/ @return Value of the field (NULL if it doesn't exist)
--/
--//////////////////////////////////////////////////////////
function GetField (HttpResponse : sfHttpResponse_Ptr; Field : String) return String is
function Internal (HttpResponse : sfHttpResponse_Ptr; Field : chars_ptr) return chars_ptr;
pragma Import (C, Internal, "sfHttpResponse_getField");
Temp1 : chars_ptr := New_String (Field);
Temp2 : chars_ptr := Internal (HttpResponse, Temp1);
R : String := Value (Temp2);
begin
Free (Temp1);
Free (Temp2);
return R;
end GetField;
--//////////////////////////////////////////////////////////
--/ Get the body of the response. The body can contain :
--/ - the requested page (for GET requests)
--/ - a response from the server (for POST requests)
--/ - nothing (for HEAD requests)
--/ - an error message (in case of an error)
--/
--/ @param HttpResponse Http response
--/
--/ @return Body of the response (empty string if no body)
--/
--//////////////////////////////////////////////////////////
function GetBody (HttpResponse : sfHttpResponse_Ptr) return String is
function Internal (HttpResponse : sfHttpResponse_Ptr) return chars_ptr;
pragma Import (C, Internal, "sfHttpResponse_getBody");
Temp : chars_ptr := Internal (HttpResponse);
R : String := Value (Temp);
begin
Free (Temp);
return R;
end GetBody;
end Response;
--//////////////////////////////////////////////////////////
--/ Set the target host of a Http server
--/
--/ @param Http Http object
--/ @param Host Web server to connect to
--/ @param Port Port to use for connection (0 to use the standard port of the protocol used)
--/
--//////////////////////////////////////////////////////////
procedure SetHost (Http : sfHttp_Ptr; Host : String; Port : sfUint16) is
procedure Internal (Http : sfHttp_Ptr; Host : chars_ptr; Port : sfUint16);
pragma Import (C, Internal, "sfHttp_setHost");
Temp : chars_ptr := New_String (Host);
begin
Internal (Http, Temp, Port);
Free (Temp);
end SetHost;
end Sf.Network.Http;
| 41.288462 | 104 | 0.525695 |
2ff28b06d46fe4367cb238a9404c6461dd84f2dd | 2,553 | adb | Ada | Validation/pyFrame3DD-master/gcc-master/gcc/ada/libgnat/a-swuwha.adb | djamal2727/Main-Bearing-Analytical-Model | 2f00c2219c71be0175c6f4f8f1d4cca231d97096 | [
"Apache-2.0"
] | null | null | null | Validation/pyFrame3DD-master/gcc-master/gcc/ada/libgnat/a-swuwha.adb | djamal2727/Main-Bearing-Analytical-Model | 2f00c2219c71be0175c6f4f8f1d4cca231d97096 | [
"Apache-2.0"
] | null | null | null | Validation/pyFrame3DD-master/gcc-master/gcc/ada/libgnat/a-swuwha.adb | djamal2727/Main-Bearing-Analytical-Model | 2f00c2219c71be0175c6f4f8f1d4cca231d97096 | [
"Apache-2.0"
] | null | null | null | ------------------------------------------------------------------------------
-- --
-- GNAT LIBRARY COMPONENTS --
-- --
-- A D A . S T R I N G S . W I D E _ U N B O U N D E D . W I D E _ H A S H --
-- --
-- B o d y --
-- --
-- Copyright (C) 2004-2020, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
-- ware Foundation; either version 3, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
-- or FITNESS FOR A PARTICULAR PURPOSE. --
-- --
-- As a special exception under Section 7 of GPL version 3, you are granted --
-- additional permissions described in the GCC Runtime Library Exception, --
-- version 3.1, as published by the Free Software Foundation. --
-- --
-- You should have received a copy of the GNU General Public License and --
-- a copy of the GCC Runtime Library Exception along with this program; --
-- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
-- <http://www.gnu.org/licenses/>. --
-- --
-- This unit was originally developed by Matthew J Heaney. --
------------------------------------------------------------------------------
with System.String_Hash;
function Ada.Strings.Wide_Unbounded.Wide_Hash
(Key : Unbounded_Wide_String) return Containers.Hash_Type
is
use Ada.Containers;
function Hash is new System.String_Hash.Hash
(Wide_Character, Wide_String, Hash_Type);
begin
return Hash (To_Wide_String (Key));
end Ada.Strings.Wide_Unbounded.Wide_Hash;
| 62.268293 | 78 | 0.424207 |
1d99a4045e58ced90d139e74f33492a27bcbea25 | 17,288 | ads | Ada | arch/ARM/STM32/svd/stm32l4x6/stm32_svd-flash.ads | morbos/Ada_Drivers_Library | a4ab26799be60997c38735f4056160c4af597ef7 | [
"BSD-3-Clause"
] | 2 | 2018-05-16T03:56:39.000Z | 2019-07-31T13:53:56.000Z | arch/ARM/STM32/svd/stm32l4x6/stm32_svd-flash.ads | morbos/Ada_Drivers_Library | a4ab26799be60997c38735f4056160c4af597ef7 | [
"BSD-3-Clause"
] | null | null | null | arch/ARM/STM32/svd/stm32l4x6/stm32_svd-flash.ads | morbos/Ada_Drivers_Library | a4ab26799be60997c38735f4056160c4af597ef7 | [
"BSD-3-Clause"
] | null | null | null | -- This spec has been automatically generated from STM32L4x6.svd
pragma Restrictions (No_Elaboration_Code);
pragma Ada_2012;
pragma Style_Checks (Off);
with HAL;
with System;
package STM32_SVD.Flash is
pragma Preelaborate;
---------------
-- Registers --
---------------
subtype ACR_LATENCY_Field is HAL.UInt3;
-- Access control register
type ACR_Register is record
-- Latency
LATENCY : ACR_LATENCY_Field := 16#0#;
-- unspecified
Reserved_3_7 : HAL.UInt5 := 16#0#;
-- Prefetch enable
PRFTEN : Boolean := False;
-- Instruction cache enable
ICEN : Boolean := True;
-- Data cache enable
DCEN : Boolean := True;
-- Instruction cache reset
ICRST : Boolean := False;
-- Data cache reset
DCRST : Boolean := False;
-- Flash Power-down mode during Low-power run mode
RUN_PD : Boolean := False;
-- Flash Power-down mode during Low-power sleep mode
SLEEP_PD : Boolean := False;
-- unspecified
Reserved_15_31 : HAL.UInt17 := 16#0#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for ACR_Register use record
LATENCY at 0 range 0 .. 2;
Reserved_3_7 at 0 range 3 .. 7;
PRFTEN at 0 range 8 .. 8;
ICEN at 0 range 9 .. 9;
DCEN at 0 range 10 .. 10;
ICRST at 0 range 11 .. 11;
DCRST at 0 range 12 .. 12;
RUN_PD at 0 range 13 .. 13;
SLEEP_PD at 0 range 14 .. 14;
Reserved_15_31 at 0 range 15 .. 31;
end record;
-- Status register
type SR_Register is record
-- End of operation
EOP : Boolean := False;
-- Operation error
OPERR : Boolean := False;
-- unspecified
Reserved_2_2 : HAL.Bit := 16#0#;
-- Programming error
PROGERR : Boolean := False;
-- Write protected error
WRPERR : Boolean := False;
-- Programming alignment error
PGAERR : Boolean := False;
-- Size error
SIZERR : Boolean := False;
-- Programming sequence error
PGSERR : Boolean := False;
-- Fast programming data miss error
MISERR : Boolean := False;
-- Fast programming error
FASTERR : Boolean := False;
-- unspecified
Reserved_10_13 : HAL.UInt4 := 16#0#;
-- PCROP read error
RDERR : Boolean := False;
-- Option validity error
OPTVERR : Boolean := False;
-- Read-only. Busy
BSY : Boolean := False;
-- unspecified
Reserved_17_31 : HAL.UInt15 := 16#0#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for SR_Register use record
EOP at 0 range 0 .. 0;
OPERR at 0 range 1 .. 1;
Reserved_2_2 at 0 range 2 .. 2;
PROGERR at 0 range 3 .. 3;
WRPERR at 0 range 4 .. 4;
PGAERR at 0 range 5 .. 5;
SIZERR at 0 range 6 .. 6;
PGSERR at 0 range 7 .. 7;
MISERR at 0 range 8 .. 8;
FASTERR at 0 range 9 .. 9;
Reserved_10_13 at 0 range 10 .. 13;
RDERR at 0 range 14 .. 14;
OPTVERR at 0 range 15 .. 15;
BSY at 0 range 16 .. 16;
Reserved_17_31 at 0 range 17 .. 31;
end record;
subtype CR_PNB_Field is HAL.UInt8;
-- Flash control register
type CR_Register is record
-- Programming
PG : Boolean := False;
-- Page erase
PER : Boolean := False;
-- Bank 1 Mass erase
MER1 : Boolean := False;
-- Page number
PNB : CR_PNB_Field := 16#0#;
-- Bank erase
BKER : Boolean := False;
-- unspecified
Reserved_12_14 : HAL.UInt3 := 16#0#;
-- Bank 2 Mass erase
MER2 : Boolean := False;
-- Start
START : Boolean := False;
-- Options modification start
OPTSTRT : Boolean := False;
-- Fast programming
FSTPG : Boolean := False;
-- unspecified
Reserved_19_23 : HAL.UInt5 := 16#0#;
-- End of operation interrupt enable
EOPIE : Boolean := False;
-- Error interrupt enable
ERRIE : Boolean := False;
-- PCROP read error interrupt enable
RDERRIE : Boolean := False;
-- Force the option byte loading
OBL_LAUNCH : Boolean := False;
-- unspecified
Reserved_28_29 : HAL.UInt2 := 16#0#;
-- Options Lock
OPTLOCK : Boolean := True;
-- FLASH_CR Lock
LOCK : Boolean := True;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for CR_Register use record
PG at 0 range 0 .. 0;
PER at 0 range 1 .. 1;
MER1 at 0 range 2 .. 2;
PNB at 0 range 3 .. 10;
BKER at 0 range 11 .. 11;
Reserved_12_14 at 0 range 12 .. 14;
MER2 at 0 range 15 .. 15;
START at 0 range 16 .. 16;
OPTSTRT at 0 range 17 .. 17;
FSTPG at 0 range 18 .. 18;
Reserved_19_23 at 0 range 19 .. 23;
EOPIE at 0 range 24 .. 24;
ERRIE at 0 range 25 .. 25;
RDERRIE at 0 range 26 .. 26;
OBL_LAUNCH at 0 range 27 .. 27;
Reserved_28_29 at 0 range 28 .. 29;
OPTLOCK at 0 range 30 .. 30;
LOCK at 0 range 31 .. 31;
end record;
subtype ECCR_ADDR_ECC_Field is HAL.UInt19;
-- Flash ECC register
type ECCR_Register is record
-- Read-only. ECC fail address
ADDR_ECC : ECCR_ADDR_ECC_Field := 16#0#;
-- Read-only. ECC fail bank
BK_ECC : Boolean := False;
-- Read-only. System Flash ECC fail
SYSF_ECC : Boolean := False;
-- unspecified
Reserved_21_23 : HAL.UInt3 := 16#0#;
-- ECC correction interrupt enable
ECCIE : Boolean := False;
-- unspecified
Reserved_25_29 : HAL.UInt5 := 16#0#;
-- ECC correction
ECCC : Boolean := False;
-- ECC detection
ECCD : Boolean := False;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for ECCR_Register use record
ADDR_ECC at 0 range 0 .. 18;
BK_ECC at 0 range 19 .. 19;
SYSF_ECC at 0 range 20 .. 20;
Reserved_21_23 at 0 range 21 .. 23;
ECCIE at 0 range 24 .. 24;
Reserved_25_29 at 0 range 25 .. 29;
ECCC at 0 range 30 .. 30;
ECCD at 0 range 31 .. 31;
end record;
subtype OPTR_RDP_Field is HAL.UInt8;
subtype OPTR_BOR_LEV_Field is HAL.UInt3;
-- Flash option register
type OPTR_Register is record
-- Read protection level
RDP : OPTR_RDP_Field := 16#0#;
-- BOR reset Level
BOR_LEV : OPTR_BOR_LEV_Field := 16#0#;
-- unspecified
Reserved_11_11 : HAL.Bit := 16#0#;
-- nRST_STOP
nRST_STOP : Boolean := False;
-- nRST_STDBY
nRST_STDBY : Boolean := False;
-- unspecified
Reserved_14_15 : HAL.UInt2 := 16#0#;
-- Independent watchdog selection
IDWG_SW : Boolean := False;
-- Independent watchdog counter freeze in Stop mode
IWDG_STOP : Boolean := False;
-- Independent watchdog counter freeze in Standby mode
IWDG_STDBY : Boolean := False;
-- Window watchdog selection
WWDG_SW : Boolean := False;
-- Dual-bank boot
BFB2 : Boolean := False;
-- Dual-Bank on 512 KB or 256 KB Flash memory devices
DUALBANK : Boolean := False;
-- unspecified
Reserved_22_22 : HAL.Bit := 16#0#;
-- Boot configuration
nBOOT1 : Boolean := False;
-- SRAM2 parity check enable
SRAM2_PE : Boolean := False;
-- SRAM2 Erase when system reset
SRAM2_RST : Boolean := False;
-- unspecified
Reserved_26_31 : HAL.UInt6 := 16#3C#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for OPTR_Register use record
RDP at 0 range 0 .. 7;
BOR_LEV at 0 range 8 .. 10;
Reserved_11_11 at 0 range 11 .. 11;
nRST_STOP at 0 range 12 .. 12;
nRST_STDBY at 0 range 13 .. 13;
Reserved_14_15 at 0 range 14 .. 15;
IDWG_SW at 0 range 16 .. 16;
IWDG_STOP at 0 range 17 .. 17;
IWDG_STDBY at 0 range 18 .. 18;
WWDG_SW at 0 range 19 .. 19;
BFB2 at 0 range 20 .. 20;
DUALBANK at 0 range 21 .. 21;
Reserved_22_22 at 0 range 22 .. 22;
nBOOT1 at 0 range 23 .. 23;
SRAM2_PE at 0 range 24 .. 24;
SRAM2_RST at 0 range 25 .. 25;
Reserved_26_31 at 0 range 26 .. 31;
end record;
subtype PCROP1SR_PCROP1_STRT_Field is HAL.UInt16;
-- Flash Bank 1 PCROP Start address register
type PCROP1SR_Register is record
-- Bank 1 PCROP area start offset
PCROP1_STRT : PCROP1SR_PCROP1_STRT_Field := 16#0#;
-- unspecified
Reserved_16_31 : HAL.UInt16 := 16#FFFF#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for PCROP1SR_Register use record
PCROP1_STRT at 0 range 0 .. 15;
Reserved_16_31 at 0 range 16 .. 31;
end record;
subtype PCROP1ER_PCROP1_END_Field is HAL.UInt16;
-- Flash Bank 1 PCROP End address register
type PCROP1ER_Register is record
-- Bank 1 PCROP area end offset
PCROP1_END : PCROP1ER_PCROP1_END_Field := 16#0#;
-- unspecified
Reserved_16_30 : HAL.UInt15 := 16#FFF#;
-- PCROP area preserved when RDP level decreased
PCROP_RDP : Boolean := False;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for PCROP1ER_Register use record
PCROP1_END at 0 range 0 .. 15;
Reserved_16_30 at 0 range 16 .. 30;
PCROP_RDP at 0 range 31 .. 31;
end record;
subtype WRP1AR_WRP1A_STRT_Field is HAL.UInt8;
subtype WRP1AR_WRP1A_END_Field is HAL.UInt8;
-- Flash Bank 1 WRP area A address register
type WRP1AR_Register is record
-- Bank 1 WRP first area start offset
WRP1A_STRT : WRP1AR_WRP1A_STRT_Field := 16#0#;
-- unspecified
Reserved_8_15 : HAL.UInt8 := 16#FF#;
-- Bank 1 WRP first area A end offset
WRP1A_END : WRP1AR_WRP1A_END_Field := 16#0#;
-- unspecified
Reserved_24_31 : HAL.UInt8 := 16#FF#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for WRP1AR_Register use record
WRP1A_STRT at 0 range 0 .. 7;
Reserved_8_15 at 0 range 8 .. 15;
WRP1A_END at 0 range 16 .. 23;
Reserved_24_31 at 0 range 24 .. 31;
end record;
subtype WRP1BR_WRP1B_END_Field is HAL.UInt8;
subtype WRP1BR_WRP1B_STRT_Field is HAL.UInt8;
-- Flash Bank 1 WRP area B address register
type WRP1BR_Register is record
-- Bank 1 WRP second area B start offset
WRP1B_END : WRP1BR_WRP1B_END_Field := 16#0#;
-- unspecified
Reserved_8_15 : HAL.UInt8 := 16#FF#;
-- Bank 1 WRP second area B end offset
WRP1B_STRT : WRP1BR_WRP1B_STRT_Field := 16#0#;
-- unspecified
Reserved_24_31 : HAL.UInt8 := 16#FF#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for WRP1BR_Register use record
WRP1B_END at 0 range 0 .. 7;
Reserved_8_15 at 0 range 8 .. 15;
WRP1B_STRT at 0 range 16 .. 23;
Reserved_24_31 at 0 range 24 .. 31;
end record;
subtype PCROP2SR_PCROP2_STRT_Field is HAL.UInt16;
-- Flash Bank 2 PCROP Start address register
type PCROP2SR_Register is record
-- Bank 2 PCROP area start offset
PCROP2_STRT : PCROP2SR_PCROP2_STRT_Field := 16#0#;
-- unspecified
Reserved_16_31 : HAL.UInt16 := 16#FFFF#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for PCROP2SR_Register use record
PCROP2_STRT at 0 range 0 .. 15;
Reserved_16_31 at 0 range 16 .. 31;
end record;
subtype PCROP2ER_PCROP2_END_Field is HAL.UInt16;
-- Flash Bank 2 PCROP End address register
type PCROP2ER_Register is record
-- Bank 2 PCROP area end offset
PCROP2_END : PCROP2ER_PCROP2_END_Field := 16#0#;
-- unspecified
Reserved_16_31 : HAL.UInt16 := 16#FFFF#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for PCROP2ER_Register use record
PCROP2_END at 0 range 0 .. 15;
Reserved_16_31 at 0 range 16 .. 31;
end record;
subtype WRP2AR_WRP2A_STRT_Field is HAL.UInt8;
subtype WRP2AR_WRP2A_END_Field is HAL.UInt8;
-- Flash Bank 2 WRP area A address register
type WRP2AR_Register is record
-- Bank 2 WRP first area A start offset
WRP2A_STRT : WRP2AR_WRP2A_STRT_Field := 16#0#;
-- unspecified
Reserved_8_15 : HAL.UInt8 := 16#FF#;
-- Bank 2 WRP first area A end offset
WRP2A_END : WRP2AR_WRP2A_END_Field := 16#0#;
-- unspecified
Reserved_24_31 : HAL.UInt8 := 16#FF#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for WRP2AR_Register use record
WRP2A_STRT at 0 range 0 .. 7;
Reserved_8_15 at 0 range 8 .. 15;
WRP2A_END at 0 range 16 .. 23;
Reserved_24_31 at 0 range 24 .. 31;
end record;
subtype WRP2BR_WRP2B_STRT_Field is HAL.UInt8;
subtype WRP2BR_WRP2B_END_Field is HAL.UInt8;
-- Flash Bank 2 WRP area B address register
type WRP2BR_Register is record
-- Bank 2 WRP second area B start offset
WRP2B_STRT : WRP2BR_WRP2B_STRT_Field := 16#0#;
-- unspecified
Reserved_8_15 : HAL.UInt8 := 16#FF#;
-- Bank 2 WRP second area B end offset
WRP2B_END : WRP2BR_WRP2B_END_Field := 16#0#;
-- unspecified
Reserved_24_31 : HAL.UInt8 := 16#FF#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for WRP2BR_Register use record
WRP2B_STRT at 0 range 0 .. 7;
Reserved_8_15 at 0 range 8 .. 15;
WRP2B_END at 0 range 16 .. 23;
Reserved_24_31 at 0 range 24 .. 31;
end record;
-----------------
-- Peripherals --
-----------------
-- Flash
type FLASH_Peripheral is record
-- Access control register
ACR : aliased ACR_Register;
-- Power down key register
PDKEYR : aliased HAL.UInt32;
-- Flash key register
KEYR : aliased HAL.UInt32;
-- Option byte key register
OPTKEYR : aliased HAL.UInt32;
-- Status register
SR : aliased SR_Register;
-- Flash control register
CR : aliased CR_Register;
-- Flash ECC register
ECCR : aliased ECCR_Register;
-- Flash option register
OPTR : aliased OPTR_Register;
-- Flash Bank 1 PCROP Start address register
PCROP1SR : aliased PCROP1SR_Register;
-- Flash Bank 1 PCROP End address register
PCROP1ER : aliased PCROP1ER_Register;
-- Flash Bank 1 WRP area A address register
WRP1AR : aliased WRP1AR_Register;
-- Flash Bank 1 WRP area B address register
WRP1BR : aliased WRP1BR_Register;
-- Flash Bank 2 PCROP Start address register
PCROP2SR : aliased PCROP2SR_Register;
-- Flash Bank 2 PCROP End address register
PCROP2ER : aliased PCROP2ER_Register;
-- Flash Bank 2 WRP area A address register
WRP2AR : aliased WRP2AR_Register;
-- Flash Bank 2 WRP area B address register
WRP2BR : aliased WRP2BR_Register;
end record
with Volatile;
for FLASH_Peripheral use record
ACR at 16#0# range 0 .. 31;
PDKEYR at 16#4# range 0 .. 31;
KEYR at 16#8# range 0 .. 31;
OPTKEYR at 16#C# range 0 .. 31;
SR at 16#10# range 0 .. 31;
CR at 16#14# range 0 .. 31;
ECCR at 16#18# range 0 .. 31;
OPTR at 16#20# range 0 .. 31;
PCROP1SR at 16#24# range 0 .. 31;
PCROP1ER at 16#28# range 0 .. 31;
WRP1AR at 16#2C# range 0 .. 31;
WRP1BR at 16#30# range 0 .. 31;
PCROP2SR at 16#44# range 0 .. 31;
PCROP2ER at 16#48# range 0 .. 31;
WRP2AR at 16#4C# range 0 .. 31;
WRP2BR at 16#50# range 0 .. 31;
end record;
-- Flash
FLASH_Periph : aliased FLASH_Peripheral
with Import, Address => System'To_Address (16#40022000#);
end STM32_SVD.Flash;
| 34.098619 | 65 | 0.574098 |
1d060992aafb6aed2940c694f43c78da39430b02 | 822 | adb | Ada | Read Only/gdb-7.12.1/gdb/testsuite/gdb.ada/iwide/classes.adb | samyvic/OS-Project | 1622bc1641876584964effd91d65ef02e92728e1 | [
"Apache-2.0"
] | null | null | null | Read Only/gdb-7.12.1/gdb/testsuite/gdb.ada/iwide/classes.adb | samyvic/OS-Project | 1622bc1641876584964effd91d65ef02e92728e1 | [
"Apache-2.0"
] | null | null | null | Read Only/gdb-7.12.1/gdb/testsuite/gdb.ada/iwide/classes.adb | samyvic/OS-Project | 1622bc1641876584964effd91d65ef02e92728e1 | [
"Apache-2.0"
] | null | null | null | -- Copyright 2012-2017 Free Software Foundation, Inc.
--
-- 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 3 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, see <http://www.gnu.org/licenses/>.
package body Classes is
procedure Draw (R : Circle) is
begin
null;
end Draw;
end Classes;
| 34.25 | 73 | 0.725061 |
12caf8507171c7102706ff6b37b9aeca680569bc | 431 | ads | Ada | tests/src/pbkdf2-tests.ads | AntonMeep/pbkdf2 | cf7a84bf94d72ac33574eed761a197f25ad37050 | [
"0BSD"
] | null | null | null | tests/src/pbkdf2-tests.ads | AntonMeep/pbkdf2 | cf7a84bf94d72ac33574eed761a197f25ad37050 | [
"0BSD"
] | 2 | 2022-03-17T09:18:38.000Z | 2022-03-24T14:42:02.000Z | tests/src/pbkdf2-tests.ads | AntonMeep/pbkdf2 | cf7a84bf94d72ac33574eed761a197f25ad37050 | [
"0BSD"
] | null | null | null | with AUnit.Test_Fixtures;
with AUnit.Test_Suites;
package PBKDF2.Tests is
function Suite return AUnit.Test_Suites.Access_Test_Suite;
private
type Fixture is new AUnit.Test_Fixtures.Test_Fixture with null record;
procedure PBKDF2_HMAC_SHA_1_Test (Object : in out Fixture);
procedure PBKDF2_HMAC_SHA_256_Test (Object : in out Fixture);
procedure PBKDF2_HMAC_SHA_512_Test (Object : in out Fixture);
end PBKDF2.Tests;
| 33.153846 | 73 | 0.802784 |
063b7bd2922dab1476a687e240acab9cf47f118e | 797 | ads | Ada | src/fltk-widgets-inputs-outputs.ads | micahwelf/FLTK-Ada | 83e0c58ea98e5ede2cbbb158b42eae44196c3ba7 | [
"Unlicense"
] | 1 | 2020-12-18T15:20:13.000Z | 2020-12-18T15:20:13.000Z | src/fltk-widgets-inputs-outputs.ads | micahwelf/FLTK-Ada | 83e0c58ea98e5ede2cbbb158b42eae44196c3ba7 | [
"Unlicense"
] | null | null | null | src/fltk-widgets-inputs-outputs.ads | micahwelf/FLTK-Ada | 83e0c58ea98e5ede2cbbb158b42eae44196c3ba7 | [
"Unlicense"
] | null | null | null |
package FLTK.Widgets.Inputs.Outputs is
type Output is new Input with private;
type Output_Reference (Data : not null access Output'Class) is
limited null record with Implicit_Dereference => Data;
package Forge is
function Create
(X, Y, W, H : in Integer;
Text : in String)
return Output;
end Forge;
procedure Draw
(This : in out Output);
function Handle
(This : in out Output;
Event : in Event_Kind)
return Event_Outcome;
private
type Output is new Input with null record;
overriding procedure Finalize
(This : in out Output);
pragma Inline (Draw);
pragma Inline (Handle);
end FLTK.Widgets.Inputs.Outputs;
| 15.326923 | 66 | 0.588457 |
a126e4ff5d5cab40eca4d08abb9c1160116ed117 | 3,713 | adb | Ada | courses/fundamentals_of_ada/labs/solar_system/160_genericity/answers/solar_system.adb | AdaCore/training_material | 6651eb2c53f8c39649b8e0b3c757bc8ff963025a | [
"CC-BY-4.0"
] | 15 | 2020-10-07T08:56:45.000Z | 2022-02-08T23:13:22.000Z | courses/fundamentals_of_ada/labs/solar_system/160_genericity/answers/solar_system.adb | AdaCore/training_material | 6651eb2c53f8c39649b8e0b3c757bc8ff963025a | [
"CC-BY-4.0"
] | 20 | 2020-11-05T14:35:20.000Z | 2022-01-13T15:59:33.000Z | courses/fundamentals_of_ada/labs/solar_system/160_genericity/answers/solar_system.adb | AdaCore/training_material | 6651eb2c53f8c39649b8e0b3c757bc8ff963025a | [
"CC-BY-4.0"
] | 6 | 2020-10-08T15:57:06.000Z | 2021-08-31T12:03:08.000Z | -----------------------------------------------------------------------
-- Ada Labs --
-- --
-- Copyright (C) 2008-2009, AdaCore --
-- --
-- Labs 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. --
-----------------------------------------------------------------------
with Libm_Single; use Libm_Single;
package body Solar_System is
procedure Init_Body
(B : Bodies_Enum_T;
Bodies : in out Bodies_Array_T;
Radius : Float;
Color : RGBA_T;
Distance : Float;
Angle : Float;
Speed : Float;
Turns_Around : Bodies_Enum_T;
Visible : Boolean := True)
is
begin
Bodies (B) :=
(Distance => Distance,
Speed => Speed,
Angle => Angle,
Turns_Around => Turns_Around,
Visible => Visible,
Color => Color,
Radius => Radius,
others => <>);
end Init_Body;
procedure Set_Center(Bodies : in out Bodies_Array_T; X : Float; Y : Float) is
begin
Bodies(Bodies_Enum_T'First).X := X;
Bodies(Bodies_Enum_T'First).Y := Y;
end Set_Center;
-- implement a function to compute the X coordinate
-- x of the reference + distance * cos(angle)
function Compute_X
(Body_To_Move : Body_T;
Turns_Around : Body_T) return Float;
-- implement a function to compute the Y coordinate
-- y of the reference + distance * sin(angle)
function Compute_Y
(Body_To_Move : Body_T;
Turns_Around : Body_T) return Float;
function Compute_X
(Body_To_Move : Body_T;
Turns_Around : Body_T) return Float
is
begin
return Turns_Around.X + Body_To_Move.Distance * Cos (Body_To_Move.Angle);
end Compute_X;
function Compute_Y
(Body_To_Move : Body_T;
Turns_Around : Body_T) return Float
is
begin
return Turns_Around.Y + Body_To_Move.Distance * Sin (Body_To_Move.Angle);
end Compute_Y;
procedure Move (Body_To_Move : in out Body_T; Bodies : Bodies_Array_T) is
begin
Body_To_Move.X :=
Compute_X (Body_To_Move, Bodies (Body_To_Move.Turns_Around));
Body_To_Move.Y :=
Compute_Y (Body_To_Move, Bodies (Body_To_Move.Turns_Around));
Body_To_Move.Angle := Body_To_Move.Angle + Body_To_Move.Speed;
end Move;
procedure Move_All (Bodies : in out Bodies_Array_T) is
begin
-- loop over all bodies and call Move procedure
for B of Bodies loop
-- call the move procedure for each body
Move (B, Bodies);
end loop;
end Move_All;
end Solar_System;
| 34.06422 | 80 | 0.541341 |
1d3f20c74b4f6f7ea8a101bff9208a06d86e82e7 | 8,254 | adb | Ada | Ada95/samples/sample-keyboard_handler.adb | Ancient-Rom/android_external_libncurses | cfb80399910df8d55602d879d5cf0bc5ceaa2f89 | [
"X11"
] | 1,167 | 2017-08-21T21:21:24.000Z | 2022-03-31T15:42:10.000Z | release/src/router/libncurses/Ada95/samples/sample-keyboard_handler.adb | mon-routeur/Firmware | b25fef7cdab7fe306853baa471ad4a96a9da4600 | [
"FSFAP"
] | 374 | 2015-11-03T12:37:22.000Z | 2021-12-17T14:18:08.000Z | release/src/router/libncurses/Ada95/samples/sample-keyboard_handler.adb | mon-routeur/Firmware | b25fef7cdab7fe306853baa471ad4a96a9da4600 | [
"FSFAP"
] | 96 | 2015-11-22T07:47:26.000Z | 2022-01-20T19:52:19.000Z | ------------------------------------------------------------------------------
-- --
-- GNAT ncurses Binding Samples --
-- --
-- Sample.Keyboard_Handler --
-- --
-- B O D Y --
-- --
------------------------------------------------------------------------------
-- Copyright (c) 1998-2006,2011 Free Software Foundation, Inc. --
-- --
-- Permission is hereby granted, free of charge, to any person obtaining a --
-- copy of this software and associated documentation files (the --
-- "Software"), to deal in the Software without restriction, including --
-- without limitation the rights to use, copy, modify, merge, publish, --
-- distribute, distribute with modifications, sublicense, and/or sell --
-- copies of the Software, and to permit persons to whom the Software is --
-- furnished to do so, subject to the following conditions: --
-- --
-- The above copyright notice and this permission notice shall be included --
-- in all copies or substantial portions of the Software. --
-- --
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS --
-- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF --
-- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. --
-- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, --
-- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR --
-- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR --
-- THE USE OR OTHER DEALINGS IN THE SOFTWARE. --
-- --
-- Except as contained in this notice, the name(s) of the above copyright --
-- holders shall not be used in advertising or otherwise to promote the --
-- sale, use or other dealings in this Software without prior written --
-- authorization. --
------------------------------------------------------------------------------
-- Author: Juergen Pfeifer, 1996
-- Version Control
-- $Revision: 1.16 $
-- $Date: 2011/03/23 00:34:24 $
-- Binding Version 01.00
------------------------------------------------------------------------------
with Ada.Strings; use Ada.Strings;
with Ada.Strings.Fixed; use Ada.Strings.Fixed;
with Ada.Strings.Maps.Constants; use Ada.Strings.Maps.Constants;
with Ada.Characters.Latin_1; use Ada.Characters.Latin_1;
with Ada.Characters.Handling; use Ada.Characters.Handling;
with Terminal_Interface.Curses.Panels; use Terminal_Interface.Curses.Panels;
with Terminal_Interface.Curses.Forms; use Terminal_Interface.Curses.Forms;
with Terminal_Interface.Curses.Forms.Field_Types.Enumeration;
use Terminal_Interface.Curses.Forms.Field_Types.Enumeration;
with Sample.Header_Handler; use Sample.Header_Handler;
with Sample.Form_Demo.Aux; use Sample.Form_Demo.Aux;
with Sample.Manifest; use Sample.Manifest;
with Sample.Form_Demo.Handler;
-- This package contains a centralized keyboard handler used throughout
-- this example. The handler establishes a timeout mechanism that provides
-- periodical updates of the common header lines used in this example.
--
package body Sample.Keyboard_Handler is
In_Command : Boolean := False;
function Get_Key (Win : Window := Standard_Window) return Real_Key_Code
is
K : Real_Key_Code;
function Command return Real_Key_Code;
function Command return Real_Key_Code
is
function My_Driver (F : Form;
C : Key_Code;
P : Panel) return Boolean;
package Fh is new Sample.Form_Demo.Handler (My_Driver);
type Label_Array is array (Label_Number) of String (1 .. 8);
Labels : Label_Array;
FA : Field_Array_Access := new Field_Array'
(Make (0, 0, "Command:"),
Make (Top => 0, Left => 9, Width => Columns - 11),
Null_Field);
K : Real_Key_Code := Key_None;
N : Natural := 0;
function My_Driver (F : Form;
C : Key_Code;
P : Panel) return Boolean
is
Ch : Character;
begin
if P = Null_Panel then
raise Panel_Exception;
end if;
if C in User_Key_Code'Range and then C = QUIT then
if Driver (F, F_Validate_Field) = Form_Ok then
K := Key_None;
return True;
end if;
elsif C in Normal_Key_Code'Range then
Ch := Character'Val (C);
if Ch = LF or else Ch = CR then
if Driver (F, F_Validate_Field) = Form_Ok then
declare
Buffer : String (1 .. Positive (Columns - 11));
Cmdc : String (1 .. 8);
begin
Get_Buffer (Fld => FA.all (2), Str => Buffer);
Trim (Buffer, Left);
if Buffer (1) /= ' ' then
Cmdc := To_Upper (Buffer (Cmdc'Range));
for I in Labels'Range loop
if Cmdc = Labels (I) then
K := Function_Key_Code
(Function_Key_Number (I));
exit;
end if;
end loop;
end if;
return True;
end;
end if;
end if;
end if;
return False;
end My_Driver;
begin
In_Command := True;
for I in Label_Number'Range loop
Get_Soft_Label_Key (I, Labels (I));
Trim (Labels (I), Left);
Translate (Labels (I), Upper_Case_Map);
if Labels (I) (1) /= ' ' then
N := N + 1;
end if;
end loop;
if N > 0 then -- some labels were really set
declare
Enum_Info : Enumeration_Info (N);
Enum_Field : Enumeration_Field;
J : Positive := Enum_Info.Names'First;
Frm : Form := Create (FA);
begin
for I in Label_Number'Range loop
if Labels (I) (1) /= ' ' then
Enum_Info.Names (J) := new String'(Labels (I));
J := J + 1;
end if;
end loop;
Enum_Field := Create (Enum_Info, True);
Set_Field_Type (FA.all (2), Enum_Field);
Set_Background (FA.all (2), Normal_Video);
Fh.Drive_Me (Frm, Lines - 3, 0);
Delete (Frm);
Update_Panels; Update_Screen;
end;
end if;
Free (FA, True);
In_Command := False;
return K;
end Command;
begin
Set_Timeout_Mode (Win, Delayed, 30000);
loop
K := Get_Keystroke (Win);
if K = Key_None then -- a timeout occurred
Update_Header_Window;
elsif K = 3 and then not In_Command then -- CTRL-C
K := Command;
exit when K /= Key_None;
else
exit;
end if;
end loop;
return K;
end Get_Key;
procedure Init_Keyboard_Handler is
begin
null;
end Init_Keyboard_Handler;
end Sample.Keyboard_Handler;
| 42.328205 | 78 | 0.475769 |
31fedc48d11cd5d279265f491d5488a317f25bbe | 7,052 | adb | Ada | llvm-gcc-4.2-2.9/gcc/ada/widechar.adb | vidkidz/crossbridge | ba0bf94aee0ce6cf7eb5be882382e52bc57ba396 | [
"MIT"
] | 1 | 2016-04-09T02:58:13.000Z | 2016-04-09T02:58:13.000Z | llvm-gcc-4.2-2.9/gcc/ada/widechar.adb | vidkidz/crossbridge | ba0bf94aee0ce6cf7eb5be882382e52bc57ba396 | [
"MIT"
] | null | null | null | llvm-gcc-4.2-2.9/gcc/ada/widechar.adb | vidkidz/crossbridge | ba0bf94aee0ce6cf7eb5be882382e52bc57ba396 | [
"MIT"
] | null | null | null | ------------------------------------------------------------------------------
-- --
-- GNAT COMPILER COMPONENTS --
-- --
-- W I D E C H A R --
-- --
-- B o d y --
-- --
-- Copyright (C) 1992-2005, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
-- ware Foundation; either version 2, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT 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 distributed with GNAT; see file COPYING. If not, write --
-- to the Free Software Foundation, 51 Franklin Street, Fifth Floor, --
-- Boston, MA 02110-1301, USA. --
-- --
-- As a special exception, if other files instantiate generics from this --
-- unit, or you link this unit with other files to produce an executable, --
-- this unit does not by itself cause the resulting executable to be --
-- covered by the GNU General Public License. This exception does not --
-- however invalidate any other reasons why the executable file might be --
-- covered by the GNU Public License. --
-- --
-- GNAT was originally developed by the GNAT team at New York University. --
-- Extensive contributions were provided by Ada Core Technologies Inc. --
-- --
------------------------------------------------------------------------------
-- Note: this package uses the generic subprograms in System.Wch_Cnv, which
-- completely encapsulate the set of wide character encoding methods, so no
-- modifications are required when adding new encoding methods.
with Opt; use Opt;
with System.WCh_Cnv; use System.WCh_Cnv;
with System.WCh_Con; use System.WCh_Con;
package body Widechar is
---------------------------
-- Is_Start_Of_Wide_Char --
---------------------------
function Is_Start_Of_Wide_Char
(S : Source_Buffer_Ptr;
P : Source_Ptr) return Boolean
is
begin
case Wide_Character_Encoding_Method is
when WCEM_Hex =>
return S (P) = ASCII.ESC;
when WCEM_Upper |
WCEM_Shift_JIS |
WCEM_EUC |
WCEM_UTF8 =>
return S (P) >= Character'Val (16#80#);
when WCEM_Brackets =>
return P <= S'Last - 2
and then S (P) = '['
and then S (P + 1) = '"'
and then S (P + 2) /= '"';
end case;
end Is_Start_Of_Wide_Char;
-----------------
-- Length_Wide --
-----------------
function Length_Wide return Nat is
begin
return WC_Longest_Sequence;
end Length_Wide;
---------------
-- Scan_Wide --
---------------
procedure Scan_Wide
(S : Source_Buffer_Ptr;
P : in out Source_Ptr;
C : out Char_Code;
Err : out Boolean)
is
P_Init : constant Source_Ptr := P;
function In_Char return Character;
-- Function to obtain characters of wide character escape sequence
-------------
-- In_Char --
-------------
function In_Char return Character is
begin
P := P + 1;
return S (P - 1);
end In_Char;
function WC_In is new Char_Sequence_To_UTF_32 (In_Char);
-- Start of processingf for Scan_Wide
begin
C := Char_Code (WC_In (In_Char, Wide_Character_Encoding_Method));
Err := False;
Wide_Char_Byte_Count := Wide_Char_Byte_Count + Nat (P - P_Init - 1);
exception
when Constraint_Error =>
C := Char_Code (0);
P := P - 1;
Err := True;
end Scan_Wide;
--------------
-- Set_Wide --
--------------
procedure Set_Wide
(C : Char_Code;
S : in out String;
P : in out Natural)
is
procedure Out_Char (C : Character);
-- Procedure to store one character of wide character sequence
--------------
-- Out_Char --
--------------
procedure Out_Char (C : Character) is
begin
P := P + 1;
S (P) := C;
end Out_Char;
procedure WC_Out is new UTF_32_To_Char_Sequence (Out_Char);
-- Start of processing for Set_Wide
begin
WC_Out (UTF_32_Code (C), Wide_Character_Encoding_Method);
end Set_Wide;
---------------
-- Skip_Wide --
---------------
procedure Skip_Wide (S : String; P : in out Natural) is
P_Init : constant Natural := P;
function Skip_Char return Character;
-- Function to skip one character of wide character escape sequence
---------------
-- Skip_Char --
---------------
function Skip_Char return Character is
begin
P := P + 1;
return S (P - 1);
end Skip_Char;
function WC_Skip is new Char_Sequence_To_UTF_32 (Skip_Char);
Discard : UTF_32_Code;
pragma Warnings (Off, Discard);
-- Start of processing for Skip_Wide
begin
Discard := WC_Skip (Skip_Char, Wide_Character_Encoding_Method);
Wide_Char_Byte_Count := Wide_Char_Byte_Count + Nat (P - P_Init - 1);
end Skip_Wide;
---------------
-- Skip_Wide --
---------------
procedure Skip_Wide (S : Source_Buffer_Ptr; P : in out Source_Ptr) is
P_Init : constant Source_Ptr := P;
function Skip_Char return Character;
-- Function to skip one character of wide character escape sequence
---------------
-- Skip_Char --
---------------
function Skip_Char return Character is
begin
P := P + 1;
return S (P - 1);
end Skip_Char;
function WC_Skip is new Char_Sequence_To_UTF_32 (Skip_Char);
Discard : UTF_32_Code;
pragma Warnings (Off, Discard);
-- Start of processing for Skip_Wide
begin
Discard := WC_Skip (Skip_Char, Wide_Character_Encoding_Method);
Wide_Char_Byte_Count := Wide_Char_Byte_Count + Nat (P - P_Init - 1);
end Skip_Wide;
end Widechar;
| 32.497696 | 78 | 0.502836 |
1d060c5377a28cc0294bacd5c747b96dbf9e6fed | 3,884 | adb | Ada | src/adda-generator.adb | alban-linard/adda | b9af3c98458927979eacefb145c019081ea75b4f | [
"MIT"
] | null | null | null | src/adda-generator.adb | alban-linard/adda | b9af3c98458927979eacefb145c019081ea75b4f | [
"MIT"
] | null | null | null | src/adda-generator.adb | alban-linard/adda | b9af3c98458927979eacefb145c019081ea75b4f | [
"MIT"
] | null | null | null | package body Adda.Generator is
use Successors;
overriding procedure Initialize
(Object : in out Decision_Diagram) is
begin
if Object.Data /= null then
Object.Data.Reference_Counter.all :=
Object.Data.Reference_Counter.all + 1;
end if;
end Initialize;
overriding procedure Adjust
(Object : in out Decision_Diagram) renames Initialize;
overriding procedure Finalize
(Object : in out Decision_Diagram) is
begin
if Object.Data /= null then
Object.Data.Reference_Counter.all :=
Object.Data.Reference_Counter.all - 1;
if Object.Data.Reference_Counter.all = 0 then
null; -- FIXME
end if;
end if;
end Finalize;
function Hash
(Element : in Decision_Diagram)
return Hash_Type is
begin
return Hash_Type (Element.Data.Identifier);
end Hash;
function "="
(Left, Right : in Decision_Diagram)
return Boolean is
begin
return Left.Data
= Right.Data; -- TODO: check that it is a pointer comparison
end "=";
function Hash
(Element : in Structure)
return Hash_Type is
begin
case Element.Of_Type is
when Terminal =>
return Hash_Terminal (Element.Value);
when Non_Terminal =>
declare
Result : Hash_Type := Hash_Variable (Element.Variable);
Current : Successors.Cursor :=
Successors.First (Element.Alpha);
begin
while Successors.Has_Element (Current) loop
Result :=
Result
xor
(Hash_Value (Successors.Key (Current))
xor Hash (Successors.Element (Current)));
Successors.Next (Current);
end loop;
return Result;
end;
end case;
end Hash;
overriding function "="
(Left, Right : in Structure)
return Boolean is
begin
if Left.Of_Type = Right.Of_Type then
case Left.Of_Type is
when Terminal =>
return Left.Value = Right.Value;
when Non_Terminal =>
return Left.Variable = Right.Variable
and then Left.Alpha = Right.Alpha;
end case;
else
return False;
end if;
end "=";
function Make
(Value : in Terminal_Type)
return Decision_Diagram is
To_Insert : constant Structure :=
(Of_Type => Terminal,
Identifier => 0,
Reference_Counter => null,
Value => Value);
Position : Unicity.Cursor;
Inserted : Boolean;
begin
Unicity_Table.Insert
(New_Item => To_Insert,
Position => Position,
Inserted => Inserted);
declare
Subdata : aliased Structure := Unicity.Element (Position);
Data : constant Any_Structure := Subdata'Unchecked_Access;
begin
if Inserted then
Identifier := Identifier + 1;
Subdata.Identifier := Identifier + 1;
Subdata.Reference_Counter := new Natural'(0);
end if;
return (Controlled with Data => Data);
end;
end Make;
function Make
(Variable : in Variable_Type;
Value : in Value_Type;
Successor : in Decision_Diagram)
return Decision_Diagram is
Result : Decision_Diagram;
begin
return Result;
end Make;
begin
null;
end Adda.Generator;
| 27.742857 | 76 | 0.518795 |
2f25f266a2511e9e4f3270ca16db0bba91fd7647 | 819 | adb | Ada | gdb/testsuite/gdb.ada/task_bp/pck.adb | greyblue9/binutils-gdb | 05377632b124fe7600eea7f4ee0e9a35d1b0cbdc | [
"BSD-3-Clause"
] | 1 | 2020-10-14T03:24:35.000Z | 2020-10-14T03:24:35.000Z | gdb/testsuite/gdb.ada/task_bp/pck.adb | greyblue9/binutils-gdb | 05377632b124fe7600eea7f4ee0e9a35d1b0cbdc | [
"BSD-3-Clause"
] | null | null | null | gdb/testsuite/gdb.ada/task_bp/pck.adb | greyblue9/binutils-gdb | 05377632b124fe7600eea7f4ee0e9a35d1b0cbdc | [
"BSD-3-Clause"
] | null | null | null | -- Copyright 2011-2021 Free Software Foundation, Inc.
--
-- 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 3 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, see <http://www.gnu.org/licenses/>.
package body Pck is
task body Dummy_Task is
begin
accept Start;
end Dummy_Task;
end Pck;
| 37.227273 | 73 | 0.73138 |
a10c754458b75b3977b314039b92daaa0395f847 | 860 | adb | Ada | src/gdb/gdb-7.11/gdb/testsuite/gdb.ada/float_param/foo.adb | alrooney/unum-sdk | bbccb10b0cd3500feccbbef22e27ea111c3d18eb | [
"Apache-2.0"
] | 31 | 2018-08-01T21:25:24.000Z | 2022-02-14T07:52:34.000Z | src/gdb/gdb-7.11/gdb/testsuite/gdb.ada/float_param/foo.adb | alrooney/unum-sdk | bbccb10b0cd3500feccbbef22e27ea111c3d18eb | [
"Apache-2.0"
] | 40 | 2018-12-03T19:48:52.000Z | 2021-03-10T06:34:26.000Z | src/gdb/gdb-7.11/gdb/testsuite/gdb.ada/float_param/foo.adb | alrooney/unum-sdk | bbccb10b0cd3500feccbbef22e27ea111c3d18eb | [
"Apache-2.0"
] | 20 | 2018-11-16T21:19:22.000Z | 2021-10-18T23:08:24.000Z | -- Copyright 2013-2016 Free Software Foundation, Inc.
--
-- 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 3 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, see <http://www.gnu.org/licenses/>.
with Pck; use Pck;
procedure Foo is
begin
Set_Float (1.0); -- START
Set_Double (1, 1.0);
Set_Long_Double (1, (I => 2), 1.0);
end Foo;
| 35.833333 | 73 | 0.715116 |
31a95812694ab16db8f840496987aba71ff28607 | 2,125 | adb | Ada | out/aaa_021if.adb | Melyodas/metalang | 399a9f1a71402c979d7f8024d4f98f081c80e771 | [
"BSD-2-Clause"
] | 22 | 2017-04-24T10:00:45.000Z | 2021-04-01T10:11:05.000Z | out/aaa_021if.adb | Melyodas/metalang | 399a9f1a71402c979d7f8024d4f98f081c80e771 | [
"BSD-2-Clause"
] | 12 | 2017-03-26T18:34:21.000Z | 2019-03-21T19:13:03.000Z | out/aaa_021if.adb | Melyodas/metalang | 399a9f1a71402c979d7f8024d4f98f081c80e771 | [
"BSD-2-Clause"
] | 7 | 2017-10-14T13:33:33.000Z | 2021-03-18T15:18:50.000Z |
with ada.text_io, ada.Integer_text_IO, Ada.Text_IO.Text_Streams, Ada.Strings.Fixed, Interfaces.C;
use ada.text_io, ada.Integer_text_IO, Ada.Strings, Ada.Strings.Fixed, Interfaces.C;
procedure aaa_021if is
type stringptr is access all char_array;
procedure PString(s : stringptr) is
begin
String'Write (Text_Streams.Stream (Current_Output), To_Ada(s.all));
end;
procedure testA(a : in Boolean; b : in Boolean) is
begin
if a
then
if b
then
PString(new char_array'( To_C("A")));
else
PString(new char_array'( To_C("B")));
end if;
else
if b
then
PString(new char_array'( To_C("C")));
else
PString(new char_array'( To_C("D")));
end if;
end if;
end;
procedure testB(a : in Boolean; b : in Boolean) is
begin
if a
then
PString(new char_array'( To_C("A")));
else
if b
then
PString(new char_array'( To_C("B")));
else
PString(new char_array'( To_C("C")));
end if;
end if;
end;
procedure testC(a : in Boolean; b : in Boolean) is
begin
if a
then
if b
then
PString(new char_array'( To_C("A")));
else
PString(new char_array'( To_C("B")));
end if;
else
PString(new char_array'( To_C("C")));
end if;
end;
procedure testD(a : in Boolean; b : in Boolean) is
begin
if a
then
if b
then
PString(new char_array'( To_C("A")));
else
PString(new char_array'( To_C("B")));
end if;
PString(new char_array'( To_C("C")));
else
PString(new char_array'( To_C("D")));
end if;
end;
procedure testE(a : in Boolean; b : in Boolean) is
begin
if a
then
if b
then
PString(new char_array'( To_C("A")));
end if;
else
if b
then
PString(new char_array'( To_C("C")));
else
PString(new char_array'( To_C("D")));
end if;
PString(new char_array'( To_C("E")));
end if;
end;
procedure test(a : in Boolean; b : in Boolean) is
begin
testD(a, b);
testE(a, b);
PString(new char_array'( To_C("" & Character'Val(10))));
end;
begin
test(TRUE, TRUE);
test(TRUE, FALSE);
test(FALSE, TRUE);
test(FALSE, FALSE);
end;
| 19.859813 | 97 | 0.613176 |
fb4b545ae4e2f33514d42ca50d77ab6f755b865a | 29,211 | adb | Ada | Validation/pyFrame3DD-master/gcc-master/gcc/ada/libgnat/a-exexpr.adb | djamal2727/Main-Bearing-Analytical-Model | 2f00c2219c71be0175c6f4f8f1d4cca231d97096 | [
"Apache-2.0"
] | null | null | null | Validation/pyFrame3DD-master/gcc-master/gcc/ada/libgnat/a-exexpr.adb | djamal2727/Main-Bearing-Analytical-Model | 2f00c2219c71be0175c6f4f8f1d4cca231d97096 | [
"Apache-2.0"
] | null | null | null | Validation/pyFrame3DD-master/gcc-master/gcc/ada/libgnat/a-exexpr.adb | djamal2727/Main-Bearing-Analytical-Model | 2f00c2219c71be0175c6f4f8f1d4cca231d97096 | [
"Apache-2.0"
] | null | null | null | ------------------------------------------------------------------------------
-- --
-- GNAT COMPILER COMPONENTS --
-- --
-- A D A . E X C E P T I O N S . E X C E P T I O N _ P R O P A G A T I O N --
-- --
-- B o d y --
-- --
-- Copyright (C) 1992-2020, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
-- ware Foundation; either version 3, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
-- or FITNESS FOR A PARTICULAR PURPOSE. --
-- --
-- As a special exception under Section 7 of GPL version 3, you are granted --
-- additional permissions described in the GCC Runtime Library Exception, --
-- version 3.1, as published by the Free Software Foundation. --
-- --
-- You should have received a copy of the GNU General Public License and --
-- a copy of the GCC Runtime Library Exception along with this program; --
-- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
-- <http://www.gnu.org/licenses/>. --
-- --
-- GNAT was originally developed by the GNAT team at New York University. --
-- Extensive contributions were provided by Ada Core Technologies Inc. --
-- --
------------------------------------------------------------------------------
-- This is the version using the GCC EH mechanism, which could rely on
-- different underlying unwinding engines, for example DWARF or ARM unwind
-- info based. Here is a sketch of the most prominent data structures
-- involved:
-- (s-excmac.ads)
-- GNAT_GCC_Exception:
-- *-----------------------------------*
-- o-->| (s-excmac.ads) |
-- | | Header : <gcc occurrence type> |
-- | | - Class |
-- | | ... | Constraint_Error:
-- | |-----------------------------------* Program_Error:
-- | | (a-except.ads) | Foreign_Exception:
-- | | Occurrence : Exception_Occurrence |
-- | | | (s-stalib. ads)
-- | | - Id : Exception_Id --------------> Exception_Data
-- o------ - Machine_Occurrence | *------------------------*
-- | - Msg | | Not_Handled_By_Others |
-- | - Traceback | | Lang |
-- | ... | | Foreign_Data --o |
-- *-----------------------------------* | Full_Name | |
-- || | ... | |
-- || foreign rtti blob *----------------|-------*
-- || *---------------* |
-- || | ... ... |<-------------------------o
-- || *---------------*
-- ||
-- Setup_Current_Excep()
-- ||
-- || Latch into ATCB or
-- || environment Current Exception Buffer:
-- ||
-- vv
-- <> : Exception_Occurrence
-- *---------------------------*
-- | ... ... ... ... ... ... * --- Get_Current_Excep() ---->
-- *---------------------------*
-- On "raise" events, the runtime allocates a new GNAT_GCC_Exception
-- instance and eventually calls into libgcc's Unwind_RaiseException.
-- This part handles the object through the header part only.
-- During execution, Get_Current_Excep provides a pointer to the
-- Exception_Occurrence being raised or last raised by the current task.
-- This is actually the address of a statically allocated
-- Exception_Occurrence attached to the current ATCB or to the environment
-- thread into which an occurrence being raised is synchronized at critical
-- points during the raise process, via Setup_Current_Excep.
with Ada.Unchecked_Conversion;
with Ada.Unchecked_Deallocation;
with System.Storage_Elements; use System.Storage_Elements;
with System.Exceptions.Machine; use System.Exceptions.Machine;
separate (Ada.Exceptions)
package body Exception_Propagation is
use Exception_Traces;
Foreign_Exception : aliased System.Standard_Library.Exception_Data;
pragma Import (Ada, Foreign_Exception,
"system__exceptions__foreign_exception");
-- Id for foreign exceptions
--------------------------------------------------------------
-- GNAT Specific Entities To Deal With The GCC EH Circuitry --
--------------------------------------------------------------
-- Phase identifiers (Unwind Actions)
type Unwind_Action is new Integer;
pragma Convention (C, Unwind_Action);
UA_SEARCH_PHASE : constant Unwind_Action := 1;
UA_CLEANUP_PHASE : constant Unwind_Action := 2;
UA_HANDLER_FRAME : constant Unwind_Action := 4;
UA_FORCE_UNWIND : constant Unwind_Action := 8;
UA_END_OF_STACK : constant Unwind_Action := 16; -- GCC extension
pragma Unreferenced
(UA_HANDLER_FRAME,
UA_FORCE_UNWIND,
UA_END_OF_STACK);
procedure GNAT_GCC_Exception_Cleanup
(Reason : Unwind_Reason_Code;
Excep : not null GNAT_GCC_Exception_Access);
pragma Convention (C, GNAT_GCC_Exception_Cleanup);
-- Procedure called when a GNAT GCC exception is free.
procedure Propagate_GCC_Exception
(GCC_Exception : not null GCC_Exception_Access);
pragma No_Return (Propagate_GCC_Exception);
-- Propagate a GCC exception
procedure Reraise_GCC_Exception
(GCC_Exception : not null GCC_Exception_Access);
pragma No_Return (Reraise_GCC_Exception);
pragma Export (C, Reraise_GCC_Exception, "__gnat_reraise_zcx");
-- Called to implement raise without exception, ie reraise. Called
-- directly from gigi.
function Setup_Current_Excep
(GCC_Exception : not null GCC_Exception_Access;
Phase : Unwind_Action) return EOA;
pragma Export (C, Setup_Current_Excep, "__gnat_setup_current_excep");
-- Acknowledge GCC_Exception as the current exception object being
-- raised, which could be an Ada or a foreign exception object. Return
-- a pointer to the embedded Ada occurrence for an Ada exception object,
-- to the current exception buffer otherwise.
--
-- Synchronize the current exception buffer as needed for possible
-- accesses through Get_Current_Except.all afterwards, depending on the
-- Phase bits, received either from the personality routine, from a
-- forced_unwind cleanup handler, or just before the start of propagation
-- for an Ada exception (Phase 0 in this case).
procedure Unhandled_Except_Handler
(GCC_Exception : not null GCC_Exception_Access);
pragma No_Return (Unhandled_Except_Handler);
pragma Export (C, Unhandled_Except_Handler,
"__gnat_unhandled_except_handler");
-- Called for handle unhandled exceptions, ie the last chance handler
-- on platforms (such as SEH) that never returns after throwing an
-- exception. Called directly by gigi.
function CleanupUnwind_Handler
(UW_Version : Integer;
UW_Phases : Unwind_Action;
UW_Eclass : Exception_Class;
UW_Exception : not null GCC_Exception_Access;
UW_Context : System.Address;
UW_Argument : System.Address) return Unwind_Reason_Code;
pragma Import (C, CleanupUnwind_Handler,
"__gnat_cleanupunwind_handler");
-- Hook called at each step of the forced unwinding we perform to trigger
-- cleanups found during the propagation of an unhandled exception.
-- GCC runtime functions used. These are C non-void functions, actually,
-- but we ignore the return values. See raise.c as to why we are using
-- __gnat stubs for these.
procedure Unwind_RaiseException
(UW_Exception : not null GCC_Exception_Access);
pragma Import (C, Unwind_RaiseException, "__gnat_Unwind_RaiseException");
procedure Unwind_ForcedUnwind
(UW_Exception : not null GCC_Exception_Access;
UW_Handler : System.Address;
UW_Argument : System.Address);
pragma Import (C, Unwind_ForcedUnwind, "__gnat_Unwind_ForcedUnwind");
procedure Set_Exception_Parameter
(Excep : EOA;
GCC_Exception : not null GCC_Exception_Access);
pragma Export
(C, Set_Exception_Parameter, "__gnat_set_exception_parameter");
-- Called inserted by gigi to set the exception choice parameter from the
-- gcc occurrence.
procedure Set_Foreign_Occurrence (Excep : EOA; Mo : System.Address);
-- Utility routine to initialize occurrence Excep from a foreign exception
-- whose machine occurrence is Mo. The message is empty, the backtrace
-- is empty too and the exception identity is Foreign_Exception.
-- Hooks called when entering/leaving an exception handler for a
-- given occurrence. The calls are generated by gigi in
-- Exception_Handler_to_gnu_gcc.
-- Begin_Handler_v1, called when entering an exception handler,
-- claims responsibility for the handler to release the
-- GCC_Exception occurrence. End_Handler_v1, called when
-- leaving the handler, releases the occurrence, unless the
-- occurrence is propagating further up, or the handler is
-- dynamically nested in the context of another handler that
-- claimed responsibility for releasing that occurrence.
-- Responsibility is claimed by changing the Cleanup field to
-- Claimed_Cleanup, which enables claimed exceptions to be
-- recognized, and avoids accidental releases even by foreign
-- handlers.
function Begin_Handler_v1
(GCC_Exception : not null GCC_Exception_Access)
return System.Address;
pragma Export (C, Begin_Handler_v1, "__gnat_begin_handler_v1");
-- Called when entering an exception handler. Claim
-- responsibility for releasing GCC_Exception, by setting the
-- cleanup/release function to Claimed_Cleanup, and return the
-- address of the previous cleanup/release function.
procedure End_Handler_v1
(GCC_Exception : not null GCC_Exception_Access;
Saved_Cleanup : System.Address;
Propagating_Exception : GCC_Exception_Access);
pragma Export (C, End_Handler_v1, "__gnat_end_handler_v1");
-- Called when leaving an exception handler. Restore the
-- Saved_Cleanup in the GCC_Exception occurrence, and then release
-- it, unless it remains claimed by an enclosing handler, or
-- GCC_Exception and Propagating_Exception are the same
-- occurrence. Propagating_Exception could be either an
-- occurrence (re)raised within the handler of GCC_Exception, when
-- we're executing as an exceptional cleanup, or null, if we're
-- completing the handler of GCC_Exception normally.
procedure Claimed_Cleanup
(Reason : Unwind_Reason_Code;
GCC_Exception : not null GCC_Exception_Access);
pragma Export (C, Claimed_Cleanup, "__gnat_claimed_cleanup");
-- A do-nothing placeholder installed as GCC_Exception.Cleanup
-- while handling GCC_Exception, to claim responsibility for
-- releasing it, and to stop it from being accidentally released.
-- The following are version 0 implementations of the version 1
-- hooks above. They remain in place for compatibility with the
-- output of compilers that still use version 0, such as those
-- used during bootstrap. They are interoperable with the v1
-- hooks, except that the older versions may malfunction when
-- handling foreign exceptions passed to Reraise_Occurrence.
procedure Begin_Handler (GCC_Exception : not null GCC_Exception_Access);
pragma Export (C, Begin_Handler, "__gnat_begin_handler");
-- Called when entering an exception handler translated by an old
-- compiler. It does nothing.
procedure End_Handler (GCC_Exception : GCC_Exception_Access);
pragma Export (C, End_Handler, "__gnat_end_handler");
-- Called when leaving an exception handler translated by an old
-- compiler. It releases GCC_Exception, unless it is null. It is
-- only ever null when the handler has a 'raise;' translated by a
-- v0-using compiler. The artificial handler variable passed to
-- End_Handler was set to null to tell End_Handler to refrain from
-- releasing the reraised exception. In v1 safer ways are used to
-- accomplish that.
--------------------------------------------------------------------
-- Accessors to Basic Components of a GNAT Exception Data Pointer --
--------------------------------------------------------------------
-- As of today, these are only used by the C implementation of the GCC
-- propagation personality routine to avoid having to rely on a C
-- counterpart of the whole exception_data structure, which is both
-- painful and error prone. These subprograms could be moved to a more
-- widely visible location if need be.
function Is_Handled_By_Others (E : Exception_Data_Ptr) return Boolean;
pragma Export (C, Is_Handled_By_Others, "__gnat_is_handled_by_others");
pragma Warnings (Off, Is_Handled_By_Others);
function Language_For (E : Exception_Data_Ptr) return Character;
pragma Export (C, Language_For, "__gnat_language_for");
function Foreign_Data_For (E : Exception_Data_Ptr) return Address;
pragma Export (C, Foreign_Data_For, "__gnat_foreign_data_for");
function EID_For (GNAT_Exception : not null GNAT_GCC_Exception_Access)
return Exception_Id;
pragma Export (C, EID_For, "__gnat_eid_for");
---------------------------------------------------------------------------
-- Objects to materialize "others" and "all others" in the GCC EH tables --
---------------------------------------------------------------------------
-- Currently, these only have their address taken and compared so there is
-- no real point having whole exception data blocks allocated. Note that
-- there are corresponding declarations in gigi (trans.c) which must be
-- kept properly synchronized.
Others_Value : constant Character := 'O';
pragma Export (C, Others_Value, "__gnat_others_value");
All_Others_Value : constant Character := 'A';
pragma Export (C, All_Others_Value, "__gnat_all_others_value");
Unhandled_Others_Value : constant Character := 'U';
pragma Export (C, Unhandled_Others_Value, "__gnat_unhandled_others_value");
-- Special choice (emitted by gigi) to catch and notify unhandled
-- exceptions on targets which always handle exceptions (such as SEH).
-- The handler will simply call Unhandled_Except_Handler.
-------------------------
-- Allocate_Occurrence --
-------------------------
function Allocate_Occurrence return EOA is
Res : GNAT_GCC_Exception_Access;
begin
Res := New_Occurrence;
Res.Header.Cleanup := GNAT_GCC_Exception_Cleanup'Address;
Res.Occurrence.Machine_Occurrence := Res.all'Address;
return Res.Occurrence'Access;
end Allocate_Occurrence;
--------------------------------
-- GNAT_GCC_Exception_Cleanup --
--------------------------------
procedure GNAT_GCC_Exception_Cleanup
(Reason : Unwind_Reason_Code;
Excep : not null GNAT_GCC_Exception_Access)
is
pragma Unreferenced (Reason);
procedure Free is new Unchecked_Deallocation
(GNAT_GCC_Exception, GNAT_GCC_Exception_Access);
Copy : GNAT_GCC_Exception_Access := Excep;
begin
-- Simply free the memory
Free (Copy);
end GNAT_GCC_Exception_Cleanup;
----------------------------
-- Set_Foreign_Occurrence --
----------------------------
procedure Set_Foreign_Occurrence (Excep : EOA; Mo : System.Address) is
begin
Excep.all := (
Id => Foreign_Exception'Access,
Machine_Occurrence => Mo,
Msg => <>,
Msg_Length => 0,
Exception_Raised => True,
Pid => Local_Partition_ID,
Num_Tracebacks => 0,
Tracebacks => <>);
end Set_Foreign_Occurrence;
-------------------------
-- Setup_Current_Excep --
-------------------------
function Setup_Current_Excep
(GCC_Exception : not null GCC_Exception_Access;
Phase : Unwind_Action) return EOA
is
Excep : constant EOA := Get_Current_Excep.all;
begin
if GCC_Exception.Class = GNAT_Exception_Class then
-- Ada exception : latch the occurrence data in the Current
-- Exception Buffer if needed and return a pointer to the original
-- Ada exception object. This particular object was specifically
-- allocated for this raise and is thus more precise than the fixed
-- Current Exception Buffer address.
declare
GNAT_Occurrence : constant GNAT_GCC_Exception_Access :=
To_GNAT_GCC_Exception (GCC_Exception);
begin
-- When reaching here during SEARCH_PHASE, no need to
-- replicate the copy performed at the propagation start.
if Phase /= UA_SEARCH_PHASE then
Excep.all := GNAT_Occurrence.Occurrence;
end if;
return GNAT_Occurrence.Occurrence'Access;
end;
else
-- Foreign exception (caught by Ada handler, reaching here from
-- personality routine) : The original exception object doesn't hold
-- an Ada occurrence info. Set the foreign data pointer in the
-- Current Exception Buffer and return the address of the latter.
Set_Foreign_Occurrence (Excep, GCC_Exception.all'Address);
return Excep;
end if;
end Setup_Current_Excep;
----------------------
-- Begin_Handler_v1 --
----------------------
function Begin_Handler_v1
(GCC_Exception : not null GCC_Exception_Access)
return System.Address is
Saved_Cleanup : constant System.Address := GCC_Exception.Cleanup;
begin
-- Claim responsibility for releasing this exception, and stop
-- others from releasing it.
GCC_Exception.Cleanup := Claimed_Cleanup'Address;
return Saved_Cleanup;
end Begin_Handler_v1;
--------------------
-- End_Handler_v1 --
--------------------
procedure End_Handler_v1
(GCC_Exception : not null GCC_Exception_Access;
Saved_Cleanup : System.Address;
Propagating_Exception : GCC_Exception_Access) is
begin
GCC_Exception.Cleanup := Saved_Cleanup;
-- Restore the Saved_Cleanup, so that it is either used to
-- release GCC_Exception below, or transferred to the next
-- handler of the Propagating_Exception occurrence. The
-- following test ensures that an occurrence is only released
-- once, even after reraises.
--
-- The idea is that the GCC_Exception is not to be released
-- unless it had an unclaimed Cleanup when the handler started
-- (see Begin_Handler_v1 above), but if we propagate across its
-- handler a reraise of the same exception, we transfer to the
-- Propagating_Exception the responsibility for running the
-- Saved_Cleanup when its handler completes.
--
-- This ownership transfer mechanism ensures safety, as in
-- single release and no dangling pointers, because there is no
-- way to hold on to the Machine_Occurrence of an
-- Exception_Occurrence: the only situations in which another
-- Exception_Occurrence gets the same Machine_Occurrence are
-- through Reraise_Occurrence, and plain reraise, and so we
-- have the following possibilities:
--
-- - Reraise_Occurrence is handled within the running handler,
-- and so when completing the dynamically nested handler, we
-- must NOT release the exception. A Claimed_Cleanup upon
-- entry of the nested handler, installed when entering the
-- enclosing handler, ensures the exception will not be
-- released by the nested handler, but rather by the enclosing
-- handler.
--
-- - Reraise_Occurrence/reraise escapes the running handler,
-- and we run as an exceptional cleanup for GCC_Exception. The
-- Saved_Cleanup was reinstalled, but since we're propagating
-- the same machine occurrence, we do not release it. Instead,
-- we transfer responsibility for releasing it to the eventual
-- handler of the propagating exception.
--
-- - An unrelated exception propagates through the running
-- handler. We restored GCC_Exception.Saved_Cleanup above.
-- Since we're propagating a different exception, we proceed to
-- release GCC_Exception, unless Saved_Cleanup was
-- Claimed_Cleanup, because then we know we're not in the
-- outermost handler for GCC_Exception.
--
-- - The handler completes normally, so it reinstalls the
-- Saved_Cleanup and runs it, unless it was Claimed_Cleanup.
-- If Saved_Cleanup is null, Unwind_DeleteException (currently)
-- has no effect, so we could skip it, but if it is ever
-- changed to do more in this case, we're ready for that,
-- calling it exactly once.
if Saved_Cleanup /= Claimed_Cleanup'Address
and then
Propagating_Exception /= GCC_Exception
then
declare
Current : constant EOA := Get_Current_Excep.all;
Cur_Occ : constant GCC_Exception_Access
:= To_GCC_Exception (Current.Machine_Occurrence);
begin
-- If we are releasing the Machine_Occurrence of the current
-- exception, reset the access to it, so that it is no
-- longer accessible.
if Cur_Occ = GCC_Exception then
Current.Machine_Occurrence := System.Null_Address;
end if;
end;
Unwind_DeleteException (GCC_Exception);
end if;
end End_Handler_v1;
---------------------
-- Claimed_Cleanup --
---------------------
procedure Claimed_Cleanup
(Reason : Unwind_Reason_Code;
GCC_Exception : not null GCC_Exception_Access) is
pragma Unreferenced (Reason);
pragma Unreferenced (GCC_Exception);
begin
-- This procedure should never run. If it does, it's either a
-- version 0 handler or a foreign handler, attempting to
-- release an exception while a version 1 handler that claimed
-- responsibility for releasing the exception remains still
-- active. This placeholder stops GCC_Exception from being
-- released by them.
-- We could get away with just Null_Address instead, with
-- nearly the same effect, but with this placeholder we can
-- detect and report unexpected releases, and we can tell apart
-- a GCC_Exception without a Cleanup, from one with another
-- active handler, so as to still call Unwind_DeleteException
-- exactly once: currently, Unwind_DeleteException does nothing
-- when the Cleanup is null, but should it ever be changed to
-- do more, we'll still be safe.
null;
end Claimed_Cleanup;
-------------------
-- Begin_Handler --
-------------------
procedure Begin_Handler (GCC_Exception : not null GCC_Exception_Access) is
pragma Unreferenced (GCC_Exception);
begin
null;
end Begin_Handler;
-----------------
-- End_Handler --
-----------------
procedure End_Handler (GCC_Exception : GCC_Exception_Access) is
begin
if GCC_Exception /= null then
-- The exception might have been reraised, in this case the cleanup
-- mustn't be called.
Unwind_DeleteException (GCC_Exception);
end if;
end End_Handler;
-----------------------------
-- Reraise_GCC_Exception --
-----------------------------
procedure Reraise_GCC_Exception
(GCC_Exception : not null GCC_Exception_Access)
is
begin
-- Simply propagate it
Propagate_GCC_Exception (GCC_Exception);
end Reraise_GCC_Exception;
-----------------------------
-- Propagate_GCC_Exception --
-----------------------------
-- Call Unwind_RaiseException to actually throw, taking care of handling
-- the two phase scheme it implements.
procedure Propagate_GCC_Exception
(GCC_Exception : not null GCC_Exception_Access)
is
-- Acknowledge the current exception info now, before unwinding
-- starts so it is available even from C++ handlers involved before
-- our personality routine.
Excep : constant EOA :=
Setup_Current_Excep (GCC_Exception, Phase => 0);
begin
-- Perform a standard raise first. If a regular handler is found, it
-- will be entered after all the intermediate cleanups have run. If
-- there is no regular handler, it will return.
Unwind_RaiseException (GCC_Exception);
-- If we get here we know the exception is not handled, as otherwise
-- Unwind_RaiseException arranges for the handler to be entered. Take
-- the necessary steps to enable the debugger to gain control while the
-- stack is still intact.
Notify_Unhandled_Exception (Excep);
-- Now, un a forced unwind to trigger cleanups. Control should not
-- resume there, if there are cleanups and in any cases as the
-- unwinding hook calls Unhandled_Exception_Terminate when end of
-- stack is reached.
Unwind_ForcedUnwind
(GCC_Exception,
CleanupUnwind_Handler'Address,
System.Null_Address);
-- We get here in case of error. The debugger has been notified before
-- the second step above.
Unhandled_Except_Handler (GCC_Exception);
end Propagate_GCC_Exception;
-------------------------
-- Propagate_Exception --
-------------------------
procedure Propagate_Exception (Excep : Exception_Occurrence) is
begin
Propagate_GCC_Exception (To_GCC_Exception (Excep.Machine_Occurrence));
end Propagate_Exception;
-----------------------------
-- Set_Exception_Parameter --
-----------------------------
procedure Set_Exception_Parameter
(Excep : EOA;
GCC_Exception : not null GCC_Exception_Access)
is
begin
-- Setup the exception occurrence
if GCC_Exception.Class = GNAT_Exception_Class then
-- From the GCC exception
declare
GNAT_Occurrence : constant GNAT_GCC_Exception_Access :=
To_GNAT_GCC_Exception (GCC_Exception);
begin
Save_Occurrence (Excep.all, GNAT_Occurrence.Occurrence);
end;
else
-- A default one
Set_Foreign_Occurrence (Excep, GCC_Exception.all'Address);
end if;
end Set_Exception_Parameter;
------------------------------
-- Unhandled_Except_Handler --
------------------------------
procedure Unhandled_Except_Handler
(GCC_Exception : not null GCC_Exception_Access)
is
Excep : EOA;
begin
Excep := Setup_Current_Excep (GCC_Exception, Phase => UA_CLEANUP_PHASE);
Unhandled_Exception_Terminate (Excep);
end Unhandled_Except_Handler;
-------------
-- EID_For --
-------------
function EID_For
(GNAT_Exception : not null GNAT_GCC_Exception_Access) return Exception_Id
is
begin
return GNAT_Exception.Occurrence.Id;
end EID_For;
----------------------
-- Foreign_Data_For --
----------------------
function Foreign_Data_For
(E : SSL.Exception_Data_Ptr) return Address
is
begin
return E.Foreign_Data;
end Foreign_Data_For;
--------------------------
-- Is_Handled_By_Others --
--------------------------
function Is_Handled_By_Others (E : SSL.Exception_Data_Ptr) return Boolean is
begin
return not E.all.Not_Handled_By_Others;
end Is_Handled_By_Others;
------------------
-- Language_For --
------------------
function Language_For (E : SSL.Exception_Data_Ptr) return Character is
begin
return E.all.Lang;
end Language_For;
end Exception_Propagation;
| 40.911765 | 79 | 0.617644 |
061c407597e7a5d4e3e969f5c0f94d95bfa69e66 | 3,311 | adb | Ada | Validation/pyFrame3DD-master/gcc-master/gcc/ada/libgnat/g-shsh64.adb | djamal2727/Main-Bearing-Analytical-Model | 2f00c2219c71be0175c6f4f8f1d4cca231d97096 | [
"Apache-2.0"
] | null | null | null | Validation/pyFrame3DD-master/gcc-master/gcc/ada/libgnat/g-shsh64.adb | djamal2727/Main-Bearing-Analytical-Model | 2f00c2219c71be0175c6f4f8f1d4cca231d97096 | [
"Apache-2.0"
] | null | null | null | Validation/pyFrame3DD-master/gcc-master/gcc/ada/libgnat/g-shsh64.adb | djamal2727/Main-Bearing-Analytical-Model | 2f00c2219c71be0175c6f4f8f1d4cca231d97096 | [
"Apache-2.0"
] | null | null | null | ------------------------------------------------------------------------------
-- --
-- GNAT LIBRARY COMPONENTS --
-- --
-- G N A T . S E C U R E _ H A S H E S . S H A 2 _ 6 4 --
-- --
-- B o d y --
-- --
-- Copyright (C) 2009-2020, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
-- ware Foundation; either version 3, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
-- or FITNESS FOR A PARTICULAR PURPOSE. --
-- --
-- As a special exception under Section 7 of GPL version 3, you are granted --
-- additional permissions described in the GCC Runtime Library Exception, --
-- version 3.1, as published by the Free Software Foundation. --
-- --
-- You should have received a copy of the GNU General Public License and --
-- a copy of the GCC Runtime Library Exception along with this program; --
-- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
-- <http://www.gnu.org/licenses/>. --
-- --
-- GNAT was originally developed by the GNAT team at New York University. --
-- Extensive contributions were provided by Ada Core Technologies Inc. --
-- --
------------------------------------------------------------------------------
package body GNAT.Secure_Hashes.SHA2_64 is
use Interfaces;
------------
-- Sigma0 --
------------
function Sigma0 (X : Word) return Word is
begin
return Rotate_Right (X, 28)
xor Rotate_Right (X, 34)
xor Rotate_Right (X, 39);
end Sigma0;
------------
-- Sigma1 --
------------
function Sigma1 (X : Word) return Word is
begin
return Rotate_Right (X, 14)
xor Rotate_Right (X, 18)
xor Rotate_Right (X, 41);
end Sigma1;
--------
-- S0 --
--------
function S0 (X : Word) return Word is
begin
return Rotate_Right (X, 1)
xor Rotate_Right (X, 8)
xor Shift_Right (X, 7);
end S0;
--------
-- S1 --
--------
function S1 (X : Word) return Word is
begin
return Rotate_Right (X, 19)
xor Rotate_Right (X, 61)
xor Shift_Right (X, 6);
end S1;
end GNAT.Secure_Hashes.SHA2_64;
| 40.876543 | 78 | 0.40894 |
2f18e9e03cf0dc394c8543858503d4a7f8611cc1 | 2,004 | ads | Ada | ga_lib/src/ga_draw.ads | rogermc2/GA_Ada | 0b55eb5691ac1c543c79c9a06ffdbe2e47e8f1be | [
"ISC"
] | 3 | 2019-04-12T01:09:55.000Z | 2021-02-24T18:17:32.000Z | ga_lib/src/ga_draw.ads | rogermc2/GA_Ada | 0b55eb5691ac1c543c79c9a06ffdbe2e47e8f1be | [
"ISC"
] | 1 | 2020-08-12T10:10:25.000Z | 2020-08-12T10:10:25.000Z | ga_lib/src/ga_draw.ads | rogermc2/GA_Ada | 0b55eb5691ac1c543c79c9a06ffdbe2e47e8f1be | [
"ISC"
] | 1 | 2019-04-12T01:14:15.000Z | 2019-04-12T01:14:15.000Z |
-- Based on libgasandbox.draw.h
with GL.Objects.Programs;
with C3GA;
with Multivector_Analyze;
with Palet;
package GA_Draw is
type Method_Type is (Draw_Method_Undefined, Draw_Bivector_Circle,
Draw_Bivector_Parallelogram,
Draw_Bivector_Parallelogram_No_Vectors,
Draw_Bivector_Cross, Draw_Bivector_Curly_Tail,
Draw_Bivector_Swirl, Draw_Bivector_Circle_Outline,
Draw_TV_Sphere, Draw_TV_Cross, Draw_TV_Curly_Tail,
Draw_TV_Parellelepiped,
Draw_TV_Parellelepiped_No_Vectors);
procedure Draw_Bivector (Render_Program : GL.Objects.Programs.Program;
Base, Normal, Ortho_1, Ortho_2 : C3GA.Vector_E3;
Palet_Type : Palet.Colour_Palet;
Scale : float := 1.0;
Method : Method_Type := Draw_Bivector_Circle);
procedure Draw_Line (Render_Program : GL.Objects.Programs.Program;
Direction : C3GA.Vector_E3; Weight : Float := 1.0);
procedure Draw_Trivector (Render_Program : GL.Objects.Programs.Program;
Base : C3GA.Vector_E3; Scale : float := 1.0;
Palet_Type : Palet.Colour_Palet;
Method : Method_Type := Draw_TV_Sphere);
procedure Draw_Trivector (Render_Program : GL.Objects.Programs.Program;
Base : C3GA.Vector_E3; Scale : float := 1.0;
V : Multivector_Analyze.E3_Vector_Array;
-- Palet_Type : Palet.Colour_Palet;
Method : Method_Type := Draw_TV_Sphere);
procedure Draw_Vector (Render_Program : GL.Objects.Programs.Program;
Tail, Direction : C3GA.Vector_E3;
Scale : float := 1.0);
end GA_Draw;
| 48.878049 | 77 | 0.556387 |
1d8d3518a51ba2edf4a1aaaab9b11ff8e9087606 | 3,659 | ads | Ada | awa/plugins/awa-mail/src/awa-mail-modules.ads | twdroeger/ada-awa | 77b824773747aecb912c37b1b7b59ea414679b80 | [
"Apache-2.0"
] | null | null | null | awa/plugins/awa-mail/src/awa-mail-modules.ads | twdroeger/ada-awa | 77b824773747aecb912c37b1b7b59ea414679b80 | [
"Apache-2.0"
] | null | null | null | awa/plugins/awa-mail/src/awa-mail-modules.ads | twdroeger/ada-awa | 77b824773747aecb912c37b1b7b59ea414679b80 | [
"Apache-2.0"
] | null | null | null | -----------------------------------------------------------------------
-- awa-mail -- Mail module
-- Copyright (C) 2011, 2012, 2017, 2018 Stephane Carrez
-- Written by Stephane Carrez ([email protected])
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you may not use this file except in compliance with the License.
-- You may obtain a copy of the License at
--
-- http://www.apache.org/licenses/LICENSE-2.0
--
-- Unless required by applicable law or agreed to in writing, software
-- distributed under the License is distributed on an "AS IS" BASIS,
-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-- See the License for the specific language governing permissions and
-- limitations under the License.
-----------------------------------------------------------------------
with Util.Beans.Objects.Maps;
with ASF.Applications;
with AWA.Modules;
with AWA.Events;
with AWA.Mail.Clients;
-- == Configuration ==
-- The *mail* module needs some properties to configure the SMTP
-- server.
--
-- |Configuration | Default | Description |
-- | --------------- | --------- | ----------------------------------------------- |
-- |mail.smtp.host | localhost | Defines the SMTP server host name |
-- |mail.smtp.port | 25 | Defines the SMTP connection port |
-- |mail.smtp.enable | 1 | Defines whether sending email is enabled or not |
--
-- == Sending an email ==
-- Sending an email when an event is posted can be done by using
-- an XML configuration. Basically, the *mail* module uses the event
-- framework provided by AWA. The XML definition looks like:
--
-- <on-event name="user-register">
-- <action>#{userMail.send}</action>
-- <property name="template">/mail/register-user-message.xhtml</property>
-- </on-event>
--
-- With this definition, the mail template `/mail/register-user-message.xhtml`
-- is formatted by using the event and application context when the
-- `user-register` event is posted.
--
-- @include awa-mail-components.ads
-- @include awa-mail-components-recipients.ads
-- @include awa-mail-components-messages.ads
--
-- == Ada Beans ==
-- @include mail.xml
--
package AWA.Mail.Modules is
NAME : constant String := "mail";
type Mail_Module is new AWA.Modules.Module with private;
type Mail_Module_Access is access all Mail_Module'Class;
-- Initialize the mail module.
overriding
procedure Initialize (Plugin : in out Mail_Module;
App : in AWA.Modules.Application_Access;
Props : in ASF.Applications.Config);
-- Configures the module after its initialization and after having read its XML configuration.
overriding
procedure Configure (Plugin : in out Mail_Module;
Props : in ASF.Applications.Config);
-- Create a new mail message.
function Create_Message (Plugin : in Mail_Module)
return AWA.Mail.Clients.Mail_Message_Access;
-- Format and send an email.
procedure Send_Mail (Plugin : in Mail_Module;
Template : in String;
Props : in Util.Beans.Objects.Maps.Map;
Content : in AWA.Events.Module_Event'Class);
-- Get the mail module instance associated with the current application.
function Get_Mail_Module return Mail_Module_Access;
private
type Mail_Module is new AWA.Modules.Module with record
Mailer : AWA.Mail.Clients.Mail_Manager_Access;
end record;
end AWA.Mail.Modules;
| 38.114583 | 98 | 0.623121 |
0648936123c68ad9bb56a9f084179f48e4e94c40 | 5,152 | adb | Ada | awa/plugins/awa-mail/src/awa-mail-modules.adb | Letractively/ada-awa | 3c82a4d29ed6c1209a2ac7d5fe123c142f3cffbe | [
"Apache-2.0"
] | null | null | null | awa/plugins/awa-mail/src/awa-mail-modules.adb | Letractively/ada-awa | 3c82a4d29ed6c1209a2ac7d5fe123c142f3cffbe | [
"Apache-2.0"
] | null | null | null | awa/plugins/awa-mail/src/awa-mail-modules.adb | Letractively/ada-awa | 3c82a4d29ed6c1209a2ac7d5fe123c142f3cffbe | [
"Apache-2.0"
] | null | null | null | -----------------------------------------------------------------------
-- awa-mail -- Mail module
-- Copyright (C) 2011, 2012 Stephane Carrez
-- Written by Stephane Carrez ([email protected])
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you may not use this file except in compliance with the License.
-- You may obtain a copy of the License at
--
-- http://www.apache.org/licenses/LICENSE-2.0
--
-- Unless required by applicable law or agreed to in writing, software
-- distributed under the License is distributed on an "AS IS" BASIS,
-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-- See the License for the specific language governing permissions and
-- limitations under the License.
-----------------------------------------------------------------------
with AWA.Modules.Beans;
with AWA.Modules.Get;
with AWA.Mail.Beans;
with AWA.Mail.Components.Factory;
with AWA.Applications;
with ASF.Requests.Mockup;
with ASF.Responses.Mockup;
with Util.Beans.Basic;
with Util.Beans.Objects;
with Util.Log.Loggers;
package body AWA.Mail.Modules is
use Util.Log;
Log : constant Loggers.Logger := Loggers.Create ("AWA.Mail.Module");
package Register is new AWA.Modules.Beans (Module => Mail_Module,
Module_Access => Mail_Module_Access);
-- ------------------------------
-- Initialize the mail module.
-- ------------------------------
overriding
procedure Initialize (Plugin : in out Mail_Module;
App : in AWA.Modules.Application_Access;
Props : in ASF.Applications.Config) is
begin
Log.Info ("Initializing the mail module");
-- Add the Mail UI components.
App.Add_Components (AWA.Mail.Components.Factory.Definition);
-- Register here any bean class, servlet, filter.
Register.Register (Plugin => Plugin,
Name => "AWA.Mail.Beans.Mail_Bean",
Handler => AWA.Mail.Beans.Create_Mail_Bean'Access);
AWA.Modules.Module (Plugin).Initialize (App, Props);
end Initialize;
-- ------------------------------
-- Configures the module after its initialization and after having read its XML configuration.
-- ------------------------------
overriding
procedure Configure (Plugin : in out Mail_Module;
Props : in ASF.Applications.Config) is
Mailer : constant String := Props.Get ("mailer", "smtp");
begin
Plugin.Mailer := AWA.Mail.Clients.Factory (Mailer, Props);
end Configure;
-- ------------------------------
-- Create a new mail message.
-- ------------------------------
function Create_Message (Plugin : in Mail_Module)
return AWA.Mail.Clients.Mail_Message_Access is
begin
return Plugin.Mailer.Create_Message;
end Create_Message;
-- ------------------------------
-- Get the mail template that must be used for the given event name.
-- The mail template is configured by the property: <i>module</i>.template.<i>event</i>.
-- ------------------------------
function Get_Template (Plugin : in Mail_Module;
Name : in String) return String is
Prop_Name : constant String := Plugin.Get_Name & ".template." & Name;
begin
return Plugin.Get_Config (Prop_Name);
end Get_Template;
-- Receive an event sent by another module with <b>Send_Event</b> method.
-- Format and send an email.
procedure Send_Mail (Plugin : in Mail_Module;
Template : in String;
Props : in Util.Beans.Objects.Maps.Map;
Content : in AWA.Events.Module_Event'Class) is
Name : constant String := Content.Get_Parameter ("name");
begin
Log.Info ("Receive event {0}", Name);
if Template = "" then
Log.Debug ("No email template associated with event {0}", Name);
return;
end if;
declare
Req : ASF.Requests.Mockup.Request;
Reply : ASF.Responses.Mockup.Response;
Ptr : constant Util.Beans.Basic.Readonly_Bean_Access := Content'Unrestricted_Access;
Bean : constant Util.Beans.Objects.Object
:= Util.Beans.Objects.To_Object (Ptr, Util.Beans.Objects.STATIC);
begin
Req.Set_Path_Info (Template);
Req.Set_Method ("GET");
Req.Set_Attribute (Name => "event", Value => Bean);
Req.Set_Attributes (Props);
Plugin.Get_Application.Dispatch (Page => Template,
Request => Req,
Response => Reply);
end;
end Send_Mail;
-- ------------------------------
-- Get the mail module instance associated with the current application.
-- ------------------------------
function Get_Mail_Module return Mail_Module_Access is
function Get is new AWA.Modules.Get (Mail_Module, Mail_Module_Access, NAME);
begin
return Get;
end Get_Mail_Module;
end AWA.Mail.Modules;
| 38.162963 | 98 | 0.574534 |
2f0c10e6bd8cae3c60543f59f4d6ba7b03282ed2 | 2,106 | adb | Ada | source/strings/a-sgecin.adb | ytomino/drake | 4e4bdcd8b8e23a11a29b31d3a8861fdf60090ea2 | [
"MIT"
] | 33 | 2015-04-04T09:19:36.000Z | 2021-11-10T05:33:34.000Z | source/strings/a-sgecin.adb | ytomino/drake | 4e4bdcd8b8e23a11a29b31d3a8861fdf60090ea2 | [
"MIT"
] | 8 | 2017-11-14T13:05:07.000Z | 2018-08-09T15:28:49.000Z | source/strings/a-sgecin.adb | ytomino/drake | 4e4bdcd8b8e23a11a29b31d3a8861fdf60090ea2 | [
"MIT"
] | 9 | 2015-02-03T17:09:53.000Z | 2021-11-12T01:16:05.000Z | with Ada.Strings.Naked_Maps.Case_Folding;
function Ada.Strings.Generic_Equal_Case_Insensitive (Left, Right : String_Type)
return Boolean
is
Mapping : constant not null Naked_Maps.Character_Mapping_Access :=
Naked_Maps.Case_Folding.Case_Folding_Map;
Left_Last : Natural := Left'First - 1;
Right_Last : Natural := Right'First - 1;
begin
while Left_Last < Left'Last and then Right_Last < Right'Last loop
declare
Left_Index : constant Positive := Left_Last + 1;
Left_Code : Wide_Wide_Character;
Left_Is_Illegal_Sequence : Boolean;
Right_Index : constant Positive := Right_Last + 1;
Right_Code : Wide_Wide_Character;
Right_Is_Illegal_Sequence : Boolean;
begin
Get (
Left (Left_Index .. Left'Last),
Left_Last,
Left_Code,
Left_Is_Illegal_Sequence);
Get (
Right (Right_Index .. Right'Last),
Right_Last,
Right_Code,
Right_Is_Illegal_Sequence);
if not Left_Is_Illegal_Sequence then
if not Right_Is_Illegal_Sequence then
-- Left and Right are legal
Left_Code := Naked_Maps.Value (Mapping.all, Left_Code);
Right_Code := Naked_Maps.Value (Mapping.all, Right_Code);
if Left_Code /= Right_Code then
return False;
end if;
else
-- Left is legal, Right is illegal
return False;
end if;
else
if not Right_Is_Illegal_Sequence then
-- Left is illegal, Right is legal
return False;
else
-- Left and Right are illegal
if Left (Left_Index .. Left_Last) /=
Right (Right_Index .. Right_Last)
then
return False;
end if;
end if;
end if;
end;
end loop;
return (Left_Last >= Left'Last) and then (Right_Last >= Right'Last);
end Ada.Strings.Generic_Equal_Case_Insensitive;
| 36.310345 | 79 | 0.576448 |
1ddc87401f0e845d33b943c62a65bcc4a5c8caec | 174 | adb | Ada | Ada/src/Problem_66.adb | Tim-Tom/project-euler | 177e0043ee93409742ec596c4379251f681b4275 | [
"Unlicense"
] | null | null | null | Ada/src/Problem_66.adb | Tim-Tom/project-euler | 177e0043ee93409742ec596c4379251f681b4275 | [
"Unlicense"
] | null | null | null | Ada/src/Problem_66.adb | Tim-Tom/project-euler | 177e0043ee93409742ec596c4379251f681b4275 | [
"Unlicense"
] | null | null | null | with Ada.Text_IO;
package body Problem_66 is
package IO renames Ada.Text_IO;
procedure Solve is
begin
IO.Put_Line("The Answer");
end Solve;
end Problem_66;
| 19.333333 | 34 | 0.712644 |
590a4624800b36868fdadec90118ea4fc30727fd | 3,147 | ads | Ada | tools-src/gnu/gcc/gcc/ada/s-widwch.ads | modern-tomato/tomato | 96f09fab4929c6ddde5c9113f1b2476ad37133c4 | [
"FSFAP"
] | 80 | 2015-01-02T10:14:04.000Z | 2021-06-07T06:29:49.000Z | tools-src/gnu/gcc/gcc/ada/s-widwch.ads | modern-tomato/tomato | 96f09fab4929c6ddde5c9113f1b2476ad37133c4 | [
"FSFAP"
] | 9 | 2015-05-14T11:03:12.000Z | 2018-01-04T07:12:58.000Z | tools-src/gnu/gcc/gcc/ada/s-widwch.ads | modern-tomato/tomato | 96f09fab4929c6ddde5c9113f1b2476ad37133c4 | [
"FSFAP"
] | 69 | 2015-01-02T10:45:56.000Z | 2021-09-06T07:52:13.000Z | ------------------------------------------------------------------------------
-- --
-- GNAT RUNTIME COMPONENTS --
-- --
-- S Y S T E M . W I D _ W C H A R --
-- --
-- S p e c --
-- --
-- $Revision$
-- --
-- Copyright (C) 1992,1993,1994 Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
-- ware Foundation; either version 2, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT 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 distributed with GNAT; see file COPYING. If not, write --
-- to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, --
-- MA 02111-1307, USA. --
-- --
-- As a special exception, if other files instantiate generics from this --
-- unit, or you link this unit with other files to produce an executable, --
-- this unit does not by itself cause the resulting executable to be --
-- covered by the GNU General Public License. This exception does not --
-- however invalidate any other reasons why the executable file might be --
-- covered by the GNU Public License. --
-- --
-- GNAT was originally developed by the GNAT team at New York University. --
-- Extensive contributions were provided by Ada Core Technologies Inc. --
-- --
------------------------------------------------------------------------------
-- This package contains the routine used for Wide_Character'Width
with System.WCh_Con;
package System.Wid_WChar is
pragma Pure (Wid_WChar);
function Width_Wide_Character
(Lo, Hi : Wide_Character;
EM : System.WCh_Con.WC_Encoding_Method)
return Natural;
-- Compute Width attribute for non-static type derived from Wide_Character.
-- The arguments are the low and high bounds for the type. EM is the
-- wide-character encoding method.
end System.Wid_WChar;
| 60.519231 | 79 | 0.446457 |
1d4d949287b6cf28b1707d91588eb30e278644a3 | 2,169 | ads | Ada | resources/scripts/api/virustotal.ads | guouopp/Amass | fa6089a26faca1347e25f4c1c7229a267068904c | [
"Apache-2.0"
] | null | null | null | resources/scripts/api/virustotal.ads | guouopp/Amass | fa6089a26faca1347e25f4c1c7229a267068904c | [
"Apache-2.0"
] | null | null | null | resources/scripts/api/virustotal.ads | guouopp/Amass | fa6089a26faca1347e25f4c1c7229a267068904c | [
"Apache-2.0"
] | null | null | null | -- Copyright 2017 Jeff Foley. All rights reserved.
-- Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file.
local json = require("json")
name = "VirusTotal"
type = "api"
function start()
setratelimit(15)
end
function vertical(ctx, domain)
local c
local cfg = datasrc_config()
if cfg ~= nil then
c = cfg.credentials
end
local haskey = true
if (c == nil or c.key == nil or c.key == "") then
haskey = false
end
local resp
local respstr = domain
local vurl = buildurl(domain)
if haskey then
vurl = apiurl(domain, c.api)
respstr = domain .. api
end
-- Check if the response data is in the graph database
if (cfg and cfg.ttl ~= nil and cfg.ttl > 0) then
resp = obtain_response(respstr, cfg.ttl)
end
if (resp == nil or resp == "") then
local err
resp, err = request({
url=vurl,
headers={['Content-Type']="application/json"},
})
if (err ~= nil and err ~= "") then
return
end
if (cfg and cfg.ttl ~= nil and cfg.ttl > 0) then
cache_response(respstr, resp)
end
end
local d = json.decode(resp)
if haskey then
if d['response_code'] ~= 1 then
log(ctx, name .. ": " .. vurl .. ": Response code " .. d['response_code'] .. ": " .. d['verbose_msg'])
return
end
for i, sub in pairs(d.subdomains) do
sendnames(ctx, sub)
end
else
for i, data in pairs(d.data) do
if data.type == "domain" then
sendnames(ctx, data.id)
end
end
end
end
function buildurl(domain)
return "https://www.virustotal.com/ui/domains/" .. domain .. "/subdomains?limit=40"
end
function apiurl(domain, key)
return "https://www.virustotal.com/vtapi/v2/domain/report?apikey=" .. key .. "&domain=" .. domain
end
function sendnames(ctx, content)
local names = find(content, subdomainre)
if names == nil then
return
end
for i, v in pairs(names) do
newname(ctx, v)
end
end
| 24.370787 | 114 | 0.567543 |
31f30129fcc550607d19dea36c12d204ed7800e7 | 5,396 | ads | Ada | support/MinGW/lib/gcc/mingw32/9.2.0/adainclude/s-taenca.ads | orb-zhuchen/Orb | 6da2404b949ac28bde786e08bf4debe4a27cd3a0 | [
"CNRI-Python-GPL-Compatible",
"MIT"
] | null | null | null | support/MinGW/lib/gcc/mingw32/9.2.0/adainclude/s-taenca.ads | orb-zhuchen/Orb | 6da2404b949ac28bde786e08bf4debe4a27cd3a0 | [
"CNRI-Python-GPL-Compatible",
"MIT"
] | null | null | null | support/MinGW/lib/gcc/mingw32/9.2.0/adainclude/s-taenca.ads | orb-zhuchen/Orb | 6da2404b949ac28bde786e08bf4debe4a27cd3a0 | [
"CNRI-Python-GPL-Compatible",
"MIT"
] | null | null | null | ------------------------------------------------------------------------------
-- --
-- GNAT RUN-TIME LIBRARY (GNARL) COMPONENTS --
-- --
-- S Y S T E M . T A S K I N G . E N T R Y _ C A L L S --
-- --
-- S p e c --
-- --
-- Copyright (C) 1992-2019, Free Software Foundation, Inc. --
-- --
-- GNARL is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
-- ware Foundation; either version 3, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
-- or FITNESS FOR A PARTICULAR PURPOSE. --
-- --
-- As a special exception under Section 7 of GPL version 3, you are granted --
-- additional permissions described in the GCC Runtime Library Exception, --
-- version 3.1, as published by the Free Software Foundation. --
-- --
-- You should have received a copy of the GNU General Public License and --
-- a copy of the GCC Runtime Library Exception along with this program; --
-- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
-- <http://www.gnu.org/licenses/>. --
-- --
-- GNARL was developed by the GNARL team at Florida State University. --
-- Extensive contributions were provided by Ada Core Technologies, Inc. --
-- --
------------------------------------------------------------------------------
-- This package provides internal RTS calls implementing operations
-- that apply to general entry calls, that is, calls to either
-- protected or task entries.
-- These declarations are not part of the GNARL Interface
package System.Tasking.Entry_Calls is
procedure Wait_For_Completion (Entry_Call : Entry_Call_Link);
-- This procedure suspends the calling task until the specified entry
-- call has either been completed or cancelled. It performs other
-- operations required of suspended tasks, such as performing
-- dynamic priority changes. On exit, the call will not be queued.
-- This waits for calls on task or protected entries.
-- Abortion must be deferred when calling this procedure.
-- Call this only when holding Self (= Entry_Call.Self) or global RTS lock.
procedure Wait_For_Completion_With_Timeout
(Entry_Call : Entry_Call_Link;
Wakeup_Time : Duration;
Mode : Delay_Modes;
Yielded : out Boolean);
-- Same as Wait_For_Completion but wait for a timeout with the value
-- specified in Wakeup_Time as well.
-- On return, Yielded indicates whether the wait has performed a yield.
-- Check_Exception must be called after calling this procedure.
procedure Wait_Until_Abortable
(Self_ID : Task_Id;
Call : Entry_Call_Link);
-- This procedure suspends the calling task until the specified entry
-- call is queued abortably or completes.
-- Abortion must be deferred when calling this procedure, and the global
-- RTS lock taken when Single_Lock.
procedure Try_To_Cancel_Entry_Call (Succeeded : out Boolean);
pragma Inline (Try_To_Cancel_Entry_Call);
-- Try to cancel async. entry call.
-- Effect includes Abort_To_Level and Wait_For_Completion.
-- Cancelled = True iff the cancellation was successful, i.e.,
-- the call was not Done before this call.
-- On return, the call is off-queue and the ATC level is reduced by one.
procedure Reset_Priority
(Acceptor : Task_Id;
Acceptor_Prev_Priority : Rendezvous_Priority);
pragma Inline (Reset_Priority);
-- Reset the priority of a task completing an accept statement to
-- the value it had before the call.
-- Acceptor should always be equal to Self.
procedure Check_Exception
(Self_ID : Task_Id;
Entry_Call : Entry_Call_Link);
pragma Inline (Check_Exception);
-- Raise any pending exception from the Entry_Call.
-- This should be called at the end of every compiler interface procedure
-- that implements an entry call.
-- In principle, the caller should not be abort-deferred (unless the
-- application program violates the Ada language rules by doing entry calls
-- from within protected operations -- an erroneous practice apparently
-- followed with success by some adventurous GNAT users).
-- Absolutely, the caller should not be holding any locks, or there
-- will be deadlock.
end System.Tasking.Entry_Calls;
| 55.061224 | 79 | 0.569681 |
31c6b3c7a133d865a4dfee1291b91706967eed79 | 290 | ada | Ada | Task/LU-decomposition/Ada/lu-decomposition-1.ada | mullikine/RosettaCodeData | 4f0027c6ce83daa36118ee8b67915a13cd23ab67 | [
"Info-ZIP"
] | 1 | 2018-11-09T22:08:38.000Z | 2018-11-09T22:08:38.000Z | Task/LU-decomposition/Ada/lu-decomposition-1.ada | mullikine/RosettaCodeData | 4f0027c6ce83daa36118ee8b67915a13cd23ab67 | [
"Info-ZIP"
] | null | null | null | Task/LU-decomposition/Ada/lu-decomposition-1.ada | mullikine/RosettaCodeData | 4f0027c6ce83daa36118ee8b67915a13cd23ab67 | [
"Info-ZIP"
] | 1 | 2018-11-09T22:08:40.000Z | 2018-11-09T22:08:40.000Z | with Ada.Numerics.Generic_Real_Arrays;
generic
with package Matrix is new Ada.Numerics.Generic_Real_Arrays (<>);
package Decomposition is
-- decompose a square matrix A by PA = LU
procedure Decompose (A : Matrix.Real_Matrix; P, L, U : out Matrix.Real_Matrix);
end Decomposition;
| 29 | 82 | 0.755172 |
2fd32e115a29a3ae34ab393d9374591fc5252f95 | 3,427 | ads | Ada | source/oasis/program-elements-entry_declarations.ads | optikos/oasis | 9f64d46d26d964790d69f9db681c874cfb3bf96d | [
"MIT"
] | null | null | null | source/oasis/program-elements-entry_declarations.ads | optikos/oasis | 9f64d46d26d964790d69f9db681c874cfb3bf96d | [
"MIT"
] | null | null | null | source/oasis/program-elements-entry_declarations.ads | optikos/oasis | 9f64d46d26d964790d69f9db681c874cfb3bf96d | [
"MIT"
] | 2 | 2019-09-14T23:18:50.000Z | 2019-10-02T10:11:40.000Z | -- Copyright (c) 2019 Maxim Reznik <[email protected]>
--
-- SPDX-License-Identifier: MIT
-- License-Filename: LICENSE
-------------------------------------------------------------
with Program.Elements.Declarations;
with Program.Lexical_Elements;
with Program.Elements.Defining_Identifiers;
with Program.Elements.Discrete_Ranges;
with Program.Elements.Parameter_Specifications;
with Program.Elements.Aspect_Specifications;
package Program.Elements.Entry_Declarations is
pragma Pure (Program.Elements.Entry_Declarations);
type Entry_Declaration is
limited interface and Program.Elements.Declarations.Declaration;
type Entry_Declaration_Access is access all Entry_Declaration'Class
with Storage_Size => 0;
not overriding function Name
(Self : Entry_Declaration)
return not null Program.Elements.Defining_Identifiers
.Defining_Identifier_Access is abstract;
not overriding function Entry_Family_Definition
(Self : Entry_Declaration)
return Program.Elements.Discrete_Ranges.Discrete_Range_Access
is abstract;
not overriding function Parameters
(Self : Entry_Declaration)
return Program.Elements.Parameter_Specifications
.Parameter_Specification_Vector_Access is abstract;
not overriding function Aspects
(Self : Entry_Declaration)
return Program.Elements.Aspect_Specifications
.Aspect_Specification_Vector_Access is abstract;
not overriding function Has_Not (Self : Entry_Declaration) return Boolean
is abstract;
not overriding function Has_Overriding
(Self : Entry_Declaration)
return Boolean is abstract;
type Entry_Declaration_Text is limited interface;
type Entry_Declaration_Text_Access is
access all Entry_Declaration_Text'Class with Storage_Size => 0;
not overriding function To_Entry_Declaration_Text
(Self : aliased in out Entry_Declaration)
return Entry_Declaration_Text_Access is abstract;
not overriding function Not_Token
(Self : Entry_Declaration_Text)
return Program.Lexical_Elements.Lexical_Element_Access is abstract;
not overriding function Overriding_Token
(Self : Entry_Declaration_Text)
return Program.Lexical_Elements.Lexical_Element_Access is abstract;
not overriding function Entry_Token
(Self : Entry_Declaration_Text)
return not null Program.Lexical_Elements.Lexical_Element_Access
is abstract;
not overriding function Left_Bracket_Token
(Self : Entry_Declaration_Text)
return Program.Lexical_Elements.Lexical_Element_Access is abstract;
not overriding function Right_Bracket_Token
(Self : Entry_Declaration_Text)
return Program.Lexical_Elements.Lexical_Element_Access is abstract;
not overriding function Left_Bracket_Token_2
(Self : Entry_Declaration_Text)
return Program.Lexical_Elements.Lexical_Element_Access is abstract;
not overriding function Right_Bracket_Token_2
(Self : Entry_Declaration_Text)
return Program.Lexical_Elements.Lexical_Element_Access is abstract;
not overriding function With_Token
(Self : Entry_Declaration_Text)
return Program.Lexical_Elements.Lexical_Element_Access is abstract;
not overriding function Semicolon_Token
(Self : Entry_Declaration_Text)
return not null Program.Lexical_Elements.Lexical_Element_Access
is abstract;
end Program.Elements.Entry_Declarations;
| 34.616162 | 76 | 0.774146 |
a1c7a359a16ac52204aeaa089338c62b4818a367 | 3,681 | ads | Ada | llvm-gcc-4.2-2.9/gcc/ada/s-pack26.ads | vidkidz/crossbridge | ba0bf94aee0ce6cf7eb5be882382e52bc57ba396 | [
"MIT"
] | 1 | 2016-04-09T02:58:13.000Z | 2016-04-09T02:58:13.000Z | llvm-gcc-4.2-2.9/gcc/ada/s-pack26.ads | vidkidz/crossbridge | ba0bf94aee0ce6cf7eb5be882382e52bc57ba396 | [
"MIT"
] | null | null | null | llvm-gcc-4.2-2.9/gcc/ada/s-pack26.ads | vidkidz/crossbridge | ba0bf94aee0ce6cf7eb5be882382e52bc57ba396 | [
"MIT"
] | null | null | null | ------------------------------------------------------------------------------
-- --
-- GNAT RUN-TIME COMPONENTS --
-- --
-- S Y S T E M . P A C K _ 2 6 --
-- --
-- S p e c --
-- --
-- Copyright (C) 1992-2005, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
-- ware Foundation; either version 2, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT 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 distributed with GNAT; see file COPYING. If not, write --
-- to the Free Software Foundation, 51 Franklin Street, Fifth Floor, --
-- Boston, MA 02110-1301, USA. --
-- --
-- As a special exception, if other files instantiate generics from this --
-- unit, or you link this unit with other files to produce an executable, --
-- this unit does not by itself cause the resulting executable to be --
-- covered by the GNU General Public License. This exception does not --
-- however invalidate any other reasons why the executable file might be --
-- covered by the GNU Public License. --
-- --
-- GNAT was originally developed by the GNAT team at New York University. --
-- Extensive contributions were provided by Ada Core Technologies Inc. --
-- --
------------------------------------------------------------------------------
-- Handling of packed arrays with Component_Size = 26
package System.Pack_26 is
pragma Preelaborate;
Bits : constant := 26;
type Bits_26 is mod 2 ** Bits;
for Bits_26'Size use Bits;
function Get_26 (Arr : System.Address; N : Natural) return Bits_26;
-- Arr is the address of the packed array, N is the zero-based
-- subscript. This element is extracted and returned.
procedure Set_26 (Arr : System.Address; N : Natural; E : Bits_26);
-- Arr is the address of the packed array, N is the zero-based
-- subscript. This element is set to the given value.
function GetU_26 (Arr : System.Address; N : Natural) return Bits_26;
-- Arr is the address of the packed array, N is the zero-based
-- subscript. This element is extracted and returned. This version
-- is used when Arr may represent an unaligned address.
procedure SetU_26 (Arr : System.Address; N : Natural; E : Bits_26);
-- Arr is the address of the packed array, N is the zero-based
-- subscript. This element is set to the given value. This version
-- is used when Arr may represent an unaligned address
end System.Pack_26;
| 58.428571 | 78 | 0.499593 |
5908fd1f2e6e2e968bc5f6902432f328b888bc72 | 28,502 | adb | Ada | example_relationships/src/one_to_many_associative.adb | cortlandstarrett/mcada | d1a7a818f91459d53bd5b9354bc7d78e2c5d4518 | [
"Apache-2.0"
] | null | null | null | example_relationships/src/one_to_many_associative.adb | cortlandstarrett/mcada | d1a7a818f91459d53bd5b9354bc7d78e2c5d4518 | [
"Apache-2.0"
] | null | null | null | example_relationships/src/one_to_many_associative.adb | cortlandstarrett/mcada | d1a7a818f91459d53bd5b9354bc7d78e2c5d4518 | [
"Apache-2.0"
] | 1 | 2021-06-08T19:44:04.000Z | 2021-06-08T19:44:04.000Z | -- *************************************************************************************
--
-- The recipient is warned that this code should be handled in accordance
-- with the HM Government Security Classification indicated throughout.
--
-- This code and its contents shall not be used for other than UK Government
-- purposes.
--
-- The copyright in this code is the property of BAE SYSTEMS Electronic Systems Limited.
-- The Code is supplied by BAE SYSTEMS on the express terms that it is to be treated in
-- confidence and that it may not be copied, used or disclosed to others for any
-- purpose except in accordance with DEFCON 91 (Edn 10/92).
--
-- File Name: One_To_Many_Associative.adb
-- Version: As detailed by ClearCase
-- Version Date: As detailed by ClearCase
-- Creation Date: 11-11-99
-- Security Classification: Unclassified
-- Project: SRLE (Sting Ray Life Extension)
-- Author: J Mann
-- Section: Tactical Software/ Software Architecture
-- Division: Underwater Systems Division
-- Description: Generic implementation of 1-1:M relationship
-- Comments:
--
-- MODIFICATION RECORD
-- --------------------
-- NAME DATE ECR No MODIFICATION
--
-- jmm 11/11/99 008310/9SR056 Order of instance specification in Unlink is wrong. Reverse it.
--
-- jmm 25/04/00 PILOT_0000_0325 Increase length of role to 32 characters for compatibility with
-- type base_text_type.
--
-- jmm 28/06/00 PILOT_0000_0423 Include diagnostic references.
--
-- jmm 26/01/01 PILOT_0000_0701 Comment out a line which was erroneously left uncommented.
--
-- db 09/08/01 PILOT_0000_1422 Illegal navigation should return null instance.
--
-- DB 24/09/01 PILOT_0000_2473 Rename Link, Unlink & Unassociate parameters
-- to match those for 1:1 type relationships,
-- at the request of George.
--
-- db 17/04/02 SRLE100003005 Correlated associative navigations supported.
--
-- db 22/04/02 SRLE100002907 Procedure initialise removed as surplus to requirements
--
-- db 09/05/02 SRLE100002899 Role phrase string is limited to 32 characters
-- by calling routine, no checks necessary here.
--
-- db 10/10/02 SRLE100003929 Remove exit condition from within Check_List_For_Multiple
-- and Check_List_For_Associative and rearrange loop
-- conditions accordingly.
--
-- db 11/10/02 SRLE100003928 Remove null checks on source navigates and
-- calls to log.
--
-- DNS 20/05/15 CR 10265 For Navigate procedures returning a list,
-- the Return is now an "in" parameter
--
-- **************************************************************************************
with Application_Types;
with Root_Object;
use type Root_Object.Object_Access;
use type Root_Object.Object_List.Node_Access_Type;
with Ada.Tags;
use type Ada.Tags.Tag;
with Ada.Unchecked_Deallocation;
package body One_To_Many_Associative is
------------------------------------------------------------------------
--
-- 'Minor' element
--
type Relationship_Pair_Type;
type Relationship_Pair_Access_Type is access all Relationship_Pair_Type;
type Relationship_Pair_Type is record
Multiple : Root_Object.Object_Access;
Associative : Root_Object.Object_Access;
Next : Relationship_Pair_Access_Type;
Previous : Relationship_Pair_Access_Type;
end record;
procedure Remove_Pair is new Ada.Unchecked_Deallocation (
Relationship_Pair_Type, Relationship_Pair_Access_Type);
--
-- 'Major' element
--
type Relationship_Entry_Type;
type Relationship_Entry_Access_Type is access all Relationship_Entry_Type;
type Relationship_Entry_Type is record
Single : Root_Object.Object_Access;
Completion_List : Relationship_Pair_Access_Type;
Next : Relationship_Entry_Access_Type;
Previous : Relationship_Entry_Access_Type;
end record;
procedure Remove_Entry is new Ada.Unchecked_Deallocation (
Relationship_Entry_Type, Relationship_Entry_Access_Type);
------------------------------------------------------------------------
The_Relationship_List: Relationship_Entry_Access_Type;
subtype Role_Phrase_Type is string (1 .. Application_Types.Maximum_Number_Of_Characters_In_String);
Multiple_Side : Ada.Tags.Tag;
Multiple_Side_Role : Role_Phrase_Type;
Multiple_Side_Role_Length : Natural;
Single_Side : Ada.Tags.Tag;
Single_Side_Role : Role_Phrase_Type;
Single_Side_Role_Length : Natural;
Associative_Side : Ada.Tags.Tag;
Associative_Side_Role : Role_Phrase_Type;
Associative_Side_Role_Length : Natural;
--
-- A = LEFT = MULTIPLE
-- B = RIGHT = SINGLE
--
------------------------------------------------------------------------
procedure Check_List_For_Multiple (
Multiple_Instance : in Root_Object.Object_Access;
Associative_Instance : out Root_Object.Object_Access;
Single_Instance : out Root_Object.Object_Access;
Multiple_Instance_Found : out Boolean) is
Temp_Minor_Pointer : Relationship_Pair_Access_Type;
Temp_Major_Pointer : Relationship_Entry_Access_Type;
begin
Multiple_Instance_Found := False;
Temp_Major_Pointer := The_Relationship_List;
Major_Loop:
while (not Multiple_Instance_Found) and then Temp_Major_Pointer /= null loop
Temp_Minor_Pointer := Temp_Major_Pointer.Completion_List;
Minor_Loop:
while (not Multiple_Instance_Found) and then Temp_Minor_Pointer /= null loop
Multiple_Instance_Found := (Temp_Minor_Pointer.Multiple = Multiple_Instance);
if Multiple_Instance_Found then
Associative_Instance := Temp_Minor_Pointer.Associative;
Single_Instance := Temp_Major_Pointer.Single;
else
-- Prevent access if we have got what we are after
-- Bailing out of the search loop is a neater solution, but test team defects
-- have been raised against this sort of thing.
Temp_Minor_Pointer := Temp_Minor_Pointer.Next;
end if;
end loop Minor_Loop;
-- Prevent the possibility that the next entry in the major queue is null causing an access error
if not Multiple_Instance_Found then
Temp_Major_Pointer := Temp_Major_Pointer.Next;
end if;
end loop Major_Loop;
end Check_List_For_Multiple;
------------------------------------------------------------------------
procedure Check_List_For_Associative (
Associative_Instance : in Root_Object.Object_Access;
Multiple_Instance : out Root_Object.Object_Access;
Single_Instance : out Root_Object.Object_Access;
Associative_Instance_Found : out Boolean) is
Temp_Minor_Pointer : Relationship_Pair_Access_Type;
Temp_Major_Pointer : Relationship_Entry_Access_Type;
begin
Associative_Instance_Found := False;
Temp_Major_Pointer := The_Relationship_List;
Major_Loop:
while (not Associative_Instance_Found) and then Temp_Major_Pointer /= null loop
Temp_Minor_Pointer := Temp_Major_Pointer.Completion_List;
Minor_Loop:
while (not Associative_Instance_Found) and then Temp_Minor_Pointer /= null loop
Associative_Instance_Found := (Temp_Minor_Pointer.Associative = Associative_Instance);
if Associative_Instance_Found then
Multiple_Instance := Temp_Minor_Pointer.Multiple;
Single_Instance := Temp_Major_Pointer.Single;
else
-- Prevent access if we have got what we are after
-- Bailing out of the search loop is a neater solution, but test team defects
-- have been raised against this sort of thing.
Temp_Minor_Pointer := Temp_Minor_Pointer.Next;
end if;
end loop Minor_Loop;
-- Prevent the possibility that the next entry in the major queue is null causing an access error
if not Associative_Instance_Found then
Temp_Major_Pointer := Temp_Major_Pointer.Next;
end if;
end loop Major_Loop;
end Check_List_For_Associative;
-----------------------------------------------------------------------
procedure Do_Link (
Multiple_Instance : in Root_Object.Object_Access;
Single_Instance : in Root_Object.Object_Access;
Associative_Instance : in Root_Object.Object_Access) is
Temp_Minor_Pointer : Relationship_Pair_Access_Type;
Temp_Major_Pointer : Relationship_Entry_Access_Type;
Found : Boolean := False;
begin
Temp_Major_Pointer := The_Relationship_List;
while (not Found) and then Temp_Major_Pointer /= null loop
Found := (Temp_Major_Pointer.Single = Single_Instance);
if not Found then -- grab the next item
Temp_Major_Pointer := Temp_Major_Pointer.Next;
end if;
end loop;
if not Found then
Temp_Major_Pointer := new Relationship_Entry_Type;
Temp_Major_Pointer.Single := Single_Instance;
Temp_Major_Pointer.Completion_List := null;
Temp_Major_Pointer.Previous := null;
Temp_Major_Pointer.Next := The_Relationship_List;
if The_Relationship_List /= null then
The_Relationship_List.Previous := Temp_Major_Pointer;
end if;
The_Relationship_List := Temp_Major_Pointer;
end if;
Temp_Minor_Pointer := new Relationship_Pair_Type;
Temp_Minor_Pointer.Multiple := Multiple_Instance;
Temp_Minor_Pointer.Associative := Associative_Instance;
Temp_Minor_Pointer.Previous := null;
Temp_Minor_Pointer.Next := Temp_Major_Pointer.Completion_List;
if Temp_Major_Pointer.Completion_List /= null then
Temp_Major_Pointer.Completion_List.Previous := Temp_Minor_Pointer;
end if;
Temp_Major_Pointer.Completion_List := Temp_Minor_Pointer;
end Do_Link;
-----------------------------------------------------------------------
procedure Do_Unlink (
Left_Instance : in Root_Object.Object_Access;
Right_Instance : in Root_Object.Object_Access) is
Temp_Minor_Pointer : Relationship_Pair_Access_Type;
Temp_Major_Pointer : Relationship_Entry_Access_Type;
Delete_List : Boolean := False;
begin
Temp_Major_Pointer := The_Relationship_List;
Major_Loop:
while Temp_Major_Pointer /= null loop
if Temp_Major_Pointer.Single = Left_Instance then
Temp_Minor_Pointer := Temp_Major_Pointer.Completion_List;
Minor_Loop:
while Temp_Minor_Pointer /= null loop
if Temp_Minor_Pointer.Multiple = Right_Instance then
if Temp_Minor_Pointer.Previous = null then
--
-- first instance in list
--
Temp_Major_Pointer.Completion_List := Temp_Minor_Pointer.Next;
--
-- it's also the last and only instance in list
-- So we're going to delete the whole relationship instance
-- (but not just yet)
--
Delete_List := (Temp_Minor_Pointer.Next = null);
end if;
if Temp_Minor_Pointer.Next /= null then
--
-- there are more instances following in the list
--
Temp_Minor_Pointer.Next.Previous := Temp_Minor_Pointer.Previous;
end if;
if Temp_Minor_Pointer.Previous /= null then
--
-- there are more instances previous in the list
--
Temp_Minor_Pointer.Previous.Next := Temp_Minor_Pointer.Next;
end if;
Remove_Pair (Temp_Minor_Pointer);
exit Major_Loop;
end if;
Temp_Minor_Pointer := Temp_Minor_Pointer.Next;
end loop Minor_Loop;
end if;
Temp_Major_Pointer := Temp_Major_Pointer.Next;
end loop Major_Loop;
--
-- if needed, now delete the list
-- the same logic applies
--
if Delete_List then
if Temp_Major_Pointer.Previous = null then
--
-- first instance in list
--
The_Relationship_List := Temp_Major_Pointer.Next;
end if;
if Temp_Major_Pointer.Next /= null then
--
-- there are more instances following in the list
--
Temp_Major_Pointer.Next.Previous := Temp_Major_Pointer.Previous;
end if;
if Temp_Major_Pointer.Previous /= null then
--
-- there are more instances previous in the list
--
Temp_Major_Pointer.Previous.Next := Temp_Major_Pointer.Next;
end if;
Remove_Entry (Temp_Major_Pointer);
end if;
end Do_Unlink;
-------------------------------------------------------------------------
procedure Register_Multiple_End_Class (Multiple_Instance : in Ada.Tags.Tag) is
begin
Multiple_Side := Multiple_Instance;
end Register_Multiple_End_Class;
---------------------------------------------------------------------
procedure Register_Multiple_End_Role (Multiple_Role : in String) is
begin
Multiple_Side_Role (1 .. Multiple_Role'Length) := Multiple_Role;
Multiple_Side_Role_Length := Multiple_Role'Length;
end Register_Multiple_End_Role;
---------------------------------------------------------------------
procedure Register_Single_End_Class (Single_Instance : in Ada.Tags.Tag) is
begin
Single_Side := Single_Instance;
end Register_Single_End_Class;
---------------------------------------------------------------------
procedure Register_Single_End_Role (Single_Role : in String) is
begin
Single_Side_Role (1..Single_Role'Length) := Single_Role;
Single_Side_Role_Length := Single_Role'Length;
end Register_Single_End_Role;
---------------------------------------------------------------------
procedure Register_Associative_End_Class (Associative_Instance : in Ada.Tags.Tag) is
begin
Associative_Side := Associative_Instance;
end Register_Associative_End_Class;
---------------------------------------------------------------------
procedure Register_Associative_End_Role (Associative_Role : in String) is
begin
Associative_Side_Role (1 .. Associative_Role'Length) := Associative_Role;
Associative_Side_Role_Length := Associative_Role'Length;
end Register_Associative_End_Role;
---------------------------------------------------------------------
procedure Link (
A_Instance : in Root_Object.Object_Access;
B_Instance : in Root_Object.Object_Access;
Using : in Root_Object.Object_Access) is
begin
if Using.all'Tag = Associative_Side then
if A_Instance.all'Tag = Multiple_Side then
Do_Link (
Multiple_Instance => A_Instance,
Single_Instance => B_Instance,
Associative_Instance => Using);
--
-- PILOT_0000_0423 Include diagnostic references.
--
Application_Types.Count_Of_Relationships := Application_Types.Count_Of_Relationships + 1;
elsif A_Instance.all'Tag = Single_Side then
Do_Link (
Multiple_Instance => B_Instance,
Single_Instance => A_Instance,
Associative_Instance => Using);
--
-- PILOT_0000_0423 Include diagnostic references.
--
Application_Types.Count_Of_Relationships := Application_Types.Count_Of_Relationships + 1;
end if;
end if; -- Using.all'tag /= Associative_Side
end Link;
-----------------------------------------------------------------------
procedure Unassociate (
A_Instance : in Root_Object.Object_Access;
B_Instance : in Root_Object.Object_Access;
From : in Root_Object.Object_Access) is
begin
null;
end Unassociate;
-----------------------------------------------------------------------
procedure Unlink (
A_Instance : in Root_Object.Object_Access;
B_Instance : in Root_Object.Object_Access) is
begin
if A_Instance.all'Tag = Multiple_Side then
Do_Unlink (
Left_Instance => B_Instance,
Right_Instance => A_Instance);
--
-- PILOT_0000_0423 Include diagnostic references.
--
Application_Types.Count_Of_Relationships := Application_Types.Count_Of_Relationships - 1;
elsif A_Instance.all'Tag = Single_Side then
--
Do_Unlink (
Left_Instance => A_Instance,
Right_Instance => B_Instance);
--
-- PILOT_0000_0423 Include diagnostic references.
--
Application_Types.Count_Of_Relationships := Application_Types.Count_Of_Relationships - 1;
end if;
end Unlink;
-----------------------------------------------------------------------
procedure Navigate (
From : in Root_Object.Object_List.List_Header_Access_Type;
Class : in Ada.Tags.Tag;
To : in Root_Object.Object_List.List_Header_Access_Type) is
Source_Instance: Root_Object.Object_Access;
Temp_Node: Root_Object.Object_List.Node_Access_Type;
Temp_Instance: Root_Object.Object_Access;
--Temp_Single: Root_Object.Object_Access;
--Temp_Associative: Root_Object.Object_Access;
--Temp_Multiple: Root_Object.Object_Access;
begin
Temp_Node := Root_Object.Object_List.First_Entry_Of (From);
while Temp_Node /= null loop
Source_Instance := Temp_Node.Item;
if Source_Instance.all'Tag = Multiple_Side then
Navigate (
From => Source_Instance,
Class => Class,
To => Temp_Instance);
if Temp_Instance /= null then
Root_Object.Object_List.Insert (
New_Item => Temp_Instance,
On_To => To );
end if;
--
elsif Source_Instance.all'Tag = Single_Side then
Navigate (
From => Source_Instance,
Class => Class,
To => To);
--
elsif Source_Instance.all'Tag = Associative_Side then
Navigate (
From => Source_Instance,
Class => Class,
To => Temp_Instance);
if Temp_Instance /= null then
Root_Object.Object_List.Insert (
New_Item => Temp_Instance,
On_To => To );
end if;
--
end if;
Temp_Node := Root_Object.Object_List.Next_Entry_Of (From);
end loop;
end Navigate;
-----------------------------------------------------------------------
procedure Navigate (
From : in Root_Object.Object_Access;
Class : in Ada.Tags.Tag;
To : out Root_Object.Object_Access) is
--
-- navigate from a single to a single
-- valid for:
-- A -> M
-- A -> S
-- M -> S
-- M -> A
--
Temp_Single: Root_Object.Object_Access;
Temp_Associative: Root_Object.Object_Access;
Temp_Multiple: Root_Object.Object_Access;
Found: Boolean;
begin
-- PILOT_0000_1422
-- Defaulting the return parameter ensures that if an attempt
-- is made to navigate this type of one to many associative
-- without having linked it, the correct null parameter is
-- returned. This relationship mechanism relies on the link
-- operation to sort out all the tags. We can't rely on that
-- happening in all cases.
To := null;
if From.all'Tag = Multiple_Side then
--
Check_List_For_Multiple (
Multiple_Instance => From,
Associative_Instance => Temp_Associative,
Single_Instance => Temp_Single,
Multiple_Instance_Found => Found);
if Found then
--
if Class = Single_Side then
To := Temp_Single;
elsif Class = Associative_Side then
To := Temp_Associative;
end if;
--
end if;
--
elsif From.all'Tag = Associative_Side then
Check_List_For_Associative (
Associative_Instance => From,
Multiple_Instance => Temp_Multiple,
Single_Instance => Temp_Single,
Associative_Instance_Found => Found);
if Found then
--
if Class = Single_Side then
To := Temp_Single;
elsif Class = Multiple_Side then
To := Temp_Multiple;
end if;
end if;
end if;
end Navigate;
---------------------------------------------------------------------
procedure Navigate (
From : in Root_Object.Object_Access;
Class : in Ada.Tags.Tag;
To : in Root_Object.Object_List.List_Header_Access_Type) is
--
-- navigate from a single to a set
-- valid for:
-- S -> M
-- S -> A
--
Temp_Minor_Pointer: Relationship_Pair_Access_Type;
Temp_Major_Pointer: Relationship_Entry_Access_Type;
begin
if From.all'Tag = Single_Side then
Temp_Major_Pointer := The_Relationship_List;
Major_Loop:
while Temp_Major_Pointer /= null loop
if Temp_Major_Pointer.Single = From then
Temp_Minor_Pointer := Temp_Major_Pointer.Completion_List;
Minor_Loop:
while Temp_Minor_Pointer /= null loop
if Class = Multiple_Side then
Root_Object.Object_List.Insert (
New_Item => Temp_Minor_Pointer.Multiple,
On_To => To);
elsif Class = Associative_Side then
Root_Object.Object_List.Insert (
New_Item => Temp_Minor_Pointer.Associative,
On_To => To);
end if;
Temp_Minor_Pointer := Temp_Minor_Pointer.Next;
end loop Minor_Loop;
exit Major_Loop;
end if;
Temp_Major_Pointer := Temp_Major_Pointer.Next;
end loop Major_Loop;
--
end if;
end Navigate;
------------------------------------------------------------------------
-- associative correlated navigation
procedure Navigate (
From : in Root_Object.Object_Access;
Also : in Root_Object.Object_Access;
Class : in Ada.Tags.Tag;
To : out Root_Object.Object_Access) is
-- navigate from two singles to a single
-- valid for:
-- M and S -> A
-- S and M -> A
Temp_Single,
Single_Side_Source ,
Multiple_Side_Source,
Temp_Associative_Multiple,
Temp_Associative_Single : Root_Object.Object_Access := null;
Assoc_Set : Root_Object.Object_List.List_Header_Access_Type := Root_Object.Object_List.Initialise;
Found,
Tags_Correct : Boolean := FALSE;
begin
-- Reset the output pointer to null so that if we don't find anything
-- useful, the caller can check for it.
To := null;
Tags_Correct := ((( From.all'Tag = Multiple_Side) and then
( Also.all'Tag = Single_Side))
or else ((( From.all'Tag = Single_Side) and then
( Also.all'Tag = Multiple_Side)))) ;
if Tags_Correct then
if From.all'Tag = Multiple_Side then
Multiple_Side_Source := From;
Single_Side_Source := Also;
else
Multiple_Side_Source := Also;
Single_Side_Source := From;
end if;
-- Do the navigations now, all is correct.
-- Navigate from multiple side to associative side.
Check_List_For_Multiple (
Multiple_Instance => Multiple_Side_Source,
Associative_Instance => Temp_Associative_Multiple,
Single_Instance => Temp_Single,
Multiple_Instance_Found => Found);
-- Navigate from single side to associative side.
if Found then
-- do the navigation
declare
Input_List : Root_Object.Object_List.List_Header_Access_Type;
begin
Input_List := Root_Object.Object_List.Initialise;
Root_Object.Object_List.Clear(Assoc_Set);
Root_Object.Object_List.Insert (
New_Item => Single_Side_Source,
On_To => Input_List);
Navigate(
From => Input_List,
Class => Class,
To => Assoc_Set);
Root_Object.Object_List.Destroy_List(Input_List);
end;
-- Extract out the instance from the set by looping through the
-- set and looking for a match with the instance found from the
-- multiple side navigation.
declare
use type Root_Object.Object_List.Node_Access_Type;
Temp_Entry : Root_Object.Object_List.Node_Access_Type;
begin
-- Grab the first entry of the set
Temp_Entry := Root_Object.Object_List.First_Entry_Of(Assoc_Set);
-- While the set is not empty, and the entry does not match the
-- assoc instance already found, loop
while (Temp_Entry /= null) and then
(Temp_Associative_Single /= Temp_Associative_Multiple) loop
Temp_Associative_Single := Temp_Entry.Item;
Temp_Entry := Root_Object.Object_List.Next_Entry_Of(Assoc_Set);
end loop;
end;
if Temp_Associative_Single = Temp_Associative_Multiple then
To := Temp_Associative_Single;
end if;
end if;
end if;
end Navigate;
-----------------------------------------------------------------------
end One_To_Many_Associative;
| 33.930952 | 112 | 0.550768 |
1d2b973bbba747b61cbe23e8866854f437d11aa6 | 1,492 | ads | Ada | source/oasis/program-elements-parenthesized_expressions.ads | reznikmm/gela | 20134f1d154fb763812e73860c6f4b04f353df79 | [
"MIT"
] | null | null | null | source/oasis/program-elements-parenthesized_expressions.ads | reznikmm/gela | 20134f1d154fb763812e73860c6f4b04f353df79 | [
"MIT"
] | null | null | null | source/oasis/program-elements-parenthesized_expressions.ads | reznikmm/gela | 20134f1d154fb763812e73860c6f4b04f353df79 | [
"MIT"
] | 1 | 2019-10-16T09:05:27.000Z | 2019-10-16T09:05:27.000Z | -- SPDX-FileCopyrightText: 2019 Max Reznik <[email protected]>
--
-- SPDX-License-Identifier: MIT
-------------------------------------------------------------
with Program.Elements.Expressions;
with Program.Lexical_Elements;
package Program.Elements.Parenthesized_Expressions is
pragma Pure (Program.Elements.Parenthesized_Expressions);
type Parenthesized_Expression is
limited interface and Program.Elements.Expressions.Expression;
type Parenthesized_Expression_Access is
access all Parenthesized_Expression'Class with Storage_Size => 0;
not overriding function Expression
(Self : Parenthesized_Expression)
return not null Program.Elements.Expressions.Expression_Access
is abstract;
type Parenthesized_Expression_Text is limited interface;
type Parenthesized_Expression_Text_Access is
access all Parenthesized_Expression_Text'Class with Storage_Size => 0;
not overriding function To_Parenthesized_Expression_Text
(Self : in out Parenthesized_Expression)
return Parenthesized_Expression_Text_Access is abstract;
not overriding function Left_Bracket_Token
(Self : Parenthesized_Expression_Text)
return not null Program.Lexical_Elements.Lexical_Element_Access
is abstract;
not overriding function Right_Bracket_Token
(Self : Parenthesized_Expression_Text)
return not null Program.Lexical_Elements.Lexical_Element_Access
is abstract;
end Program.Elements.Parenthesized_Expressions;
| 33.909091 | 75 | 0.768767 |
2f9580ae0002604a4fa7a04e6354b9b6c7c68b98 | 9,051 | adb | Ada | Validation/pyFrame3DD-master/gcc-master/gcc/ada/libgnat/s-pack34.adb | djamal2727/Main-Bearing-Analytical-Model | 2f00c2219c71be0175c6f4f8f1d4cca231d97096 | [
"Apache-2.0"
] | null | null | null | Validation/pyFrame3DD-master/gcc-master/gcc/ada/libgnat/s-pack34.adb | djamal2727/Main-Bearing-Analytical-Model | 2f00c2219c71be0175c6f4f8f1d4cca231d97096 | [
"Apache-2.0"
] | null | null | null | Validation/pyFrame3DD-master/gcc-master/gcc/ada/libgnat/s-pack34.adb | djamal2727/Main-Bearing-Analytical-Model | 2f00c2219c71be0175c6f4f8f1d4cca231d97096 | [
"Apache-2.0"
] | null | null | null | ------------------------------------------------------------------------------
-- --
-- GNAT RUN-TIME COMPONENTS --
-- --
-- S Y S T E M . P A C K _ 3 4 --
-- --
-- B o d y --
-- --
-- Copyright (C) 1992-2020, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
-- ware Foundation; either version 3, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
-- or FITNESS FOR A PARTICULAR PURPOSE. --
-- --
-- As a special exception under Section 7 of GPL version 3, you are granted --
-- additional permissions described in the GCC Runtime Library Exception, --
-- version 3.1, as published by the Free Software Foundation. --
-- --
-- You should have received a copy of the GNU General Public License and --
-- a copy of the GCC Runtime Library Exception along with this program; --
-- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
-- <http://www.gnu.org/licenses/>. --
-- --
-- GNAT was originally developed by the GNAT team at New York University. --
-- Extensive contributions were provided by Ada Core Technologies Inc. --
-- --
------------------------------------------------------------------------------
with System.Storage_Elements;
with System.Unsigned_Types;
package body System.Pack_34 is
subtype Bit_Order is System.Bit_Order;
Reverse_Bit_Order : constant Bit_Order :=
Bit_Order'Val (1 - Bit_Order'Pos (System.Default_Bit_Order));
subtype Ofs is System.Storage_Elements.Storage_Offset;
subtype Uns is System.Unsigned_Types.Unsigned;
subtype N07 is System.Unsigned_Types.Unsigned range 0 .. 7;
use type System.Storage_Elements.Storage_Offset;
use type System.Unsigned_Types.Unsigned;
type Cluster is record
E0, E1, E2, E3, E4, E5, E6, E7 : Bits_34;
end record;
for Cluster use record
E0 at 0 range 0 * Bits .. 0 * Bits + Bits - 1;
E1 at 0 range 1 * Bits .. 1 * Bits + Bits - 1;
E2 at 0 range 2 * Bits .. 2 * Bits + Bits - 1;
E3 at 0 range 3 * Bits .. 3 * Bits + Bits - 1;
E4 at 0 range 4 * Bits .. 4 * Bits + Bits - 1;
E5 at 0 range 5 * Bits .. 5 * Bits + Bits - 1;
E6 at 0 range 6 * Bits .. 6 * Bits + Bits - 1;
E7 at 0 range 7 * Bits .. 7 * Bits + Bits - 1;
end record;
for Cluster'Size use Bits * 8;
for Cluster'Alignment use Integer'Min (Standard'Maximum_Alignment,
1 +
1 * Boolean'Pos (Bits mod 2 = 0) +
2 * Boolean'Pos (Bits mod 4 = 0));
-- Use maximum possible alignment, given the bit field size, since this
-- will result in the most efficient code possible for the field.
type Cluster_Ref is access Cluster;
type Rev_Cluster is new Cluster
with Bit_Order => Reverse_Bit_Order,
Scalar_Storage_Order => Reverse_Bit_Order;
type Rev_Cluster_Ref is access Rev_Cluster;
-- The following declarations are for the case where the address
-- passed to GetU_34 or SetU_34 is not guaranteed to be aligned.
-- These routines are used when the packed array is itself a
-- component of a packed record, and therefore may not be aligned.
type ClusterU is new Cluster;
for ClusterU'Alignment use 1;
type ClusterU_Ref is access ClusterU;
type Rev_ClusterU is new ClusterU
with Bit_Order => Reverse_Bit_Order,
Scalar_Storage_Order => Reverse_Bit_Order;
type Rev_ClusterU_Ref is access Rev_ClusterU;
------------
-- Get_34 --
------------
function Get_34
(Arr : System.Address;
N : Natural;
Rev_SSO : Boolean) return Bits_34
is
A : constant System.Address := Arr + Bits * Ofs (Uns (N) / 8);
C : Cluster_Ref with Address => A'Address, Import;
RC : Rev_Cluster_Ref with Address => A'Address, Import;
begin
if Rev_SSO then
case N07 (Uns (N) mod 8) is
when 0 => return RC.E0;
when 1 => return RC.E1;
when 2 => return RC.E2;
when 3 => return RC.E3;
when 4 => return RC.E4;
when 5 => return RC.E5;
when 6 => return RC.E6;
when 7 => return RC.E7;
end case;
else
case N07 (Uns (N) mod 8) is
when 0 => return C.E0;
when 1 => return C.E1;
when 2 => return C.E2;
when 3 => return C.E3;
when 4 => return C.E4;
when 5 => return C.E5;
when 6 => return C.E6;
when 7 => return C.E7;
end case;
end if;
end Get_34;
-------------
-- GetU_34 --
-------------
function GetU_34
(Arr : System.Address;
N : Natural;
Rev_SSO : Boolean) return Bits_34
is
A : constant System.Address := Arr + Bits * Ofs (Uns (N) / 8);
C : ClusterU_Ref with Address => A'Address, Import;
RC : Rev_ClusterU_Ref with Address => A'Address, Import;
begin
if Rev_SSO then
case N07 (Uns (N) mod 8) is
when 0 => return RC.E0;
when 1 => return RC.E1;
when 2 => return RC.E2;
when 3 => return RC.E3;
when 4 => return RC.E4;
when 5 => return RC.E5;
when 6 => return RC.E6;
when 7 => return RC.E7;
end case;
else
case N07 (Uns (N) mod 8) is
when 0 => return C.E0;
when 1 => return C.E1;
when 2 => return C.E2;
when 3 => return C.E3;
when 4 => return C.E4;
when 5 => return C.E5;
when 6 => return C.E6;
when 7 => return C.E7;
end case;
end if;
end GetU_34;
------------
-- Set_34 --
------------
procedure Set_34
(Arr : System.Address;
N : Natural;
E : Bits_34;
Rev_SSO : Boolean)
is
A : constant System.Address := Arr + Bits * Ofs (Uns (N) / 8);
C : Cluster_Ref with Address => A'Address, Import;
RC : Rev_Cluster_Ref with Address => A'Address, Import;
begin
if Rev_SSO then
case N07 (Uns (N) mod 8) is
when 0 => RC.E0 := E;
when 1 => RC.E1 := E;
when 2 => RC.E2 := E;
when 3 => RC.E3 := E;
when 4 => RC.E4 := E;
when 5 => RC.E5 := E;
when 6 => RC.E6 := E;
when 7 => RC.E7 := E;
end case;
else
case N07 (Uns (N) mod 8) is
when 0 => C.E0 := E;
when 1 => C.E1 := E;
when 2 => C.E2 := E;
when 3 => C.E3 := E;
when 4 => C.E4 := E;
when 5 => C.E5 := E;
when 6 => C.E6 := E;
when 7 => C.E7 := E;
end case;
end if;
end Set_34;
-------------
-- SetU_34 --
-------------
procedure SetU_34
(Arr : System.Address;
N : Natural;
E : Bits_34;
Rev_SSO : Boolean)
is
A : constant System.Address := Arr + Bits * Ofs (Uns (N) / 8);
C : ClusterU_Ref with Address => A'Address, Import;
RC : Rev_ClusterU_Ref with Address => A'Address, Import;
begin
if Rev_SSO then
case N07 (Uns (N) mod 8) is
when 0 => RC.E0 := E;
when 1 => RC.E1 := E;
when 2 => RC.E2 := E;
when 3 => RC.E3 := E;
when 4 => RC.E4 := E;
when 5 => RC.E5 := E;
when 6 => RC.E6 := E;
when 7 => RC.E7 := E;
end case;
else
case N07 (Uns (N) mod 8) is
when 0 => C.E0 := E;
when 1 => C.E1 := E;
when 2 => C.E2 := E;
when 3 => C.E3 := E;
when 4 => C.E4 := E;
when 5 => C.E5 := E;
when 6 => C.E6 := E;
when 7 => C.E7 := E;
end case;
end if;
end SetU_34;
end System.Pack_34;
| 36.059761 | 78 | 0.467352 |
2ff91cc10c0ddcc64fbca0ea742a7d7694b7769f | 184,907 | adb | Ada | clients/ada-server/generated/src/server/-skeletons.adb | PankTrue/swaggy-jenkins | aca35a7cca6e1fcc08bd399e05148942ac2f514b | [
"MIT"
] | 23 | 2017-08-01T12:25:26.000Z | 2022-01-25T03:44:11.000Z | clients/ada-server/generated/src/server/-skeletons.adb | PankTrue/swaggy-jenkins | aca35a7cca6e1fcc08bd399e05148942ac2f514b | [
"MIT"
] | 35 | 2017-06-14T03:28:15.000Z | 2022-02-14T10:25:54.000Z | clients/ada-server/generated/src/server/-skeletons.adb | PankTrue/swaggy-jenkins | aca35a7cca6e1fcc08bd399e05148942ac2f514b | [
"MIT"
] | 11 | 2017-08-31T19:00:20.000Z | 2021-12-19T12:04:12.000Z | -- Swaggy Jenkins
-- Jenkins API clients generated from Swagger / Open API specification
--
-- OpenAPI spec version: 1.1.1
-- Contact: [email protected]
--
-- NOTE: This package is auto generated by the swagger code generator 3.2.1-SNAPSHOT.
-- https://openapi-generator.tech
-- Do not edit the class manually.
with Swagger.Streams;
with Swagger.Servers.Operation;
package body .Skeletons is
package body Skeleton is
package API_Get_Crumb is
new Swagger.Servers.Operation (Handler => Get_Crumb,
Method => Swagger.Servers.GET,
URI => "/crumbIssuer/api/json");
--
procedure Get_Crumb
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Result : .Models.DefaultCrumbIssuer_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Impl.Get_Crumb (Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Crumb;
package API_Delete_Pipeline_Queue_Item is
new Swagger.Servers.Operation (Handler => Delete_Pipeline_Queue_Item,
Method => Swagger.Servers.DELETE,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/queue/{queue}");
--
procedure Delete_Pipeline_Queue_Item
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Queue : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Queue);
Impl.Delete_Pipeline_Queue_Item
(Organization,
Pipeline,
Queue, Context);
end Delete_Pipeline_Queue_Item;
package API_Get_Authenticated_User is
new Swagger.Servers.Operation (Handler => Get_Authenticated_User,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/user/");
--
procedure Get_Authenticated_User
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Result : .Models.User_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Organization);
Impl.Get_Authenticated_User
(Organization, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Authenticated_User;
package API_Get_Classes is
new Swagger.Servers.Operation (Handler => Get_Classes,
Method => Swagger.Servers.GET,
URI => "/blue/rest/classes/{class}");
--
procedure Get_Classes
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Class : Swagger.UString;
Result : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Class);
Impl.Get_Classes
(Class, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Classes;
package API_Get_Json_Web_Key is
new Swagger.Servers.Operation (Handler => Get_Json_Web_Key,
Method => Swagger.Servers.GET,
URI => "/jwt-auth/jwks/{key}");
--
procedure Get_Json_Web_Key
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Key : Integer;
Result : Swagger.UString;
begin
Swagger.Servers.Get_Path_Parameter (Req, 1, Key);
Impl.Get_Json_Web_Key
(Key, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Json_Web_Key;
package API_Get_Json_Web_Token is
new Swagger.Servers.Operation (Handler => Get_Json_Web_Token,
Method => Swagger.Servers.GET,
URI => "/jwt-auth/token");
--
procedure Get_Json_Web_Token
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Expiry_Time_In_Mins : Swagger.Nullable_Integer;
Max_Expiry_Time_In_Mins : Swagger.Nullable_Integer;
Result : Swagger.UString;
begin
Swagger.Servers.Get_Query_Parameter (Req, "expiryTimeInMins", Expiry_Time_In_Mins);
Swagger.Servers.Get_Query_Parameter (Req, "maxExpiryTimeInMins", Max_Expiry_Time_In_Mins);
Impl.Get_Json_Web_Token
(Expiry_Time_In_Mins,
Max_Expiry_Time_In_Mins, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Json_Web_Token;
package API_Get_Organisation is
new Swagger.Servers.Operation (Handler => Get_Organisation,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}");
--
procedure Get_Organisation
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Result : .Models.Organisation_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Organization);
Impl.Get_Organisation
(Organization, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Organisation;
package API_Get_Organisations is
new Swagger.Servers.Operation (Handler => Get_Organisations,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/");
--
procedure Get_Organisations
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Result : .Models.Organisations_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Impl.Get_Organisations (Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Organisations;
package API_Get_Pipeline is
new Swagger.Servers.Operation (Handler => Get_Pipeline,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}");
--
procedure Get_Pipeline
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Result : .Models.Pipeline_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Pipeline);
Impl.Get_Pipeline
(Organization,
Pipeline, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline;
package API_Get_Pipeline_Activities is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Activities,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/activities");
--
procedure Get_Pipeline_Activities
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Result : .Models.PipelineActivities_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Pipeline);
Impl.Get_Pipeline_Activities
(Organization,
Pipeline, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Activities;
package API_Get_Pipeline_Branch is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Branch,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/branches/{branch}/");
--
procedure Get_Pipeline_Branch
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Branch : Swagger.UString;
Result : .Models.BranchImpl_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Branch);
Impl.Get_Pipeline_Branch
(Organization,
Pipeline,
Branch, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Branch;
package API_Get_Pipeline_Branch_Run is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Branch_Run,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/branches/{branch}/runs/{run}");
--
procedure Get_Pipeline_Branch_Run
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Branch : Swagger.UString;
Run : Swagger.UString;
Result : .Models.PipelineRun_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 4, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 4, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 4, Branch);
Swagger.Servers.Get_Path_Parameter (Req, 4, Run);
Impl.Get_Pipeline_Branch_Run
(Organization,
Pipeline,
Branch,
Run, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Branch_Run;
package API_Get_Pipeline_Branches is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Branches,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/branches");
--
procedure Get_Pipeline_Branches
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Result : .Models.MultibranchPipeline_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Pipeline);
Impl.Get_Pipeline_Branches
(Organization,
Pipeline, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Branches;
package API_Get_Pipeline_Folder is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Folder,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{folder}/");
--
procedure Get_Pipeline_Folder
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Folder : Swagger.UString;
Result : .Models.PipelineFolderImpl_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Folder);
Impl.Get_Pipeline_Folder
(Organization,
Folder, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Folder;
package API_Get_Pipeline_Folder_Pipeline is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Folder_Pipeline,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{folder}/pipelines/{pipeline}");
--
procedure Get_Pipeline_Folder_Pipeline
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Folder : Swagger.UString;
Result : .Models.PipelineImpl_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Folder);
Impl.Get_Pipeline_Folder_Pipeline
(Organization,
Pipeline,
Folder, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Folder_Pipeline;
package API_Get_Pipeline_Queue is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Queue,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/queue");
--
procedure Get_Pipeline_Queue
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Result : .Models.PipelineQueue_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Pipeline);
Impl.Get_Pipeline_Queue
(Organization,
Pipeline, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Queue;
package API_Get_Pipeline_Run is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Run,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}");
--
procedure Get_Pipeline_Run
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Result : .Models.PipelineRun_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Run);
Impl.Get_Pipeline_Run
(Organization,
Pipeline,
Run, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Run;
package API_Get_Pipeline_Run_Log is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Run_Log,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/log");
--
procedure Get_Pipeline_Run_Log
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Start : Swagger.Nullable_Integer;
Download : Swagger.Nullable_Boolean;
Result : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "start", Start);
Swagger.Servers.Get_Query_Parameter (Req, "download", Download);
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Run);
Impl.Get_Pipeline_Run_Log
(Organization,
Pipeline,
Run,
Start,
Download, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Run_Log;
package API_Get_Pipeline_Run_Node is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Run_Node,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/nodes/{node}");
--
procedure Get_Pipeline_Run_Node
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Node : Swagger.UString;
Result : .Models.PipelineRunNode_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 4, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 4, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 4, Run);
Swagger.Servers.Get_Path_Parameter (Req, 4, Node);
Impl.Get_Pipeline_Run_Node
(Organization,
Pipeline,
Run,
Node, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Run_Node;
package API_Get_Pipeline_Run_Node_Step is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Run_Node_Step,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/nodes/{node}/steps/{step}");
--
procedure Get_Pipeline_Run_Node_Step
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Node : Swagger.UString;
Step : Swagger.UString;
Result : .Models.PipelineStepImpl_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 5, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 5, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 5, Run);
Swagger.Servers.Get_Path_Parameter (Req, 5, Node);
Swagger.Servers.Get_Path_Parameter (Req, 5, Step);
Impl.Get_Pipeline_Run_Node_Step
(Organization,
Pipeline,
Run,
Node,
Step, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Run_Node_Step;
package API_Get_Pipeline_Run_Node_Step_Log is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Run_Node_Step_Log,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/nodes/{node}/steps/{step}/log");
--
procedure Get_Pipeline_Run_Node_Step_Log
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Node : Swagger.UString;
Step : Swagger.UString;
Result : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 5, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 5, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 5, Run);
Swagger.Servers.Get_Path_Parameter (Req, 5, Node);
Swagger.Servers.Get_Path_Parameter (Req, 5, Step);
Impl.Get_Pipeline_Run_Node_Step_Log
(Organization,
Pipeline,
Run,
Node,
Step, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Run_Node_Step_Log;
package API_Get_Pipeline_Run_Node_Steps is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Run_Node_Steps,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/nodes/{node}/steps");
--
procedure Get_Pipeline_Run_Node_Steps
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Node : Swagger.UString;
Result : .Models.PipelineRunNodeSteps_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 4, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 4, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 4, Run);
Swagger.Servers.Get_Path_Parameter (Req, 4, Node);
Impl.Get_Pipeline_Run_Node_Steps
(Organization,
Pipeline,
Run,
Node, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Run_Node_Steps;
package API_Get_Pipeline_Run_Nodes is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Run_Nodes,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/nodes");
--
procedure Get_Pipeline_Run_Nodes
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Result : .Models.PipelineRunNodes_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Run);
Impl.Get_Pipeline_Run_Nodes
(Organization,
Pipeline,
Run, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Run_Nodes;
package API_Get_Pipeline_Runs is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Runs,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs");
--
procedure Get_Pipeline_Runs
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Result : .Models.PipelineRuns_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Pipeline);
Impl.Get_Pipeline_Runs
(Organization,
Pipeline, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Runs;
package API_Get_Pipelines is
new Swagger.Servers.Operation (Handler => Get_Pipelines,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/");
--
procedure Get_Pipelines
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Result : .Models.Pipelines_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Organization);
Impl.Get_Pipelines
(Organization, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipelines;
package API_Get_S_C_M is
new Swagger.Servers.Operation (Handler => Get_S_C_M,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/scm/{scm}");
--
procedure Get_S_C_M
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Scm : Swagger.UString;
Result : .Models.GithubScm_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Scm);
Impl.Get_S_C_M
(Organization,
Scm, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_S_C_M;
package API_Get_S_C_M_Organisation_Repositories is
new Swagger.Servers.Operation (Handler => Get_S_C_M_Organisation_Repositories,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/scm/{scm}/organizations/{scmOrganisation}/repositories");
--
procedure Get_S_C_M_Organisation_Repositories
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Scm : Swagger.UString;
Scm_Organisation : Swagger.UString;
Credential_Id : Swagger.Nullable_UString;
Page_Size : Swagger.Nullable_Integer;
Page_Number : Swagger.Nullable_Integer;
Result : .Models.ScmOrganisations_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "credentialId", Credential_Id);
Swagger.Servers.Get_Query_Parameter (Req, "pageSize", Page_Size);
Swagger.Servers.Get_Query_Parameter (Req, "pageNumber", Page_Number);
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Scm);
Swagger.Servers.Get_Path_Parameter (Req, 3, Scm_Organisation);
Impl.Get_S_C_M_Organisation_Repositories
(Organization,
Scm,
Scm_Organisation,
Credential_Id,
Page_Size,
Page_Number, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_S_C_M_Organisation_Repositories;
package API_Get_S_C_M_Organisation_Repository is
new Swagger.Servers.Operation (Handler => Get_S_C_M_Organisation_Repository,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/scm/{scm}/organizations/{scmOrganisation}/repositories/{repository}");
--
procedure Get_S_C_M_Organisation_Repository
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Scm : Swagger.UString;
Scm_Organisation : Swagger.UString;
Repository : Swagger.UString;
Credential_Id : Swagger.Nullable_UString;
Result : .Models.ScmOrganisations_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "credentialId", Credential_Id);
Swagger.Servers.Get_Path_Parameter (Req, 4, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 4, Scm);
Swagger.Servers.Get_Path_Parameter (Req, 4, Scm_Organisation);
Swagger.Servers.Get_Path_Parameter (Req, 4, Repository);
Impl.Get_S_C_M_Organisation_Repository
(Organization,
Scm,
Scm_Organisation,
Repository,
Credential_Id, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_S_C_M_Organisation_Repository;
package API_Get_S_C_M_Organisations is
new Swagger.Servers.Operation (Handler => Get_S_C_M_Organisations,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/scm/{scm}/organizations");
--
procedure Get_S_C_M_Organisations
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Scm : Swagger.UString;
Credential_Id : Swagger.Nullable_UString;
Result : .Models.ScmOrganisations_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "credentialId", Credential_Id);
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Scm);
Impl.Get_S_C_M_Organisations
(Organization,
Scm,
Credential_Id, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_S_C_M_Organisations;
package API_Get_User is
new Swagger.Servers.Operation (Handler => Get_User,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/users/{user}");
--
procedure Get_User
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
User : Swagger.UString;
Result : .Models.User_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, User);
Impl.Get_User
(Organization,
User, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_User;
package API_Get_User_Favorites is
new Swagger.Servers.Operation (Handler => Get_User_Favorites,
Method => Swagger.Servers.GET,
URI => "/blue/rest/users/{user}/favorites");
--
procedure Get_User_Favorites
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
User : Swagger.UString;
Result : .Models.UserFavorites_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, User);
Impl.Get_User_Favorites
(User, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_User_Favorites;
package API_Get_Users is
new Swagger.Servers.Operation (Handler => Get_Users,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/users/");
--
procedure Get_Users
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Result : .Models.User_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Organization);
Impl.Get_Users
(Organization, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Users;
package API_Post_Pipeline_Run is
new Swagger.Servers.Operation (Handler => Post_Pipeline_Run,
Method => Swagger.Servers.POST,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/replay");
--
procedure Post_Pipeline_Run
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Result : .Models.QueueItemImpl_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Run);
Impl.Post_Pipeline_Run
(Organization,
Pipeline,
Run, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Post_Pipeline_Run;
package API_Post_Pipeline_Runs is
new Swagger.Servers.Operation (Handler => Post_Pipeline_Runs,
Method => Swagger.Servers.POST,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs");
--
procedure Post_Pipeline_Runs
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Result : .Models.QueueItemImpl_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Pipeline);
Impl.Post_Pipeline_Runs
(Organization,
Pipeline, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Post_Pipeline_Runs;
package API_Put_Pipeline_Favorite is
new Swagger.Servers.Operation (Handler => Put_Pipeline_Favorite,
Method => Swagger.Servers.PUT,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/favorite");
--
procedure Put_Pipeline_Favorite
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Input : Swagger.Value_Type;
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Body_Type : Body_Type;
Result : .Models.FavoriteImpl_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Pipeline);
Swagger.Servers.Read (Req, Input);
.Models.Deserialize (Input, "Body_Type", Body_Type);
Impl.Put_Pipeline_Favorite
(Organization,
Pipeline,
Body_Type, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Put_Pipeline_Favorite;
package API_Put_Pipeline_Run is
new Swagger.Servers.Operation (Handler => Put_Pipeline_Run,
Method => Swagger.Servers.PUT,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/stop");
--
procedure Put_Pipeline_Run
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Blocking : Swagger.Nullable_UString;
Time_Out_In_Secs : Swagger.Nullable_Integer;
Result : .Models.PipelineRun_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "blocking", Blocking);
Swagger.Servers.Get_Query_Parameter (Req, "timeOutInSecs", Time_Out_In_Secs);
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Run);
Impl.Put_Pipeline_Run
(Organization,
Pipeline,
Run,
Blocking,
Time_Out_In_Secs, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Put_Pipeline_Run;
package API_Search is
new Swagger.Servers.Operation (Handler => Search,
Method => Swagger.Servers.GET,
URI => "/blue/rest/search/");
--
procedure Search
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Q : Swagger.UString;
Result : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "q", Q);
Impl.Search
(Q, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Search;
package API_Search_Classes is
new Swagger.Servers.Operation (Handler => Search_Classes,
Method => Swagger.Servers.GET,
URI => "/blue/rest/classes/");
--
procedure Search_Classes
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Q : Swagger.UString;
Result : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "q", Q);
Impl.Search_Classes
(Q, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Search_Classes;
package API_Get_Computer is
new Swagger.Servers.Operation (Handler => Get_Computer,
Method => Swagger.Servers.GET,
URI => "/computer/api/json");
--
procedure Get_Computer
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Depth : Integer;
Result : .Models.ComputerSet_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "depth", Depth);
Impl.Get_Computer
(Depth, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Computer;
package API_Get_Jenkins is
new Swagger.Servers.Operation (Handler => Get_Jenkins,
Method => Swagger.Servers.GET,
URI => "/api/json");
--
procedure Get_Jenkins
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Result : .Models.Hudson_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Impl.Get_Jenkins (Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Jenkins;
package API_Get_Job is
new Swagger.Servers.Operation (Handler => Get_Job,
Method => Swagger.Servers.GET,
URI => "/job/{name}/api/json");
--
procedure Get_Job
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Name : Swagger.UString;
Result : .Models.FreeStyleProject_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Impl.Get_Job
(Name, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Job;
package API_Get_Job_Config is
new Swagger.Servers.Operation (Handler => Get_Job_Config,
Method => Swagger.Servers.GET,
URI => "/job/{name}/config.xml");
--
procedure Get_Job_Config
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Name : Swagger.UString;
Result : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Impl.Get_Job_Config
(Name, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Job_Config;
package API_Get_Job_Last_Build is
new Swagger.Servers.Operation (Handler => Get_Job_Last_Build,
Method => Swagger.Servers.GET,
URI => "/job/{name}/lastBuild/api/json");
--
procedure Get_Job_Last_Build
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Name : Swagger.UString;
Result : .Models.FreeStyleBuild_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Impl.Get_Job_Last_Build
(Name, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Job_Last_Build;
package API_Get_Job_Progressive_Text is
new Swagger.Servers.Operation (Handler => Get_Job_Progressive_Text,
Method => Swagger.Servers.GET,
URI => "/job/{name}/{number}/logText/progressiveText");
--
procedure Get_Job_Progressive_Text
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Name : Swagger.UString;
Number : Swagger.UString;
Start : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "start", Start);
Swagger.Servers.Get_Path_Parameter (Req, 2, Name);
Swagger.Servers.Get_Path_Parameter (Req, 2, Number);
Impl.Get_Job_Progressive_Text
(Name,
Number,
Start, Context);
end Get_Job_Progressive_Text;
package API_Get_Queue is
new Swagger.Servers.Operation (Handler => Get_Queue,
Method => Swagger.Servers.GET,
URI => "/queue/api/json");
--
procedure Get_Queue
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Result : .Models.Queue_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Impl.Get_Queue (Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Queue;
package API_Get_Queue_Item is
new Swagger.Servers.Operation (Handler => Get_Queue_Item,
Method => Swagger.Servers.GET,
URI => "/queue/item/{number}/api/json");
--
procedure Get_Queue_Item
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Number : Swagger.UString;
Result : .Models.Queue_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Number);
Impl.Get_Queue_Item
(Number, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Queue_Item;
package API_Get_View is
new Swagger.Servers.Operation (Handler => Get_View,
Method => Swagger.Servers.GET,
URI => "/view/{name}/api/json");
--
procedure Get_View
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Name : Swagger.UString;
Result : .Models.ListView_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Impl.Get_View
(Name, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_View;
package API_Get_View_Config is
new Swagger.Servers.Operation (Handler => Get_View_Config,
Method => Swagger.Servers.GET,
URI => "/view/{name}/config.xml");
--
procedure Get_View_Config
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Name : Swagger.UString;
Result : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Impl.Get_View_Config
(Name, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_View_Config;
package API_Head_Jenkins is
new Swagger.Servers.Operation (Handler => Head_Jenkins,
Method => Swagger.Servers.HEAD,
URI => "/api/json");
--
procedure Head_Jenkins
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Impl.Head_Jenkins (Context);
end Head_Jenkins;
package API_Post_Create_Item is
new Swagger.Servers.Operation (Handler => Post_Create_Item,
Method => Swagger.Servers.POST,
URI => "/createItem");
--
procedure Post_Create_Item
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Input : Swagger.Value_Type;
Impl : Implementation_Type;
Name : Swagger.UString;
From : Swagger.Nullable_UString;
Mode : Swagger.Nullable_UString;
Jenkins_Crumb : Swagger.Nullable_UString;
Content_Type : Swagger.Nullable_UString;
P_Body : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "name", Name);
Swagger.Servers.Get_Query_Parameter (Req, "from", From);
Swagger.Servers.Get_Query_Parameter (Req, "mode", Mode);
Swagger.Servers.Read (Req, Input);
.Models.Deserialize (Input, "body", P_Body);
Impl.Post_Create_Item
(Name,
From,
Mode,
Jenkins_Crumb,
Content_Type,
P_Body, Context);
end Post_Create_Item;
package API_Post_Create_View is
new Swagger.Servers.Operation (Handler => Post_Create_View,
Method => Swagger.Servers.POST,
URI => "/createView");
--
procedure Post_Create_View
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Input : Swagger.Value_Type;
Impl : Implementation_Type;
Name : Swagger.UString;
Jenkins_Crumb : Swagger.Nullable_UString;
Content_Type : Swagger.Nullable_UString;
P_Body : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "name", Name);
Swagger.Servers.Read (Req, Input);
.Models.Deserialize (Input, "body", P_Body);
Impl.Post_Create_View
(Name,
Jenkins_Crumb,
Content_Type,
P_Body, Context);
end Post_Create_View;
package API_Post_Job_Build is
new Swagger.Servers.Operation (Handler => Post_Job_Build,
Method => Swagger.Servers.POST,
URI => "/job/{name}/build");
--
procedure Post_Job_Build
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Name : Swagger.UString;
Json : Swagger.UString;
Token : Swagger.Nullable_UString;
Jenkins_Crumb : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "json", Json);
Swagger.Servers.Get_Query_Parameter (Req, "token", Token);
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Impl.Post_Job_Build
(Name,
Json,
Token,
Jenkins_Crumb, Context);
end Post_Job_Build;
package API_Post_Job_Config is
new Swagger.Servers.Operation (Handler => Post_Job_Config,
Method => Swagger.Servers.POST,
URI => "/job/{name}/config.xml");
--
procedure Post_Job_Config
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Input : Swagger.Value_Type;
Impl : Implementation_Type;
Name : Swagger.UString;
P_Body : Swagger.UString;
Jenkins_Crumb : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Swagger.Servers.Read (Req, Input);
.Models.Deserialize (Input, "body", P_Body);
Impl.Post_Job_Config
(Name,
P_Body,
Jenkins_Crumb, Context);
end Post_Job_Config;
package API_Post_Job_Delete is
new Swagger.Servers.Operation (Handler => Post_Job_Delete,
Method => Swagger.Servers.POST,
URI => "/job/{name}/doDelete");
--
procedure Post_Job_Delete
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Name : Swagger.UString;
Jenkins_Crumb : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Impl.Post_Job_Delete
(Name,
Jenkins_Crumb, Context);
end Post_Job_Delete;
package API_Post_Job_Disable is
new Swagger.Servers.Operation (Handler => Post_Job_Disable,
Method => Swagger.Servers.POST,
URI => "/job/{name}/disable");
--
procedure Post_Job_Disable
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Name : Swagger.UString;
Jenkins_Crumb : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Impl.Post_Job_Disable
(Name,
Jenkins_Crumb, Context);
end Post_Job_Disable;
package API_Post_Job_Enable is
new Swagger.Servers.Operation (Handler => Post_Job_Enable,
Method => Swagger.Servers.POST,
URI => "/job/{name}/enable");
--
procedure Post_Job_Enable
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Name : Swagger.UString;
Jenkins_Crumb : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Impl.Post_Job_Enable
(Name,
Jenkins_Crumb, Context);
end Post_Job_Enable;
package API_Post_Job_Last_Build_Stop is
new Swagger.Servers.Operation (Handler => Post_Job_Last_Build_Stop,
Method => Swagger.Servers.POST,
URI => "/job/{name}/lastBuild/stop");
--
procedure Post_Job_Last_Build_Stop
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Impl : Implementation_Type;
Name : Swagger.UString;
Jenkins_Crumb : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Impl.Post_Job_Last_Build_Stop
(Name,
Jenkins_Crumb, Context);
end Post_Job_Last_Build_Stop;
package API_Post_View_Config is
new Swagger.Servers.Operation (Handler => Post_View_Config,
Method => Swagger.Servers.POST,
URI => "/view/{name}/config.xml");
--
procedure Post_View_Config
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Input : Swagger.Value_Type;
Impl : Implementation_Type;
Name : Swagger.UString;
P_Body : Swagger.UString;
Jenkins_Crumb : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Swagger.Servers.Read (Req, Input);
.Models.Deserialize (Input, "body", P_Body);
Impl.Post_View_Config
(Name,
P_Body,
Jenkins_Crumb, Context);
end Post_View_Config;
procedure Register (Server : in out Swagger.Servers.Application_Type'Class) is
begin
Swagger.Servers.Register (Server, API_Get_Crumb.Definition);
Swagger.Servers.Register (Server, API_Delete_Pipeline_Queue_Item.Definition);
Swagger.Servers.Register (Server, API_Get_Authenticated_User.Definition);
Swagger.Servers.Register (Server, API_Get_Classes.Definition);
Swagger.Servers.Register (Server, API_Get_Json_Web_Key.Definition);
Swagger.Servers.Register (Server, API_Get_Json_Web_Token.Definition);
Swagger.Servers.Register (Server, API_Get_Organisation.Definition);
Swagger.Servers.Register (Server, API_Get_Organisations.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Activities.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Branch.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Branch_Run.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Branches.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Folder.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Folder_Pipeline.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Queue.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Run.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Run_Log.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Run_Node.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Run_Node_Step.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Run_Node_Step_Log.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Run_Node_Steps.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Run_Nodes.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Runs.Definition);
Swagger.Servers.Register (Server, API_Get_Pipelines.Definition);
Swagger.Servers.Register (Server, API_Get_S_C_M.Definition);
Swagger.Servers.Register (Server, API_Get_S_C_M_Organisation_Repositories.Definition);
Swagger.Servers.Register (Server, API_Get_S_C_M_Organisation_Repository.Definition);
Swagger.Servers.Register (Server, API_Get_S_C_M_Organisations.Definition);
Swagger.Servers.Register (Server, API_Get_User.Definition);
Swagger.Servers.Register (Server, API_Get_User_Favorites.Definition);
Swagger.Servers.Register (Server, API_Get_Users.Definition);
Swagger.Servers.Register (Server, API_Post_Pipeline_Run.Definition);
Swagger.Servers.Register (Server, API_Post_Pipeline_Runs.Definition);
Swagger.Servers.Register (Server, API_Put_Pipeline_Favorite.Definition);
Swagger.Servers.Register (Server, API_Put_Pipeline_Run.Definition);
Swagger.Servers.Register (Server, API_Search.Definition);
Swagger.Servers.Register (Server, API_Search_Classes.Definition);
Swagger.Servers.Register (Server, API_Get_Computer.Definition);
Swagger.Servers.Register (Server, API_Get_Jenkins.Definition);
Swagger.Servers.Register (Server, API_Get_Job.Definition);
Swagger.Servers.Register (Server, API_Get_Job_Config.Definition);
Swagger.Servers.Register (Server, API_Get_Job_Last_Build.Definition);
Swagger.Servers.Register (Server, API_Get_Job_Progressive_Text.Definition);
Swagger.Servers.Register (Server, API_Get_Queue.Definition);
Swagger.Servers.Register (Server, API_Get_Queue_Item.Definition);
Swagger.Servers.Register (Server, API_Get_View.Definition);
Swagger.Servers.Register (Server, API_Get_View_Config.Definition);
Swagger.Servers.Register (Server, API_Head_Jenkins.Definition);
Swagger.Servers.Register (Server, API_Post_Create_Item.Definition);
Swagger.Servers.Register (Server, API_Post_Create_View.Definition);
Swagger.Servers.Register (Server, API_Post_Job_Build.Definition);
Swagger.Servers.Register (Server, API_Post_Job_Config.Definition);
Swagger.Servers.Register (Server, API_Post_Job_Delete.Definition);
Swagger.Servers.Register (Server, API_Post_Job_Disable.Definition);
Swagger.Servers.Register (Server, API_Post_Job_Enable.Definition);
Swagger.Servers.Register (Server, API_Post_Job_Last_Build_Stop.Definition);
Swagger.Servers.Register (Server, API_Post_View_Config.Definition);
end Register;
end Skeleton;
package body Shared_Instance is
--
procedure Get_Crumb
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Result : .Models.DefaultCrumbIssuer_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Server.Get_Crumb (Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Crumb;
package API_Get_Crumb is
new Swagger.Servers.Operation (Handler => Get_Crumb,
Method => Swagger.Servers.GET,
URI => "/crumbIssuer/api/json");
--
procedure Delete_Pipeline_Queue_Item
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Queue : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Queue);
Server.Delete_Pipeline_Queue_Item
(Organization,
Pipeline,
Queue, Context);
end Delete_Pipeline_Queue_Item;
package API_Delete_Pipeline_Queue_Item is
new Swagger.Servers.Operation (Handler => Delete_Pipeline_Queue_Item,
Method => Swagger.Servers.DELETE,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/queue/{queue}");
--
procedure Get_Authenticated_User
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Result : .Models.User_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Organization);
Server.Get_Authenticated_User
(Organization, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Authenticated_User;
package API_Get_Authenticated_User is
new Swagger.Servers.Operation (Handler => Get_Authenticated_User,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/user/");
--
procedure Get_Classes
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Class : Swagger.UString;
Result : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Class);
Server.Get_Classes
(Class, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Classes;
package API_Get_Classes is
new Swagger.Servers.Operation (Handler => Get_Classes,
Method => Swagger.Servers.GET,
URI => "/blue/rest/classes/{class}");
--
procedure Get_Json_Web_Key
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Key : Integer;
Result : Swagger.UString;
begin
Swagger.Servers.Get_Path_Parameter (Req, 1, Key);
Server.Get_Json_Web_Key
(Key, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Json_Web_Key;
package API_Get_Json_Web_Key is
new Swagger.Servers.Operation (Handler => Get_Json_Web_Key,
Method => Swagger.Servers.GET,
URI => "/jwt-auth/jwks/{key}");
--
procedure Get_Json_Web_Token
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Expiry_Time_In_Mins : Swagger.Nullable_Integer;
Max_Expiry_Time_In_Mins : Swagger.Nullable_Integer;
Result : Swagger.UString;
begin
Swagger.Servers.Get_Query_Parameter (Req, "expiryTimeInMins", Expiry_Time_In_Mins);
Swagger.Servers.Get_Query_Parameter (Req, "maxExpiryTimeInMins", Max_Expiry_Time_In_Mins);
Server.Get_Json_Web_Token
(Expiry_Time_In_Mins,
Max_Expiry_Time_In_Mins, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Json_Web_Token;
package API_Get_Json_Web_Token is
new Swagger.Servers.Operation (Handler => Get_Json_Web_Token,
Method => Swagger.Servers.GET,
URI => "/jwt-auth/token");
--
procedure Get_Organisation
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Result : .Models.Organisation_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Organization);
Server.Get_Organisation
(Organization, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Organisation;
package API_Get_Organisation is
new Swagger.Servers.Operation (Handler => Get_Organisation,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}");
--
procedure Get_Organisations
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Result : .Models.Organisations_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Server.Get_Organisations (Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Organisations;
package API_Get_Organisations is
new Swagger.Servers.Operation (Handler => Get_Organisations,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/");
--
procedure Get_Pipeline
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Result : .Models.Pipeline_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Pipeline);
Server.Get_Pipeline
(Organization,
Pipeline, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline;
package API_Get_Pipeline is
new Swagger.Servers.Operation (Handler => Get_Pipeline,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}");
--
procedure Get_Pipeline_Activities
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Result : .Models.PipelineActivities_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Pipeline);
Server.Get_Pipeline_Activities
(Organization,
Pipeline, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Activities;
package API_Get_Pipeline_Activities is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Activities,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/activities");
--
procedure Get_Pipeline_Branch
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Branch : Swagger.UString;
Result : .Models.BranchImpl_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Branch);
Server.Get_Pipeline_Branch
(Organization,
Pipeline,
Branch, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Branch;
package API_Get_Pipeline_Branch is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Branch,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/branches/{branch}/");
--
procedure Get_Pipeline_Branch_Run
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Branch : Swagger.UString;
Run : Swagger.UString;
Result : .Models.PipelineRun_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 4, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 4, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 4, Branch);
Swagger.Servers.Get_Path_Parameter (Req, 4, Run);
Server.Get_Pipeline_Branch_Run
(Organization,
Pipeline,
Branch,
Run, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Branch_Run;
package API_Get_Pipeline_Branch_Run is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Branch_Run,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/branches/{branch}/runs/{run}");
--
procedure Get_Pipeline_Branches
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Result : .Models.MultibranchPipeline_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Pipeline);
Server.Get_Pipeline_Branches
(Organization,
Pipeline, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Branches;
package API_Get_Pipeline_Branches is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Branches,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/branches");
--
procedure Get_Pipeline_Folder
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Folder : Swagger.UString;
Result : .Models.PipelineFolderImpl_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Folder);
Server.Get_Pipeline_Folder
(Organization,
Folder, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Folder;
package API_Get_Pipeline_Folder is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Folder,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{folder}/");
--
procedure Get_Pipeline_Folder_Pipeline
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Folder : Swagger.UString;
Result : .Models.PipelineImpl_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Folder);
Server.Get_Pipeline_Folder_Pipeline
(Organization,
Pipeline,
Folder, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Folder_Pipeline;
package API_Get_Pipeline_Folder_Pipeline is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Folder_Pipeline,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{folder}/pipelines/{pipeline}");
--
procedure Get_Pipeline_Queue
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Result : .Models.PipelineQueue_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Pipeline);
Server.Get_Pipeline_Queue
(Organization,
Pipeline, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Queue;
package API_Get_Pipeline_Queue is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Queue,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/queue");
--
procedure Get_Pipeline_Run
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Result : .Models.PipelineRun_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Run);
Server.Get_Pipeline_Run
(Organization,
Pipeline,
Run, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Run;
package API_Get_Pipeline_Run is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Run,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}");
--
procedure Get_Pipeline_Run_Log
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Start : Swagger.Nullable_Integer;
Download : Swagger.Nullable_Boolean;
Result : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "start", Start);
Swagger.Servers.Get_Query_Parameter (Req, "download", Download);
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Run);
Server.Get_Pipeline_Run_Log
(Organization,
Pipeline,
Run,
Start,
Download, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Run_Log;
package API_Get_Pipeline_Run_Log is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Run_Log,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/log");
--
procedure Get_Pipeline_Run_Node
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Node : Swagger.UString;
Result : .Models.PipelineRunNode_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 4, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 4, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 4, Run);
Swagger.Servers.Get_Path_Parameter (Req, 4, Node);
Server.Get_Pipeline_Run_Node
(Organization,
Pipeline,
Run,
Node, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Run_Node;
package API_Get_Pipeline_Run_Node is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Run_Node,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/nodes/{node}");
--
procedure Get_Pipeline_Run_Node_Step
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Node : Swagger.UString;
Step : Swagger.UString;
Result : .Models.PipelineStepImpl_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 5, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 5, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 5, Run);
Swagger.Servers.Get_Path_Parameter (Req, 5, Node);
Swagger.Servers.Get_Path_Parameter (Req, 5, Step);
Server.Get_Pipeline_Run_Node_Step
(Organization,
Pipeline,
Run,
Node,
Step, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Run_Node_Step;
package API_Get_Pipeline_Run_Node_Step is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Run_Node_Step,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/nodes/{node}/steps/{step}");
--
procedure Get_Pipeline_Run_Node_Step_Log
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Node : Swagger.UString;
Step : Swagger.UString;
Result : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 5, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 5, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 5, Run);
Swagger.Servers.Get_Path_Parameter (Req, 5, Node);
Swagger.Servers.Get_Path_Parameter (Req, 5, Step);
Server.Get_Pipeline_Run_Node_Step_Log
(Organization,
Pipeline,
Run,
Node,
Step, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Run_Node_Step_Log;
package API_Get_Pipeline_Run_Node_Step_Log is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Run_Node_Step_Log,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/nodes/{node}/steps/{step}/log");
--
procedure Get_Pipeline_Run_Node_Steps
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Node : Swagger.UString;
Result : .Models.PipelineRunNodeSteps_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 4, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 4, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 4, Run);
Swagger.Servers.Get_Path_Parameter (Req, 4, Node);
Server.Get_Pipeline_Run_Node_Steps
(Organization,
Pipeline,
Run,
Node, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Run_Node_Steps;
package API_Get_Pipeline_Run_Node_Steps is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Run_Node_Steps,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/nodes/{node}/steps");
--
procedure Get_Pipeline_Run_Nodes
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Result : .Models.PipelineRunNodes_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Run);
Server.Get_Pipeline_Run_Nodes
(Organization,
Pipeline,
Run, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Run_Nodes;
package API_Get_Pipeline_Run_Nodes is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Run_Nodes,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/nodes");
--
procedure Get_Pipeline_Runs
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Result : .Models.PipelineRuns_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Pipeline);
Server.Get_Pipeline_Runs
(Organization,
Pipeline, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipeline_Runs;
package API_Get_Pipeline_Runs is
new Swagger.Servers.Operation (Handler => Get_Pipeline_Runs,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs");
--
procedure Get_Pipelines
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Result : .Models.Pipelines_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Organization);
Server.Get_Pipelines
(Organization, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Pipelines;
package API_Get_Pipelines is
new Swagger.Servers.Operation (Handler => Get_Pipelines,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/pipelines/");
--
procedure Get_S_C_M
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Scm : Swagger.UString;
Result : .Models.GithubScm_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Scm);
Server.Get_S_C_M
(Organization,
Scm, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_S_C_M;
package API_Get_S_C_M is
new Swagger.Servers.Operation (Handler => Get_S_C_M,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/scm/{scm}");
--
procedure Get_S_C_M_Organisation_Repositories
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Scm : Swagger.UString;
Scm_Organisation : Swagger.UString;
Credential_Id : Swagger.Nullable_UString;
Page_Size : Swagger.Nullable_Integer;
Page_Number : Swagger.Nullable_Integer;
Result : .Models.ScmOrganisations_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "credentialId", Credential_Id);
Swagger.Servers.Get_Query_Parameter (Req, "pageSize", Page_Size);
Swagger.Servers.Get_Query_Parameter (Req, "pageNumber", Page_Number);
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Scm);
Swagger.Servers.Get_Path_Parameter (Req, 3, Scm_Organisation);
Server.Get_S_C_M_Organisation_Repositories
(Organization,
Scm,
Scm_Organisation,
Credential_Id,
Page_Size,
Page_Number, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_S_C_M_Organisation_Repositories;
package API_Get_S_C_M_Organisation_Repositories is
new Swagger.Servers.Operation (Handler => Get_S_C_M_Organisation_Repositories,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/scm/{scm}/organizations/{scmOrganisation}/repositories");
--
procedure Get_S_C_M_Organisation_Repository
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Scm : Swagger.UString;
Scm_Organisation : Swagger.UString;
Repository : Swagger.UString;
Credential_Id : Swagger.Nullable_UString;
Result : .Models.ScmOrganisations_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "credentialId", Credential_Id);
Swagger.Servers.Get_Path_Parameter (Req, 4, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 4, Scm);
Swagger.Servers.Get_Path_Parameter (Req, 4, Scm_Organisation);
Swagger.Servers.Get_Path_Parameter (Req, 4, Repository);
Server.Get_S_C_M_Organisation_Repository
(Organization,
Scm,
Scm_Organisation,
Repository,
Credential_Id, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_S_C_M_Organisation_Repository;
package API_Get_S_C_M_Organisation_Repository is
new Swagger.Servers.Operation (Handler => Get_S_C_M_Organisation_Repository,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/scm/{scm}/organizations/{scmOrganisation}/repositories/{repository}");
--
procedure Get_S_C_M_Organisations
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Scm : Swagger.UString;
Credential_Id : Swagger.Nullable_UString;
Result : .Models.ScmOrganisations_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "credentialId", Credential_Id);
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Scm);
Server.Get_S_C_M_Organisations
(Organization,
Scm,
Credential_Id, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_S_C_M_Organisations;
package API_Get_S_C_M_Organisations is
new Swagger.Servers.Operation (Handler => Get_S_C_M_Organisations,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/scm/{scm}/organizations");
--
procedure Get_User
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
User : Swagger.UString;
Result : .Models.User_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, User);
Server.Get_User
(Organization,
User, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_User;
package API_Get_User is
new Swagger.Servers.Operation (Handler => Get_User,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/users/{user}");
--
procedure Get_User_Favorites
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
User : Swagger.UString;
Result : .Models.UserFavorites_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, User);
Server.Get_User_Favorites
(User, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_User_Favorites;
package API_Get_User_Favorites is
new Swagger.Servers.Operation (Handler => Get_User_Favorites,
Method => Swagger.Servers.GET,
URI => "/blue/rest/users/{user}/favorites");
--
procedure Get_Users
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Result : .Models.User_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Organization);
Server.Get_Users
(Organization, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Users;
package API_Get_Users is
new Swagger.Servers.Operation (Handler => Get_Users,
Method => Swagger.Servers.GET,
URI => "/blue/rest/organizations/{organization}/users/");
--
procedure Post_Pipeline_Run
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Result : .Models.QueueItemImpl_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Run);
Server.Post_Pipeline_Run
(Organization,
Pipeline,
Run, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Post_Pipeline_Run;
package API_Post_Pipeline_Run is
new Swagger.Servers.Operation (Handler => Post_Pipeline_Run,
Method => Swagger.Servers.POST,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/replay");
--
procedure Post_Pipeline_Runs
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Result : .Models.QueueItemImpl_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Pipeline);
Server.Post_Pipeline_Runs
(Organization,
Pipeline, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Post_Pipeline_Runs;
package API_Post_Pipeline_Runs is
new Swagger.Servers.Operation (Handler => Post_Pipeline_Runs,
Method => Swagger.Servers.POST,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs");
--
procedure Put_Pipeline_Favorite
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Input : Swagger.Value_Type;
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Body_Type : Body_Type;
Result : .Models.FavoriteImpl_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 2, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 2, Pipeline);
Swagger.Servers.Read (Req, Input);
.Models.Deserialize (Input, "Body_Type", Body_Type);
Server.Put_Pipeline_Favorite
(Organization,
Pipeline,
Body_Type, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Put_Pipeline_Favorite;
package API_Put_Pipeline_Favorite is
new Swagger.Servers.Operation (Handler => Put_Pipeline_Favorite,
Method => Swagger.Servers.PUT,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/favorite");
--
procedure Put_Pipeline_Run
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Organization : Swagger.UString;
Pipeline : Swagger.UString;
Run : Swagger.UString;
Blocking : Swagger.Nullable_UString;
Time_Out_In_Secs : Swagger.Nullable_Integer;
Result : .Models.PipelineRun_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "blocking", Blocking);
Swagger.Servers.Get_Query_Parameter (Req, "timeOutInSecs", Time_Out_In_Secs);
Swagger.Servers.Get_Path_Parameter (Req, 3, Organization);
Swagger.Servers.Get_Path_Parameter (Req, 3, Pipeline);
Swagger.Servers.Get_Path_Parameter (Req, 3, Run);
Server.Put_Pipeline_Run
(Organization,
Pipeline,
Run,
Blocking,
Time_Out_In_Secs, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Put_Pipeline_Run;
package API_Put_Pipeline_Run is
new Swagger.Servers.Operation (Handler => Put_Pipeline_Run,
Method => Swagger.Servers.PUT,
URI => "/blue/rest/organizations/{organization}/pipelines/{pipeline}/runs/{run}/stop");
--
procedure Search
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Q : Swagger.UString;
Result : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "q", Q);
Server.Search
(Q, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Search;
package API_Search is
new Swagger.Servers.Operation (Handler => Search,
Method => Swagger.Servers.GET,
URI => "/blue/rest/search/");
--
procedure Search_Classes
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Q : Swagger.UString;
Result : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "q", Q);
Server.Search_Classes
(Q, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Search_Classes;
package API_Search_Classes is
new Swagger.Servers.Operation (Handler => Search_Classes,
Method => Swagger.Servers.GET,
URI => "/blue/rest/classes/");
--
procedure Get_Computer
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Depth : Integer;
Result : .Models.ComputerSet_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "depth", Depth);
Server.Get_Computer
(Depth, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Computer;
package API_Get_Computer is
new Swagger.Servers.Operation (Handler => Get_Computer,
Method => Swagger.Servers.GET,
URI => "/computer/api/json");
--
procedure Get_Jenkins
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Result : .Models.Hudson_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Server.Get_Jenkins (Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Jenkins;
package API_Get_Jenkins is
new Swagger.Servers.Operation (Handler => Get_Jenkins,
Method => Swagger.Servers.GET,
URI => "/api/json");
--
procedure Get_Job
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Name : Swagger.UString;
Result : .Models.FreeStyleProject_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Server.Get_Job
(Name, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Job;
package API_Get_Job is
new Swagger.Servers.Operation (Handler => Get_Job,
Method => Swagger.Servers.GET,
URI => "/job/{name}/api/json");
--
procedure Get_Job_Config
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Name : Swagger.UString;
Result : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Server.Get_Job_Config
(Name, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Job_Config;
package API_Get_Job_Config is
new Swagger.Servers.Operation (Handler => Get_Job_Config,
Method => Swagger.Servers.GET,
URI => "/job/{name}/config.xml");
--
procedure Get_Job_Last_Build
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Name : Swagger.UString;
Result : .Models.FreeStyleBuild_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Server.Get_Job_Last_Build
(Name, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Job_Last_Build;
package API_Get_Job_Last_Build is
new Swagger.Servers.Operation (Handler => Get_Job_Last_Build,
Method => Swagger.Servers.GET,
URI => "/job/{name}/lastBuild/api/json");
--
procedure Get_Job_Progressive_Text
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Name : Swagger.UString;
Number : Swagger.UString;
Start : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "start", Start);
Swagger.Servers.Get_Path_Parameter (Req, 2, Name);
Swagger.Servers.Get_Path_Parameter (Req, 2, Number);
Server.Get_Job_Progressive_Text
(Name,
Number,
Start, Context);
end Get_Job_Progressive_Text;
package API_Get_Job_Progressive_Text is
new Swagger.Servers.Operation (Handler => Get_Job_Progressive_Text,
Method => Swagger.Servers.GET,
URI => "/job/{name}/{number}/logText/progressiveText");
--
procedure Get_Queue
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Result : .Models.Queue_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Server.Get_Queue (Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Queue;
package API_Get_Queue is
new Swagger.Servers.Operation (Handler => Get_Queue,
Method => Swagger.Servers.GET,
URI => "/queue/api/json");
--
procedure Get_Queue_Item
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Number : Swagger.UString;
Result : .Models.Queue_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Number);
Server.Get_Queue_Item
(Number, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_Queue_Item;
package API_Get_Queue_Item is
new Swagger.Servers.Operation (Handler => Get_Queue_Item,
Method => Swagger.Servers.GET,
URI => "/queue/item/{number}/api/json");
--
procedure Get_View
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Name : Swagger.UString;
Result : .Models.ListView_Type;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Server.Get_View
(Name, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
.Models.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_View;
package API_Get_View is
new Swagger.Servers.Operation (Handler => Get_View,
Method => Swagger.Servers.GET,
URI => "/view/{name}/api/json");
--
procedure Get_View_Config
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Name : Swagger.UString;
Result : Swagger.UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Server.Get_View_Config
(Name, Result, Context);
if Context.Get_Status = 200 then
Stream.Start_Document;
Swagger.Streams.Serialize (Stream, "", Result);
Stream.End_Document;
end if;
end Get_View_Config;
package API_Get_View_Config is
new Swagger.Servers.Operation (Handler => Get_View_Config,
Method => Swagger.Servers.GET,
URI => "/view/{name}/config.xml");
--
procedure Head_Jenkins
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Server.Head_Jenkins (Context);
end Head_Jenkins;
package API_Head_Jenkins is
new Swagger.Servers.Operation (Handler => Head_Jenkins,
Method => Swagger.Servers.HEAD,
URI => "/api/json");
--
procedure Post_Create_Item
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Input : Swagger.Value_Type;
Name : Swagger.UString;
From : Swagger.Nullable_UString;
Mode : Swagger.Nullable_UString;
Jenkins_Crumb : Swagger.Nullable_UString;
Content_Type : Swagger.Nullable_UString;
P_Body : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "name", Name);
Swagger.Servers.Get_Query_Parameter (Req, "from", From);
Swagger.Servers.Get_Query_Parameter (Req, "mode", Mode);
Swagger.Servers.Read (Req, Input);
.Models.Deserialize (Input, "body", P_Body);
Server.Post_Create_Item
(Name,
From,
Mode,
Jenkins_Crumb,
Content_Type,
P_Body, Context);
end Post_Create_Item;
package API_Post_Create_Item is
new Swagger.Servers.Operation (Handler => Post_Create_Item,
Method => Swagger.Servers.POST,
URI => "/createItem");
--
procedure Post_Create_View
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Input : Swagger.Value_Type;
Name : Swagger.UString;
Jenkins_Crumb : Swagger.Nullable_UString;
Content_Type : Swagger.Nullable_UString;
P_Body : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "name", Name);
Swagger.Servers.Read (Req, Input);
.Models.Deserialize (Input, "body", P_Body);
Server.Post_Create_View
(Name,
Jenkins_Crumb,
Content_Type,
P_Body, Context);
end Post_Create_View;
package API_Post_Create_View is
new Swagger.Servers.Operation (Handler => Post_Create_View,
Method => Swagger.Servers.POST,
URI => "/createView");
--
procedure Post_Job_Build
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Name : Swagger.UString;
Json : Swagger.UString;
Token : Swagger.Nullable_UString;
Jenkins_Crumb : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Query_Parameter (Req, "json", Json);
Swagger.Servers.Get_Query_Parameter (Req, "token", Token);
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Server.Post_Job_Build
(Name,
Json,
Token,
Jenkins_Crumb, Context);
end Post_Job_Build;
package API_Post_Job_Build is
new Swagger.Servers.Operation (Handler => Post_Job_Build,
Method => Swagger.Servers.POST,
URI => "/job/{name}/build");
--
procedure Post_Job_Config
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Input : Swagger.Value_Type;
Name : Swagger.UString;
P_Body : Swagger.UString;
Jenkins_Crumb : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Swagger.Servers.Read (Req, Input);
.Models.Deserialize (Input, "body", P_Body);
Server.Post_Job_Config
(Name,
P_Body,
Jenkins_Crumb, Context);
end Post_Job_Config;
package API_Post_Job_Config is
new Swagger.Servers.Operation (Handler => Post_Job_Config,
Method => Swagger.Servers.POST,
URI => "/job/{name}/config.xml");
--
procedure Post_Job_Delete
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Name : Swagger.UString;
Jenkins_Crumb : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Server.Post_Job_Delete
(Name,
Jenkins_Crumb, Context);
end Post_Job_Delete;
package API_Post_Job_Delete is
new Swagger.Servers.Operation (Handler => Post_Job_Delete,
Method => Swagger.Servers.POST,
URI => "/job/{name}/doDelete");
--
procedure Post_Job_Disable
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Name : Swagger.UString;
Jenkins_Crumb : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Server.Post_Job_Disable
(Name,
Jenkins_Crumb, Context);
end Post_Job_Disable;
package API_Post_Job_Disable is
new Swagger.Servers.Operation (Handler => Post_Job_Disable,
Method => Swagger.Servers.POST,
URI => "/job/{name}/disable");
--
procedure Post_Job_Enable
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Name : Swagger.UString;
Jenkins_Crumb : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Server.Post_Job_Enable
(Name,
Jenkins_Crumb, Context);
end Post_Job_Enable;
package API_Post_Job_Enable is
new Swagger.Servers.Operation (Handler => Post_Job_Enable,
Method => Swagger.Servers.POST,
URI => "/job/{name}/enable");
--
procedure Post_Job_Last_Build_Stop
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Name : Swagger.UString;
Jenkins_Crumb : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Server.Post_Job_Last_Build_Stop
(Name,
Jenkins_Crumb, Context);
end Post_Job_Last_Build_Stop;
package API_Post_Job_Last_Build_Stop is
new Swagger.Servers.Operation (Handler => Post_Job_Last_Build_Stop,
Method => Swagger.Servers.POST,
URI => "/job/{name}/lastBuild/stop");
--
procedure Post_View_Config
(Req : in out Swagger.Servers.Request'Class;
Reply : in out Swagger.Servers.Response'Class;
Stream : in out Swagger.Servers.Output_Stream'Class;
Context : in out Swagger.Servers.Context_Type) is
Input : Swagger.Value_Type;
Name : Swagger.UString;
P_Body : Swagger.UString;
Jenkins_Crumb : Swagger.Nullable_UString;
begin
if not Context.Is_Authenticated then
Context.Set_Error (401, "Not authenticated");
return;
end if;
Swagger.Servers.Get_Path_Parameter (Req, 1, Name);
Swagger.Servers.Read (Req, Input);
.Models.Deserialize (Input, "body", P_Body);
Server.Post_View_Config
(Name,
P_Body,
Jenkins_Crumb, Context);
end Post_View_Config;
package API_Post_View_Config is
new Swagger.Servers.Operation (Handler => Post_View_Config,
Method => Swagger.Servers.POST,
URI => "/view/{name}/config.xml");
procedure Register (Server : in out Swagger.Servers.Application_Type'Class) is
begin
Swagger.Servers.Register (Server, API_Get_Crumb.Definition);
Swagger.Servers.Register (Server, API_Delete_Pipeline_Queue_Item.Definition);
Swagger.Servers.Register (Server, API_Get_Authenticated_User.Definition);
Swagger.Servers.Register (Server, API_Get_Classes.Definition);
Swagger.Servers.Register (Server, API_Get_Json_Web_Key.Definition);
Swagger.Servers.Register (Server, API_Get_Json_Web_Token.Definition);
Swagger.Servers.Register (Server, API_Get_Organisation.Definition);
Swagger.Servers.Register (Server, API_Get_Organisations.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Activities.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Branch.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Branch_Run.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Branches.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Folder.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Folder_Pipeline.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Queue.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Run.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Run_Log.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Run_Node.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Run_Node_Step.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Run_Node_Step_Log.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Run_Node_Steps.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Run_Nodes.Definition);
Swagger.Servers.Register (Server, API_Get_Pipeline_Runs.Definition);
Swagger.Servers.Register (Server, API_Get_Pipelines.Definition);
Swagger.Servers.Register (Server, API_Get_S_C_M.Definition);
Swagger.Servers.Register (Server, API_Get_S_C_M_Organisation_Repositories.Definition);
Swagger.Servers.Register (Server, API_Get_S_C_M_Organisation_Repository.Definition);
Swagger.Servers.Register (Server, API_Get_S_C_M_Organisations.Definition);
Swagger.Servers.Register (Server, API_Get_User.Definition);
Swagger.Servers.Register (Server, API_Get_User_Favorites.Definition);
Swagger.Servers.Register (Server, API_Get_Users.Definition);
Swagger.Servers.Register (Server, API_Post_Pipeline_Run.Definition);
Swagger.Servers.Register (Server, API_Post_Pipeline_Runs.Definition);
Swagger.Servers.Register (Server, API_Put_Pipeline_Favorite.Definition);
Swagger.Servers.Register (Server, API_Put_Pipeline_Run.Definition);
Swagger.Servers.Register (Server, API_Search.Definition);
Swagger.Servers.Register (Server, API_Search_Classes.Definition);
Swagger.Servers.Register (Server, API_Get_Computer.Definition);
Swagger.Servers.Register (Server, API_Get_Jenkins.Definition);
Swagger.Servers.Register (Server, API_Get_Job.Definition);
Swagger.Servers.Register (Server, API_Get_Job_Config.Definition);
Swagger.Servers.Register (Server, API_Get_Job_Last_Build.Definition);
Swagger.Servers.Register (Server, API_Get_Job_Progressive_Text.Definition);
Swagger.Servers.Register (Server, API_Get_Queue.Definition);
Swagger.Servers.Register (Server, API_Get_Queue_Item.Definition);
Swagger.Servers.Register (Server, API_Get_View.Definition);
Swagger.Servers.Register (Server, API_Get_View_Config.Definition);
Swagger.Servers.Register (Server, API_Head_Jenkins.Definition);
Swagger.Servers.Register (Server, API_Post_Create_Item.Definition);
Swagger.Servers.Register (Server, API_Post_Create_View.Definition);
Swagger.Servers.Register (Server, API_Post_Job_Build.Definition);
Swagger.Servers.Register (Server, API_Post_Job_Config.Definition);
Swagger.Servers.Register (Server, API_Post_Job_Delete.Definition);
Swagger.Servers.Register (Server, API_Post_Job_Disable.Definition);
Swagger.Servers.Register (Server, API_Post_Job_Enable.Definition);
Swagger.Servers.Register (Server, API_Post_Job_Last_Build_Stop.Definition);
Swagger.Servers.Register (Server, API_Post_View_Config.Definition);
end Register;
protected body Server is
--
procedure Get_Crumb (Result : out .Models.DefaultCrumbIssuer_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Crumb (Result, Context);
end Get_Crumb;
--
procedure Delete_Pipeline_Queue_Item
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Queue : in Swagger.UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Delete_Pipeline_Queue_Item
(Organization,
Pipeline,
Queue,
Context);
end Delete_Pipeline_Queue_Item;
--
procedure Get_Authenticated_User
(Organization : in Swagger.UString;
Result : out .Models.User_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Authenticated_User
(Organization,
Result,
Context);
end Get_Authenticated_User;
--
procedure Get_Classes
(Class : in Swagger.UString;
Result : out Swagger.UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Classes
(Class,
Result,
Context);
end Get_Classes;
--
procedure Get_Json_Web_Key
(Key : in Integer;
Result : out Swagger.UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Json_Web_Key
(Key,
Result,
Context);
end Get_Json_Web_Key;
--
procedure Get_Json_Web_Token
(Expiry_Time_In_Mins : in Swagger.Nullable_Integer;
Max_Expiry_Time_In_Mins : in Swagger.Nullable_Integer;
Result : out Swagger.UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Json_Web_Token
(Expiry_Time_In_Mins,
Max_Expiry_Time_In_Mins,
Result,
Context);
end Get_Json_Web_Token;
--
procedure Get_Organisation
(Organization : in Swagger.UString;
Result : out .Models.Organisation_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Organisation
(Organization,
Result,
Context);
end Get_Organisation;
--
procedure Get_Organisations (Result : out .Models.Organisations_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Organisations (Result, Context);
end Get_Organisations;
--
procedure Get_Pipeline
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Result : out .Models.Pipeline_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline
(Organization,
Pipeline,
Result,
Context);
end Get_Pipeline;
--
procedure Get_Pipeline_Activities
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Result : out .Models.PipelineActivities_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline_Activities
(Organization,
Pipeline,
Result,
Context);
end Get_Pipeline_Activities;
--
procedure Get_Pipeline_Branch
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Branch : in Swagger.UString;
Result : out .Models.BranchImpl_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline_Branch
(Organization,
Pipeline,
Branch,
Result,
Context);
end Get_Pipeline_Branch;
--
procedure Get_Pipeline_Branch_Run
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Branch : in Swagger.UString;
Run : in Swagger.UString;
Result : out .Models.PipelineRun_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline_Branch_Run
(Organization,
Pipeline,
Branch,
Run,
Result,
Context);
end Get_Pipeline_Branch_Run;
--
procedure Get_Pipeline_Branches
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Result : out .Models.MultibranchPipeline_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline_Branches
(Organization,
Pipeline,
Result,
Context);
end Get_Pipeline_Branches;
--
procedure Get_Pipeline_Folder
(Organization : in Swagger.UString;
Folder : in Swagger.UString;
Result : out .Models.PipelineFolderImpl_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline_Folder
(Organization,
Folder,
Result,
Context);
end Get_Pipeline_Folder;
--
procedure Get_Pipeline_Folder_Pipeline
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Folder : in Swagger.UString;
Result : out .Models.PipelineImpl_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline_Folder_Pipeline
(Organization,
Pipeline,
Folder,
Result,
Context);
end Get_Pipeline_Folder_Pipeline;
--
procedure Get_Pipeline_Queue
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Result : out .Models.PipelineQueue_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline_Queue
(Organization,
Pipeline,
Result,
Context);
end Get_Pipeline_Queue;
--
procedure Get_Pipeline_Run
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Run : in Swagger.UString;
Result : out .Models.PipelineRun_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline_Run
(Organization,
Pipeline,
Run,
Result,
Context);
end Get_Pipeline_Run;
--
procedure Get_Pipeline_Run_Log
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Run : in Swagger.UString;
Start : in Swagger.Nullable_Integer;
Download : in Swagger.Nullable_Boolean;
Result : out Swagger.UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline_Run_Log
(Organization,
Pipeline,
Run,
Start,
Download,
Result,
Context);
end Get_Pipeline_Run_Log;
--
procedure Get_Pipeline_Run_Node
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Run : in Swagger.UString;
Node : in Swagger.UString;
Result : out .Models.PipelineRunNode_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline_Run_Node
(Organization,
Pipeline,
Run,
Node,
Result,
Context);
end Get_Pipeline_Run_Node;
--
procedure Get_Pipeline_Run_Node_Step
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Run : in Swagger.UString;
Node : in Swagger.UString;
Step : in Swagger.UString;
Result : out .Models.PipelineStepImpl_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline_Run_Node_Step
(Organization,
Pipeline,
Run,
Node,
Step,
Result,
Context);
end Get_Pipeline_Run_Node_Step;
--
procedure Get_Pipeline_Run_Node_Step_Log
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Run : in Swagger.UString;
Node : in Swagger.UString;
Step : in Swagger.UString;
Result : out Swagger.UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline_Run_Node_Step_Log
(Organization,
Pipeline,
Run,
Node,
Step,
Result,
Context);
end Get_Pipeline_Run_Node_Step_Log;
--
procedure Get_Pipeline_Run_Node_Steps
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Run : in Swagger.UString;
Node : in Swagger.UString;
Result : out .Models.PipelineRunNodeSteps_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline_Run_Node_Steps
(Organization,
Pipeline,
Run,
Node,
Result,
Context);
end Get_Pipeline_Run_Node_Steps;
--
procedure Get_Pipeline_Run_Nodes
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Run : in Swagger.UString;
Result : out .Models.PipelineRunNodes_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline_Run_Nodes
(Organization,
Pipeline,
Run,
Result,
Context);
end Get_Pipeline_Run_Nodes;
--
procedure Get_Pipeline_Runs
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Result : out .Models.PipelineRuns_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipeline_Runs
(Organization,
Pipeline,
Result,
Context);
end Get_Pipeline_Runs;
--
procedure Get_Pipelines
(Organization : in Swagger.UString;
Result : out .Models.Pipelines_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Pipelines
(Organization,
Result,
Context);
end Get_Pipelines;
--
procedure Get_S_C_M
(Organization : in Swagger.UString;
Scm : in Swagger.UString;
Result : out .Models.GithubScm_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_S_C_M
(Organization,
Scm,
Result,
Context);
end Get_S_C_M;
--
procedure Get_S_C_M_Organisation_Repositories
(Organization : in Swagger.UString;
Scm : in Swagger.UString;
Scm_Organisation : in Swagger.UString;
Credential_Id : in Swagger.Nullable_UString;
Page_Size : in Swagger.Nullable_Integer;
Page_Number : in Swagger.Nullable_Integer;
Result : out .Models.ScmOrganisations_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_S_C_M_Organisation_Repositories
(Organization,
Scm,
Scm_Organisation,
Credential_Id,
Page_Size,
Page_Number,
Result,
Context);
end Get_S_C_M_Organisation_Repositories;
--
procedure Get_S_C_M_Organisation_Repository
(Organization : in Swagger.UString;
Scm : in Swagger.UString;
Scm_Organisation : in Swagger.UString;
Repository : in Swagger.UString;
Credential_Id : in Swagger.Nullable_UString;
Result : out .Models.ScmOrganisations_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_S_C_M_Organisation_Repository
(Organization,
Scm,
Scm_Organisation,
Repository,
Credential_Id,
Result,
Context);
end Get_S_C_M_Organisation_Repository;
--
procedure Get_S_C_M_Organisations
(Organization : in Swagger.UString;
Scm : in Swagger.UString;
Credential_Id : in Swagger.Nullable_UString;
Result : out .Models.ScmOrganisations_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_S_C_M_Organisations
(Organization,
Scm,
Credential_Id,
Result,
Context);
end Get_S_C_M_Organisations;
--
procedure Get_User
(Organization : in Swagger.UString;
User : in Swagger.UString;
Result : out .Models.User_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_User
(Organization,
User,
Result,
Context);
end Get_User;
--
procedure Get_User_Favorites
(User : in Swagger.UString;
Result : out .Models.UserFavorites_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_User_Favorites
(User,
Result,
Context);
end Get_User_Favorites;
--
procedure Get_Users
(Organization : in Swagger.UString;
Result : out .Models.User_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Users
(Organization,
Result,
Context);
end Get_Users;
--
procedure Post_Pipeline_Run
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Run : in Swagger.UString;
Result : out .Models.QueueItemImpl_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Post_Pipeline_Run
(Organization,
Pipeline,
Run,
Result,
Context);
end Post_Pipeline_Run;
--
procedure Post_Pipeline_Runs
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Result : out .Models.QueueItemImpl_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Post_Pipeline_Runs
(Organization,
Pipeline,
Result,
Context);
end Post_Pipeline_Runs;
--
procedure Put_Pipeline_Favorite
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Body_Type : in Body_Type;
Result : out .Models.FavoriteImpl_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Put_Pipeline_Favorite
(Organization,
Pipeline,
Body_Type,
Result,
Context);
end Put_Pipeline_Favorite;
--
procedure Put_Pipeline_Run
(Organization : in Swagger.UString;
Pipeline : in Swagger.UString;
Run : in Swagger.UString;
Blocking : in Swagger.Nullable_UString;
Time_Out_In_Secs : in Swagger.Nullable_Integer;
Result : out .Models.PipelineRun_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Put_Pipeline_Run
(Organization,
Pipeline,
Run,
Blocking,
Time_Out_In_Secs,
Result,
Context);
end Put_Pipeline_Run;
--
procedure Search
(Q : in Swagger.UString;
Result : out Swagger.UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Search
(Q,
Result,
Context);
end Search;
--
procedure Search_Classes
(Q : in Swagger.UString;
Result : out Swagger.UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Search_Classes
(Q,
Result,
Context);
end Search_Classes;
--
procedure Get_Computer
(Depth : in Integer;
Result : out .Models.ComputerSet_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Computer
(Depth,
Result,
Context);
end Get_Computer;
--
procedure Get_Jenkins (Result : out .Models.Hudson_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Jenkins (Result, Context);
end Get_Jenkins;
--
procedure Get_Job
(Name : in Swagger.UString;
Result : out .Models.FreeStyleProject_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Job
(Name,
Result,
Context);
end Get_Job;
--
procedure Get_Job_Config
(Name : in Swagger.UString;
Result : out Swagger.UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Job_Config
(Name,
Result,
Context);
end Get_Job_Config;
--
procedure Get_Job_Last_Build
(Name : in Swagger.UString;
Result : out .Models.FreeStyleBuild_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Job_Last_Build
(Name,
Result,
Context);
end Get_Job_Last_Build;
--
procedure Get_Job_Progressive_Text
(Name : in Swagger.UString;
Number : in Swagger.UString;
Start : in Swagger.UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Job_Progressive_Text
(Name,
Number,
Start,
Context);
end Get_Job_Progressive_Text;
--
procedure Get_Queue (Result : out .Models.Queue_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Queue (Result, Context);
end Get_Queue;
--
procedure Get_Queue_Item
(Number : in Swagger.UString;
Result : out .Models.Queue_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_Queue_Item
(Number,
Result,
Context);
end Get_Queue_Item;
--
procedure Get_View
(Name : in Swagger.UString;
Result : out .Models.ListView_Type;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_View
(Name,
Result,
Context);
end Get_View;
--
procedure Get_View_Config
(Name : in Swagger.UString;
Result : out Swagger.UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Get_View_Config
(Name,
Result,
Context);
end Get_View_Config;
--
procedure Head_Jenkins (Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Head_Jenkins (Context);
end Head_Jenkins;
--
procedure Post_Create_Item
(Name : in Swagger.UString;
From : in Swagger.Nullable_UString;
Mode : in Swagger.Nullable_UString;
Jenkins_Crumb : in Swagger.Nullable_UString;
Content_Type : in Swagger.Nullable_UString;
P_Body : in Swagger.Nullable_UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Post_Create_Item
(Name,
From,
Mode,
Jenkins_Crumb,
Content_Type,
P_Body,
Context);
end Post_Create_Item;
--
procedure Post_Create_View
(Name : in Swagger.UString;
Jenkins_Crumb : in Swagger.Nullable_UString;
Content_Type : in Swagger.Nullable_UString;
P_Body : in Swagger.Nullable_UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Post_Create_View
(Name,
Jenkins_Crumb,
Content_Type,
P_Body,
Context);
end Post_Create_View;
--
procedure Post_Job_Build
(Name : in Swagger.UString;
Json : in Swagger.UString;
Token : in Swagger.Nullable_UString;
Jenkins_Crumb : in Swagger.Nullable_UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Post_Job_Build
(Name,
Json,
Token,
Jenkins_Crumb,
Context);
end Post_Job_Build;
--
procedure Post_Job_Config
(Name : in Swagger.UString;
P_Body : in Swagger.UString;
Jenkins_Crumb : in Swagger.Nullable_UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Post_Job_Config
(Name,
P_Body,
Jenkins_Crumb,
Context);
end Post_Job_Config;
--
procedure Post_Job_Delete
(Name : in Swagger.UString;
Jenkins_Crumb : in Swagger.Nullable_UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Post_Job_Delete
(Name,
Jenkins_Crumb,
Context);
end Post_Job_Delete;
--
procedure Post_Job_Disable
(Name : in Swagger.UString;
Jenkins_Crumb : in Swagger.Nullable_UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Post_Job_Disable
(Name,
Jenkins_Crumb,
Context);
end Post_Job_Disable;
--
procedure Post_Job_Enable
(Name : in Swagger.UString;
Jenkins_Crumb : in Swagger.Nullable_UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Post_Job_Enable
(Name,
Jenkins_Crumb,
Context);
end Post_Job_Enable;
--
procedure Post_Job_Last_Build_Stop
(Name : in Swagger.UString;
Jenkins_Crumb : in Swagger.Nullable_UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Post_Job_Last_Build_Stop
(Name,
Jenkins_Crumb,
Context);
end Post_Job_Last_Build_Stop;
--
procedure Post_View_Config
(Name : in Swagger.UString;
P_Body : in Swagger.UString;
Jenkins_Crumb : in Swagger.Nullable_UString;
Context : in out Swagger.Servers.Context_Type) is
begin
Impl.Post_View_Config
(Name,
P_Body,
Jenkins_Crumb,
Context);
end Post_View_Config;
end Server;
end Shared_Instance;
end .Skeletons;
| 40.232158 | 162 | 0.577728 |
23e4f2d35a6f54fe16ba4974039feffd2075aa27 | 13,445 | adb | Ada | contrib/ayacc/src/parser.adb | faelys/gela-asis | 48a3bee90eda9f0c9d958b4e3c80a5a9b1c65253 | [
"BSD-3-Clause"
] | 4 | 2016-02-05T15:51:56.000Z | 2022-03-25T20:38:32.000Z | lib/ayacc/parser.adb | alvaromb/Compilemon | de5f88f084705868d38e301d95bb4a19a46a1156 | [
"MIT"
] | null | null | null | lib/ayacc/parser.adb | alvaromb/Compilemon | de5f88f084705868d38e301d95bb4a19a46a1156 | [
"MIT"
] | null | null | null | -- Copyright (c) 1990 Regents of the University of California.
-- All rights reserved.
--
-- The primary authors of ayacc were David Taback and Deepak Tolani.
-- Enhancements were made by Ronald J. Schmalz.
--
-- Send requests for ayacc information to [email protected]
-- Send bug reports for ayacc to [email protected]
--
-- Redistribution and use in source and binary forms are permitted
-- provided that the above copyright notice and this paragraph are
-- duplicated in all such forms and that any documentation,
-- advertising materials, and other materials related to such
-- distribution and use acknowledge that the software was developed
-- by the University of California, Irvine. The name of the
-- University may not be used to endorse or promote products derived
-- from this software without specific prior written permission.
-- THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
-- IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
-- WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-- Module : parser_body.ada
-- Component of : ayacc
-- Version : 1.2
-- Date : 11/21/86 12:32:43
-- SCCS File : disk21~/rschm/hasee/sccs/ayacc/sccs/sxparser_body.ada
-- $Header: parser_body.a,v 0.1 86/04/01 15:10:24 ada Exp $
-- $Log: parser_body.a,v $
-- Revision 0.1 86/04/01 15:10:24 ada
-- This version fixes some minor bugs with empty grammars
-- and $$ expansion. It also uses vads5.1b enhancements
-- such as pragma inline.
--
--
-- Revision 0.0 86/02/19 18:40:31 ada
--
-- These files comprise the initial version of Ayacc
-- designed and implemented by David Taback and Deepak Tolani.
-- Ayacc has been compiled and tested under the Verdix Ada compiler
-- version 4.06 on a vax 11/750 running Unix 4.2BSD.
--
-- --
-- The body of the parser for the specification file --
-- --
with Text_IO; use Text_IO;
with Lexical_Analyzer; use Lexical_Analyzer;
with STR_Pack; use STR_Pack;
with Symbol_Table; use Symbol_Table;
with Rule_Table; use Rule_Table;
with Actions_File; use Actions_File;
with Tokens_File; use Tokens_File;
with String_Pkg;
package body Parser is
SCCS_ID : constant String := "@(#) parser_body.ada, Version 1.2";
Found_Error : Boolean := False;
Start_Defined : Boolean := False;
procedure Nonfatal_Error(Message: in String) is
begin
Print_Context_Lines;
--RJS Put_Line("--- " & Message);
New_Line;
Put_Line ("Ayacc: " & Message);
Found_Error := True;
end Nonfatal_Error;
procedure Fatal_Error(Message: in String) is
begin
Print_Context_Lines;
--RJS Put_Line("--- " & Message);
New_Line;
Put_Line ("Ayacc: " & Message);
raise Syntax_Error;
end Fatal_Error;
procedure Augment_Grammar(Users_Start_Symbol : in Grammar_Symbol) is
-- Inserts S' -> S $end as a rule in the rule table.
Start_Sym : Grammar_Symbol;
Augmented_Rule : Rule;
begin
Start_Defined := True;
Augmented_Rule := Make_Rule(Start_Symbol);
Append_RHS(Augmented_Rule, Users_Start_Symbol);
Append_RHS(Augmented_Rule, End_Symbol);
end Augment_Grammar;
-- --
-- A recursive descent parser for the rules in the --
-- grammar. --
procedure Parse_Rules is
T : Ayacc_Token;
Current_Rule : Rule;
LHS : Grammar_Symbol;
-- --
-- Gets an action from the file and writes it to --
-- the actions file. --
-- --
-- --
-- Parses a sequence of Symbols --
-- --
procedure Symbols is
ID : Grammar_Symbol;
Got_Action : Boolean := False;
Precedence_Level : Precedence;
begin
loop
T := Get_Token;
exit when T = Vertical_Bar or T = Semicolon or T = Prec;
-- Do we have an action in the middle of a rule?
if Got_Action then
Got_Action := T = Left_Brace;
Handle_Nested_Rule(Current_Rule);
end if;
case T is
-- Update the current rule
when Character_Literal =>
ID := Insert_Terminal(Get_Lexeme_Text);
Append_RHS(Current_Rule, ID);
-- Update the current rule and add to symbol table
when Identifier =>
ID := Insert_Identifier(Get_Lexeme_Text);
Append_RHS(Current_Rule, ID);
-- Got an action
when Left_Brace =>
Handle_Action(Integer(Current_Rule),
Integer(Length_of(Current_Rule)));
Got_Action := True;
when others =>
Fatal_Error("Unexpected symbol");
end case;
end loop;
if T = Prec then
if Got_Action then
Fatal_Error("%prec cannot be preceded by an action");
raise Syntax_Error;
end if;
T := Get_Token;
if T /= Identifier and T /= Character_Literal then
Fatal_Error("Expecting a terminal after %prec");
end if;
ID := Insert_Identifier(Get_Lexeme_Text);
if Is_Nonterminal(ID) then
Fatal_Error("Expecting a terminal after %prec");
end if;
Precedence_Level := Get_Precedence(ID);
if Precedence_Level = 0 then
Fatal_Error("Terminal following %prec has no precedence");
else
Set_Rule_Precedence(Current_Rule, Precedence_Level);
end if;
T := Get_Token;
case T is
when Left_Brace =>
Handle_Action(Integer(Current_Rule),
Integer(Length_of(Current_Rule)));
T := Get_Token;
when Semicolon | Vertical_Bar =>
null;
when others =>
Fatal_Error("Illegal token following %prec");
end case;
end if;
end Symbols;
-- --
-- Parse an Ayacc grammar rule --
-- --
procedure Rule is
begin
T := Get_Token;
if T /= Colon then
Fatal_Error("Expecting a colon after the LHS of the rule");
else
Current_Rule := Make_Rule(LHS);
Symbols;
end if;
while (T = Vertical_Bar) loop
-- Make a new rule with the current LHS grammar symbol
Current_Rule := Make_Rule(LHS);
Symbols;
end loop;
if T /= Semicolon then
Fatal_Error("Expecting a semicolon");
end if;
end Rule;
-- --
-- Parse a sequence of grammar rules --
-- --
procedure Rules is
begin
T := Get_Token;
if T = Identifier then
-- Make the left hand side of the rule
LHS := Insert_Identifier(Get_Lexeme_Text);
if Is_Terminal(LHS) then
Fatal_Error("Terminals cannot be on the LHS of a rule");
end if;
if not Start_Defined then
Augment_Grammar(LHS);
end if;
Rule;
Rules;
elsif T /= Mark then
Fatal_Error("Expecting next section");
end if;
end Rules;
begin -- parse_rules
Actions_File.Initialize;
Rules;
Actions_File.Finish;
-- Check for empty grammars. If the grammar is empty then
-- create a rule S -> $end.
if not Start_Defined then
Append_RHS(Make_Rule(Start_Symbol), End_Symbol);
end if;
exception
when Illegal_Token =>
Fatal_Error("illegal token");
end Parse_Rules;
-- --
-- Parse the declarations section of the source --
-- --
procedure Parse_Declarations is
Precedence_Level : Precedence := 0;
Next_Token : Ayacc_Token;
ID : Grammar_Symbol;
procedure Parse_Start_Symbol is
Users_Start_Symbol : Grammar_Symbol;
begin
if Start_Defined then
Fatal_Error("The start symbol has been defined already.");
end if;
if Next_Token /= Identifier then
if Next_Token = Lexical_Analyzer.Eof_Token then
Fatal_Error("Unexpected end of file before first '%%'");
else
Fatal_Error("Expecting identifier");
end if;
end if;
Users_Start_Symbol := Insert_Identifier(Get_Lexeme_Text);
if Is_Nonterminal(Users_Start_Symbol) then
Augment_Grammar(Users_Start_Symbol);
else
Fatal_Error("Attempt to define terminal as start_symbol");
end if;
Next_Token := Get_Token;
end Parse_Start_Symbol;
procedure Parse_Token_List(Precedence_Value : in Precedence;
Associativity_Value : in Associativity) is
Temp_Sym : Grammar_Symbol;
begin
loop
if Next_Token /= Identifier and then
Next_Token /= Character_Literal then
if Next_Token = Lexical_Analyzer.Eof_Token then
Fatal_Error("Unexpected end of file before first '%%'");
else
Fatal_Error("Expecting token declaration");
end if;
end if;
Temp_Sym := Insert_Terminal(Get_Lexeme_Text,
Precedence_Value,
Associativity_Value);
Next_Token := Get_Token;
if Next_Token = Comma then
Next_Token := Get_Token;
elsif Next_Token = Semicolon then
Next_Token := Get_Token;
exit;
elsif Next_Token /= Identifier and then
Next_Token /= Character_Literal then
exit;
end if;
end loop;
exception
when Illegal_Entry =>
-- I think only trying to insert the "start symbol"
-- in a token list will cause this exception
Fatal_Error("Illegal symbol as token");
end Parse_Token_List;
procedure Parse_Package_Name_List(Context_Clause : in Ayacc_Token) is
use String_Pkg;
begin
if Tokens_Package_Header_Has_Been_Generated then
Fatal_Error ("Context Clause Specifications May Not " &
"Appear After Ada Declarations.");
else
case Context_Clause is
when With_Clause =>
Tokens_File.Write ("with ");
when Use_Clause =>
Tokens_File.Write ("use ");
when others =>
Fatal_Error ("Illegal Context Clause Specification");
end case;
loop
if Next_Token /= Identifier then
if Next_Token = Lexical_Analyzer.Eof_Token then
Fatal_Error("Unexpected end of file before first '%%'");
else
Fatal_Error("Expecting Package Name");
end if;
end if;
Tokens_File.Write (' ' & Value (Mixed (Get_Lexeme_Text)));
Next_Token := Get_Token;
if Next_Token = Comma then
Next_Token := Get_Token;
Tokens_File.Write (",");
elsif Next_Token = Semicolon then
Next_Token := Get_Token;
Tokens_File.Writeln (";");
exit;
elsif Next_Token /= Identifier then
Tokens_File.Writeln (";");
exit;
else
Tokens_File.Write (",");
end if;
end loop;
end if;
end Parse_Package_Name_List;
begin
Next_Token := Get_Token;
loop
case Next_Token is
when Start =>
Next_Token := Get_Token;
Parse_Start_Symbol;
if Next_Token = Semicolon then
Next_Token := Get_Token;
end if;
when Token =>
Next_Token := Get_Token;
Parse_Token_List(0, Undefined);
when Nonassoc =>
Next_Token := Get_Token;
Precedence_Level := Precedence_Level + 1;
Parse_Token_List(Precedence_Level, Nonassociative);
when Right =>
Next_Token := Get_Token;
Precedence_Level := Precedence_Level + 1;
Parse_Token_List(Precedence_Level, Right_Associative);
when Left =>
Next_Token := Get_Token;
Precedence_Level := Precedence_Level + 1;
Parse_Token_List(Precedence_Level, Left_Associative);
when Mark =>
exit;
when Lexical_Analyzer.Eof_Token =>
Fatal_Error("Unexpected end of file before first %%");
when Left_Brace =>
Start_Tokens_Package;
Dump_Declarations; -- to the TOKENS file.
Next_Token := Get_Token;
when With_Clause =>
Next_Token := Get_Token;
Parse_Package_Name_List (With_Clause);
when Use_Clause =>
Next_Token := Get_Token;
Parse_Package_Name_List (Use_Clause);
when others =>
Fatal_Error("Unexpected symbol");
end case;
end loop;
exception
when Illegal_Token =>
Fatal_Error("Bad symbol");
when Redefined_Precedence_Error =>
Fatal_Error("Attempt to redefine precedence");
end Parse_Declarations;
end Parser;
| 31.050808 | 77 | 0.576869 |
2f80961aabbd94b11a1f8c1333cb3dcda57171ff | 737 | ads | Ada | orka_simd/src/x86/gnat/fma/orka-simd-fma-singles.ads | onox/orka | 9edf99559a16ffa96dfdb208322f4d18efbcbac6 | [
"Apache-2.0"
] | 52 | 2016-07-30T23:00:28.000Z | 2022-02-05T11:54:55.000Z | orka_simd/src/x86/gnat/fma/orka-simd-fma-singles.ads | onox/orka | 9edf99559a16ffa96dfdb208322f4d18efbcbac6 | [
"Apache-2.0"
] | 79 | 2016-08-01T18:36:48.000Z | 2022-02-27T12:14:20.000Z | orka_simd/src/x86/gnat/fma/orka-simd-fma-singles.ads | onox/orka | 9edf99559a16ffa96dfdb208322f4d18efbcbac6 | [
"Apache-2.0"
] | 4 | 2018-04-28T22:36:26.000Z | 2020-11-14T23:00:29.000Z | -- SPDX-License-Identifier: Apache-2.0
--
-- Copyright (c) 2020 onox <[email protected]>
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you may not use this file except in compliance with the License.
-- You may obtain a copy of the License at
--
-- http://www.apache.org/licenses/LICENSE-2.0
--
-- Unless required by applicable law or agreed to in writing, software
-- distributed under the License is distributed on an "AS IS" BASIS,
-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-- See the License for the specific language governing permissions and
-- limitations under the License.
package Orka.SIMD.FMA.Singles is
pragma Pure;
end Orka.SIMD.FMA.Singles;
| 36.85 | 76 | 0.729986 |
50ce36174604527fdca657545f3eaf800c5623f4 | 15,012 | ads | Ada | software/hal/hpl/STM32/svd/stm32f40x/stm32_svd-dac.ads | TUM-EI-RCS/StratoX | 5fdd04e01a25efef6052376f43ce85b5bc973392 | [
"BSD-3-Clause"
] | 12 | 2017-06-08T14:19:57.000Z | 2022-03-09T02:48:59.000Z | software/hal/hpl/STM32/svd/stm32f40x/stm32_svd-dac.ads | TUM-EI-RCS/StratoX | 5fdd04e01a25efef6052376f43ce85b5bc973392 | [
"BSD-3-Clause"
] | 6 | 2017-06-08T13:13:50.000Z | 2020-05-15T09:32:43.000Z | software/hal/hpl/STM32/svd/stm32f40x/stm32_svd-dac.ads | TUM-EI-RCS/StratoX | 5fdd04e01a25efef6052376f43ce85b5bc973392 | [
"BSD-3-Clause"
] | 3 | 2017-06-30T14:05:06.000Z | 2022-02-17T12:20:45.000Z | -- This spec has been automatically generated from STM32F40x.svd
pragma Restrictions (No_Elaboration_Code);
pragma Ada_2012;
with HAL;
with System;
package STM32_SVD.DAC is
pragma Preelaborate;
---------------
-- Registers --
---------------
-----------------
-- CR_Register --
-----------------
subtype CR_TSEL1_Field is HAL.UInt3;
subtype CR_WAVE1_Field is HAL.UInt2;
subtype CR_MAMP1_Field is HAL.UInt4;
subtype CR_TSEL2_Field is HAL.UInt3;
subtype CR_WAVE2_Field is HAL.UInt2;
subtype CR_MAMP2_Field is HAL.UInt4;
-- control register
type CR_Register is record
-- DAC channel1 enable
EN1 : Boolean := False;
-- DAC channel1 output buffer disable
BOFF1 : Boolean := False;
-- DAC channel1 trigger enable
TEN1 : Boolean := False;
-- DAC channel1 trigger selection
TSEL1 : CR_TSEL1_Field := 16#0#;
-- DAC channel1 noise/triangle wave generation enable
WAVE1 : CR_WAVE1_Field := 16#0#;
-- DAC channel1 mask/amplitude selector
MAMP1 : CR_MAMP1_Field := 16#0#;
-- DAC channel1 DMA enable
DMAEN1 : Boolean := False;
-- DAC channel1 DMA Underrun Interrupt enable
DMAUDRIE1 : Boolean := False;
-- unspecified
Reserved_14_15 : HAL.UInt2 := 16#0#;
-- DAC channel2 enable
EN2 : Boolean := False;
-- DAC channel2 output buffer disable
BOFF2 : Boolean := False;
-- DAC channel2 trigger enable
TEN2 : Boolean := False;
-- DAC channel2 trigger selection
TSEL2 : CR_TSEL2_Field := 16#0#;
-- DAC channel2 noise/triangle wave generation enable
WAVE2 : CR_WAVE2_Field := 16#0#;
-- DAC channel2 mask/amplitude selector
MAMP2 : CR_MAMP2_Field := 16#0#;
-- DAC channel2 DMA enable
DMAEN2 : Boolean := False;
-- DAC channel2 DMA underrun interrupt enable
DMAUDRIE2 : Boolean := False;
-- unspecified
Reserved_30_31 : HAL.UInt2 := 16#0#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for CR_Register use record
EN1 at 0 range 0 .. 0;
BOFF1 at 0 range 1 .. 1;
TEN1 at 0 range 2 .. 2;
TSEL1 at 0 range 3 .. 5;
WAVE1 at 0 range 6 .. 7;
MAMP1 at 0 range 8 .. 11;
DMAEN1 at 0 range 12 .. 12;
DMAUDRIE1 at 0 range 13 .. 13;
Reserved_14_15 at 0 range 14 .. 15;
EN2 at 0 range 16 .. 16;
BOFF2 at 0 range 17 .. 17;
TEN2 at 0 range 18 .. 18;
TSEL2 at 0 range 19 .. 21;
WAVE2 at 0 range 22 .. 23;
MAMP2 at 0 range 24 .. 27;
DMAEN2 at 0 range 28 .. 28;
DMAUDRIE2 at 0 range 29 .. 29;
Reserved_30_31 at 0 range 30 .. 31;
end record;
----------------------
-- SWTRIGR_Register --
----------------------
--------------------
-- SWTRIGR.SWTRIG --
--------------------
-- SWTRIGR_SWTRIG array
type SWTRIGR_SWTRIG_Field_Array is array (1 .. 2) of Boolean
with Component_Size => 1, Size => 2;
-- Type definition for SWTRIGR_SWTRIG
type SWTRIGR_SWTRIG_Field
(As_Array : Boolean := False)
is record
case As_Array is
when False =>
-- SWTRIG as a value
Val : HAL.UInt2;
when True =>
-- SWTRIG as an array
Arr : SWTRIGR_SWTRIG_Field_Array;
end case;
end record
with Unchecked_Union, Size => 2;
for SWTRIGR_SWTRIG_Field use record
Val at 0 range 0 .. 1;
Arr at 0 range 0 .. 1;
end record;
-- software trigger register
type SWTRIGR_Register is record
-- Write-only. DAC channel1 software trigger
SWTRIG : SWTRIGR_SWTRIG_Field :=
(As_Array => False, Val => 16#0#);
-- unspecified
Reserved_2_31 : HAL.UInt30 := 16#0#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for SWTRIGR_Register use record
SWTRIG at 0 range 0 .. 1;
Reserved_2_31 at 0 range 2 .. 31;
end record;
----------------------
-- DHR12R1_Register --
----------------------
subtype DHR12R1_DACC1DHR_Field is HAL.UInt12;
-- channel1 12-bit right-aligned data holding register
type DHR12R1_Register is record
-- DAC channel1 12-bit right-aligned data
DACC1DHR : DHR12R1_DACC1DHR_Field := 16#0#;
-- unspecified
Reserved_12_31 : HAL.UInt20 := 16#0#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for DHR12R1_Register use record
DACC1DHR at 0 range 0 .. 11;
Reserved_12_31 at 0 range 12 .. 31;
end record;
----------------------
-- DHR12L1_Register --
----------------------
subtype DHR12L1_DACC1DHR_Field is HAL.UInt12;
-- channel1 12-bit left aligned data holding register
type DHR12L1_Register is record
-- unspecified
Reserved_0_3 : HAL.UInt4 := 16#0#;
-- DAC channel1 12-bit left-aligned data
DACC1DHR : DHR12L1_DACC1DHR_Field := 16#0#;
-- unspecified
Reserved_16_31 : HAL.Short := 16#0#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for DHR12L1_Register use record
Reserved_0_3 at 0 range 0 .. 3;
DACC1DHR at 0 range 4 .. 15;
Reserved_16_31 at 0 range 16 .. 31;
end record;
---------------------
-- DHR8R1_Register --
---------------------
subtype DHR8R1_DACC1DHR_Field is HAL.Byte;
-- channel1 8-bit right aligned data holding register
type DHR8R1_Register is record
-- DAC channel1 8-bit right-aligned data
DACC1DHR : DHR8R1_DACC1DHR_Field := 16#0#;
-- unspecified
Reserved_8_31 : HAL.UInt24 := 16#0#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for DHR8R1_Register use record
DACC1DHR at 0 range 0 .. 7;
Reserved_8_31 at 0 range 8 .. 31;
end record;
----------------------
-- DHR12R2_Register --
----------------------
subtype DHR12R2_DACC2DHR_Field is HAL.UInt12;
-- channel2 12-bit right aligned data holding register
type DHR12R2_Register is record
-- DAC channel2 12-bit right-aligned data
DACC2DHR : DHR12R2_DACC2DHR_Field := 16#0#;
-- unspecified
Reserved_12_31 : HAL.UInt20 := 16#0#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for DHR12R2_Register use record
DACC2DHR at 0 range 0 .. 11;
Reserved_12_31 at 0 range 12 .. 31;
end record;
----------------------
-- DHR12L2_Register --
----------------------
subtype DHR12L2_DACC2DHR_Field is HAL.UInt12;
-- channel2 12-bit left aligned data holding register
type DHR12L2_Register is record
-- unspecified
Reserved_0_3 : HAL.UInt4 := 16#0#;
-- DAC channel2 12-bit left-aligned data
DACC2DHR : DHR12L2_DACC2DHR_Field := 16#0#;
-- unspecified
Reserved_16_31 : HAL.Short := 16#0#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for DHR12L2_Register use record
Reserved_0_3 at 0 range 0 .. 3;
DACC2DHR at 0 range 4 .. 15;
Reserved_16_31 at 0 range 16 .. 31;
end record;
---------------------
-- DHR8R2_Register --
---------------------
subtype DHR8R2_DACC2DHR_Field is HAL.Byte;
-- channel2 8-bit right-aligned data holding register
type DHR8R2_Register is record
-- DAC channel2 8-bit right-aligned data
DACC2DHR : DHR8R2_DACC2DHR_Field := 16#0#;
-- unspecified
Reserved_8_31 : HAL.UInt24 := 16#0#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for DHR8R2_Register use record
DACC2DHR at 0 range 0 .. 7;
Reserved_8_31 at 0 range 8 .. 31;
end record;
----------------------
-- DHR12RD_Register --
----------------------
subtype DHR12RD_DACC1DHR_Field is HAL.UInt12;
subtype DHR12RD_DACC2DHR_Field is HAL.UInt12;
-- Dual DAC 12-bit right-aligned data holding register
type DHR12RD_Register is record
-- DAC channel1 12-bit right-aligned data
DACC1DHR : DHR12RD_DACC1DHR_Field := 16#0#;
-- unspecified
Reserved_12_15 : HAL.UInt4 := 16#0#;
-- DAC channel2 12-bit right-aligned data
DACC2DHR : DHR12RD_DACC2DHR_Field := 16#0#;
-- unspecified
Reserved_28_31 : HAL.UInt4 := 16#0#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for DHR12RD_Register use record
DACC1DHR at 0 range 0 .. 11;
Reserved_12_15 at 0 range 12 .. 15;
DACC2DHR at 0 range 16 .. 27;
Reserved_28_31 at 0 range 28 .. 31;
end record;
----------------------
-- DHR12LD_Register --
----------------------
subtype DHR12LD_DACC1DHR_Field is HAL.UInt12;
subtype DHR12LD_DACC2DHR_Field is HAL.UInt12;
-- DUAL DAC 12-bit left aligned data holding register
type DHR12LD_Register is record
-- unspecified
Reserved_0_3 : HAL.UInt4 := 16#0#;
-- DAC channel1 12-bit left-aligned data
DACC1DHR : DHR12LD_DACC1DHR_Field := 16#0#;
-- unspecified
Reserved_16_19 : HAL.UInt4 := 16#0#;
-- DAC channel2 12-bit left-aligned data
DACC2DHR : DHR12LD_DACC2DHR_Field := 16#0#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for DHR12LD_Register use record
Reserved_0_3 at 0 range 0 .. 3;
DACC1DHR at 0 range 4 .. 15;
Reserved_16_19 at 0 range 16 .. 19;
DACC2DHR at 0 range 20 .. 31;
end record;
---------------------
-- DHR8RD_Register --
---------------------
subtype DHR8RD_DACC1DHR_Field is HAL.Byte;
subtype DHR8RD_DACC2DHR_Field is HAL.Byte;
-- DUAL DAC 8-bit right aligned data holding register
type DHR8RD_Register is record
-- DAC channel1 8-bit right-aligned data
DACC1DHR : DHR8RD_DACC1DHR_Field := 16#0#;
-- DAC channel2 8-bit right-aligned data
DACC2DHR : DHR8RD_DACC2DHR_Field := 16#0#;
-- unspecified
Reserved_16_31 : HAL.Short := 16#0#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for DHR8RD_Register use record
DACC1DHR at 0 range 0 .. 7;
DACC2DHR at 0 range 8 .. 15;
Reserved_16_31 at 0 range 16 .. 31;
end record;
-------------------
-- DOR1_Register --
-------------------
subtype DOR1_DACC1DOR_Field is HAL.UInt12;
-- channel1 data output register
type DOR1_Register is record
-- Read-only. DAC channel1 data output
DACC1DOR : DOR1_DACC1DOR_Field;
-- unspecified
Reserved_12_31 : HAL.UInt20;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for DOR1_Register use record
DACC1DOR at 0 range 0 .. 11;
Reserved_12_31 at 0 range 12 .. 31;
end record;
-------------------
-- DOR2_Register --
-------------------
subtype DOR2_DACC2DOR_Field is HAL.UInt12;
-- channel2 data output register
type DOR2_Register is record
-- Read-only. DAC channel2 data output
DACC2DOR : DOR2_DACC2DOR_Field;
-- unspecified
Reserved_12_31 : HAL.UInt20;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for DOR2_Register use record
DACC2DOR at 0 range 0 .. 11;
Reserved_12_31 at 0 range 12 .. 31;
end record;
-----------------
-- SR_Register --
-----------------
-- status register
type SR_Register is record
-- unspecified
Reserved_0_12 : HAL.UInt13 := 16#0#;
-- DAC channel1 DMA underrun flag
DMAUDR1 : Boolean := False;
-- unspecified
Reserved_14_28 : HAL.UInt15 := 16#0#;
-- DAC channel2 DMA underrun flag
DMAUDR2 : Boolean := False;
-- unspecified
Reserved_30_31 : HAL.UInt2 := 16#0#;
end record
with Volatile_Full_Access, Size => 32,
Bit_Order => System.Low_Order_First;
for SR_Register use record
Reserved_0_12 at 0 range 0 .. 12;
DMAUDR1 at 0 range 13 .. 13;
Reserved_14_28 at 0 range 14 .. 28;
DMAUDR2 at 0 range 29 .. 29;
Reserved_30_31 at 0 range 30 .. 31;
end record;
-----------------
-- Peripherals --
-----------------
-- Digital-to-analog converter
type DAC_Peripheral is record
-- control register
CR : CR_Register;
-- software trigger register
SWTRIGR : SWTRIGR_Register;
-- channel1 12-bit right-aligned data holding register
DHR12R1 : DHR12R1_Register;
-- channel1 12-bit left aligned data holding register
DHR12L1 : DHR12L1_Register;
-- channel1 8-bit right aligned data holding register
DHR8R1 : DHR8R1_Register;
-- channel2 12-bit right aligned data holding register
DHR12R2 : DHR12R2_Register;
-- channel2 12-bit left aligned data holding register
DHR12L2 : DHR12L2_Register;
-- channel2 8-bit right-aligned data holding register
DHR8R2 : DHR8R2_Register;
-- Dual DAC 12-bit right-aligned data holding register
DHR12RD : DHR12RD_Register;
-- DUAL DAC 12-bit left aligned data holding register
DHR12LD : DHR12LD_Register;
-- DUAL DAC 8-bit right aligned data holding register
DHR8RD : DHR8RD_Register;
-- channel1 data output register
DOR1 : DOR1_Register;
-- channel2 data output register
DOR2 : DOR2_Register;
-- status register
SR : SR_Register;
end record
with Volatile;
for DAC_Peripheral use record
CR at 0 range 0 .. 31;
SWTRIGR at 4 range 0 .. 31;
DHR12R1 at 8 range 0 .. 31;
DHR12L1 at 12 range 0 .. 31;
DHR8R1 at 16 range 0 .. 31;
DHR12R2 at 20 range 0 .. 31;
DHR12L2 at 24 range 0 .. 31;
DHR8R2 at 28 range 0 .. 31;
DHR12RD at 32 range 0 .. 31;
DHR12LD at 36 range 0 .. 31;
DHR8RD at 40 range 0 .. 31;
DOR1 at 44 range 0 .. 31;
DOR2 at 48 range 0 .. 31;
SR at 52 range 0 .. 31;
end record;
-- Digital-to-analog converter
DAC_Periph : aliased DAC_Peripheral
with Import, Address => DAC_Base;
end STM32_SVD.DAC;
| 31.275 | 65 | 0.581735 |
a1913a0b3e9f4718de8d500f778616503858c39f | 3,227 | ada | Ada | gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/c9/c97204a.ada | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 7 | 2020-05-02T17:34:05.000Z | 2021-10-17T10:15:18.000Z | gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/c9/c97204a.ada | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | null | null | null | gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/c9/c97204a.ada | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 2 | 2020-07-27T00:22:36.000Z | 2021-04-01T09:41:02.000Z | -- C97204A.ADA
-- Grant of Unlimited Rights
--
-- Under contracts F33600-87-D-0337, F33600-84-D-0280, MDA903-79-C-0687,
-- F08630-91-C-0015, and DCA100-97-D-0025, the U.S. Government obtained
-- unlimited rights in the software and documentation contained herein.
-- Unlimited rights are defined in DFAR 252.227-7013(a)(19). By making
-- this public release, the Government intends to confer upon all
-- recipients unlimited rights equal to those held by the Government.
-- These rights include rights to use, duplicate, release or disclose the
-- released technical data and computer software in whole or in part, in
-- any manner and for any purpose whatsoever, and to have or permit others
-- to do so.
--
-- DISCLAIMER
--
-- ALL MATERIALS OR INFORMATION HEREIN RELEASED, MADE AVAILABLE OR
-- DISCLOSED ARE AS IS. THE GOVERNMENT MAKES NO EXPRESS OR IMPLIED
-- WARRANTY AS TO ANY MATTER WHATSOEVER, INCLUDING THE CONDITIONS OF THE
-- SOFTWARE, DOCUMENTATION OR OTHER INFORMATION RELEASED, MADE AVAILABLE
-- OR DISCLOSED, OR THE OWNERSHIP, MERCHANTABILITY, OR FITNESS FOR A
-- PARTICULAR PURPOSE OF SAID MATERIAL.
--*
-- CHECK THAT THE EXCEPTION TASKING_ERROR WILL BE RAISED IF THE CALLED
-- TASK HAS ALREADY COMPLETED ITS EXECUTION AT THE TIME OF THE
-- CONDITIONAL_ENTRY_CALL.
-- RM 5/28/82
-- SPS 11/21/82
-- PWN 09/11/94 REMOVED PRAGMA PRIORITY FOR ADA 9X.
with Impdef;
WITH REPORT; USE REPORT;
WITH SYSTEM; USE SYSTEM;
PROCEDURE C97204A IS
-- THE TASK WILL HAVE HIGHER PRIORITY ( PRIORITY'LAST )
BEGIN
-------------------------------------------------------------------
TEST ("C97204A", "CHECK THAT THE EXCEPTION TASKING_ERROR WILL" &
" BE RAISED IF THE CALLED TASK HAS ALREADY" &
" COMPLETED ITS EXECUTION AT THE TIME OF THE" &
" CONDITIONAL_ENTRY_CALL" );
DECLARE
TASK TYPE T_TYPE IS
ENTRY E ;
END T_TYPE ;
T_OBJECT1 : T_TYPE ;
TASK BODY T_TYPE IS
BUSY : BOOLEAN := FALSE ;
BEGIN
NULL;
END T_TYPE ;
BEGIN
FOR I IN 1..5 LOOP
EXIT WHEN T_OBJECT1'TERMINATED ;
DELAY 10.0 * Impdef.One_Second;
END LOOP;
IF NOT T_OBJECT1'TERMINATED THEN
COMMENT( "TASK NOT YET TERMINATED (AFTER 50 S.)" );
END IF;
BEGIN
SELECT
T_OBJECT1.E ;
FAILED( "CALL WAS NOT DISOBEYED" );
ELSE
FAILED( "'ELSE' BRANCH TAKEN INSTEAD OF TSKG_ERR" );
END SELECT;
FAILED( "EXCEPTION NOT RAISED" );
EXCEPTION
WHEN TASKING_ERROR =>
NULL ;
WHEN OTHERS =>
FAILED( "WRONG EXCEPTION RAISED" );
END ;
END ;
-------------------------------------------------------------------
RESULT;
END C97204A ;
| 26.235772 | 79 | 0.53951 |
1de7c6bec9dd8804d0b9e6c6da02c91ef609caa9 | 4,172 | ads | Ada | bb-runtimes/runtimes/ravenscar-full-stm32f3x4/gnat/s-exctab.ads | JCGobbi/Nucleo-STM32F334R8 | 2a0b1b4b2664c92773703ac5e95dcb71979d051c | [
"BSD-3-Clause"
] | null | null | null | bb-runtimes/runtimes/ravenscar-full-stm32f3x4/gnat/s-exctab.ads | JCGobbi/Nucleo-STM32F334R8 | 2a0b1b4b2664c92773703ac5e95dcb71979d051c | [
"BSD-3-Clause"
] | null | null | null | bb-runtimes/runtimes/ravenscar-full-stm32f3x4/gnat/s-exctab.ads | JCGobbi/Nucleo-STM32F334R8 | 2a0b1b4b2664c92773703ac5e95dcb71979d051c | [
"BSD-3-Clause"
] | null | null | null | ------------------------------------------------------------------------------
-- --
-- GNAT COMPILER COMPONENTS --
-- --
-- S Y S T E M . E X C E P T I O N _ T A B L E --
-- --
-- S p e c --
-- --
-- Copyright (C) 1996-2021, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
-- ware Foundation; either version 3, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
-- or FITNESS FOR A PARTICULAR PURPOSE. --
-- --
-- --
-- --
-- --
-- --
-- You should have received a copy of the GNU General Public License and --
-- a copy of the GCC Runtime Library Exception along with this program; --
-- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
-- <http://www.gnu.org/licenses/>. --
-- --
-- GNAT was originally developed by the GNAT team at New York University. --
-- Extensive contributions were provided by Ada Core Technologies Inc. --
-- --
------------------------------------------------------------------------------
-- This package implements the interface used to maintain a table of
-- registered exception names, for the implementation of the mapping
-- of names to exceptions (used for exception streams and attributes)
pragma Compiler_Unit_Warning;
with System.Standard_Library;
package System.Exception_Table is
pragma Elaborate_Body;
package SSL renames System.Standard_Library;
procedure Register_Exception (X : SSL.Exception_Data_Ptr);
pragma Inline (Register_Exception);
-- Register an exception in the hash table mapping. This function is
-- called during elaboration of library packages. For exceptions that
-- are declared within subprograms, the registration occurs the first
-- time that an exception is elaborated during a call of the subprogram.
--
-- Note: all calls to Register_Exception other than those to register the
-- predefined exceptions are suppressed if the application is compiled
-- with pragma Restrictions (No_Exception_Registration).
function Internal_Exception
(X : String;
Create_If_Not_Exist : Boolean := True) return SSL.Exception_Data_Ptr;
-- Given an exception_name X, returns a pointer to the actual internal
-- exception data. A new entry is created in the table if X does not
-- exist yet and Create_If_Not_Exist is True. If it is false and X
-- does not exist yet, null is returned.
function Registered_Exceptions_Count return Natural;
-- Return the number of currently registered exceptions
type Exception_Data_Array is array (Natural range <>)
of SSL.Exception_Data_Ptr;
procedure Get_Registered_Exceptions
(List : out Exception_Data_Array;
Last : out Integer);
-- Return the list of registered exceptions
end System.Exception_Table;
| 54.894737 | 78 | 0.49257 |
2fffd2abc42c907f0b7eaedccbb9334dfa07cc14 | 24,835 | adb | Ada | source/amf/uml/amf-internals-uml_read_link_actions.adb | svn2github/matreshka | 9d222b3ad9da508855fb1f5adbe5e8a4fad4c530 | [
"BSD-3-Clause"
] | 24 | 2016-11-29T06:59:41.000Z | 2021-08-30T11:55:16.000Z | source/amf/uml/amf-internals-uml_read_link_actions.adb | svn2github/matreshka | 9d222b3ad9da508855fb1f5adbe5e8a4fad4c530 | [
"BSD-3-Clause"
] | 2 | 2019-01-16T05:15:20.000Z | 2019-02-03T10:03:32.000Z | source/amf/uml/amf-internals-uml_read_link_actions.adb | svn2github/matreshka | 9d222b3ad9da508855fb1f5adbe5e8a4fad4c530 | [
"BSD-3-Clause"
] | 4 | 2017-07-18T07:11:05.000Z | 2020-06-21T03:02:25.000Z | ------------------------------------------------------------------------------
-- --
-- Matreshka Project --
-- --
-- Ada Modeling Framework --
-- --
-- Runtime Library Component --
-- --
------------------------------------------------------------------------------
-- --
-- Copyright © 2011-2012, Vadim Godunko <[email protected]> --
-- All rights reserved. --
-- --
-- Redistribution and use in source and binary forms, with or without --
-- modification, are permitted provided that the following conditions --
-- are met: --
-- --
-- * Redistributions of source code must retain the above copyright --
-- notice, this list of conditions and the following disclaimer. --
-- --
-- * Redistributions in binary form must reproduce the above copyright --
-- notice, this list of conditions and the following disclaimer in the --
-- documentation and/or other materials provided with the distribution. --
-- --
-- * Neither the name of the Vadim Godunko, IE nor the names of its --
-- contributors may be used to endorse or promote products derived from --
-- this software without specific prior written permission. --
-- --
-- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS --
-- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT --
-- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR --
-- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT --
-- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, --
-- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED --
-- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR --
-- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF --
-- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING --
-- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS --
-- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. --
-- --
------------------------------------------------------------------------------
-- $Revision$ $Date$
------------------------------------------------------------------------------
with AMF.Elements;
with AMF.Internals.Element_Collections;
with AMF.Internals.Helpers;
with AMF.Internals.Tables.UML_Attributes;
with AMF.Visitors.UML_Iterators;
with AMF.Visitors.UML_Visitors;
with League.Strings.Internals;
with Matreshka.Internals.Strings;
package body AMF.Internals.UML_Read_Link_Actions is
-------------------
-- Enter_Element --
-------------------
overriding procedure Enter_Element
(Self : not null access constant UML_Read_Link_Action_Proxy;
Visitor : in out AMF.Visitors.Abstract_Visitor'Class;
Control : in out AMF.Visitors.Traverse_Control) is
begin
if Visitor in AMF.Visitors.UML_Visitors.UML_Visitor'Class then
AMF.Visitors.UML_Visitors.UML_Visitor'Class
(Visitor).Enter_Read_Link_Action
(AMF.UML.Read_Link_Actions.UML_Read_Link_Action_Access (Self),
Control);
end if;
end Enter_Element;
-------------------
-- Leave_Element --
-------------------
overriding procedure Leave_Element
(Self : not null access constant UML_Read_Link_Action_Proxy;
Visitor : in out AMF.Visitors.Abstract_Visitor'Class;
Control : in out AMF.Visitors.Traverse_Control) is
begin
if Visitor in AMF.Visitors.UML_Visitors.UML_Visitor'Class then
AMF.Visitors.UML_Visitors.UML_Visitor'Class
(Visitor).Leave_Read_Link_Action
(AMF.UML.Read_Link_Actions.UML_Read_Link_Action_Access (Self),
Control);
end if;
end Leave_Element;
-------------------
-- Visit_Element --
-------------------
overriding procedure Visit_Element
(Self : not null access constant UML_Read_Link_Action_Proxy;
Iterator : in out AMF.Visitors.Abstract_Iterator'Class;
Visitor : in out AMF.Visitors.Abstract_Visitor'Class;
Control : in out AMF.Visitors.Traverse_Control) is
begin
if Iterator in AMF.Visitors.UML_Iterators.UML_Iterator'Class then
AMF.Visitors.UML_Iterators.UML_Iterator'Class
(Iterator).Visit_Read_Link_Action
(Visitor,
AMF.UML.Read_Link_Actions.UML_Read_Link_Action_Access (Self),
Control);
end if;
end Visit_Element;
----------------
-- Get_Result --
----------------
overriding function Get_Result
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Output_Pins.UML_Output_Pin_Access is
begin
return
AMF.UML.Output_Pins.UML_Output_Pin_Access
(AMF.Internals.Helpers.To_Element
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Result
(Self.Element)));
end Get_Result;
----------------
-- Set_Result --
----------------
overriding procedure Set_Result
(Self : not null access UML_Read_Link_Action_Proxy;
To : AMF.UML.Output_Pins.UML_Output_Pin_Access) is
begin
AMF.Internals.Tables.UML_Attributes.Internal_Set_Result
(Self.Element,
AMF.Internals.Helpers.To_Element
(AMF.Elements.Element_Access (To)));
end Set_Result;
------------------
-- Get_End_Data --
------------------
overriding function Get_End_Data
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Link_End_Datas.Collections.Set_Of_UML_Link_End_Data is
begin
return
AMF.UML.Link_End_Datas.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_End_Data
(Self.Element)));
end Get_End_Data;
---------------------
-- Get_Input_Value --
---------------------
overriding function Get_Input_Value
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Input_Pins.Collections.Set_Of_UML_Input_Pin is
begin
return
AMF.UML.Input_Pins.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Input_Value
(Self.Element)));
end Get_Input_Value;
-----------------
-- Get_Context --
-----------------
overriding function Get_Context
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Classifiers.UML_Classifier_Access is
begin
return
AMF.UML.Classifiers.UML_Classifier_Access
(AMF.Internals.Helpers.To_Element
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Context
(Self.Element)));
end Get_Context;
---------------
-- Get_Input --
---------------
overriding function Get_Input
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Input_Pins.Collections.Ordered_Set_Of_UML_Input_Pin is
begin
return
AMF.UML.Input_Pins.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Input
(Self.Element)));
end Get_Input;
------------------------------
-- Get_Is_Locally_Reentrant --
------------------------------
overriding function Get_Is_Locally_Reentrant
(Self : not null access constant UML_Read_Link_Action_Proxy)
return Boolean is
begin
return
AMF.Internals.Tables.UML_Attributes.Internal_Get_Is_Locally_Reentrant
(Self.Element);
end Get_Is_Locally_Reentrant;
------------------------------
-- Set_Is_Locally_Reentrant --
------------------------------
overriding procedure Set_Is_Locally_Reentrant
(Self : not null access UML_Read_Link_Action_Proxy;
To : Boolean) is
begin
AMF.Internals.Tables.UML_Attributes.Internal_Set_Is_Locally_Reentrant
(Self.Element, To);
end Set_Is_Locally_Reentrant;
-----------------------------
-- Get_Local_Postcondition --
-----------------------------
overriding function Get_Local_Postcondition
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Constraints.Collections.Set_Of_UML_Constraint is
begin
return
AMF.UML.Constraints.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Local_Postcondition
(Self.Element)));
end Get_Local_Postcondition;
----------------------------
-- Get_Local_Precondition --
----------------------------
overriding function Get_Local_Precondition
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Constraints.Collections.Set_Of_UML_Constraint is
begin
return
AMF.UML.Constraints.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Local_Precondition
(Self.Element)));
end Get_Local_Precondition;
----------------
-- Get_Output --
----------------
overriding function Get_Output
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Output_Pins.Collections.Ordered_Set_Of_UML_Output_Pin is
begin
return
AMF.UML.Output_Pins.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Output
(Self.Element)));
end Get_Output;
-----------------
-- Get_Handler --
-----------------
overriding function Get_Handler
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Exception_Handlers.Collections.Set_Of_UML_Exception_Handler is
begin
return
AMF.UML.Exception_Handlers.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Handler
(Self.Element)));
end Get_Handler;
------------------
-- Get_Activity --
------------------
overriding function Get_Activity
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Activities.UML_Activity_Access is
begin
return
AMF.UML.Activities.UML_Activity_Access
(AMF.Internals.Helpers.To_Element
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Activity
(Self.Element)));
end Get_Activity;
------------------
-- Set_Activity --
------------------
overriding procedure Set_Activity
(Self : not null access UML_Read_Link_Action_Proxy;
To : AMF.UML.Activities.UML_Activity_Access) is
begin
AMF.Internals.Tables.UML_Attributes.Internal_Set_Activity
(Self.Element,
AMF.Internals.Helpers.To_Element
(AMF.Elements.Element_Access (To)));
end Set_Activity;
------------------
-- Get_In_Group --
------------------
overriding function Get_In_Group
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Activity_Groups.Collections.Set_Of_UML_Activity_Group is
begin
return
AMF.UML.Activity_Groups.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_In_Group
(Self.Element)));
end Get_In_Group;
---------------------------------
-- Get_In_Interruptible_Region --
---------------------------------
overriding function Get_In_Interruptible_Region
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Interruptible_Activity_Regions.Collections.Set_Of_UML_Interruptible_Activity_Region is
begin
return
AMF.UML.Interruptible_Activity_Regions.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_In_Interruptible_Region
(Self.Element)));
end Get_In_Interruptible_Region;
----------------------
-- Get_In_Partition --
----------------------
overriding function Get_In_Partition
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Activity_Partitions.Collections.Set_Of_UML_Activity_Partition is
begin
return
AMF.UML.Activity_Partitions.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_In_Partition
(Self.Element)));
end Get_In_Partition;
----------------------------
-- Get_In_Structured_Node --
----------------------------
overriding function Get_In_Structured_Node
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Structured_Activity_Nodes.UML_Structured_Activity_Node_Access is
begin
return
AMF.UML.Structured_Activity_Nodes.UML_Structured_Activity_Node_Access
(AMF.Internals.Helpers.To_Element
(AMF.Internals.Tables.UML_Attributes.Internal_Get_In_Structured_Node
(Self.Element)));
end Get_In_Structured_Node;
----------------------------
-- Set_In_Structured_Node --
----------------------------
overriding procedure Set_In_Structured_Node
(Self : not null access UML_Read_Link_Action_Proxy;
To : AMF.UML.Structured_Activity_Nodes.UML_Structured_Activity_Node_Access) is
begin
AMF.Internals.Tables.UML_Attributes.Internal_Set_In_Structured_Node
(Self.Element,
AMF.Internals.Helpers.To_Element
(AMF.Elements.Element_Access (To)));
end Set_In_Structured_Node;
------------------
-- Get_Incoming --
------------------
overriding function Get_Incoming
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Activity_Edges.Collections.Set_Of_UML_Activity_Edge is
begin
return
AMF.UML.Activity_Edges.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Incoming
(Self.Element)));
end Get_Incoming;
------------------
-- Get_Outgoing --
------------------
overriding function Get_Outgoing
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Activity_Edges.Collections.Set_Of_UML_Activity_Edge is
begin
return
AMF.UML.Activity_Edges.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Outgoing
(Self.Element)));
end Get_Outgoing;
------------------------
-- Get_Redefined_Node --
------------------------
overriding function Get_Redefined_Node
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Activity_Nodes.Collections.Set_Of_UML_Activity_Node is
begin
return
AMF.UML.Activity_Nodes.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Redefined_Node
(Self.Element)));
end Get_Redefined_Node;
-----------------
-- Get_Is_Leaf --
-----------------
overriding function Get_Is_Leaf
(Self : not null access constant UML_Read_Link_Action_Proxy)
return Boolean is
begin
return
AMF.Internals.Tables.UML_Attributes.Internal_Get_Is_Leaf
(Self.Element);
end Get_Is_Leaf;
-----------------
-- Set_Is_Leaf --
-----------------
overriding procedure Set_Is_Leaf
(Self : not null access UML_Read_Link_Action_Proxy;
To : Boolean) is
begin
AMF.Internals.Tables.UML_Attributes.Internal_Set_Is_Leaf
(Self.Element, To);
end Set_Is_Leaf;
---------------------------
-- Get_Redefined_Element --
---------------------------
overriding function Get_Redefined_Element
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Redefinable_Elements.Collections.Set_Of_UML_Redefinable_Element is
begin
return
AMF.UML.Redefinable_Elements.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Redefined_Element
(Self.Element)));
end Get_Redefined_Element;
------------------------------
-- Get_Redefinition_Context --
------------------------------
overriding function Get_Redefinition_Context
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Classifiers.Collections.Set_Of_UML_Classifier is
begin
return
AMF.UML.Classifiers.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Redefinition_Context
(Self.Element)));
end Get_Redefinition_Context;
---------------------------
-- Get_Client_Dependency --
---------------------------
overriding function Get_Client_Dependency
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Dependencies.Collections.Set_Of_UML_Dependency is
begin
return
AMF.UML.Dependencies.Collections.Wrap
(AMF.Internals.Element_Collections.Wrap
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Client_Dependency
(Self.Element)));
end Get_Client_Dependency;
-------------------------
-- Get_Name_Expression --
-------------------------
overriding function Get_Name_Expression
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.String_Expressions.UML_String_Expression_Access is
begin
return
AMF.UML.String_Expressions.UML_String_Expression_Access
(AMF.Internals.Helpers.To_Element
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Name_Expression
(Self.Element)));
end Get_Name_Expression;
-------------------------
-- Set_Name_Expression --
-------------------------
overriding procedure Set_Name_Expression
(Self : not null access UML_Read_Link_Action_Proxy;
To : AMF.UML.String_Expressions.UML_String_Expression_Access) is
begin
AMF.Internals.Tables.UML_Attributes.Internal_Set_Name_Expression
(Self.Element,
AMF.Internals.Helpers.To_Element
(AMF.Elements.Element_Access (To)));
end Set_Name_Expression;
-------------------
-- Get_Namespace --
-------------------
overriding function Get_Namespace
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Namespaces.UML_Namespace_Access is
begin
return
AMF.UML.Namespaces.UML_Namespace_Access
(AMF.Internals.Helpers.To_Element
(AMF.Internals.Tables.UML_Attributes.Internal_Get_Namespace
(Self.Element)));
end Get_Namespace;
------------------------
-- Get_Qualified_Name --
------------------------
overriding function Get_Qualified_Name
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.Optional_String is
begin
declare
use type Matreshka.Internals.Strings.Shared_String_Access;
Aux : constant Matreshka.Internals.Strings.Shared_String_Access
:= AMF.Internals.Tables.UML_Attributes.Internal_Get_Qualified_Name (Self.Element);
begin
if Aux = null then
return (Is_Empty => True);
else
return (False, League.Strings.Internals.Create (Aux));
end if;
end;
end Get_Qualified_Name;
-----------------
-- Association --
-----------------
overriding function Association
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Associations.UML_Association_Access is
begin
-- Generated stub: replace with real body!
pragma Compile_Time_Warning (Standard.True, "Association unimplemented");
raise Program_Error with "Unimplemented procedure UML_Read_Link_Action_Proxy.Association";
return Association (Self);
end Association;
-------------
-- Context --
-------------
overriding function Context
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Classifiers.UML_Classifier_Access is
begin
-- Generated stub: replace with real body!
pragma Compile_Time_Warning (Standard.True, "Context unimplemented");
raise Program_Error with "Unimplemented procedure UML_Read_Link_Action_Proxy.Context";
return Context (Self);
end Context;
------------------------
-- Is_Consistent_With --
------------------------
overriding function Is_Consistent_With
(Self : not null access constant UML_Read_Link_Action_Proxy;
Redefinee : AMF.UML.Redefinable_Elements.UML_Redefinable_Element_Access)
return Boolean is
begin
-- Generated stub: replace with real body!
pragma Compile_Time_Warning (Standard.True, "Is_Consistent_With unimplemented");
raise Program_Error with "Unimplemented procedure UML_Read_Link_Action_Proxy.Is_Consistent_With";
return Is_Consistent_With (Self, Redefinee);
end Is_Consistent_With;
-----------------------------------
-- Is_Redefinition_Context_Valid --
-----------------------------------
overriding function Is_Redefinition_Context_Valid
(Self : not null access constant UML_Read_Link_Action_Proxy;
Redefined : AMF.UML.Redefinable_Elements.UML_Redefinable_Element_Access)
return Boolean is
begin
-- Generated stub: replace with real body!
pragma Compile_Time_Warning (Standard.True, "Is_Redefinition_Context_Valid unimplemented");
raise Program_Error with "Unimplemented procedure UML_Read_Link_Action_Proxy.Is_Redefinition_Context_Valid";
return Is_Redefinition_Context_Valid (Self, Redefined);
end Is_Redefinition_Context_Valid;
-------------------------
-- All_Owning_Packages --
-------------------------
overriding function All_Owning_Packages
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Packages.Collections.Set_Of_UML_Package is
begin
-- Generated stub: replace with real body!
pragma Compile_Time_Warning (Standard.True, "All_Owning_Packages unimplemented");
raise Program_Error with "Unimplemented procedure UML_Read_Link_Action_Proxy.All_Owning_Packages";
return All_Owning_Packages (Self);
end All_Owning_Packages;
-----------------------------
-- Is_Distinguishable_From --
-----------------------------
overriding function Is_Distinguishable_From
(Self : not null access constant UML_Read_Link_Action_Proxy;
N : AMF.UML.Named_Elements.UML_Named_Element_Access;
Ns : AMF.UML.Namespaces.UML_Namespace_Access)
return Boolean is
begin
-- Generated stub: replace with real body!
pragma Compile_Time_Warning (Standard.True, "Is_Distinguishable_From unimplemented");
raise Program_Error with "Unimplemented procedure UML_Read_Link_Action_Proxy.Is_Distinguishable_From";
return Is_Distinguishable_From (Self, N, Ns);
end Is_Distinguishable_From;
---------------
-- Namespace --
---------------
overriding function Namespace
(Self : not null access constant UML_Read_Link_Action_Proxy)
return AMF.UML.Namespaces.UML_Namespace_Access is
begin
-- Generated stub: replace with real body!
pragma Compile_Time_Warning (Standard.True, "Namespace unimplemented");
raise Program_Error with "Unimplemented procedure UML_Read_Link_Action_Proxy.Namespace";
return Namespace (Self);
end Namespace;
end AMF.Internals.UML_Read_Link_Actions;
| 37.011923 | 114 | 0.62126 |
1d3e66028d3d8e1d999a6677c321c97991fd10c4 | 860 | adb | Ada | contrib/gnu/gdb/dist/gdb/testsuite/gdb.ada/float_param/foo.adb | TheSledgeHammer/2.11BSD | fe61f0b9aaa273783cd027c7b5ec77e95ead2153 | [
"BSD-3-Clause"
] | 3 | 2021-05-04T17:09:06.000Z | 2021-10-04T07:19:26.000Z | contrib/gnu/gdb/dist/gdb/testsuite/gdb.ada/float_param/foo.adb | TheSledgeHammer/2.11BSD | fe61f0b9aaa273783cd027c7b5ec77e95ead2153 | [
"BSD-3-Clause"
] | null | null | null | contrib/gnu/gdb/dist/gdb/testsuite/gdb.ada/float_param/foo.adb | TheSledgeHammer/2.11BSD | fe61f0b9aaa273783cd027c7b5ec77e95ead2153 | [
"BSD-3-Clause"
] | null | null | null | -- Copyright 2013-2020 Free Software Foundation, Inc.
--
-- 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 3 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, see <http://www.gnu.org/licenses/>.
with Pck; use Pck;
procedure Foo is
begin
Set_Float (1.0); -- START
Set_Double (1, 1.0);
Set_Long_Double (1, (I => 2), 1.0);
end Foo;
| 35.833333 | 73 | 0.715116 |
064d08748ba3dd6b2586fd6e7072b64f81310c85 | 2,770 | ads | Ada | boards/stm32l0_nrf24/stm32gd-board.ads | ekoeppen/STM32_Generic_Ada_Drivers | 4ff29c3026c4b24280baf22a5b81ea9969375466 | [
"MIT"
] | 1 | 2021-04-06T07:57:56.000Z | 2021-04-06T07:57:56.000Z | boards/stm32l0_nrf24/stm32gd-board.ads | ekoeppen/STM32_Generic_Ada_Drivers | 4ff29c3026c4b24280baf22a5b81ea9969375466 | [
"MIT"
] | null | null | null | boards/stm32l0_nrf24/stm32gd-board.ads | ekoeppen/STM32_Generic_Ada_Drivers | 4ff29c3026c4b24280baf22a5b81ea9969375466 | [
"MIT"
] | 2 | 2018-05-29T13:59:31.000Z | 2019-02-03T19:48:08.000Z | with STM32GD.GPIO;
with STM32GD.GPIO.Pin;
with STM32GD.USART;
with STM32GD.USART.Peripheral;
with STM32GD.SPI;
with STM32GD.SPI.Peripheral;
with STM32GD.I2C;
with STM32GD.I2C.Peripheral;
with STM32GD.GPIO;
with STM32GD.RTC;
with STM32GD.Clock;
with STM32GD.Clock.Tree;
with Drivers.Text_IO;
with Drivers.NRF24;
package STM32GD.Board is
package CLOCKS is new STM32GD.Clock.Tree;
package GPIO renames STM32GD.GPIO;
package BUTTON is new GPIO.Pin (Pin => GPIO.Pin_15, Port => GPIO.Port_C);
package LED is new GPIO.Pin (Pin => GPIO.Pin_1, Port => GPIO.Port_A, Mode => GPIO.Mode_Out);
package LED2 is new GPIO.Pin (Pin => GPIO.Pin_14, Port => GPIO.Port_C, Mode => GPIO.Mode_Out);
package SCLK is new GPIO.Pin (Pin => GPIO.Pin_5, Port => GPIO.Port_A, Mode => GPIO.Mode_AF);
package MISO is new GPIO.Pin (Pin => GPIO.Pin_6, Port => GPIO.Port_A, Mode => GPIO.Mode_AF);
package MOSI is new GPIO.Pin (Pin => GPIO.Pin_7, Port => GPIO.Port_A, Mode => GPIO.Mode_AF);
package CSN is new GPIO.Pin (Pin => GPIO.Pin_4, Port => GPIO.Port_A, Mode => GPIO.Mode_Out);
package CE is new GPIO.Pin (Pin => GPIO.Pin_1, Port => GPIO.Port_B, Mode => GPIO.Mode_Out);
package TX is new GPIO.Pin (Pin => GPIO.Pin_2, Port => GPIO.Port_A, Pull_Resistor => GPIO.Pull_Up, Mode => GPIO.Mode_AF, Alternate_Function => 4);
package RX is new GPIO.Pin (Pin => GPIO.Pin_3, Port => GPIO.Port_A, Pull_Resistor => GPIO.Pull_Up, Mode => GPIO.Mode_AF, Alternate_Function => 4);
package IRQ is new GPIO.Pin (Pin => GPIO.Pin_0, Port => GPIO.Port_A, Mode => GPIO.Mode_In);
package SCL is new GPIO.Pin (Pin => GPIO.Pin_9, Port => GPIO.Port_A, Output_Type => GPIO.Open_Drain, Mode => GPIO.Mode_AF, Alternate_Function => 1);
package SCL_OUT is new GPIO.Pin (Pin => GPIO.Pin_9, Port => GPIO.Port_A, Mode => GPIO.Mode_Out);
package SDA is new GPIO.Pin (Pin => GPIO.Pin_10, Port => GPIO.Port_A, Output_Type => GPIO.Open_Drain, Mode => GPIO.Mode_AF, Alternate_Function => 1);
package SPI is new STM32GD.SPI.Peripheral (SPI => STM32GD.SPI.SPI_1);
package USART is new STM32GD.USART.Peripheral (USART => STM32GD.USART.USART_2, Speed => 115200, Clock_Tree => CLOCKS, Clock => STM32GD.Clock.PCLK1);
package I2C is new STM32GD.I2C.Peripheral (I2C => STM32GD.I2C.I2C_1);
package RTC is new STM32GD.RTC (Clock_Tree => STM32GD.Board.Clocks, Clock => STM32GD.Clock.LSI);
package Radio is new Drivers.NRF24 (SPI => SPI, Chip_Select => CSN, Chip_Enable => CE, IRQ => IRQ);
package Text_IO is new Drivers.Text_IO (USART => STM32GD.Board.USART);
procedure Init;
procedure Enable_Peripherals;
procedure Disable_Peripherals;
end STM32GD.Board;
| 54.313725 | 158 | 0.681588 |
590fccec48e9cf4022081ca2406da0f2c40707c2 | 4,135 | ads | Ada | orka/src/orka/interface/orka-rendering-effects-filters.ads | onox/orka | 9edf99559a16ffa96dfdb208322f4d18efbcbac6 | [
"Apache-2.0"
] | 52 | 2016-07-30T23:00:28.000Z | 2022-02-05T11:54:55.000Z | orka/src/orka/interface/orka-rendering-effects-filters.ads | onox/orka | 9edf99559a16ffa96dfdb208322f4d18efbcbac6 | [
"Apache-2.0"
] | 79 | 2016-08-01T18:36:48.000Z | 2022-02-27T12:14:20.000Z | orka/src/orka/interface/orka-rendering-effects-filters.ads | onox/orka | 9edf99559a16ffa96dfdb208322f4d18efbcbac6 | [
"Apache-2.0"
] | 4 | 2018-04-28T22:36:26.000Z | 2020-11-14T23:00:29.000Z | -- SPDX-License-Identifier: Apache-2.0
--
-- Copyright (c) 2020 onox <[email protected]>
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you may not use this file except in compliance with the License.
-- You may obtain a copy of the License at
--
-- http://www.apache.org/licenses/LICENSE-2.0
--
-- Unless required by applicable law or agreed to in writing, software
-- distributed under the License is distributed on an "AS IS" BASIS,
-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-- See the License for the specific language governing permissions and
-- limitations under the License.
private with GL.Low_Level.Enums;
private with Orka.Rendering.Buffers;
private with Orka.Rendering.Programs.Uniforms;
private with Orka.Rendering.Framebuffers;
private with Orka.Types;
with GL.Objects.Textures;
with GL.Types;
with Orka.Resources.Locations;
package Orka.Rendering.Effects.Filters is
pragma Preelaborate;
use type GL.Types.Size;
function Gaussian_Kernel (Radius : GL.Types.Size) return GL.Types.Single_Array
with Pre => Radius mod 2 = 0;
type Separable_Filter is tagged limited private;
function Create_Filter
(Location : Resources.Locations.Location_Ptr;
Subject : GL.Objects.Textures.Texture;
Kernel : GL.Types.Single_Array) return Separable_Filter
with Pre => Kernel'Length mod 2 = 0;
-- Create a separable filter
--
-- The kernel must consist of a sequence of offsets, followed by a
-- sequence of weights.
procedure Render (Object : in out Separable_Filter; Passes : Positive := 1);
-- Apply the filter to the texture given to the constructor of the filter
-- in one or more passes
--
-- For better performance, it is recommended to first downsample a
-- texture to half the size (with procedure Resolve_To in the package
-- Orka.Rendering.Framebuffers) before applying the filter to it. However,
-- this can visibly reduce the quality of the image for very small kernels.
-----------------------------------------------------------------------------
type Moving_Average_Filter is tagged limited private;
function Create_Filter
(Location : Resources.Locations.Location_Ptr;
Subject : GL.Objects.Textures.Texture;
Radius : GL.Types.Size) return Moving_Average_Filter;
-- Create a filter that computes the moving average per row in a
-- compute shader for a O(1) time complexity, giving a consistent
-- performance independent of the radius
procedure Render (Object : in out Moving_Average_Filter; Passes : Positive := 2);
-- Apply the filter to the texture given to the constructor of the filter
-- in one or more passes
--
-- Passes is 2 by default to get a Gaussian blur instead of a box blur.
--
-- For better performance, it is recommended to first downsample the
-- texture. Due to the O(1) time complexity, for very large kernel this
-- filter should give better performance than the separable filter with
-- a Gaussian kernel.
private
package LE renames GL.Low_Level.Enums;
type Separable_Filter is tagged limited record
Program_Blur : Rendering.Programs.Program;
Uniform_Horizontal : Rendering.Programs.Uniforms.Uniform (LE.Bool_Type);
Buffer_Weights : Rendering.Buffers.Buffer (Types.Single_Type);
Framebuffer_H : Rendering.Framebuffers.Framebuffer (Default => False);
Framebuffer_V : Rendering.Framebuffers.Framebuffer (Default => False);
Texture_H : GL.Objects.Textures.Texture (LE.Texture_Rectangle);
Texture_V : GL.Objects.Textures.Texture (LE.Texture_Rectangle);
end record;
type Moving_Average_Filter is tagged limited record
Program_Blur : Rendering.Programs.Program;
Uniform_Horizontal : Rendering.Programs.Uniforms.Uniform (LE.Bool_Type);
Texture_H : GL.Objects.Textures.Texture (LE.Texture_Rectangle);
Texture_V : GL.Objects.Textures.Texture (LE.Texture_Rectangle);
Columns, Rows : GL.Types.UInt;
end record;
end Orka.Rendering.Effects.Filters;
| 37.93578 | 84 | 0.712938 |
a194a3cfcbc3ee46a13af2323ee48c6a1f5178fe | 1,683 | ads | Ada | source/oasis/program-elements-real_range_specifications.ads | reznikmm/gela | 20134f1d154fb763812e73860c6f4b04f353df79 | [
"MIT"
] | null | null | null | source/oasis/program-elements-real_range_specifications.ads | reznikmm/gela | 20134f1d154fb763812e73860c6f4b04f353df79 | [
"MIT"
] | null | null | null | source/oasis/program-elements-real_range_specifications.ads | reznikmm/gela | 20134f1d154fb763812e73860c6f4b04f353df79 | [
"MIT"
] | 1 | 2019-10-16T09:05:27.000Z | 2019-10-16T09:05:27.000Z | -- SPDX-FileCopyrightText: 2019 Max Reznik <[email protected]>
--
-- SPDX-License-Identifier: MIT
-------------------------------------------------------------
with Program.Elements.Definitions;
with Program.Lexical_Elements;
with Program.Elements.Expressions;
package Program.Elements.Real_Range_Specifications is
pragma Pure (Program.Elements.Real_Range_Specifications);
type Real_Range_Specification is
limited interface and Program.Elements.Definitions.Definition;
type Real_Range_Specification_Access is
access all Real_Range_Specification'Class with Storage_Size => 0;
not overriding function Lower_Bound
(Self : Real_Range_Specification)
return not null Program.Elements.Expressions.Expression_Access
is abstract;
not overriding function Upper_Bound
(Self : Real_Range_Specification)
return not null Program.Elements.Expressions.Expression_Access
is abstract;
type Real_Range_Specification_Text is limited interface;
type Real_Range_Specification_Text_Access is
access all Real_Range_Specification_Text'Class with Storage_Size => 0;
not overriding function To_Real_Range_Specification_Text
(Self : in out Real_Range_Specification)
return Real_Range_Specification_Text_Access is abstract;
not overriding function Range_Token
(Self : Real_Range_Specification_Text)
return not null Program.Lexical_Elements.Lexical_Element_Access
is abstract;
not overriding function Double_Dot_Token
(Self : Real_Range_Specification_Text)
return not null Program.Lexical_Elements.Lexical_Element_Access
is abstract;
end Program.Elements.Real_Range_Specifications;
| 33.66 | 75 | 0.768865 |
2fee5194ed762931003f43cb9e3bc191ef656914 | 8,694 | ada | Ada | gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/c4/c47009a.ada | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 7 | 2020-05-02T17:34:05.000Z | 2021-10-17T10:15:18.000Z | gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/c4/c47009a.ada | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | null | null | null | gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/c4/c47009a.ada | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 2 | 2020-07-27T00:22:36.000Z | 2021-04-01T09:41:02.000Z | -- C47009A.ADA
-- Grant of Unlimited Rights
--
-- Under contracts F33600-87-D-0337, F33600-84-D-0280, MDA903-79-C-0687,
-- F08630-91-C-0015, and DCA100-97-D-0025, the U.S. Government obtained
-- unlimited rights in the software and documentation contained herein.
-- Unlimited rights are defined in DFAR 252.227-7013(a)(19). By making
-- this public release, the Government intends to confer upon all
-- recipients unlimited rights equal to those held by the Government.
-- These rights include rights to use, duplicate, release or disclose the
-- released technical data and computer software in whole or in part, in
-- any manner and for any purpose whatsoever, and to have or permit others
-- to do so.
--
-- DISCLAIMER
--
-- ALL MATERIALS OR INFORMATION HEREIN RELEASED, MADE AVAILABLE OR
-- DISCLOSED ARE AS IS. THE GOVERNMENT MAKES NO EXPRESS OR IMPLIED
-- WARRANTY AS TO ANY MATTER WHATSOEVER, INCLUDING THE CONDITIONS OF THE
-- SOFTWARE, DOCUMENTATION OR OTHER INFORMATION RELEASED, MADE AVAILABLE
-- OR DISCLOSED, OR THE OWNERSHIP, MERCHANTABILITY, OR FITNESS FOR A
-- PARTICULAR PURPOSE OF SAID MATERIAL.
--*
-- OBJECTIVE:
-- WHEN THE TYPE MARK IN A QUALIFIED EXPRESSION DENOTES A
-- CONSTRAINED ACCESS TYPE, CHECK THAT CONSTRAINT_ERROR IS RAISED
-- WHEN THE VALUE OF THE OPERAND IS NOT NULL AND THE DESIGNATED
-- OBJECT HAS INDEX BOUNDS OR DISCRIMINANT VALUES THAT DO NOT EQUAL
-- THOSE SPECIFIED IN THE ACCESS TYPE'S CONSTRAINT.
-- HISTORY:
-- RJW 7/23/86
-- DWC 07/24/87 REVISED TO MAKE THE ACCESS TYPE UNCONSTRAINED
-- AND TO PREVENT DEAD VARIABLE OPTIMIZATION.
WITH REPORT; USE REPORT;
PROCEDURE C47009A IS
BEGIN
TEST( "C47009A", "WHEN THE TYPE MARK IN A QUALIFIED EXPRESSION " &
"DENOTES A CONSTRAINED ACCESS TYPE, CHECK " &
"THAT CONSTRAINT_ERROR IS RAISED WHEN THE " &
"VALUE OF THE OPERAND IS NOT NULL AND THE " &
"DESIGNATED OBJECT HAS INDEX BOUNDS OR " &
"DISCRIMINANT VALUES THAT DO NOT EQUAL THOSE " &
"SPECIFIED IN THE ACCESS TYPE'S CONSTRAINT" );
DECLARE
TYPE ARR IS ARRAY (NATURAL RANGE <>) OF INTEGER;
TYPE ACC1 IS ACCESS ARR;
SUBTYPE ACC1S IS ACC1 (IDENT_INT (1) .. IDENT_INT (5));
A : ACC1;
B : ARR (IDENT_INT (2) .. IDENT_INT (6));
BEGIN
A := ACC1S'(NEW ARR'(B'FIRST .. B'LAST => 0));
IF A'FIRST = 1 THEN
FAILED ( "NO EXCEPTION RAISED FOR INDEX BOUNDS " &
"DIFFERENT FROM THOSE OF TYPE ACC1 - 1" );
ELSE
FAILED ( "NO EXCEPTION RAISED FOR INDEX BOUNDS " &
"DIFFERENT FROM THOSE OF TYPE ACC1 - 2" );
END IF;
EXCEPTION
WHEN CONSTRAINT_ERROR =>
NULL;
WHEN OTHERS =>
FAILED ( "WRONG EXCEPTION RAISED FOR INDEX BOUNDS " &
"DIFFERENT FROM THOSE OF TYPE ACC1" );
END;
DECLARE
TYPE ARR IS ARRAY (NATURAL RANGE <>, NATURAL RANGE <>)
OF INTEGER;
TYPE ACC2 IS ACCESS ARR;
SUBTYPE ACC2S IS ACC2 (IDENT_INT (1) .. IDENT_INT (5),
IDENT_INT (1) .. IDENT_INT (1));
A : ACC2;
B : ARR (IDENT_INT (1) .. IDENT_INT (5),
IDENT_INT (2) .. IDENT_INT (2));
BEGIN
A := ACC2S'(NEW ARR'(B'RANGE => (B'RANGE (2) => 0)));
IF A'FIRST = 1 THEN
FAILED ( "NO EXCEPTION RAISED FOR INDEX BOUNDS " &
"DIFFERENT FROM THOSE OF TYPE ACC2 - 1" );
ELSE
FAILED ( "NO EXCEPTION RAISED FOR INDEX BOUNDS " &
"DIFFERENT FROM THOSE OF TYPE ACC2 - 2" );
END IF;
EXCEPTION
WHEN CONSTRAINT_ERROR =>
NULL;
WHEN OTHERS =>
FAILED ( "WRONG EXCEPTION RAISED FOR INDEX BOUNDS " &
"DIFFERENT FROM THOSE OF TYPE ACC2" );
END;
DECLARE
TYPE REC (D : INTEGER) IS
RECORD
NULL;
END RECORD;
TYPE ACC3 IS ACCESS REC;
SUBTYPE ACC3S IS ACC3 (IDENT_INT (3));
A : ACC3;
B : REC (IDENT_INT (5)) := (D => (IDENT_INT (5)));
BEGIN
A := ACC3S'(NEW REC'(B));
IF A = NULL THEN
FAILED ( "NO EXCEPTION RAISED FOR INDEX BOUNDS " &
"DIFFERENT FROM THOSE OF TYPE ACC3 - 1" );
ELSE
FAILED ( "NO EXCEPTION RAISED FOR INDEX BOUNDS " &
"DIFFERENT FROM THOSE OF TYPE ACC3 - 2" );
END IF;
EXCEPTION
WHEN CONSTRAINT_ERROR =>
NULL;
WHEN OTHERS =>
FAILED ( "WRONG EXCEPTION RAISED FOR INDEX BOUNDS " &
"DIFFERENT FROM THOSE OF TYPE ACC3" );
END;
DECLARE
TYPE REC (D1,D2 : INTEGER) IS
RECORD
NULL;
END RECORD;
TYPE ACC4 IS ACCESS REC;
SUBTYPE ACC4S IS ACC4 (IDENT_INT (4), IDENT_INT (5));
A : ACC4;
B : REC (IDENT_INT (5), IDENT_INT (4)) :=
(D1 => (IDENT_INT (5)), D2 => (IDENT_INT (4)));
BEGIN
A := ACC4S'(NEW REC'(B));
IF A = NULL THEN
FAILED ( "NO EXCEPTION RAISED FOR INDEX BOUNDS " &
"DIFFERENT FROM THOSE OF TYPE ACC4 - 1" );
ELSE
FAILED ( "NO EXCEPTION RAISED FOR INDEX BOUNDS " &
"DIFFERENT FROM THOSE OF TYPE ACC4 - 2" );
END IF;
EXCEPTION
WHEN CONSTRAINT_ERROR =>
NULL;
WHEN OTHERS =>
FAILED ( "WRONG EXCEPTION RAISED FOR DISC VALUES " &
"DIFFERENT FROM THOSE OF TYPE ACC4" );
END;
DECLARE
PACKAGE PKG IS
TYPE REC (D : INTEGER) IS PRIVATE;
B : CONSTANT REC;
PRIVATE
TYPE REC (D : INTEGER) IS
RECORD
NULL;
END RECORD;
B : CONSTANT REC := (D => (IDENT_INT (4)));
END PKG;
USE PKG;
TYPE ACC5 IS ACCESS REC;
SUBTYPE ACC5S IS ACC5 (IDENT_INT (3));
A : ACC5;
BEGIN
A := ACC5S'(NEW REC'(B));
IF A = NULL THEN
FAILED ( "NO EXCEPTION RAISED FOR INDEX BOUNDS " &
"DIFFERENT FROM THOSE OF TYPE ACC5 - 1" );
ELSE
FAILED ( "NO EXCEPTION RAISED FOR INDEX BOUNDS " &
"DIFFERENT FROM THOSE OF TYPE ACC5 - 2" );
END IF;
EXCEPTION
WHEN CONSTRAINT_ERROR =>
NULL;
WHEN OTHERS =>
FAILED ( "WRONG EXCEPTION RAISED FOR DISC VALUES " &
"DIFFERENT FROM THOSE OF TYPE ACC5" );
END;
DECLARE
PACKAGE PKG1 IS
TYPE REC (D : INTEGER) IS LIMITED PRIVATE;
TYPE ACC6 IS ACCESS REC;
SUBTYPE ACC6S IS ACC6 (IDENT_INT (6));
FUNCTION F RETURN ACC6;
PRIVATE
TYPE REC (D : INTEGER) IS
RECORD
NULL;
END RECORD;
END PKG1;
PACKAGE BODY PKG1 IS
FUNCTION F RETURN ACC6 IS
BEGIN
RETURN NEW REC'(D => IDENT_INT (5));
END F;
END PKG1;
PACKAGE PKG2 IS END PKG2;
PACKAGE BODY PKG2 IS
USE PKG1;
A : ACC6;
BEGIN
A := ACC6S'(F);
IF A = NULL THEN
FAILED ( "NO EXCEPTION RAISED FOR INDEX BOUNDS " &
"DIFFERENT FROM THOSE OF TYPE ACC6 - 1" );
ELSE
FAILED ( "NO EXCEPTION RAISED FOR INDEX BOUNDS " &
"DIFFERENT FROM THOSE OF TYPE ACC6 - 2" );
END IF;
EXCEPTION
WHEN CONSTRAINT_ERROR =>
NULL;
WHEN OTHERS =>
FAILED ( "WRONG EXCEPTION RAISED FOR DISC " &
"VALUES DIFFERENT FROM THOSE OF TYPE " &
"ACC6" );
END PKG2;
BEGIN
NULL;
END;
RESULT;
END C47009A;
| 34.094118 | 79 | 0.496319 |
5904f7e758c770299e9078cd40151eb1acf96bff | 38,164 | adb | Ada | apps/hls_examples/camera_ready_synthesis/app_files/big_apps_32_shifts/sharpen/sharpen/hls_target/.autopilot/db/linebuffer_Loop_1_pr.bind.adb | dillonhuff/Halide-HLS | e9f4c3ac7915e5a52f211ce65004ae17890515a0 | [
"MIT"
] | 1 | 2020-06-18T16:51:39.000Z | 2020-06-18T16:51:39.000Z | apps/hls_examples/camera_ready_synthesis/app_files/big_apps_32_shifts/sharpen/sharpen/hls_target/.autopilot/db/linebuffer_Loop_1_pr.bind.adb | dillonhuff/Halide-HLS | e9f4c3ac7915e5a52f211ce65004ae17890515a0 | [
"MIT"
] | null | null | null | apps/hls_examples/camera_ready_synthesis/app_files/big_apps_32_shifts/sharpen/sharpen/hls_target/.autopilot/db/linebuffer_Loop_1_pr.bind.adb | dillonhuff/Halide-HLS | e9f4c3ac7915e5a52f211ce65004ae17890515a0 | [
"MIT"
] | 1 | 2020-03-18T00:43:22.000Z | 2020-03-18T00:43:22.000Z | <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE boost_serialization>
<boost_serialization signature="serialization::archive" version="14">
<syndb class_id="0" tracking_level="0" version="0">
<userIPLatency>-1</userIPLatency>
<userIPName></userIPName>
<cdfg class_id="1" tracking_level="1" version="0" object_id="_0">
<name>linebuffer_Loop_1_pr</name>
<ret_bitwidth>0</ret_bitwidth>
<ports class_id="2" tracking_level="0" version="0">
<count>3</count>
<item_version>0</item_version>
<item class_id="3" tracking_level="1" version="0" object_id="_1">
<Value class_id="4" tracking_level="0" version="0">
<Obj class_id="5" tracking_level="0" version="0">
<type>1</type>
<id>1</id>
<name>in_axi_stream_V_value_V</name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo class_id="6" tracking_level="0" version="0">
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName>stream&lt;AxiPackedStencil&lt;unsigned int, 1, 1, 1, 1&gt; &gt;.V.value.V</originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<direction>0</direction>
<if_type>0</if_type>
<array_size>0</array_size>
<bit_vecs class_id="7" tracking_level="0" version="0">
<count>0</count>
<item_version>0</item_version>
</bit_vecs>
</item>
<item class_id_reference="3" object_id="_2">
<Value>
<Obj>
<type>1</type>
<id>2</id>
<name>in_axi_stream_V_last_V</name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName>stream&lt;AxiPackedStencil&lt;unsigned int, 1, 1, 1, 1&gt; &gt;.V.last.V</originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<bitwidth>1</bitwidth>
</Value>
<direction>0</direction>
<if_type>0</if_type>
<array_size>0</array_size>
<bit_vecs>
<count>0</count>
<item_version>0</item_version>
</bit_vecs>
</item>
<item class_id_reference="3" object_id="_3">
<Value>
<Obj>
<type>1</type>
<id>3</id>
<name>in_stream_V_value_V</name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName>FIFO_SRL</coreName>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<direction>1</direction>
<if_type>3</if_type>
<array_size>0</array_size>
<bit_vecs>
<count>0</count>
<item_version>0</item_version>
</bit_vecs>
</item>
</ports>
<nodes class_id="8" tracking_level="0" version="0">
<count>10</count>
<item_version>0</item_version>
<item class_id="9" tracking_level="1" version="0" object_id="_4">
<Value>
<Obj>
<type>0</type>
<id>6</id>
<name></name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>24</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_5">
<Value>
<Obj>
<type>0</type>
<id>8</id>
<name>indvar_flatten</name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<bitwidth>21</bitwidth>
</Value>
<oprand_edges>
<count>4</count>
<item_version>0</item_version>
<item>36</item>
<item>37</item>
<item>38</item>
<item>39</item>
</oprand_edges>
<opcode>phi</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_6">
<Value>
<Obj>
<type>0</type>
<id>9</id>
<name>exitcond_flatten</name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<bitwidth>1</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>40</item>
<item>42</item>
</oprand_edges>
<opcode>icmp</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_7">
<Value>
<Obj>
<type>0</type>
<id>10</id>
<name>indvar_flatten_next</name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<bitwidth>21</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>43</item>
<item>45</item>
</oprand_edges>
<opcode>add</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_8">
<Value>
<Obj>
<type>0</type>
<id>11</id>
<name></name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>3</count>
<item_version>0</item_version>
<item>46</item>
<item>47</item>
<item>48</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_9">
<Value>
<Obj>
<type>0</type>
<id>16</id>
<name>empty_16</name>
<fileName>../../../lib_files/Linebuffer.h</fileName>
<fileDirectory>/home/dhuff/Halide-HLS/apps/hls_examples/camera_ready_synthesis/app_files/big_apps_32_shifts/sharpen</fileDirectory>
<lineNumber>554</lineNumber>
<contextFuncName>linebuffer&lt;1920, 1080, 1, 1, 1, 1, 1, 1, 3, 3, 1, 1, unsigned int&gt;</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item class_id="11" tracking_level="0" version="0">
<first>/home/dhuff/Halide-HLS/apps/hls_examples/camera_ready_synthesis/app_files/big_apps_32_shifts/sharpen</first>
<second class_id="12" tracking_level="0" version="0">
<count>1</count>
<item_version>0</item_version>
<item class_id="13" tracking_level="0" version="0">
<first class_id="14" tracking_level="0" version="0">
<first>../../../lib_files/Linebuffer.h</first>
<second>linebuffer&lt;1920, 1080, 1, 1, 1, 1, 1, 1, 3, 3, 1, 1, unsigned int&gt;</second>
</first>
<second>554</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<bitwidth>33</bitwidth>
</Value>
<oprand_edges>
<count>3</count>
<item_version>0</item_version>
<item>26</item>
<item>27</item>
<item>28</item>
</oprand_edges>
<opcode>read</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_10">
<Value>
<Obj>
<type>0</type>
<id>17</id>
<name>tmp_value_V</name>
<fileName>../../../lib_files/Linebuffer.h</fileName>
<fileDirectory>/home/dhuff/Halide-HLS/apps/hls_examples/camera_ready_synthesis/app_files/big_apps_32_shifts/sharpen</fileDirectory>
<lineNumber>554</lineNumber>
<contextFuncName>linebuffer&lt;1920, 1080, 1, 1, 1, 1, 1, 1, 3, 3, 1, 1, unsigned int&gt;</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>/home/dhuff/Halide-HLS/apps/hls_examples/camera_ready_synthesis/app_files/big_apps_32_shifts/sharpen</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>../../../lib_files/Linebuffer.h</first>
<second>linebuffer&lt;1920, 1080, 1, 1, 1, 1, 1, 1, 3, 3, 1, 1, unsigned int&gt;</second>
</first>
<second>554</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName>tmp.value.V</originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>29</item>
</oprand_edges>
<opcode>extractvalue</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_11">
<Value>
<Obj>
<type>0</type>
<id>18</id>
<name></name>
<fileName>../../../lib_files/Linebuffer.h</fileName>
<fileDirectory>/home/dhuff/Halide-HLS/apps/hls_examples/camera_ready_synthesis/app_files/big_apps_32_shifts/sharpen</fileDirectory>
<lineNumber>554</lineNumber>
<contextFuncName>linebuffer&lt;1920, 1080, 1, 1, 1, 1, 1, 1, 3, 3, 1, 1, unsigned int&gt;</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>/home/dhuff/Halide-HLS/apps/hls_examples/camera_ready_synthesis/app_files/big_apps_32_shifts/sharpen</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>../../../lib_files/Linebuffer.h</first>
<second>linebuffer&lt;1920, 1080, 1, 1, 1, 1, 1, 1, 3, 3, 1, 1, unsigned int&gt;</second>
</first>
<second>554</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>3</count>
<item_version>0</item_version>
<item>31</item>
<item>32</item>
<item>33</item>
</oprand_edges>
<opcode>write</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_12">
<Value>
<Obj>
<type>0</type>
<id>20</id>
<name></name>
<fileName>../../../lib_files/Linebuffer.h</fileName>
<fileDirectory>/home/dhuff/Halide-HLS/apps/hls_examples/camera_ready_synthesis/app_files/big_apps_32_shifts/sharpen</fileDirectory>
<lineNumber>552</lineNumber>
<contextFuncName>linebuffer&lt;1920, 1080, 1, 1, 1, 1, 1, 1, 3, 3, 1, 1, unsigned int&gt;</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>/home/dhuff/Halide-HLS/apps/hls_examples/camera_ready_synthesis/app_files/big_apps_32_shifts/sharpen</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>../../../lib_files/Linebuffer.h</first>
<second>linebuffer&lt;1920, 1080, 1, 1, 1, 1, 1, 1, 3, 3, 1, 1, unsigned int&gt;</second>
</first>
<second>552</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>34</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_13">
<Value>
<Obj>
<type>0</type>
<id>22</id>
<name></name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>0</count>
<item_version>0</item_version>
</oprand_edges>
<opcode>ret</opcode>
<m_Display>0</m_Display>
</item>
</nodes>
<consts class_id="15" tracking_level="0" version="0">
<count>3</count>
<item_version>0</item_version>
<item class_id="16" tracking_level="1" version="0" object_id="_14">
<Value>
<Obj>
<type>2</type>
<id>35</id>
<name>empty</name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<bitwidth>21</bitwidth>
</Value>
<const_type>0</const_type>
<content>0</content>
</item>
<item class_id_reference="16" object_id="_15">
<Value>
<Obj>
<type>2</type>
<id>41</id>
<name>empty</name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<bitwidth>21</bitwidth>
</Value>
<const_type>0</const_type>
<content>2073600</content>
</item>
<item class_id_reference="16" object_id="_16">
<Value>
<Obj>
<type>2</type>
<id>44</id>
<name>empty</name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<bitwidth>21</bitwidth>
</Value>
<const_type>0</const_type>
<content>1</content>
</item>
</consts>
<blocks class_id="17" tracking_level="0" version="0">
<count>4</count>
<item_version>0</item_version>
<item class_id="18" tracking_level="1" version="0" object_id="_17">
<Obj>
<type>3</type>
<id>7</id>
<name>newFuncRoot</name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<node_objs>
<count>1</count>
<item_version>0</item_version>
<item>6</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_18">
<Obj>
<type>3</type>
<id>12</id>
<name>.preheader.i</name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<node_objs>
<count>4</count>
<item_version>0</item_version>
<item>8</item>
<item>9</item>
<item>10</item>
<item>11</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_19">
<Obj>
<type>3</type>
<id>21</id>
<name>.preheader4.i</name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<node_objs>
<count>4</count>
<item_version>0</item_version>
<item>16</item>
<item>17</item>
<item>18</item>
<item>20</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_20">
<Obj>
<type>3</type>
<id>23</id>
<name>.critedge.exitStub</name>
<fileName></fileName>
<fileDirectory></fileDirectory>
<lineNumber>0</lineNumber>
<contextFuncName></contextFuncName>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName></originalName>
<rtlName></rtlName>
<coreName></coreName>
</Obj>
<node_objs>
<count>1</count>
<item_version>0</item_version>
<item>22</item>
</node_objs>
</item>
</blocks>
<edges class_id="19" tracking_level="0" version="0">
<count>22</count>
<item_version>0</item_version>
<item class_id="20" tracking_level="1" version="0" object_id="_21">
<id>24</id>
<edge_type>2</edge_type>
<source_obj>12</source_obj>
<sink_obj>6</sink_obj>
</item>
<item class_id_reference="20" object_id="_22">
<id>27</id>
<edge_type>1</edge_type>
<source_obj>1</source_obj>
<sink_obj>16</sink_obj>
</item>
<item class_id_reference="20" object_id="_23">
<id>28</id>
<edge_type>1</edge_type>
<source_obj>2</source_obj>
<sink_obj>16</sink_obj>
</item>
<item class_id_reference="20" object_id="_24">
<id>29</id>
<edge_type>1</edge_type>
<source_obj>16</source_obj>
<sink_obj>17</sink_obj>
</item>
<item class_id_reference="20" object_id="_25">
<id>32</id>
<edge_type>1</edge_type>
<source_obj>3</source_obj>
<sink_obj>18</sink_obj>
</item>
<item class_id_reference="20" object_id="_26">
<id>33</id>
<edge_type>1</edge_type>
<source_obj>17</source_obj>
<sink_obj>18</sink_obj>
</item>
<item class_id_reference="20" object_id="_27">
<id>34</id>
<edge_type>2</edge_type>
<source_obj>12</source_obj>
<sink_obj>20</sink_obj>
</item>
<item class_id_reference="20" object_id="_28">
<id>36</id>
<edge_type>1</edge_type>
<source_obj>35</source_obj>
<sink_obj>8</sink_obj>
</item>
<item class_id_reference="20" object_id="_29">
<id>37</id>
<edge_type>2</edge_type>
<source_obj>7</source_obj>
<sink_obj>8</sink_obj>
</item>
<item class_id_reference="20" object_id="_30">
<id>38</id>
<edge_type>1</edge_type>
<source_obj>10</source_obj>
<sink_obj>8</sink_obj>
</item>
<item class_id_reference="20" object_id="_31">
<id>39</id>
<edge_type>2</edge_type>
<source_obj>21</source_obj>
<sink_obj>8</sink_obj>
</item>
<item class_id_reference="20" object_id="_32">
<id>40</id>
<edge_type>1</edge_type>
<source_obj>8</source_obj>
<sink_obj>9</sink_obj>
</item>
<item class_id_reference="20" object_id="_33">
<id>42</id>
<edge_type>1</edge_type>
<source_obj>41</source_obj>
<sink_obj>9</sink_obj>
</item>
<item class_id_reference="20" object_id="_34">
<id>43</id>
<edge_type>1</edge_type>
<source_obj>8</source_obj>
<sink_obj>10</sink_obj>
</item>
<item class_id_reference="20" object_id="_35">
<id>45</id>
<edge_type>1</edge_type>
<source_obj>44</source_obj>
<sink_obj>10</sink_obj>
</item>
<item class_id_reference="20" object_id="_36">
<id>46</id>
<edge_type>1</edge_type>
<source_obj>9</source_obj>
<sink_obj>11</sink_obj>
</item>
<item class_id_reference="20" object_id="_37">
<id>47</id>
<edge_type>2</edge_type>
<source_obj>21</source_obj>
<sink_obj>11</sink_obj>
</item>
<item class_id_reference="20" object_id="_38">
<id>48</id>
<edge_type>2</edge_type>
<source_obj>23</source_obj>
<sink_obj>11</sink_obj>
</item>
<item class_id_reference="20" object_id="_39">
<id>108</id>
<edge_type>2</edge_type>
<source_obj>7</source_obj>
<sink_obj>12</sink_obj>
</item>
<item class_id_reference="20" object_id="_40">
<id>109</id>
<edge_type>2</edge_type>
<source_obj>12</source_obj>
<sink_obj>23</sink_obj>
</item>
<item class_id_reference="20" object_id="_41">
<id>110</id>
<edge_type>2</edge_type>
<source_obj>12</source_obj>
<sink_obj>21</sink_obj>
</item>
<item class_id_reference="20" object_id="_42">
<id>111</id>
<edge_type>2</edge_type>
<source_obj>21</source_obj>
<sink_obj>12</sink_obj>
</item>
</edges>
</cdfg>
<cdfg_regions class_id="21" tracking_level="0" version="0">
<count>4</count>
<item_version>0</item_version>
<item class_id="22" tracking_level="1" version="0" object_id="_43">
<mId>1</mId>
<mTag>linebuffer_Loop_1_pr</mTag>
<mType>0</mType>
<sub_regions>
<count>3</count>
<item_version>0</item_version>
<item>2</item>
<item>3</item>
<item>4</item>
</sub_regions>
<basic_blocks>
<count>0</count>
<item_version>0</item_version>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>-1</mMinTripCount>
<mMaxTripCount>-1</mMaxTripCount>
<mMinLatency>2073602</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"></mDfPipe>
</item>
<item class_id_reference="22" object_id="_44">
<mId>2</mId>
<mTag>Entry</mTag>
<mType>0</mType>
<sub_regions>
<count>0</count>
<item_version>0</item_version>
</sub_regions>
<basic_blocks>
<count>1</count>
<item_version>0</item_version>
<item>7</item>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>-1</mMinTripCount>
<mMaxTripCount>-1</mMaxTripCount>
<mMinLatency>0</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"></mDfPipe>
</item>
<item class_id_reference="22" object_id="_45">
<mId>3</mId>
<mTag>Loop 1</mTag>
<mType>1</mType>
<sub_regions>
<count>0</count>
<item_version>0</item_version>
</sub_regions>
<basic_blocks>
<count>2</count>
<item_version>0</item_version>
<item>12</item>
<item>21</item>
</basic_blocks>
<mII>1</mII>
<mDepth>2</mDepth>
<mMinTripCount>2073600</mMinTripCount>
<mMaxTripCount>2073600</mMaxTripCount>
<mMinLatency>2073600</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"></mDfPipe>
</item>
<item class_id_reference="22" object_id="_46">
<mId>4</mId>
<mTag>Return</mTag>
<mType>0</mType>
<sub_regions>
<count>0</count>
<item_version>0</item_version>
</sub_regions>
<basic_blocks>
<count>1</count>
<item_version>0</item_version>
<item>23</item>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>-1</mMinTripCount>
<mMaxTripCount>-1</mMaxTripCount>
<mMinLatency>0</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"></mDfPipe>
</item>
</cdfg_regions>
<fsm class_id="24" tracking_level="1" version="0" object_id="_47">
<states class_id="25" tracking_level="0" version="0">
<count>4</count>
<item_version>0</item_version>
<item class_id="26" tracking_level="1" version="0" object_id="_48">
<id>1</id>
<operations class_id="27" tracking_level="0" version="0">
<count>3</count>
<item_version>0</item_version>
<item class_id="28" tracking_level="1" version="0" object_id="_49">
<id>4</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_50">
<id>5</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_51">
<id>6</id>
<stage>1</stage>
<latency>1</latency>
</item>
</operations>
</item>
<item class_id_reference="26" object_id="_52">
<id>2</id>
<operations>
<count>6</count>
<item_version>0</item_version>
<item class_id_reference="28" object_id="_53">
<id>8</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_54">
<id>9</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_55">
<id>10</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_56">
<id>11</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_57">
<id>16</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_58">
<id>17</id>
<stage>1</stage>
<latency>1</latency>
</item>
</operations>
</item>
<item class_id_reference="26" object_id="_59">
<id>3</id>
<operations>
<count>6</count>
<item_version>0</item_version>
<item class_id_reference="28" object_id="_60">
<id>13</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_61">
<id>14</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_62">
<id>15</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_63">
<id>18</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_64">
<id>19</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_65">
<id>20</id>
<stage>1</stage>
<latency>1</latency>
</item>
</operations>
</item>
<item class_id_reference="26" object_id="_66">
<id>4</id>
<operations>
<count>1</count>
<item_version>0</item_version>
<item class_id_reference="28" object_id="_67">
<id>22</id>
<stage>1</stage>
<latency>1</latency>
</item>
</operations>
</item>
</states>
<transitions class_id="29" tracking_level="0" version="0">
<count>4</count>
<item_version>0</item_version>
<item class_id="30" tracking_level="1" version="0" object_id="_68">
<inState>1</inState>
<outState>2</outState>
<condition class_id="31" tracking_level="0" version="0">
<id>12</id>
<sop class_id="32" tracking_level="0" version="0">
<count>1</count>
<item_version>0</item_version>
<item class_id="33" tracking_level="0" version="0">
<count>0</count>
<item_version>0</item_version>
</item>
</sop>
</condition>
</item>
<item class_id_reference="30" object_id="_69">
<inState>3</inState>
<outState>2</outState>
<condition>
<id>20</id>
<sop>
<count>1</count>
<item_version>0</item_version>
<item>
<count>0</count>
<item_version>0</item_version>
</item>
</sop>
</condition>
</item>
<item class_id_reference="30" object_id="_70">
<inState>2</inState>
<outState>4</outState>
<condition>
<id>19</id>
<sop>
<count>1</count>
<item_version>0</item_version>
<item>
<count>1</count>
<item_version>0</item_version>
<item class_id="34" tracking_level="0" version="0">
<first class_id="35" tracking_level="0" version="0">
<first>9</first>
<second>0</second>
</first>
<second>0</second>
</item>
</item>
</sop>
</condition>
</item>
<item class_id_reference="30" object_id="_71">
<inState>2</inState>
<outState>3</outState>
<condition>
<id>21</id>
<sop>
<count>1</count>
<item_version>0</item_version>
<item>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>9</first>
<second>0</second>
</first>
<second>1</second>
</item>
</item>
</sop>
</condition>
</item>
</transitions>
</fsm>
<res class_id="-1"></res>
<node_label_latency class_id="37" tracking_level="0" version="0">
<count>10</count>
<item_version>0</item_version>
<item class_id="38" tracking_level="0" version="0">
<first>6</first>
<second class_id="39" tracking_level="0" version="0">
<first>0</first>
<second>0</second>
</second>
</item>
<item>
<first>8</first>
<second>
<first>1</first>
<second>0</second>
</second>
</item>
<item>
<first>9</first>
<second>
<first>1</first>
<second>0</second>
</second>
</item>
<item>
<first>10</first>
<second>
<first>1</first>
<second>0</second>
</second>
</item>
<item>
<first>11</first>
<second>
<first>1</first>
<second>0</second>
</second>
</item>
<item>
<first>16</first>
<second>
<first>1</first>
<second>0</second>
</second>
</item>
<item>
<first>17</first>
<second>
<first>1</first>
<second>0</second>
</second>
</item>
<item>
<first>18</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>20</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>22</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
</node_label_latency>
<bblk_ent_exit class_id="40" tracking_level="0" version="0">
<count>4</count>
<item_version>0</item_version>
<item class_id="41" tracking_level="0" version="0">
<first>7</first>
<second class_id="42" tracking_level="0" version="0">
<first>0</first>
<second>0</second>
</second>
</item>
<item>
<first>12</first>
<second>
<first>1</first>
<second>1</second>
</second>
</item>
<item>
<first>21</first>
<second>
<first>1</first>
<second>2</second>
</second>
</item>
<item>
<first>23</first>
<second>
<first>2</first>
<second>2</second>
</second>
</item>
</bblk_ent_exit>
<regions class_id="43" tracking_level="0" version="0">
<count>1</count>
<item_version>0</item_version>
<item class_id="44" tracking_level="1" version="0" object_id="_72">
<region_name>Loop 1</region_name>
<basic_blocks>
<count>2</count>
<item_version>0</item_version>
<item>12</item>
<item>21</item>
</basic_blocks>
<nodes>
<count>0</count>
<item_version>0</item_version>
</nodes>
<anchor_node>-1</anchor_node>
<region_type>8</region_type>
<interval>1</interval>
<pipe_depth>2</pipe_depth>
</item>
</regions>
<dp_fu_nodes class_id="45" tracking_level="0" version="0">
<count>6</count>
<item_version>0</item_version>
<item class_id="46" tracking_level="0" version="0">
<first>48</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>16</item>
</second>
</item>
<item>
<first>56</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>18</item>
</second>
</item>
<item>
<first>67</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>8</item>
</second>
</item>
<item>
<first>74</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>9</item>
</second>
</item>
<item>
<first>80</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>10</item>
</second>
</item>
<item>
<first>86</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>17</item>
</second>
</item>
</dp_fu_nodes>
<dp_fu_nodes_expression class_id="48" tracking_level="0" version="0">
<count>4</count>
<item_version>0</item_version>
<item class_id="49" tracking_level="0" version="0">
<first>exitcond_flatten_fu_74</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>9</item>
</second>
</item>
<item>
<first>indvar_flatten_next_fu_80</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>10</item>
</second>
</item>
<item>
<first>indvar_flatten_phi_fu_67</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>8</item>
</second>
</item>
<item>
<first>tmp_value_V_fu_86</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>17</item>
</second>
</item>
</dp_fu_nodes_expression>
<dp_fu_nodes_module>
<count>0</count>
<item_version>0</item_version>
</dp_fu_nodes_module>
<dp_fu_nodes_io>
<count>2</count>
<item_version>0</item_version>
<item>
<first>StgValue_17_write_fu_56</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>18</item>
</second>
</item>
<item>
<first>empty_16_read_fu_48</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>16</item>
</second>
</item>
</dp_fu_nodes_io>
<return_ports>
<count>0</count>
<item_version>0</item_version>
</return_ports>
<dp_mem_port_nodes class_id="50" tracking_level="0" version="0">
<count>0</count>
<item_version>0</item_version>
</dp_mem_port_nodes>
<dp_reg_nodes>
<count>4</count>
<item_version>0</item_version>
<item>
<first>63</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>8</item>
</second>
</item>
<item>
<first>90</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>9</item>
</second>
</item>
<item>
<first>94</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>10</item>
</second>
</item>
<item>
<first>99</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>17</item>
</second>
</item>
</dp_reg_nodes>
<dp_regname_nodes>
<count>4</count>
<item_version>0</item_version>
<item>
<first>exitcond_flatten_reg_90</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>9</item>
</second>
</item>
<item>
<first>indvar_flatten_next_reg_94</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>10</item>
</second>
</item>
<item>
<first>indvar_flatten_reg_63</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>8</item>
</second>
</item>
<item>
<first>tmp_value_V_reg_99</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>17</item>
</second>
</item>
</dp_regname_nodes>
<dp_reg_phi>
<count>1</count>
<item_version>0</item_version>
<item>
<first>63</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>8</item>
</second>
</item>
</dp_reg_phi>
<dp_regname_phi>
<count>1</count>
<item_version>0</item_version>
<item>
<first>indvar_flatten_reg_63</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>8</item>
</second>
</item>
</dp_regname_phi>
<dp_port_io_nodes class_id="51" tracking_level="0" version="0">
<count>3</count>
<item_version>0</item_version>
<item class_id="52" tracking_level="0" version="0">
<first>in_axi_stream_V_last_V</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>read</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>16</item>
</second>
</item>
</second>
</item>
<item>
<first>in_axi_stream_V_value_V</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>read</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>16</item>
</second>
</item>
</second>
</item>
<item>
<first>in_stream_V_value_V</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>write</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>18</item>
</second>
</item>
</second>
</item>
</dp_port_io_nodes>
<port2core class_id="53" tracking_level="0" version="0">
<count>1</count>
<item_version>0</item_version>
<item class_id="54" tracking_level="0" version="0">
<first>3</first>
<second>FIFO_SRL</second>
</item>
</port2core>
<node2core>
<count>0</count>
<item_version>0</item_version>
</node2core>
</syndb>
</boost_serialization>
| 26.229553 | 137 | 0.601719 |
0bce2e3170c10475936400741bdca4edd00aa1a4 | 2,990 | adb | Ada | src/sparknacl-secretbox.adb | yannickmoy/SPARKNaCl | c27fa811bf38b3706c1dc242f30e82967ad8f1c6 | [
"BSD-2-Clause"
] | 76 | 2020-02-24T20:30:15.000Z | 2022-02-16T15:10:56.000Z | src/sparknacl-secretbox.adb | yannickmoy/SPARKNaCl | c27fa811bf38b3706c1dc242f30e82967ad8f1c6 | [
"BSD-2-Clause"
] | 10 | 2020-04-15T10:02:49.000Z | 2022-02-24T20:10:46.000Z | src/sparknacl-secretbox.adb | yannickmoy/SPARKNaCl | c27fa811bf38b3706c1dc242f30e82967ad8f1c6 | [
"BSD-2-Clause"
] | 4 | 2020-03-10T15:19:45.000Z | 2022-02-17T09:46:20.000Z | with SPARKNaCl.MAC;
package body SPARKNaCl.Secretbox
with SPARK_Mode => On
is
--------------------------------------------------------
-- Secret Key Authenticated Encryption - "SecretBox" --
--------------------------------------------------------
procedure Create (C : out Byte_Seq;
Status : out Boolean;
M : in Byte_Seq;
N : in Stream.HSalsa20_Nonce;
K : in Core.Salsa20_Key)
is
K2 : MAC.Poly_1305_Key;
R : Bytes_16;
begin
-- Defensive - re-check precondition
if (M'First = 0 and then
C'First = 0 and then
C'Last = M'Last and then
M'Length >= 32 and then
Equal (M (0 .. 31), Zero_Bytes_32))
then
-- All OK
Stream.HSalsa20_Xor (C, M, N, K);
MAC.Construct (K2, C (0 .. 31));
declare
subtype M_Array is Byte_Seq (0 .. (C'Last - 32));
begin
MAC.Onetimeauth (R,
-- Slice and slide to make the index value
-- meet the precondition
M_Array (C (32 .. C'Last)),
K2);
end;
C (0 .. 15) := Zero_Bytes_16;
C (16 .. 31) := R;
Status := True;
else
-- Precondition violated
C := (others => 0);
Status := False;
end if;
end Create;
procedure Open
(M : out Byte_Seq; -- Output plaintext
Status : out Boolean;
C : in Byte_Seq; -- Input ciphertext
N : in Stream.HSalsa20_Nonce;
K : in Core.Salsa20_Key)
is
X : Bytes_32;
begin
-- Defensive - re-check precondition
if (M'First = 0 and then
C'First = 0 and then
M'Last = C'Last and then
C'Length >= 32 and then
Equal (C (0 .. 15), Zero_Bytes_16))
then
-- All OK
Stream.HSalsa20 (X, N, K);
declare
subtype M_Array is Byte_Seq (0 .. (C'Last - 32));
MAC_Key : constant MAC.Poly_1305_Key := MAC.Construct (X);
begin
if MAC.Onetimeauth_Verify
(H => C (16 .. 31),
-- Slide and slide so that M'First = 0
M => M_Array (C (32 .. C'Last)),
K => MAC_Key)
then
-- MAC verifies OK, so decrypt payload
Stream.HSalsa20_Xor (C => M, M => C, N => N, K => K);
M (0 .. 31) := Zero_Bytes_32;
Status := True;
else
-- MAC verification failed
M := (others => 0);
Status := False;
end if;
end;
else
-- Precondition violated
M := (others => 0);
Status := False;
end if;
end Open;
end SPARKNaCl.Secretbox;
| 30.20202 | 72 | 0.426087 |
2f8107261950edc1ea8c3b8b94847a34e366a485 | 4,138 | ads | Ada | bb-runtimes/runtimes/ravenscar-full-stm32f3x4/gnat/s-crc32.ads | JCGobbi/Nucleo-STM32F334R8 | 2a0b1b4b2664c92773703ac5e95dcb71979d051c | [
"BSD-3-Clause"
] | null | null | null | bb-runtimes/runtimes/ravenscar-full-stm32f3x4/gnat/s-crc32.ads | JCGobbi/Nucleo-STM32F334R8 | 2a0b1b4b2664c92773703ac5e95dcb71979d051c | [
"BSD-3-Clause"
] | null | null | null | bb-runtimes/runtimes/ravenscar-full-stm32f3x4/gnat/s-crc32.ads | JCGobbi/Nucleo-STM32F334R8 | 2a0b1b4b2664c92773703ac5e95dcb71979d051c | [
"BSD-3-Clause"
] | null | null | null | ------------------------------------------------------------------------------
-- --
-- GNAT LIBRARY COMPONENTS --
-- --
-- S Y S T E M . C R C 3 2 --
-- --
-- S p e c --
-- --
-- Copyright (C) 2001-2021, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
-- ware Foundation; either version 3, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
-- or FITNESS FOR A PARTICULAR PURPOSE. --
-- --
-- --
-- --
-- --
-- --
-- You should have received a copy of the GNU General Public License and --
-- a copy of the GCC Runtime Library Exception along with this program; --
-- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
-- <http://www.gnu.org/licenses/>. --
-- --
-- GNAT was originally developed by the GNAT team at New York University. --
-- Extensive contributions were provided by Ada Core Technologies Inc. --
-- --
------------------------------------------------------------------------------
-- This package provides routines for computing a commonly used checksum
-- called CRC-32. This is a checksum based on treating the binary data
-- as a polynomial over a binary field, and the exact specifications of
-- the CRC-32 algorithm are as follows:
--
-- Name : "CRC-32"
-- Width : 32
-- Poly : 04C11DB7
-- Init : FFFFFFFF
-- RefIn : True
-- RefOut : True
-- XorOut : FFFFFFFF
-- Check : CBF43926
--
-- Note that this is the algorithm used by PKZip, Ethernet and FDDI.
--
-- For more information about this algorithm see:
--
-- ftp://ftp.rocksoft.com/papers/crc_v3.txt
-- "A Painless Guide to CRC Error Detection Algorithms", Ross N. Williams
--
-- "Computation of Cyclic Redundancy Checks via Table Look-Up", Communications
-- of the ACM, Vol. 31 No. 8, pp.1008-1013 Aug. 1988. Sarwate, D.V.
pragma Compiler_Unit_Warning;
with Interfaces;
package System.CRC32 is
type CRC32 is new Interfaces.Unsigned_32;
-- Used to represent CRC32 values, which are 32 bit bit-strings
procedure Initialize (C : out CRC32);
pragma Inline (Initialize);
-- Initialize CRC value by assigning the standard Init value (16#FFFF_FFFF)
procedure Update
(C : in out CRC32;
Value : Character);
pragma Inline (Update);
-- Evolve CRC by including the contribution from Character'Pos (Value)
function Get_Value (C : CRC32) return Interfaces.Unsigned_32;
pragma Inline (Get_Value);
-- Get_Value computes the CRC32 value by performing an XOR with the
-- standard XorOut value (16#FFFF_FFFF). Note that this does not
-- change the value of C, so it may be used to retrieve intermediate
-- values of the CRC32 value during a sequence of Update calls.
end System.CRC32;
| 49.261905 | 79 | 0.464717 |
06e48bd1b9c04d4a52e4f600fc9844cd30e67e90 | 3,124 | ads | Ada | gcc-gcc-7_3_0-release/gcc/ada/s-mudido.ads | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 7 | 2020-05-02T17:34:05.000Z | 2021-10-17T10:15:18.000Z | gcc-gcc-7_3_0-release/gcc/ada/s-mudido.ads | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | null | null | null | gcc-gcc-7_3_0-release/gcc/ada/s-mudido.ads | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 2 | 2020-07-27T00:22:36.000Z | 2021-04-01T09:41:02.000Z | ------------------------------------------------------------------------------
-- --
-- GNAT RUN-TIME COMPONENTS --
-- --
-- SYSTEM.MULTIPROCESSORS.DISPATCHING_DOMAINS --
-- --
-- S p e c --
-- --
-- This specification is derived from the Ada Reference Manual for use with --
-- GNAT. In accordance with the copyright of that document, you can freely --
-- copy and modify this specification, provided that if you redistribute a --
-- modified version, any changes that you have made are clearly indicated. --
-- --
------------------------------------------------------------------------------
with Ada.Real_Time;
with Ada.Task_Identification;
private with System.Tasking;
package System.Multiprocessors.Dispatching_Domains is
-- pragma Preelaborate (Dispatching_Domains);
-- ??? According to AI 167 this unit should be preelaborate, but it cannot
-- be preelaborate because it depends on Ada.Real_Time which is not
-- preelaborate.
Dispatching_Domain_Error : exception;
type Dispatching_Domain (<>) is limited private;
System_Dispatching_Domain : constant Dispatching_Domain;
function Create (First : CPU; Last : CPU_Range) return Dispatching_Domain;
function Get_First_CPU (Domain : Dispatching_Domain) return CPU;
function Get_Last_CPU (Domain : Dispatching_Domain) return CPU_Range;
type CPU_Set is array (CPU range <>) of Boolean;
function Create (Set : CPU_Set) return Dispatching_Domain;
function Get_CPU_Set (Domain : Dispatching_Domain) return CPU_Set;
function Get_Dispatching_Domain
(T : Ada.Task_Identification.Task_Id :=
Ada.Task_Identification.Current_Task) return Dispatching_Domain;
procedure Assign_Task
(Domain : in out Dispatching_Domain;
CPU : CPU_Range := Not_A_Specific_CPU;
T : Ada.Task_Identification.Task_Id :=
Ada.Task_Identification.Current_Task);
procedure Set_CPU
(CPU : CPU_Range;
T : Ada.Task_Identification.Task_Id :=
Ada.Task_Identification.Current_Task);
function Get_CPU
(T : Ada.Task_Identification.Task_Id :=
Ada.Task_Identification.Current_Task) return CPU_Range;
procedure Delay_Until_And_Set_CPU
(Delay_Until_Time : Ada.Real_Time.Time;
CPU : CPU_Range);
private
type Dispatching_Domain is new System.Tasking.Dispatching_Domain_Access;
System_Dispatching_Domain : constant Dispatching_Domain :=
Dispatching_Domain
(System.Tasking.System_Domain);
end System.Multiprocessors.Dispatching_Domains;
| 41.105263 | 78 | 0.557618 |
1d9e386d35837c81d0715b3e1a44458a24465d29 | 4,995 | ads | Ada | sources/md/markdown-inline_parsers.ads | reznikmm/markdown | af47bd45427f1c016c0a2a11e86fa2d1b1c82315 | [
"MIT"
] | null | null | null | sources/md/markdown-inline_parsers.ads | reznikmm/markdown | af47bd45427f1c016c0a2a11e86fa2d1b1c82315 | [
"MIT"
] | null | null | null | sources/md/markdown-inline_parsers.ads | reznikmm/markdown | af47bd45427f1c016c0a2a11e86fa2d1b1c82315 | [
"MIT"
] | null | null | null | -- SPDX-FileCopyrightText: 2020 Max Reznik <[email protected]>
--
-- SPDX-License-Identifier: MIT
----------------------------------------------------------------
with Ada.Containers.Vectors;
with League.Strings;
with League.String_Vectors;
with Markdown.Link_Registers;
package Markdown.Inline_Parsers is
type Annotation_Kind is
(Soft_Line_Break, Emphasis, Strong, Link, Code_Span,
Open_HTML_Tag, Close_HTML_Tag, HTML_Comment,
HTML_Processing_Instruction, HTML_Declaration, HTML_CDATA);
type HTML_Attribute is record
Name : League.Strings.Universal_String;
Value : League.String_Vectors.Universal_String_Vector;
-- An empty vector means no value for the attribute
end record;
package Attr_Vectors is new Ada.Containers.Vectors
(Positive, HTML_Attribute);
type Annotation (Kind : Annotation_Kind := Annotation_Kind'First) is record
From : Positive;
To : Natural;
case Kind is
when Emphasis | Strong | Link =>
case Kind is
when Link =>
Destination : League.Strings.Universal_String;
Title : League.String_Vectors.Universal_String_Vector;
when others =>
null;
end case;
when Soft_Line_Break | Code_Span =>
null;
when Open_HTML_Tag | Close_HTML_Tag =>
Tag : League.Strings.Universal_String;
case Kind is
when Open_HTML_Tag =>
Attr : Attr_Vectors.Vector;
Is_Empty : Boolean;
when others =>
null;
end case;
when HTML_Comment =>
HTML_Comment : League.String_Vectors.Universal_String_Vector;
when HTML_Processing_Instruction =>
HTML_PI : League.String_Vectors.Universal_String_Vector;
when HTML_Declaration =>
HTML_Decl : League.String_Vectors.Universal_String_Vector;
when HTML_CDATA =>
HTML_CDATA : League.String_Vectors.Universal_String_Vector;
end case;
end record;
package Annotation_Vectors is new
Ada.Containers.Vectors (Positive, Annotation);
type Annotated_Text is record
Plain_Text : League.Strings.Universal_String;
Annotation : Annotation_Vectors.Vector;
end record;
function Parse
(Register : Markdown.Link_Registers.Link_Register'Class;
Lines : League.String_Vectors.Universal_String_Vector)
return Annotated_Text;
private
type Position is record
Line : Positive;
Column : Natural;
end record;
function "+" (Cursor : Position; Value : Integer) return Position is
((Cursor.Line, Cursor.Column + Value));
function "<" (Left, Right : Position) return Boolean is
(Left.Line < Right.Line or
(Left.Line = Right.Line and Left.Column < Right.Column));
function "<=" (Left, Right : Position) return Boolean is
(Left < Right or Left = Right);
function ">" (Left, Right : Position) return Boolean is
(Left.Line > Right.Line or
(Left.Line = Right.Line and Left.Column > Right.Column));
package Plain_Texts is
type Plain_Text is tagged limited private;
procedure Initialize
(Self : in out Plain_Text'Class;
Text : League.String_Vectors.Universal_String_Vector;
From : Position := (1, 1);
To : Position := (Positive'Last, Positive'Last));
procedure Initialize
(Self : in out Plain_Text'Class;
Text : Plain_Text'Class;
From : Position;
To : Position := (Positive'Last, Positive'Last));
function First (Self : Plain_Text'Class) return Position;
function Last (Self : Plain_Text'Class) return Position;
function Line
(Self : Plain_Text'Class;
From : Position) return League.Strings.Universal_String;
function Line
(Self : Plain_Text'Class;
Index : Positive) return League.Strings.Universal_String;
function Lines (Self : Plain_Text'Class) return Positive;
pragma Unreferenced (Lines);
procedure Step
(Self : Plain_Text'Class;
Value : Natural;
Cursor : in out Position);
function Join
(Self : Plain_Text'Class;
From : Position;
Char : Wide_Wide_Character) return League.Strings.Universal_String;
private
type Plain_Text is tagged limited record
Data : League.String_Vectors.Universal_String_Vector;
From : Position;
To : Position;
end record;
end Plain_Texts;
type Inline_Span is record
From : Position;
To : Position;
end record;
type Optional_Inline_State (Is_Set : Boolean := False) is record
case Is_Set is
when True =>
Span : Inline_Span;
Value : Annotated_Text;
when False =>
null;
end case;
end record;
end Markdown.Inline_Parsers;
| 31.415094 | 78 | 0.627427 |
0bc4942f847334c4afc3494d37ba5a5f3104bc7a | 11,316 | ads | Ada | tools/scitools/conf/understand/ada/ada95/i-cpthre.ads | brucegua/moocos | 575c161cfa35e220f10d042e2e5ca18773691695 | [
"Apache-2.0"
] | 1 | 2020-01-20T21:26:46.000Z | 2020-01-20T21:26:46.000Z | tools/scitools/conf/understand/ada/ada95/i-cpthre.ads | brucegua/moocos | 575c161cfa35e220f10d042e2e5ca18773691695 | [
"Apache-2.0"
] | null | null | null | tools/scitools/conf/understand/ada/ada95/i-cpthre.ads | brucegua/moocos | 575c161cfa35e220f10d042e2e5ca18773691695 | [
"Apache-2.0"
] | null | null | null | ------------------------------------------------------------------------------
-- --
-- GNU ADA RUNTIME LIBRARY (GNARL) COMPONENTS --
-- --
-- I N T E R F A C E S . C . P T H R E A D S --
-- --
-- S p e c --
-- --
-- $Revision: 2 $ --
-- --
-- Copyright (c) 1991,1992,1993,1994, FSU, All Rights Reserved --
-- --
-- GNARL is free software; you can redistribute it and/or modify it under --
-- terms of the GNU Library General Public License as published by the --
-- Free Software Foundation; either version 2, or (at your option) any --
-- later version. GNARL is distributed in the hope that it will be use- --
-- ful, but but WITHOUT ANY WARRANTY; without even the implied warranty of --
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Gen- --
-- eral Library Public License for more details. You should have received --
-- a copy of the GNU Library General Public License along with GNARL; see --
-- file COPYING.LIB. If not, write to the Free Software Foundation, 675 --
-- Mass Ave, Cambridge, MA 02139, USA. --
-- --
------------------------------------------------------------------------------
-- This package interfaces with Pthreads. It is not a complete interface;
-- it only includes what is needed to implement the Ada runtime.
with System;
with Interfaces.C.System_Constants;
-- Used for, Add_Prio
-- pthread_attr_t_size
-- pthread_mutexattr_t_size
-- pthread_mutex_t_size
-- pthread_condattr_t_size
-- pthread_cond_t_size
-- NO_PRIO_INHERIT
-- PRIO_INHERIT
-- PRIO_PROTECT
with Interfaces.C.POSIX_RTE;
-- Used for, Signal,
-- Signal_Set
with Interfaces.C.POSIX_Error; use Interfaces.C.POSIX_Error;
-- Used for, Return_Code
with Interfaces.C.POSIX_Timers;
-- Used for, timespec
package Interfaces.C.Pthreads is
Alignment : constant := Natural'Min (16, 8);
Pthreads_Error : exception;
type Priority_Type is new int;
type pthread_t is private;
type pthread_mutex_t is private;
type pthread_cond_t is private;
type pthread_attr_t is private;
type pthread_mutexattr_t is private;
type pthread_condattr_t is private;
type pthread_key_t is private;
type pthread_protocol_t is private;
NO_PRIO_INHERIT : constant pthread_protocol_t;
PRIO_INHERIT : constant pthread_protocol_t;
PRIO_PROTECT : constant pthread_protocol_t;
procedure pthread_attr_init
(attributes : out pthread_attr_t;
result : out Return_Code);
pragma Inline (pthread_attr_init);
procedure pthread_attr_destroy
(attributes : in out pthread_attr_t;
result : out Return_Code);
pragma Inline (pthread_attr_destroy);
procedure pthread_attr_setstacksize
(attr : in out pthread_attr_t;
stacksize : size_t;
result : out Return_Code);
pragma Inline (pthread_attr_setstacksize);
procedure pthread_attr_setdetachstate
(attr : in out pthread_attr_t;
detachstate : int;
Result : out Return_Code);
pragma Inline (pthread_attr_setdetachstate);
procedure pthread_create
(thread : out pthread_t;
attributes : pthread_attr_t;
start_routine : System.Address;
arg : System.Address;
result : out Return_Code);
pragma Inline (pthread_create);
procedure pthread_init;
function pthread_self return pthread_t;
pragma Inline (pthread_self);
procedure pthread_detach
(thread : in out pthread_t;
result : out Return_Code);
pragma Inline (pthread_detach);
procedure pthread_mutexattr_init
(attributes : out pthread_mutexattr_t;
result : out Return_Code);
pragma Inline (pthread_mutexattr_init);
procedure pthread_mutexattr_setprotocol
(attributes : in out pthread_mutexattr_t;
protocol : pthread_protocol_t;
result : out Return_Code);
pragma Inline (pthread_mutexattr_setprotocol);
procedure pthread_mutexattr_setprio_ceiling
(attributes : in out pthread_mutexattr_t;
prio_ceiling : int;
result : out Return_Code);
pragma Inline (pthread_mutexattr_setprio_ceiling);
procedure pthread_mutex_init
(mutex : out pthread_mutex_t;
attributes : pthread_mutexattr_t;
result : out Return_Code);
pragma Inline (pthread_mutex_init);
procedure pthread_mutex_destroy
(mutex : in out pthread_mutex_t;
result : out Return_Code);
pragma Inline (pthread_mutex_destroy);
procedure pthread_mutex_trylock
(mutex : in out pthread_mutex_t;
result : out Return_Code);
pragma Inline (pthread_mutex_trylock);
procedure pthread_mutex_lock
(mutex : in out pthread_mutex_t;
result : out Return_Code);
pragma Inline (pthread_mutex_lock);
procedure pthread_mutex_unlock
(mutex : in out pthread_mutex_t;
result : out Return_Code);
pragma Inline (pthread_mutex_unlock);
procedure pthread_cond_init
(condition : out pthread_cond_t;
attributes : pthread_condattr_t;
result : out Return_Code);
pragma Inline (pthread_cond_init);
procedure pthread_cond_wait
(condition : in out pthread_cond_t;
mutex : in out pthread_mutex_t;
result : out Return_Code);
pragma Inline (pthread_cond_wait);
procedure pthread_cond_timedwait
(condition : in out pthread_cond_t;
mutex : in out pthread_mutex_t;
absolute_time : Interfaces.C.POSIX_Timers.timespec;
result : out Return_Code);
pragma Inline (pthread_cond_timedwait);
procedure pthread_cond_signal
(condition : in out pthread_cond_t;
result : out Return_Code);
pragma Inline (pthread_cond_signal);
procedure pthread_cond_broadcast
(condition : in out pthread_cond_t;
result : out Return_Code);
pragma Inline (pthread_cond_broadcast);
procedure pthread_cond_destroy
(condition : in out pthread_cond_t;
result : out Return_Code);
pragma Inline (pthread_cond_destroy);
procedure pthread_condattr_init
(attributes : out pthread_condattr_t;
result : out Return_Code);
pragma Inline (pthread_condattr_init);
procedure pthread_condattr_destroy
(attributes : in out pthread_condattr_t;
result : out Return_Code);
pragma Inline (pthread_condattr_destroy);
procedure pthread_setspecific
(key : pthread_key_t;
value : System.Address;
result : out Return_Code);
pragma Inline (pthread_setspecific);
procedure pthread_getspecific
(key : pthread_key_t;
value : out System.Address;
result : out Return_Code);
pragma Inline (pthread_getspecific);
procedure pthread_key_create
(key : out pthread_key_t;
destructor : System.Address;
result : out Return_Code);
pragma Inline (pthread_key_create);
procedure pthread_attr_setprio
(attr : in out pthread_attr_t;
priority : Priority_Type;
result : out Return_Code);
pragma Inline (pthread_attr_setprio);
procedure pthread_attr_getprio
(attr : pthread_attr_t;
priority : out Priority_Type;
result : out Return_Code);
pragma Inline (pthread_attr_getprio);
procedure pthread_setschedattr
(thread : pthread_t;
attributes : pthread_attr_t;
result : out Return_Code);
pragma Inline (pthread_setschedattr);
procedure pthread_getschedattr
(thread : pthread_t;
attributes : out pthread_attr_t;
result : out Return_Code);
pragma Inline (pthread_getschedattr);
procedure pthread_exit (status : System.Address);
pragma Interface (C, pthread_exit);
pragma Interface_Name (pthread_exit, "pthread_exit");
procedure sigwait
(set : Interfaces.C.POSIX_RTE.Signal_Set;
sig : out Interfaces.C.POSIX_RTE.Signal;
result : out Return_Code);
pragma Inline (sigwait);
procedure pthread_kill
(thread : pthread_t; sig : Interfaces.C.POSIX_RTE.Signal;
result : out Return_Code);
pragma Inline (pthread_kill);
procedure pthread_cleanup_push
(routine : System.Address;
arg : System.Address);
pragma Inline (pthread_cleanup_push);
procedure pthread_cleanup_pop (execute : int);
pragma Inline (pthread_cleanup_pop);
procedure pthread_yield;
pragma Inline (pthread_yield);
private
-- The use of longword alignment for the following C types is
-- a stopgap measure which is not generally portable. A portable
-- solution will require some means of getting alignment information
-- from the C compiler.
type pthread_attr_t is
array (1 .. System_Constants.pthread_attr_t_size) of unsigned;
for pthread_attr_t'Alignment use Alignment;
type pthread_mutexattr_t is
array (1 .. System_Constants.pthread_mutexattr_t_size) of unsigned;
for pthread_mutexattr_t'Alignment use Alignment;
type pthread_mutex_t is
array (1 .. System_Constants.pthread_mutex_t_size) of unsigned;
for pthread_mutex_t'Alignment use Alignment;
type pthread_condattr_t is
array (1 .. System_Constants.pthread_condattr_t_size) of unsigned;
for pthread_condattr_t'Alignment use Alignment;
type pthread_cond_t is
array (1 .. System_Constants.pthread_cond_t_size) of unsigned;
for pthread_cond_t'Alignment use Alignment;
-- type pthread_t is
-- array (1 .. System_Constants.pthread_t_size) of unsigned;
type pthread_t is new unsigned;
-- ??? The use of an array here (of one element, usually) seems to cause
-- problems in the compiler. It put a long word 4 in the
-- instruction stream of Interfaces.C.Pthreads.pthread_self. This
-- is obviously meant to provide some clue as to what size
-- item it is to return, but pthread_self tried to execute it.
type pthread_key_t is new unsigned;
-- This type is passed as a scaler into a C function. It must
-- be declared as a scaler, not an array. This being so, an unsigned
-- should work.
type pthread_protocol_t is new int;
NO_PRIO_INHERIT : constant pthread_protocol_t :=
System_Constants.NO_PRIO_INHERIT;
PRIO_INHERIT : constant pthread_protocol_t :=
System_Constants.PRIO_INHERIT;
PRIO_PROTECT : constant pthread_protocol_t :=
System_Constants.PRIO_PROTECT;
end Interfaces.C.Pthreads;
| 35.3625 | 78 | 0.636532 |
a1ed820083bd186b46d61a45d92f188810b7f510 | 7,243 | ads | Ada | src/sdl-video-gl.ads | mosteo/sdlada | 429c594de613c5ba2f0d7c59f8708956697e14f1 | [
"Zlib"
] | 89 | 2015-01-03T01:41:23.000Z | 2022-02-23T18:21:11.000Z | src/sdl-video-gl.ads | mosteo/sdlada | 429c594de613c5ba2f0d7c59f8708956697e14f1 | [
"Zlib"
] | 66 | 2015-05-01T00:54:03.000Z | 2022-01-20T04:09:59.000Z | src/sdl-video-gl.ads | Jellix/sdlada | 997d2ae2da5c75e2ea99cee98372cf5b752519cf | [
"Zlib"
] | 33 | 2015-04-30T23:39:31.000Z | 2022-01-03T13:00:41.000Z | --------------------------------------------------------------------------------------------------------------------
-- Copyright (c) 2013-2020, Luke A. Guest
--
-- This software is provided 'as-is', without any express or implied
-- warranty. In no event will the authors be held liable for any damages
-- arising from the use of this software.
--
-- Permission is granted to anyone to use this software for any purpose,
-- including commercial applications, and to alter it and redistribute it
-- freely, subject to the following restrictions:
--
-- 1. The origin of this software must not be misrepresented; you must not
-- claim that you wrote the original software. If you use this software
-- in a product, an acknowledgment in the product documentation would be
-- appreciated but is not required.
--
-- 2. Altered source versions must be plainly marked as such, and must not be
-- misrepresented as being the original software.
--
-- 3. This notice may not be removed or altered from any source
-- distribution.
--------------------------------------------------------------------------------------------------------------------
-- SDL.Video.GL
--
-- Extended OpenGL functionality.
--------------------------------------------------------------------------------------------------------------------
with Ada.Finalization;
with Interfaces.C;
private with SDL.C_Pointers;
with SDL.Video.Windows;
with SDL.Video.Textures;
package SDL.Video.GL is
pragma Preelaborate;
SDL_GL_Error : exception;
type Colour_Bit_Size is range 0 .. 8 with
Size => 8;
-- TODO: Do I need 15 bits here?
-- This is the size of the various Colour_Bit_Sizes for red, blue, green and alpha.
type Buffer_Sizes is range 8 .. 32 with
Static_Predicate => Buffer_Sizes in 8 | 16 | 24 | 32;
type Depth_Buffer_Sizes is range 16 .. 32 with
Static_Predicate => Depth_Buffer_Sizes in 16 | 24 | 32;
type Stencil_Buffer_Sizes is range 0 .. 32 with
Static_Predicate => Stencil_Buffer_Sizes in 0 | 8 | 16 | 24 | 32;
type Multisample_Samples is range 0 .. 16;
-- The curent values allowed for a GL version, whether lower versions will work
-- with SDL is anothing matter.
type Major_Versions is range 1 .. 4;
type Minor_Versions is range 0 .. 4;
type Profiles is (Core, Compatibility, ES) with
Convention => C,
Size => Interfaces.C.int'Size;
for Profiles use (Core => 16#0000_0001#,
Compatibility => 16#0000_0002#,
ES => 16#0000_0004#);
type Flags is mod 2 ** 8 with
Convention => C,
Size => 8;
Context_Debug : constant Flags := 16#0000_0001#;
Context_Forward_Compatible : constant Flags := 16#0000_0002#;
Context_Robust_Access : constant Flags := 16#0000_0004#;
Context_Reset_Isolation : constant Flags := 16#0000_0008#;
function Red_Size return Colour_Bit_Size;
procedure Set_Red_Size (Size : in Colour_Bit_Size);
function Green_Size return Colour_Bit_Size;
procedure Set_Green_Size (Size : in Colour_Bit_Size);
function Blue_Size return Colour_Bit_Size;
procedure Set_Blue_Size (Size : in Colour_Bit_Size);
function Alpha_Size return Colour_Bit_Size;
procedure Set_Alpha_Size (Size : in Colour_Bit_Size);
function Buffer_Size return Buffer_Sizes;
procedure Set_Buffer_Size (Size : in Buffer_Sizes);
function Is_Double_Buffered return Boolean;
procedure Set_Double_Buffer (On : in Boolean);
function Depth_Buffer_Size return Depth_Buffer_Sizes;
procedure Set_Depth_Buffer_Size (Size : in Depth_Buffer_Sizes);
function Stencil_Buffer_Size return Stencil_Buffer_Sizes;
procedure Set_Stencil_Buffer_Size (Size : in Stencil_Buffer_Sizes);
function Accumulator_Red_Size return Colour_Bit_Size;
procedure Set_Accumulator_Red_Size (Size : in Colour_Bit_Size);
function Accumulator_Green_Size return Colour_Bit_Size;
procedure Set_Accumulator_Green_Size (Size : in Colour_Bit_Size);
function Accumulator_Blue_Size return Colour_Bit_Size;
procedure Set_Accumulator_Blue_Size (Size : in Colour_Bit_Size);
function Accumulator_Alpha_Size return Colour_Bit_Size;
procedure Set_Accumulator_Alpha_Size (Size : in Colour_Bit_Size);
function Is_Stereo return Boolean;
procedure Set_Stereo (On : in Boolean);
function Is_Multisampled return Boolean;
procedure Set_Multisampling (On : in Boolean);
function Multisampling_Samples return Multisample_Samples;
procedure Set_Multisampling_Samples (Samples : in Multisample_Samples);
function Is_Accelerated return Boolean;
procedure Set_Accelerated (On : in Boolean);
function Context_Major_Version return Major_Versions;
procedure Set_Context_Major_Version (Version : Major_Versions);
function Context_Minor_Version return Minor_Versions;
procedure Set_Context_Minor_Version (Version : Minor_Versions);
function Is_Context_EGL return Boolean;
procedure Set_Context_EGL (On : in Boolean);
function Context_Flags return Flags;
procedure Set_Context_Flags (Context_Flags : in Flags);
function Context_Profile return Profiles;
procedure Set_Context_Profile (Profile : in Profiles);
-- Utility subprograms.
procedure Set_Core_Context_Profile (Major : in Major_Versions; Minor : Minor_Versions);
function Is_Sharing_With_Current_Context return Boolean;
procedure Set_Share_With_Current_Context (On : in Boolean);
-- The GL context.
type Contexts is new Ada.Finalization.Limited_Controlled with private;
procedure Create (Self : in out Contexts; From : in SDL.Video.Windows.Window);
overriding
procedure Finalize (Self : in out Contexts);
function Get_Current return Contexts;
procedure Set_Current (Self : in Contexts; To : in SDL.Video.Windows.Window);
procedure Bind_Texture (Texture : in SDL.Video.Textures.Texture);
procedure Bind_Texture (Texture : in SDL.Video.Textures.Texture; Size : out SDL.Sizes);
procedure Unbind_Texture (Texture : in SDL.Video.Textures.Texture);
function Supports (Extension : in String) return Boolean;
generic
type Access_To_Sub_Program is private;
function Get_Sub_Program (Name : in String) return Access_To_Sub_Program;
type Swap_Intervals is (Not_Supported, Not_Synchronised, Synchronised) with
Convention => C;
for Swap_Intervals use (Not_Supported => -1, Not_Synchronised => 0, Synchronised => 1);
subtype Allowed_Swap_Intervals is Swap_Intervals range Not_Synchronised .. Synchronised;
function Get_Swap_Interval return Swap_Intervals;
-- Returns False if setting this is not supported.
function Set_Swap_Interval (Interval : in Allowed_Swap_Intervals; Late_Swap_Tear : in Boolean) return Boolean;
procedure Swap (Window : in out SDL.Video.Windows.Window) with
Inline => True;
procedure Load_Library;
procedure Load_Library (Path : in String);
procedure Unload_Library with
Inline => True;
private
type Contexts is new Ada.Finalization.Limited_Controlled with
record
Internal : SDL.C_Pointers.GL_Context_Pointer;
Owns : Boolean;
end record;
end SDL.Video.GL;
| 37.528497 | 116 | 0.703024 |
a17c471a19448084c034178c35dc28111ee75b7e | 2,564 | ads | Ada | src/lithium-markdown-filters.ads | faelys/lithium3 | f167143e2e4d8a968c6608cffe179eb2b05d4c2c | [
"ISC"
] | 1 | 2020-09-10T10:14:35.000Z | 2020-09-10T10:14:35.000Z | src/lithium-markdown-filters.ads | faelys/lithium3 | f167143e2e4d8a968c6608cffe179eb2b05d4c2c | [
"ISC"
] | null | null | null | src/lithium-markdown-filters.ads | faelys/lithium3 | f167143e2e4d8a968c6608cffe179eb2b05d4c2c | [
"ISC"
] | 1 | 2020-01-06T14:16:55.000Z | 2020-01-06T14:16:55.000Z | ------------------------------------------------------------------------------
-- Copyright (c) 2015-2017, Natacha Porté --
-- --
-- Permission to use, copy, modify, and distribute this software for any --
-- purpose with or without fee is hereby granted, provided that the above --
-- copyright notice and this permission notice appear in all copies. --
-- --
-- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES --
-- WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF --
-- MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR --
-- ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES --
-- WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN --
-- ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF --
-- OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. --
------------------------------------------------------------------------------
------------------------------------------------------------------------------
-- Lithium.Markdown.Filters provides implementations of web filters --
-- performing markdown to HTML transformation. --
------------------------------------------------------------------------------
with Ada.Streams;
with Natools.S_Expressions.Lockable;
with Natools.Web.Filters;
package Lithium.Markdown.Filters is
type Extended is new Natools.Web.Filters.Filter with private;
overriding procedure Apply
(Object : in Extended;
Output : in out Ada.Streams.Root_Stream_Type'Class;
Data : in Ada.Streams.Stream_Element_Array);
function Create_Extended
(Arguments : in out Natools.S_Expressions.Lockable.Descriptor'Class)
return Natools.Web.Filters.Filter'Class;
type Comment is new Natools.Web.Filters.Filter with private;
overriding procedure Apply
(Object : in Comment;
Output : in out Ada.Streams.Root_Stream_Type'Class;
Data : in Ada.Streams.Stream_Element_Array);
function Create_Comment
(Arguments : in out Natools.S_Expressions.Lockable.Descriptor'Class)
return Natools.Web.Filters.Filter'Class;
private
type Extended is new Natools.Web.Filters.Filter with null record;
type Comment is new Natools.Web.Filters.Filter with null record;
end Lithium.Markdown.Filters;
| 44.206897 | 78 | 0.581513 |
31976c5f797ce210bac872bb4521319307a9253b | 4,857 | ads | Ada | tools-src/gnu/gcc/gcc/ada/s-arit64.ads | modern-tomato/tomato | 96f09fab4929c6ddde5c9113f1b2476ad37133c4 | [
"FSFAP"
] | 80 | 2015-01-02T10:14:04.000Z | 2021-06-07T06:29:49.000Z | tools-src/gnu/gcc/gcc/ada/s-arit64.ads | modern-tomato/tomato | 96f09fab4929c6ddde5c9113f1b2476ad37133c4 | [
"FSFAP"
] | 9 | 2015-05-14T11:03:12.000Z | 2018-01-04T07:12:58.000Z | tools-src/gnu/gcc/gcc/ada/s-arit64.ads | modern-tomato/tomato | 96f09fab4929c6ddde5c9113f1b2476ad37133c4 | [
"FSFAP"
] | 69 | 2015-01-02T10:45:56.000Z | 2021-09-06T07:52:13.000Z | ------------------------------------------------------------------------------
-- --
-- GNAT COMPILER COMPONENTS --
-- --
-- S Y S T E M . A R I T H _ 6 4 --
-- --
-- S p e c --
-- --
-- $Revision$
-- --
-- Copyright (C) 1994,1995,1996 Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
-- ware Foundation; either version 2, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT 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 distributed with GNAT; see file COPYING. If not, write --
-- to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, --
-- MA 02111-1307, USA. --
-- --
-- As a special exception, if other files instantiate generics from this --
-- unit, or you link this unit with other files to produce an executable, --
-- this unit does not by itself cause the resulting executable to be --
-- covered by the GNU General Public License. This exception does not --
-- however invalidate any other reasons why the executable file might be --
-- covered by the GNU Public License. --
-- --
-- GNAT was originally developed by the GNAT team at New York University. --
-- Extensive contributions were provided by Ada Core Technologies Inc. --
-- --
------------------------------------------------------------------------------
-- This unit provides software routines for doing arithmetic on 64-bit
-- signed integer values in cases where either overflow checking is
-- required, or intermediate results are longer than 64 bits.
with Interfaces;
package System.Arith_64 is
pragma Pure (Arith_64);
subtype Int64 is Interfaces.Integer_64;
function Add_With_Ovflo_Check (X, Y : Int64) return Int64;
-- Raises Constraint_Error if sum of operands overflows 64 bits,
-- otherwise returns the 64-bit signed integer sum.
function Subtract_With_Ovflo_Check (X, Y : Int64) return Int64;
-- Raises Constraint_Error if difference of operands overflows 64
-- bits, otherwise returns the 64-bit signed integer difference.
function Multiply_With_Ovflo_Check (X, Y : Int64) return Int64;
-- Raises Constraint_Error if product of operands overflows 64
-- bits, otherwise returns the 64-bit signed integer difference.
procedure Scaled_Divide
(X, Y, Z : Int64;
Q, R : out Int64;
Round : Boolean);
-- Performs the division of (X * Y) / Z, storing the quotient in Q
-- and the remainder in R. Constraint_Error is raised if Z is zero,
-- or if the quotient does not fit in 64-bits. Round indicates if
-- the result should be rounded. If Round is False, then Q, R are
-- the normal quotient and remainder from a truncating division.
-- If Round is True, then Q is the rounded quotient. the remainder
-- R is not affected by the setting of the Round flag.
procedure Double_Divide
(X, Y, Z : Int64;
Q, R : out Int64;
Round : Boolean);
-- Performs the division X / (Y * Z), storing the quotient in Q and
-- the remainder in R. Constraint_Error is raised if Y or Z is zero.
-- Round indicates if the result should be rounded. If Round is False,
-- then Q, R are the normal quotient and remainder from a truncating
-- division. If Round is True, then Q is the rounded quotient. The
-- remainder R is not affected by the setting of the Round flag. The
-- result is known to be in range except for the noted possibility of
-- Y or Z being zero, so no other overflow checks are required.
end System.Arith_64;
| 57.141176 | 78 | 0.535104 |
12830f6273770b198349c17af4eb50f9494702b4 | 4,157 | ads | Ada | ADL/drivers/stm32f334/stm32-power_control.ads | JCGobbi/Nucleo-STM32F334R8 | 2a0b1b4b2664c92773703ac5e95dcb71979d051c | [
"BSD-3-Clause"
] | null | null | null | ADL/drivers/stm32f334/stm32-power_control.ads | JCGobbi/Nucleo-STM32F334R8 | 2a0b1b4b2664c92773703ac5e95dcb71979d051c | [
"BSD-3-Clause"
] | null | null | null | ADL/drivers/stm32f334/stm32-power_control.ads | JCGobbi/Nucleo-STM32F334R8 | 2a0b1b4b2664c92773703ac5e95dcb71979d051c | [
"BSD-3-Clause"
] | null | null | null | ------------------------------------------------------------------------------
-- --
-- Copyright (C) 2016-2017, AdaCore --
-- --
-- Redistribution and use in source and binary forms, with or without --
-- modification, are permitted provided that the following conditions are --
-- met: --
-- 1. Redistributions of source code must retain the above copyright --
-- notice, this list of conditions and the following disclaimer. --
-- 2. Redistributions in binary form must reproduce the above copyright --
-- notice, this list of conditions and the following disclaimer in --
-- the documentation and/or other materials provided with the --
-- distribution. --
-- 3. Neither the name of the copyright holder nor the names of its --
-- contributors may be used to endorse or promote products derived --
-- from this software without specific prior written permission. --
-- --
-- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS --
-- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT --
-- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR --
-- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT --
-- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, --
-- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT --
-- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, --
-- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY --
-- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT --
-- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE --
-- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. --
-- --
------------------------------------------------------------------------------
with STM32_SVD.PWR; use STM32_SVD.PWR;
package STM32.Power_Control is
procedure Enable;
-- Enable power control module
procedure Disable_Backup_Domain_Protection;
procedure Enable_Backup_Domain_Protection;
function Wakeup_Flag return Boolean;
-- This flag is set by hardware and cleared either by a system reset or by
-- calling the Clear_Wakeup_Flag procedure.
procedure Clear_Wakeup_Flag;
function Standby_Flag return Boolean;
-- This flag is set by hardware and cleared only by a POR/PDR (power-on
-- reset/power-down reset) or by calling the Clear_Standby_Flag procedure.
procedure Clear_Standby_Flag;
procedure Set_Power_Down_Deepsleep (Enabled : Boolean := True);
-- When enabled, the MCU enters Standby mode when CPU enters deepsleep.
-- When disabled, the MCU enters Stop mode when CPU enters deepsleep.
procedure Set_Low_Power_Deepsleep (Enabled : Boolean := True);
-- When enabled, the voltage regulator is in low-power during MCU Stop mode.
-- When disabled, the voltage regulator is on during MCU Stop mode.
procedure Enable_Wakeup_Pin (Enabled : CSR_EWUP_Field);
-- When enabled, the wakeup pin (PA0) is used for wakeup from Standby mode
-- and forced in input pull down configuration (rising edge on WKUP pin
-- wakes-up the system from Standby mode).
-- When disabled, the wakeup pin is used for general purpose I/O. An event
-- on the wakeup pin does not wakeup the device from Standby mode.
procedure Enter_Standby_Mode
with No_Return;
-- Clear the wakeup and standby flag, set the power-down on CPU deep sleep
-- and trigger MCU deep sleep.
-- MCU gets out of standby with a reset, so this procedure does not return.
end STM32.Power_Control;
| 54.697368 | 80 | 0.604522 |
0e5699a7cf9602304981f17085861a65de05f1d6 | 10,766 | ads | Ada | ADL/devices/stm32-rcc.ads | JCGobbi/Nucleo-STM32G474RE | 8dc1c4948ffeb11841eed10f1c3708f00fa1d832 | [
"BSD-3-Clause"
] | null | null | null | ADL/devices/stm32-rcc.ads | JCGobbi/Nucleo-STM32G474RE | 8dc1c4948ffeb11841eed10f1c3708f00fa1d832 | [
"BSD-3-Clause"
] | null | null | null | ADL/devices/stm32-rcc.ads | JCGobbi/Nucleo-STM32G474RE | 8dc1c4948ffeb11841eed10f1c3708f00fa1d832 | [
"BSD-3-Clause"
] | null | null | null | ------------------------------------------------------------------------------
-- --
-- Copyright (C) 2015, AdaCore --
-- --
-- Redistribution and use in source and binary forms, with or without --
-- modification, are permitted provided that the following conditions are --
-- met: --
-- 1. Redistributions of source code must retain the above copyright --
-- notice, this list of conditions and the following disclaimer. --
-- 2. Redistributions in binary form must reproduce the above copyright --
-- notice, this list of conditions and the following disclaimer in --
-- the documentation and/or other materials provided with the --
-- distribution. --
-- 3. Neither the name of the copyright holder nor the names of its --
-- contributors may be used to endorse or promote products derived --
-- from this software without specific prior written permission. --
-- --
-- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS --
-- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT --
-- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR --
-- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT --
-- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, --
-- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT --
-- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, --
-- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY --
-- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT --
-- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE --
-- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. --
-- --
------------------------------------------------------------------------------
pragma Restrictions (No_Elaboration_Code);
package STM32.RCC is
procedure AHB_Force_Reset with Inline;
procedure AHB_Release_Reset with Inline;
procedure APB1_Force_Reset with Inline;
procedure APB1_Release_Reset with Inline;
procedure APB2_Force_Reset with Inline;
procedure APB2_Release_Reset with Inline;
procedure Backup_Domain_Reset;
-- Disable LSE clock and RTC and reset its configurations.
---------------------------------------------------------------------------
-- Clock Configuration --------------------------------------------------
---------------------------------------------------------------------------
---------------
-- HSE Clock --
---------------
procedure Set_HSE_Clock
(Enable : Boolean;
Bypass : Boolean := False;
Enable_CSS : Boolean := False)
with Post => HSE_Clock_Enabled = Enable;
function HSE_Clock_Enabled return Boolean;
---------------
-- LSE Clock --
---------------
type HSE_Capability is
(Lowest_Drive,
Low_Drive,
High_Drive,
Highest_Drive)
with Size => 2;
procedure Set_LSE_Clock
(Enable : Boolean;
Bypass : Boolean := False;
Enable_CSS : Boolean := False;
Capability : HSE_Capability)
with Post => LSE_Clock_Enabled = Enable;
function LSE_Clock_Enabled return Boolean;
---------------
-- HSI Clock --
---------------
procedure Set_HSI_Clock (Enable : Boolean)
with Post => HSI_Clock_Enabled = Enable;
-- The HSI clock can't be disabled if it is used directly (via SW mux) as
-- system clock or if the HSI is selected as reference clock for PLL with
-- PLL enabled (PLLON bit set to ‘1’). It is set by hardware if it is used
-- directly or indirectly as system clock.
function HSI_Clock_Enabled return Boolean;
-----------------
-- HSI48 Clock --
-----------------
procedure Set_HSI48_Clock (Enable : Boolean)
with Post => HSI48_Clock_Enabled = Enable;
function HSI48_Clock_Enabled return Boolean;
---------------
-- LSI Clock --
---------------
procedure Set_LSI_Clock (Enable : Boolean)
with Post => LSI_Clock_Enabled = Enable;
function LSI_Clock_Enabled return Boolean;
------------------
-- System Clock --
------------------
type SYSCLK_Clock_Source is
(SYSCLK_SRC_HSI,
SYSCLK_SRC_HSE,
SYSCLK_SRC_PLL)
with Size => 2;
for SYSCLK_Clock_Source use
(SYSCLK_SRC_HSI => 2#01#,
SYSCLK_SRC_HSE => 2#10#,
SYSCLK_SRC_PLL => 2#11#);
procedure Configure_System_Clock_Mux (Source : SYSCLK_Clock_Source);
------------------------
-- AHB and APB Clocks --
------------------------
type AHB_Prescaler_Enum is
(DIV_2, DIV_4, DIV_8, DIV_16,
DIV_64, DIV_128, DIV_256, DIV_512)
with Size => 3;
type AHB_Prescaler is record
Enable : Boolean := False;
Value : AHB_Prescaler_Enum := AHB_Prescaler_Enum'First;
end record with Size => 4;
for AHB_Prescaler use record
Enable at 0 range 3 .. 3;
Value at 0 range 0 .. 2;
end record;
procedure Configure_AHB_Clock_Prescaler
(Value : AHB_Prescaler);
-- The AHB clock bus is the CPU clock selected by the AHB prescaler.
-- Example to create a variable:
-- AHB_PRE : AHB_Prescaler := (Enable => True, Value => DIV_2);
type APB_Prescaler_Enum is
(DIV_2, DIV_4, DIV_8, DIV_16)
with Size => 2;
type APB_Prescaler is record
Enable : Boolean;
Value : APB_Prescaler_Enum := APB_Prescaler_Enum'First;
end record with Size => 3;
for APB_Prescaler use record
Enable at 0 range 2 .. 2;
Value at 0 range 0 .. 1;
end record;
type APB_Clock_Range is (APB_1, APB_2);
procedure Configure_APB_Clock_Prescaler
(Bus : APB_Clock_Range;
Value : APB_Prescaler);
-- The APB1 clock bus is the APB1 peripheral clock selected by the APB1
-- prescaler.
-- The APB2 clock bus is the APB2 peripheral clock selected by the APB2
-- prescaler.
-- Example to create a variable:
-- APB_PRE : APB_Prescaler := (Enable => True, Value => DIV_2);
----------------
-- PLL Clocks --
----------------
type PLL_Clock_Source is
(PLL_No_Source_PWR_OFF,
PLL_No_Source,
PLL_SRC_HSI,
PLL_SRC_HSE)
with Size => 2;
for PLL_Clock_Source use
(PLL_No_Source_PWR_OFF => 2#00#,
PLL_No_Source => 2#01#,
PLL_SRC_HSI => 2#10#,
PLL_SRC_HSE => 2#11#);
procedure Configure_PLL_Source_Mux (Source : PLL_Clock_Source);
subtype PLLM_Range is Integer range 1 .. 16;
subtype PLLN_Range is Integer range 8 .. 127;
subtype PLLP_Range is Integer range 2 .. 31;
subtype PLLQ_Range is Integer range 2 .. 8
with Static_Predicate => (case PLLQ_Range is
when 2 | 4 | 6 | 8 => True,
when others => False);
subtype PLLR_Range is Integer range 2 .. 8
with Static_Predicate => (case PLLR_Range is
when 2 | 4 | 6 | 8 => True,
when others => False);
procedure Configure_PLL
(Enable : Boolean;
PLLM : PLLM_Range;
PLLN : PLLN_Range;
PLLP : PLLP_Range;
Enable_Output_P : Boolean;
PLLQ : PLLQ_Range;
Enable_Output_Q : Boolean;
PLLR : PLLR_Range;
Enable_Output_R : Boolean);
-- Configure PLL according with RM0440 rev 6 Chapter 7.2.4 section "PLL"
-- pg 282.
-------------------
-- Output Clocks --
-------------------
type MCO_Clock_Source is
(MCOSEL_Disabled,
MCOSEL_SYSCLK,
MCOSEL_HSI,
MCOSEL_HSE,
MCOSEL_PLL,
MCOSEL_LSI,
MCOSEL_LSE,
MCOSEL_HSI48)
with Size => 4;
for MCO_Clock_Source use
(MCOSEL_Disabled => 2#0000#,
MCOSEL_SYSCLK => 2#0001#,
MCOSEL_HSI => 2#0011#,
MCOSEL_HSE => 2#0100#,
MCOSEL_PLL => 2#0101#,
MCOSEL_LSI => 2#0110#,
MCOSEL_LSE => 2#0111#,
MCOSEL_HSI48 => 2#1000#);
type MCO_Prescaler is
(MCOPRE_DIV1,
MCOPRE_DIV2,
MCOPRE_DIV4,
MCOPRE_DIV8,
MCOPRE_DIV16)
with Size => 3;
for MCO_Prescaler use
(MCOPRE_DIV1 => 2#000#,
MCOPRE_DIV2 => 2#001#,
MCOPRE_DIV4 => 2#010#,
MCOPRE_DIV8 => 2#011#,
MCOPRE_DIV16 => 2#100#);
procedure Configure_MCO_Output_Clock
(Source : MCO_Clock_Source;
Value : MCO_Prescaler);
-- Select the source for micro-controller clock output.
type LSCO_Clock_Source is (LSI, LSE);
procedure Configure_LSCO_Output_Clock
(Enable : Boolean;
Source : LSCO_Clock_Source := LSCO_Clock_Source'First);
------------------
-- Flash Memory --
------------------
-- Flash wait states
type FLASH_Wait_State is (FWS0, FWS1, FWS2, FWS3, FWS4)
with Size => 4;
procedure Set_FLASH_Latency (Latency : FLASH_Wait_State);
-- Constants for Flash Latency
-- with VCORE Range 1 boost mode | Range 1 normal mode
-- 000: Zero wait state 0 < HCLK ≤ 34 MHz | 0 < HCLK ≤ 30 MHz
-- 001: One wait state 34 < HCLK ≤ 68 MHz | 30 < HCLK ≤ 60 MHz
-- 010: Two wait sates 68 < HCLK ≤ 102 MHz | 60 < HCLK ≤ 90 MHz
-- 011: Three wait sates 102 < HCLK ≤ 136 MHz | 90 < HCLK ≤ 120 MHz
-- 100: Four wait sates 136 < HCLK ≤ 170 MHz | 120 < HCLK ≤ 150 MHz
-- RM0440 STM32G474 pg. 97 chapter 3.3.3 and pg. 129 chapter 3.7.1
-------------------
-- VCORE Scaling --
-------------------
type VCORE_Scaling_Selection is
(Range_1,
Range_2);
for VCORE_Scaling_Selection use
(Range_1 => 2#01#,
Range_2 => 2#10#);
procedure Set_VCORE_Scaling (Scale : VCORE_Scaling_Selection);
-- Range 2 => PLL max. is 26 MHz,
-- Range 1 => PLL max. is 150 MHz,
-- Range 1 boost => PLL max. is 170 MHz,
-- See RM0440 rev 6 Chapter 7.2.8 for frequency x voltage scaling.
procedure PWR_Overdrive_Enable;
-- Range 1 boost mode (R1MODE = 0) when SYSCLK ≤ 170 MHz.
-- Range 1 normal mode (R1MODE = 1) when SYSCLK ≤ 150 MHz.
-- See RM0440 ver 4 pg. 235 chapter 6.1.5 for other modes.
end STM32.RCC;
| 33.962145 | 78 | 0.558053 |
5933edbe32fd02c71e68d8074a0a9327ac3744c9 | 5,753 | adb | Ada | traceur_intermediaire.adb | zyron92/banana_tree_generator | cee785638abcba2acfadd22bf83224578e32d875 | [
"MIT"
] | null | null | null | traceur_intermediaire.adb | zyron92/banana_tree_generator | cee785638abcba2acfadd22bf83224578e32d875 | [
"MIT"
] | null | null | null | traceur_intermediaire.adb | zyron92/banana_tree_generator | cee785638abcba2acfadd22bf83224578e32d875 | [
"MIT"
] | null | null | null | with Geometry_Helpers, Ada.Numerics.Generic_Elementary_Functions;
use Geometry_Helpers;
package body Traceur_Intermediaire is
--Calcul des 2 points de contrôle du côté du sommet de départ
procedure Calcul_Point_Control(Coord_S_D, Mid: in Coord_Point; Longueur: in Float; Ctl_T, Ctl_I: out Coord_Point) is
Angle_Inc : Float := Angle_Incident_Arrete(Coord_S_D,Mid,Longueur);
Angle_Croix : Float := En_Radian(45.0);
begin
--Ctl_T.X => Point Controle Trigo du coté du sommet de départ
--Ctl_T.Y => Point Controle Inverse du coté du sommet de départ
if A_Droite(Coord_S_D, Mid) then
if En_Haut(Coord_S_D, Mid) then
-->> Arète en direction nord-ouest (sur le plan svg)
Ctl_T.X := Mid.X - Oppose(Angle_Inc,Angle_Croix,Longueur);
Ctl_T.Y := Mid.Y + Adjacent(Angle_Inc,Angle_Croix,Longueur);
Ctl_I.X := Mid.X + Adjacent(Angle_Inc,Angle_Croix,Longueur);
Ctl_I.Y := Mid.Y + Oppose(Angle_Inc,Angle_Croix,Longueur);
else
-->>Arète en direction sud-ouest (sur le plan svg)
Ctl_T.X := Mid.X + Adjacent(Angle_Inc,Angle_Croix,Longueur);
Ctl_T.Y := Mid.Y - Oppose(Angle_Inc,Angle_Croix,Longueur);
Ctl_I.X := Mid.X - Oppose(Angle_Inc,Angle_Croix,Longueur);
Ctl_I.Y := Mid.Y - Adjacent(Angle_Inc,Angle_Croix,Longueur);
end if;
else
-->>Arète en direction nord-est (sur le plan svg)
if En_Haut(Coord_S_D, Mid) then
Ctl_T.X := Mid.X - Adjacent(Angle_Inc,Angle_Croix,Longueur);
Ctl_T.Y := Mid.Y + Oppose(Angle_Inc,Angle_Croix,Longueur);
Ctl_I.X := Mid.X + Oppose(Angle_Inc,Angle_Croix,Longueur);
Ctl_I.Y := Mid.Y + Adjacent(Angle_Inc,Angle_Croix,Longueur);
-->>Arrete en direction sud-est (sur le plan svg)
else
Ctl_T.X := Mid.X + Oppose(Angle_Inc,Angle_Croix,Longueur);
Ctl_T.Y := Mid.Y - Adjacent(Angle_Inc,Angle_Croix,Longueur);
Ctl_I.X := Mid.X - Adjacent(Angle_Inc,Angle_Croix,Longueur);
Ctl_I.Y := Mid.Y - Oppose(Angle_Inc,Angle_Croix,Longueur);
end if;
end if;
end Calcul_Point_Control;
--Mise à jour des champs des points de contrôle et du point de millieu de l'arète
procedure Mise_A_Jour_Control_Milieu(Ctl_T, Ctl_I, Mid: Coord_Point; Ptr_Arr: in Ptr_Liste_Arretes_Adj) is
begin
Ptr_Arr.all.Arr.PCtl_T := Ctl_T;
Ptr_Arr.all.Arr.PCtl_I := Ctl_I;
Ptr_Arr.all.Arr.PMilieu := Mid;
--Trouver les points les plus loin dans le dessin svg pour faciliter la génération de l'entête du fichier svg
Tester_Max_Min(Ctl_T);
Tester_Max_Min(Ctl_T);
end Mise_A_Jour_Control_Milieu;
procedure Tracer_Arretes_Controls(G: in Graphe; Fichier: in File_Type; Tracer: in Boolean) is
Cour: Ptr_Liste_Arretes_Adj;
Coord_S_D, Coord_S_A, Mid, Ctl_T, Ctl_I: Coord_Point;
Longueur: Float;
begin
--D étant l'ID de sommet de départ
--Nous parcourons tous les sommets
for S in G'Range loop
--Nous parcourons toutes les arètes adjacentes au sommet S
Cour:=G(S).Liste_Arr_Adj;
while Cour /= null loop
--Coord_S_D : Coordonnées du sommet de départ & Coord_S_A : celles d'arrivée
Coord_S_D := G(S).Coord_Sommet;
Coord_S_A := G(Cour.all.Arr.Id_SomArrive).Coord_Sommet;
--Tracé d'une arète (un sommet de départ vers un sommet d'arrivée)
--si l'ID de sommet d'arrivé est plus grand que celui de départ pour ne pas redessiner l'arète
if Cour.all.Arr.Id_SomArrive > S and Tracer then
Tracer_Ligne_Droite(Coord_S_D, Coord_S_A, Fichier);
end if;
Mid := Milieu(Coord_S_D, Coord_S_A);
Longueur:= Longueur_Arrete(Coord_S_D, Coord_S_A);
--Nous avons choisi la moitié de la longueur de l'arête pour la longueur d'un trait du croix
Calcul_Point_Control(Coord_S_D, Mid, Longueur/2.0, Ctl_T, Ctl_I);
Mise_A_Jour_Control_Milieu(Ctl_T, Ctl_I, Mid, Cour);
--Tracé des segments reliant chaque point contrôle du côté du sommet de départ avec le point du milieu de l'arète
--en utilisant les champs dans l'arète qui viennent d'être mis-a-jour pour s'assurer la mise-à-jour est bonne.
if Tracer then
Tracer_Ligne_Droite(Cour.all.Arr.PCtl_T, Cour.all.Arr.PMilieu, Fichier);
Tracer_Ligne_Droite(Cour.all.Arr.PCtl_I, Cour.all.Arr.PMilieu, Fichier);
end if;
--Nous passons à l'arète adjacente au sommet de départ suivante
Cour := Cour.all.Arr_Adj_Suiv;
end loop;
end loop;
end Tracer_Arretes_Controls;
procedure Generer_Trace_Intermediaire (Nom_Fichier: in string; Couleur_Trait: in RGB; Epaisseur: in string; G: in Graphe) is
Fichier : File_Type;
begin
--Création et entêtes du fichier SVG
Create(Fichier,Out_File,Nom_Fichier);
Le_Debut(Fichier);
--Le tracé intermédiaire
Appliquer_Couleur_Epaisseur(True,Couleur_Trait,Epaisseur,Fichier);
Tracer_Arretes_Controls(G,Fichier,True);
Fin_Couleur_Translation(Fichier);
--Les queues & Fermeture du fichier SVG
La_Fin(Fichier);
Close(Fichier);
end;
procedure Le_Debut(Fichier: in File_Type) is
W,H,Translat_X,Translat_Y : Float;
begin
Taille_SVG_Translation(W,H,Translat_X,Translat_Y);
Header(W,H,Fichier);
Translation_Image(Translat_X,Translat_Y,Fichier);
end Le_Debut;
procedure La_Fin(Fichier: in File_Type) is
begin
Fin_Couleur_Translation(Fichier);
Footer(Fichier);
end La_Fin;
end Traceur_Intermediaire;
| 44.945313 | 127 | 0.664175 |
201d83b72eb1ebf8ac8df82468ef10b035f4f599 | 9,340 | adb | Ada | tests/util_tests.adb | Componolit/libsparkcrypto | 8531a07b6e9f5eb33eae0fa32759b4cbd3509d95 | [
"OpenSSL",
"Unlicense"
] | 30 | 2018-05-18T09:11:50.000Z | 2021-05-18T16:29:14.000Z | tests/util_tests.adb | Componolit/libsparkcrypto | 8531a07b6e9f5eb33eae0fa32759b4cbd3509d95 | [
"OpenSSL",
"Unlicense"
] | 15 | 2018-12-13T07:53:36.000Z | 2019-09-24T19:43:35.000Z | tests/util_tests.adb | Componolit/libsparkcrypto | 8531a07b6e9f5eb33eae0fa32759b4cbd3509d95 | [
"OpenSSL",
"Unlicense"
] | 3 | 2019-04-04T17:41:29.000Z | 2021-05-07T22:28:46.000Z | -------------------------------------------------------------------------------
-- This file is part of libsparkcrypto.
--
-- @author Alexander Senier
-- @date 2019-01-16
--
-- Copyright (C) 2018 Componolit GmbH
-- All rights reserved.
--
-- Redistribution and use in source and binary forms, with or without
-- modification, are permitted provided that the following conditions are met:
--
-- * Redistributions of source code must retain the above copyright notice,
-- this list of conditions and the following disclaimer.
--
-- * Redistributions in binary form must reproduce the above copyright
-- notice, this list of conditions and the following disclaimer in the
-- documentation and/or other materials provided with the distribution.
--
-- * Neither the name of the nor the names of its contributors may be used
-- to endorse or promote products derived from this software without
-- specific prior written permission.
--
-- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-- ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS
-- BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-- CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-- SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-- INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-- CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-- ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-- POSSIBILITY OF SUCH DAMAGE.
-------------------------------------------------------------------------------
with AUnit.Assertions; use AUnit.Assertions;
with Util;
with LSC.Types;
pragma Style_Checks (Off);
package body Util_Tests
is
use type LSC.Types.Bytes;
pragma Warnings (Off, "formal parameter ""T"" is not referenced");
procedure Test_Bytes_To_String_Simple (T : in out Test_Cases.Test_Case'Class)
is
Result : constant String := Util.B2S ((16#de#, 16#ad#, 16#be#, 16#ef#));
begin
Assert (Result = "deadbeef", "Invalid result: " & Result);
end Test_Bytes_To_String_Simple;
---------------------------------------------------------------------------
procedure Test_Bytes_To_String_Odd (T : in out Test_Cases.Test_Case'Class)
is
Result : constant String := Util.B2S ((16#c#, 16#af#, 16#ef#, 16#ee#));
begin
Assert (Result = "cafefee", "Invalid result: " & Result);
end Test_Bytes_To_String_Odd;
---------------------------------------------------------------------------
procedure Test_String_To_Bytes_Simple (T : in out Test_Cases.Test_Case'Class)
is
Result : constant LSC.Types.Bytes := Util.S2B ("deadbeef");
begin
Assert (Result = (16#de#, 16#ad#, 16#be#, 16#ef#), "Invalid result: " & Util.B2S (Result));
end Test_String_To_Bytes_Simple;
---------------------------------------------------------------------------
procedure Test_String_To_Bytes_Whitespace (T : in out Test_Cases.Test_Case'Class)
is
Result : constant LSC.Types.Bytes := Util.S2B ("01 23" & ASCII.HT & "45 67 89 ab cd ef");
begin
Assert (Result = (16#01#, 16#23#, 16#45#, 16#67#, 16#89#, 16#ab#, 16#cd#, 16#ef#),
"Invalid result: " & Util.B2S (Result));
end Test_String_To_Bytes_Whitespace;
---------------------------------------------------------------------------
procedure Test_String_To_Bytes_Odd (T : in out Test_Cases.Test_Case'Class)
is
Result : constant LSC.Types.Bytes := Util.S2B ("dead bee"); -- ;-(
begin
Assert (Result = (16#d#, 16#ea#, 16#db#, 16#ee#), "Invalid result: " & Util.B2S (Result));
end Test_String_To_Bytes_Odd;
---------------------------------------------------------------------------
procedure Test_String_To_Bytes_Surrounding (T : in out Test_Cases.Test_Case'Class)
is
Result : constant LSC.Types.Bytes := Util.S2B (" 0123456789abcdef" & ASCII.HT & " ");
begin
Assert (Result = (16#01#, 16#23#, 16#45#, 16#67#, 16#89#, 16#ab#, 16#cd#, 16#ef#),
"Invalid result: " & Util.B2S (Result));
end Test_String_To_Bytes_Surrounding;
---------------------------------------------------------------------------
procedure Test_String_To_Bytes_Uppercase (T : in out Test_Cases.Test_Case'Class)
is
Result : constant LSC.Types.Bytes := Util.S2B ("ADF3456789aBCdEf");
begin
Assert (Result = (16#ad#, 16#f3#, 16#45#, 16#67#, 16#89#, 16#ab#, 16#cd#, 16#ef#),
"Invalid result: " & Util.B2S (Result));
end Test_String_To_Bytes_Uppercase;
---------------------------------------------------------------------------
procedure Invalid_Conversion
is
Result : constant LSC.Types.Bytes := Util.S2B ("An invalid hex string does not belong here!");
pragma Unreferenced (Result);
begin
null;
end Invalid_Conversion;
procedure Test_String_To_Bytes_Invalid (T : in out Test_Cases.Test_Case'Class)
is
begin
Assert_Exception (Invalid_Conversion'Access, "Exception expected");
end Test_String_To_Bytes_Invalid;
---------------------------------------------------------------------------
procedure Test_Text_To_Bytes_Simple (T : in out Test_Cases.Test_Case'Class)
is
Result : constant LSC.Types.Bytes := Util.T2B ("Dead Beef!");
begin
Assert (Result = (16#44#, 16#65#, 16#61#, 16#64#, 16#20#,
16#42#, 16#65#, 16#65#, 16#66#, 16#21#), "Invalid result: " & Util.B2S (Result));
end Test_Text_To_Bytes_Simple;
---------------------------------------------------------------------------
procedure Test_Bytes_To_Text_Simple (T : in out Test_Cases.Test_Case'Class)
is
Result : constant String := Util.B2T ((16#44#, 16#65#, 16#61#, 16#64#, 16#20#,
16#42#, 16#65#, 16#65#, 16#66#, 16#21#));
begin
Assert (Result = "Dead Beef!", "Invalid result: " & Result);
end Test_Bytes_To_Text_Simple;
---------------------------------------------------------------------------
procedure Test_Bytes_To_Text_To_Bytes (T : in out Test_Cases.Test_Case'Class)
is
Expected : constant LSC.Types.Bytes :=
(16#0B#, 16#46#, 16#D9#, 16#8D#, 16#A1#, 16#04#, 16#64#, 16#84#,
16#60#, 16#55#, 16#8B#, 16#3F#, 16#2B#, 16#22#, 16#4E#, 16#FE#,
16#CB#, 16#EF#, 16#32#, 16#95#, 16#A7#, 16#0E#, 16#E0#, 16#E9#,
16#CA#, 16#79#, 16#28#, 16#C9#, 16#8B#, 16#31#, 16#64#, 16#81#,
16#93#, 16#85#, 16#56#, 16#B2#, 16#28#, 16#22#, 16#A7#, 16#55#,
16#BA#, 16#4D#, 16#B2#, 16#90#, 16#D3#, 16#E4#, 16#D7#, 16#9F#);
Result : constant LSC.Types.Bytes := Util.T2B (Util.B2T (Expected));
begin
Assert (Result = Expected, "Invalid result: " & Util.B2S (Result));
end Test_Bytes_To_Text_To_Bytes;
---------------------------------------------------------------------------
procedure Test_Text_To_Bytes_To_Text (T : in out Test_Cases.Test_Case'Class)
is
Expected : constant String :=
"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do "&
"eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim " &
"ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut " &
"aliquip ex ea commodo consequat. Duis aute irure dolor in";
Result : constant String := Util.B2T (Util.T2B (Expected));
begin
Assert (Result = Expected, "Invalid result: " & Result);
end Test_Text_To_Bytes_To_Text;
---------------------------------------------------------------------------
procedure Register_Tests (T: in out Test_Case) is
use AUnit.Test_Cases.Registration;
begin
Register_Routine (T, Test_Bytes_To_String_Simple'Access, "Bytes to string (simple)");
Register_Routine (T, Test_Bytes_To_String_Odd'Access, "Bytes to string (odd)");
Register_Routine (T, Test_String_To_Bytes_Simple'Access, "String to bytes (simple)");
Register_Routine (T, Test_String_To_Bytes_Whitespace'Access, "String to bytes (whitespace)");
Register_Routine (T, Test_String_To_Bytes_Odd'Access, "String to bytes (odd)");
Register_Routine (T, Test_String_To_Bytes_Surrounding'Access, "String to bytes (surrounding whitespace)");
Register_Routine (T, Test_String_To_Bytes_Uppercase'Access, "String to bytes (uppercase)");
Register_Routine (T, Test_String_To_Bytes_Invalid'Access, "String to bytes (invalid)");
Register_Routine (T, Test_Text_To_Bytes_Simple'Access, "Text to bytes (simple)");
Register_Routine (T, Test_Bytes_To_Text_Simple'Access, "Bytes to text (simple)");
Register_Routine (T, Test_Bytes_To_Text_To_Bytes'Access, "Bytes to text to bytes");
Register_Routine (T, Test_Text_To_Bytes_To_Text'Access, "Text to bytes to text");
end Register_Tests;
---------------------------------------------------------------------------
function Name (T : Test_Case) return Test_String is
begin
return Format ("Utils");
end Name;
end Util_Tests;
| 45.560976 | 112 | 0.586188 |
3914e0f90b3f0da42207150440d8b24d5a1cd2dc | 148 | ads | Ada | gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/specs/lto12.ads | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 7 | 2020-05-02T17:34:05.000Z | 2021-10-17T10:15:18.000Z | gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/specs/lto12.ads | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | null | null | null | gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/specs/lto12.ads | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 2 | 2020-07-27T00:22:36.000Z | 2021-04-01T09:41:02.000Z | -- { dg-do compile }
-- { dg-options "-flto" { target lto } }
with Lto12_Pkg; use Lto12_Pkg;
package Lto12 is
C : constant R := F;
end Lto12;
| 13.454545 | 40 | 0.614865 |
2fa43aec5864a3e2680e31b170aaa2f67b5830bc | 5,929 | ads | Ada | src/gen/gstreamer-gst_low_level-gstreamer_0_10_gst_rtsp_gstrtspurl_h.ads | persan/A-gst | 7a39693d105617adea52680424c862a1a08f7368 | [
"Apache-2.0"
] | 1 | 2018-01-18T00:51:00.000Z | 2018-01-18T00:51:00.000Z | src/gen/gstreamer-gst_low_level-gstreamer_0_10_gst_rtsp_gstrtspurl_h.ads | persan/A-gst | 7a39693d105617adea52680424c862a1a08f7368 | [
"Apache-2.0"
] | null | null | null | src/gen/gstreamer-gst_low_level-gstreamer_0_10_gst_rtsp_gstrtspurl_h.ads | persan/A-gst | 7a39693d105617adea52680424c862a1a08f7368 | [
"Apache-2.0"
] | null | null | null | pragma Ada_2005;
pragma Style_Checks (Off);
pragma Warnings (Off);
with Interfaces.C; use Interfaces.C;
with GStreamer.GST_Low_Level.gstreamer_0_10_gst_rtsp_gstrtsptransport_h;
with GStreamer.GST_Low_Level.gstreamer_0_10_gst_rtsp_gstrtspdefs_h;
with glib;
with glib.Values;
with System;
with GLIB; -- with GStreamer.GST_Low_Level.glibconfig_h;
with glib;
with System;
package GStreamer.GST_Low_Level.gstreamer_0_10_gst_rtsp_gstrtspurl_h is
GST_RTSP_DEFAULT_PORT : constant := 554; -- gst/rtsp/gstrtspurl.h:59
-- unsupported macro: GST_TYPE_RTSP_URL (gst_rtsp_url_get_type())
-- GStreamer
-- * Copyright (C) <2005,2006> Wim Taymans <[email protected]>
-- *
-- * This library is free software; you can redistribute it and/or
-- * modify it under the terms of the GNU Library General Public
-- * License as published by the Free Software Foundation; either
-- * version 2 of the License, or (at your option) any later version.
-- *
-- * This library 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
-- * Library General Public License for more details.
-- *
-- * You should have received a copy of the GNU Library General Public
-- * License along with this library; if not, write to the
-- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-- * Boston, MA 02111-1307, USA.
--
-- * Unless otherwise indicated, Source Code is licensed under MIT license.
-- * See further explanation attached in License Statement (distributed in the file
-- * LICENSE).
-- *
-- * Permission is hereby granted, free of charge, to any person obtaining a copy of
-- * this software and associated documentation files (the "Software"), to deal in
-- * the Software without restriction, including without limitation the rights to
-- * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
-- * of the Software, and to permit persons to whom the Software is furnished to do
-- * so, subject to the following conditions:
-- *
-- * The above copyright notice and this permission notice shall be included in all
-- * copies or substantial portions of the Software.
-- *
-- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-- * SOFTWARE.
--
--*
-- * GST_RTSP_DEFAULT_PORT:
-- *
-- * The default RTSP port to connect to.
--
type GstRTSPUrl;
--subtype GstRTSPUrl is u_GstRTSPUrl; -- gst/rtsp/gstrtspurl.h:63
--*
-- * GstRTSPUrl:
-- * @transports: the transports allowed
-- * @family: the family
-- * @user: the user
-- * @passwd: the password
-- * @host: the host
-- * @port: the port
-- * @abspath: the absolute path
-- * @query: additional query parameters
-- *
-- * This structure contains the result of a parsed RTSP URL
--
type GstRTSPUrl is record
transports : aliased GStreamer.GST_Low_Level.gstreamer_0_10_gst_rtsp_gstrtsptransport_h.GstRTSPLowerTrans; -- gst/rtsp/gstrtspurl.h:79
family : aliased GStreamer.GST_Low_Level.gstreamer_0_10_gst_rtsp_gstrtspdefs_h.GstRTSPFamily; -- gst/rtsp/gstrtspurl.h:80
user : access GLIB.gchar; -- gst/rtsp/gstrtspurl.h:81
passwd : access GLIB.gchar; -- gst/rtsp/gstrtspurl.h:82
host : access GLIB.gchar; -- gst/rtsp/gstrtspurl.h:83
port : aliased GLIB.guint16; -- gst/rtsp/gstrtspurl.h:84
abspath : access GLIB.gchar; -- gst/rtsp/gstrtspurl.h:85
query : access GLIB.gchar; -- gst/rtsp/gstrtspurl.h:86
end record;
pragma Convention (C_Pass_By_Copy, GstRTSPUrl); -- gst/rtsp/gstrtspurl.h:78
function gst_rtsp_url_get_type return GLIB.GType; -- gst/rtsp/gstrtspurl.h:89
pragma Import (C, gst_rtsp_url_get_type, "gst_rtsp_url_get_type");
function gst_rtsp_url_parse (urlstr : access GLIB.gchar; url : System.Address) return GStreamer.GST_Low_Level.gstreamer_0_10_gst_rtsp_gstrtspdefs_h.GstRTSPResult; -- gst/rtsp/gstrtspurl.h:91
pragma Import (C, gst_rtsp_url_parse, "gst_rtsp_url_parse");
function gst_rtsp_url_copy (url : access constant GstRTSPUrl) return access GstRTSPUrl; -- gst/rtsp/gstrtspurl.h:92
pragma Import (C, gst_rtsp_url_copy, "gst_rtsp_url_copy");
procedure gst_rtsp_url_free (url : access GstRTSPUrl); -- gst/rtsp/gstrtspurl.h:93
pragma Import (C, gst_rtsp_url_free, "gst_rtsp_url_free");
function gst_rtsp_url_get_request_uri (url : access constant GstRTSPUrl) return access GLIB.gchar; -- gst/rtsp/gstrtspurl.h:94
pragma Import (C, gst_rtsp_url_get_request_uri, "gst_rtsp_url_get_request_uri");
function gst_rtsp_url_decode_path_components (url : access constant GstRTSPUrl) return System.Address; -- gst/rtsp/gstrtspurl.h:95
pragma Import (C, gst_rtsp_url_decode_path_components, "gst_rtsp_url_decode_path_components");
function gst_rtsp_url_set_port (url : access GstRTSPUrl; port : GLIB.guint16) return GStreamer.GST_Low_Level.gstreamer_0_10_gst_rtsp_gstrtspdefs_h.GstRTSPResult; -- gst/rtsp/gstrtspurl.h:98
pragma Import (C, gst_rtsp_url_set_port, "gst_rtsp_url_set_port");
function gst_rtsp_url_get_port (url : access constant GstRTSPUrl; port : access GLIB.guint16) return GStreamer.GST_Low_Level.gstreamer_0_10_gst_rtsp_gstrtspdefs_h.GstRTSPResult; -- gst/rtsp/gstrtspurl.h:99
pragma Import (C, gst_rtsp_url_get_port, "gst_rtsp_url_get_port");
end GStreamer.GST_Low_Level.gstreamer_0_10_gst_rtsp_gstrtspurl_h;
| 48.598361 | 209 | 0.738404 |
1d5e904899171b32e60e78f282c03e615c12c8bf | 4,270 | ads | Ada | libraries/zlib/contrib/ada/zlib-streams.ads | tomberek/RaySAR | b8f885e1b640662b67a568cf8c41b8dcfc9a9c8d | [
"Zlib"
] | 1 | 2021-07-29T01:38:56.000Z | 2021-07-29T01:38:56.000Z | libraries/zlib/contrib/ada/zlib-streams.ads | tomberek/RaySAR | b8f885e1b640662b67a568cf8c41b8dcfc9a9c8d | [
"Zlib"
] | null | null | null | libraries/zlib/contrib/ada/zlib-streams.ads | tomberek/RaySAR | b8f885e1b640662b67a568cf8c41b8dcfc9a9c8d | [
"Zlib"
] | 1 | 2021-08-05T17:43:15.000Z | 2021-08-05T17:43:15.000Z | ----------------------------------------------------------------
-- ZLib for Ada thick binding. --
-- --
-- Copyright (C) 2002-2003 Dmitriy Anisimkov --
-- --
-- Open source license information is in the zlib.ads file. --
----------------------------------------------------------------
-- $Id: zlib-streams.ads,v 1.11 2003/08/12 13:15:31 vagul Exp $
package ZLib.Streams is
type Stream_Mode is (In_Stream, Out_Stream, Duplex);
type Stream_Access is access all Ada.Streams.Root_Stream_Type'Class;
type Stream_Type is
new Ada.Streams.Root_Stream_Type with private;
procedure Read
(Stream : in out Stream_Type;
Item : out Ada.Streams.Stream_Element_Array;
Last : out Ada.Streams.Stream_Element_Offset);
procedure Write
(Stream : in out Stream_Type;
Item : in Ada.Streams.Stream_Element_Array);
procedure Flush
(Stream : in out Stream_Type;
Mode : in Flush_Mode := Sync_Flush);
-- Flush the written data to the back stream,
-- all data placed to the compressor is flushing to the Back stream.
-- Should not be used untill necessary, becouse it is decreasing
-- compression.
function Read_Total_In (Stream : in Stream_Type) return Count;
pragma Inline (Read_Total_In);
-- Return total number of bytes read from back stream so far.
function Read_Total_Out (Stream : in Stream_Type) return Count;
pragma Inline (Read_Total_Out);
-- Return total number of bytes read so far.
function Write_Total_In (Stream : in Stream_Type) return Count;
pragma Inline (Write_Total_In);
-- Return total number of bytes written so far.
function Write_Total_Out (Stream : in Stream_Type) return Count;
pragma Inline (Write_Total_Out);
-- Return total number of bytes written to the back stream.
procedure Create
(Stream : out Stream_Type;
Mode : in Stream_Mode;
Back : in Stream_Access;
Back_Compressed : in Boolean;
Level : in Compression_Level := Default_Compression;
Strategy : in Strategy_Type := Default_Strategy;
Header : in Header_Type := Default;
Read_Buffer_Size : in Ada.Streams.Stream_Element_Offset
:= Default_Buffer_Size;
Write_Buffer_Size : in Ada.Streams.Stream_Element_Offset
:= Default_Buffer_Size);
-- Create the Comression/Decompression stream.
-- If mode is In_Stream then Write operation is disabled.
-- If mode is Out_Stream then Read operation is disabled.
-- If Back_Compressed is true then
-- Data written to the Stream is compressing to the Back stream
-- and data read from the Stream is decompressed data from the Back stream.
-- If Back_Compressed is false then
-- Data written to the Stream is decompressing to the Back stream
-- and data read from the Stream is compressed data from the Back stream.
-- !!! When the Need_Header is False ZLib-Ada is using undocumented
-- ZLib 1.1.4 functionality to do not create/wait for ZLib headers.
procedure Close (Stream : in out Stream_Type);
private
use Ada.Streams;
type Buffer_Access is access all Stream_Element_Array;
type Stream_Type
is new Root_Stream_Type with
record
Mode : Stream_Mode;
Buffer : Buffer_Access;
Rest_First : Stream_Element_Offset;
Rest_Last : Stream_Element_Offset;
-- Buffer for Read operation.
-- We need to have this buffer in the record
-- becouse not all read data from back stream
-- could be processed during the read operation.
Buffer_Size : Stream_Element_Offset;
-- Buffer size for write operation.
-- We do not need to have this buffer
-- in the record becouse all data could be
-- processed in the write operation.
Back : Stream_Access;
Reader : Filter_Type;
Writer : Filter_Type;
end record;
end ZLib.Streams;
| 37.787611 | 79 | 0.614754 |
12b60f594cc5052544c91ecbab458976b1c1b20a | 5,429 | adb | Ada | src/histogram.adb | sebsgit/textproc | 2f12d6a030425e937ee0c6a67dcff6828fc1331f | [
"MIT"
] | null | null | null | src/histogram.adb | sebsgit/textproc | 2f12d6a030425e937ee0c6a67dcff6828fc1331f | [
"MIT"
] | null | null | null | src/histogram.adb | sebsgit/textproc | 2f12d6a030425e937ee0c6a67dcff6828fc1331f | [
"MIT"
] | null | null | null | with Ada.Numerics.Generic_Elementary_Functions;
with Ada.Exceptions;
with Ada.Strings.Unbounded;
use Ada.Strings.Unbounded;
package body Histogram
with SPARK_Mode => On
is
package Float_Functions is new Ada.Numerics.Generic_Elementary_Functions(Float);
use Float_Functions;
procedure set(d: out Data; i:Natural; value: Float) is
begin
d.bin(i + 1) := value;
end set;
function get(d: Data; i: Natural) return Float is
begin
return d.bin(i + 1);
end get;
function size(d: Data) return Natural is
begin
return d.bin'Length;
end size;
function sum(d: Data) return Float is
result: Float := 0.0;
begin
for i in d.bin'Range loop
result := result + d.bin(i);
end loop;
return result;
end sum;
function average(d: Data) return Float is
begin
return d.sum / Float(d.size);
end average;
function normalized(d: Data) return Data is
result: Data(d.size);
total: constant Float := d.sum;
begin
for i in result.bin'Range loop
result.bin(i) := d.bin(i) / total;
end loop;
return result;
end normalized;
procedure normalize(d: in out Data) is
total: constant Float := d.sum;
begin
if total /= 0.0 then
for i in d.bin'Range loop
d.bin(i) := d.bin(i) / total;
end loop;
end if;
end normalize;
function resized(d: Data; size: Positive) return Data is
result: Data(size);
scale: Float;
begin
if d.size = size then
return d;
end if;
result.set(0, d.get(0));
result.set(result.size - 1, d.get(d.size - 1));
scale := Float(d.size - 1) / Float(size - 1);
for i in 1 .. result.size - 2 loop
declare
newCoord: constant Float := scale * Float(i);
x0: constant Float := Float'Floor(newCoord);
x1: constant Float := x0 + 1.0;
weight0: constant Float := 1.0 - (newCoord - x0);
weight1: constant Float := 1.0 - weight0;
total: constant Float := weight0 * d.get(Natural(x0)) + weight1 * d.get(Natural(x1));
begin
result.set(i, total);
end;
end loop;
return result;
end resized;
procedure multiply(d: in out Data; value: Float) is
begin
for i in 0 .. d.size - 1 loop
d.set(i, d.get(i) * value);
end loop;
end multiply;
function multiplied(d: Data; value: Float) return Data is
result: Data := (size => d.size, bin => d.bin);
begin
for i in 0 .. d.size - 1 loop
result.set(i, d.get(i) * value);
end loop;
return result;
end multiplied;
function compare(d0, d1: Data; method: CompareMethod) return Float
is
result: Float := 0.0;
avg0: constant Float := d0.average;
avg1: constant Float := d1.average;
begin
case method is
when Correlation =>
declare
a: Float := 0.0;
b: Float := 0.0;
c: Float := 0.0;
begin
for i in d0.bin'Range loop
a := a + (d0.bin(i) - avg0) * (d1.bin(i) - avg1);
b := b + (d0.bin(i) - avg0) ** 2;
c := c + (d1.bin(i) - avg1) ** 2;
end loop;
if b = 0.0 and c = 0.0 then
result := 0.0;
elsif b = 0.0 then
result := c;
elsif c = 0.0 then
result := b;
else
result := a / Sqrt(b * c);
end if;
end;
when ChiSquare =>
begin
for i in d0.bin'Range loop
if d0.bin(i) = 0.0 then
result := result + d1.bin(i);
else
result := result + Float((d0.bin(i) - d1.bin(i)) * (d0.bin(i) - d1.bin(i))) / Float(d0.bin(i));
end if;
end loop;
end;
when Bhattacharyya =>
declare
a: Float := 0.0;
begin
if avg0 = 0.0 and avg1 = 0.0 then
result := 0.0;
elsif avg1 = 0.0 then
result := 1.0;
elsif avg0 = 0.0 then
result := 1.0;
else
for i in d0.bin'Range loop
a := a + Sqrt(d0.bin(i) * d1.bin(i));
end loop;
a := a / Sqrt(avg1 * avg0 * Float(d0.size ** 2));
if a > 1.0 then
a := 1.0;
end if;
result := Sqrt(1.0 - a);
end if;
end;
end case;
return result;
end compare;
function add(d0, d1: Data) return Data is
result: Data(d0.size);
begin
for i in 0 .. d0.size - 1 loop
result.set(i, d0.get(i) + d1.get(i));
end loop;
return result;
end add;
function toString(d: Data) return Ada.Strings.Unbounded.Unbounded_String is
result: Ada.Strings.Unbounded.Unbounded_String;
begin
result := Ada.Strings.Unbounded.To_Unbounded_String("[");
for i in 0 .. d.size - 2 loop
result := result & Float(d.get(i))'Image & ", ";
end loop;
result := result & Float(d.get(d.size - 1))'Image & "]";
return result;
end toString;
end Histogram;
| 29.032086 | 116 | 0.496961 |
12b68d7a9da147986fbbe6660839ff6c47a7edee | 726 | ads | Ada | source/torrent-initiators.ads | reznikmm/torrent | 7b32dbab106a54846000409e79f853339b7ecd64 | [
"MIT"
] | 4 | 2019-12-14T19:02:48.000Z | 2020-12-06T16:56:33.000Z | source/torrent-initiators.ads | reznikmm/torrent | 7b32dbab106a54846000409e79f853339b7ecd64 | [
"MIT"
] | null | null | null | source/torrent-initiators.ads | reznikmm/torrent | 7b32dbab106a54846000409e79f853339b7ecd64 | [
"MIT"
] | null | null | null | -- Copyright (c) 2020 Maxim Reznik <[email protected]>
--
-- SPDX-License-Identifier: MIT
-- License-Filename: LICENSE
-------------------------------------------------------------
with GNAT.Sockets;
with Torrent.Connections;
with Torrent.Downloaders;
limited with Torrent.Contexts;
package Torrent.Initiators is
task type Initiator
(Port : Natural;
Context : not null access Torrent.Contexts.Context;
Recycle : not null access
Torrent.Connections.Queue_Interfaces.Queue'Class)
is
entry Connect
(Downloader : not null Torrent.Downloaders.Downloader_Access;
Address : GNAT.Sockets.Sock_Addr_Type);
entry Stop;
end Initiator;
end Torrent.Initiators;
| 25.928571 | 69 | 0.64876 |
1d3794f7176a351dabec05da545a59047a9405f4 | 13,151 | ads | Ada | src/notify-notification.ads | VitalijBondarenko/notifyada | 6bda83bf698b97fff150e2f7bc49d0684a7eb7d5 | [
"MIT"
] | null | null | null | src/notify-notification.ads | VitalijBondarenko/notifyada | 6bda83bf698b97fff150e2f7bc49d0684a7eb7d5 | [
"MIT"
] | null | null | null | src/notify-notification.ads | VitalijBondarenko/notifyada | 6bda83bf698b97fff150e2f7bc49d0684a7eb7d5 | [
"MIT"
] | null | null | null | ------------------------------------------------------------------------------
-- --
-- Copyright (c) 2014-2021 Vitalii Bondarenko <[email protected]> --
-- --
------------------------------------------------------------------------------
-- --
-- The MIT License (MIT) --
-- --
-- Permission is hereby granted, free of charge, to any person obtaining a --
-- copy of this software and associated documentation files (the --
-- "Software"), to deal in the Software without restriction, including --
-- without limitation the rights to use, copy, modify, merge, publish, --
-- distribute, sublicense, and/or sell copies of the Software, and to --
-- permit persons to whom the Software is furnished to do so, subject to --
-- the following conditions: --
-- --
-- The above copyright notice and this permission notice shall be included --
-- in all copies or substantial portions of the Software. --
-- --
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS --
-- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF --
-- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. --
-- IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY --
-- CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, --
-- TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE --
-- SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. --
------------------------------------------------------------------------------
-- Notify_Notification — A passive pop-up notification.
with Gdk.Pixbuf; use Gdk.Pixbuf;
with Glib; use Glib;
with Glib.Object; use Glib.Object;
with Glib.Error; use Glib.Error;
with Glib.Properties;
with Glib.Variant; use Glib.Variant;
package Notify.Notification is
type Notify_Notification_Record is new GObject_Record with null record;
type Notify_Notification is access all Notify_Notification_Record'Class;
NOTIFY_EXPIRES_DEFAULT : constant Integer := -1;
-- The default expiration time on a notification.
NOTIFY_EXPIRES_NEVER : constant Integer := 0;
-- The notification never expires. It stays open until closed by the
-- calling API or the user.
type Notify_Urgency is
(NOTIFY_URGENCY_LOW,
NOTIFY_URGENCY_NORMAL,
NOTIFY_URGENCY_CRITICAL);
pragma Convention (C, Notify_Urgency);
-- The urgency level of the notification.
-- NOTIFY_URGENCY_LOW : Low urgency. Used for unimportant notifications.
-- NOTIFY_URGENCY_NORMAL : Normal urgency. Used for most standard
-- notifications.
-- NOTIFY_URGENCY_CRITICAL: Critical urgency. Used for very important
-- notifications.
function Notify_Notification_Get_Type return Glib.GType;
procedure G_New
(Notification : out Notify_Notification;
Summary : UTF8_String;
Body_Text : UTF8_String := "";
Icon_Name : UTF8_String := "");
-- Creates a new Notification. The summary text is required, but all other
-- parameters are optional.
--
-- Notification : Returns the new Notify_Notification.
-- Summary : The required summary text.
-- Body_Text : The optional body text.
-- Icon_Name : The optional icon theme icon name or filename.
procedure Initialize
(Notification : not null access Notify_Notification_Record'Class;
Summary : UTF8_String;
Body_Text : UTF8_String;
Icon_Name : UTF8_String);
-- Initializes a newly created Notification.
function Update
(Notification : not null access Notify_Notification_Record;
Summary : UTF8_String;
Body_Text : UTF8_String := "";
Icon_Name : UTF8_String := "") return Boolean;
-- Updates the notification text and icon. This won't send the update out
-- and display it on the screen. For that, you will need to call Show.
--
-- Notification : The notification to update.
-- Summary : The new required summary text.
-- Body_Text : The optional body text.
-- Icon_Name : The optional icon theme icon name or filename.
-- Returns : TRUE, unless an invalid parameter was passed.
function Show
(Notification : not null access Notify_Notification_Record;
Error : access GError := null) return Boolean;
-- Tells the notification server to display the notification on the screen.
--
-- Notification : The notification.
-- Error : The returned error information.
-- Returns : TRUE if successful. On error, this will return FALSE and
-- set error.
procedure Set_Timeout
(Notification : not null access Notify_Notification_Record;
Timeout : Integer);
-- Sets the timeout of the Notification. To set the default time, pass
-- NOTIFY_EXPIRES_DEFAULT as timeout. To set the notification to never
-- expire, pass NOTIFY_EXPIRES_NEVER.
--
-- Note that the timeout may be ignored by the server.
--
-- Notification : The notification.
-- Timeout : The timeout in milliseconds.
procedure Set_Category
(Notification : not null access Notify_Notification_Record;
Category : String);
-- Sets the category of this Notification. This can be used by the
-- notification server to filter or display the data in a certain way.
--
-- Notification : The notification.
-- Category : The category.
procedure Set_Urgency
(Notification : not null access Notify_Notification_Record;
Urgency : Notify_Urgency);
-- Sets the urgency level of this notification.
-- See: Notify_Urgency
--
-- Notification : The notification.
-- Urgency : The urgency level.
procedure Set_Image_From_Pixbuf
(Notification : not null access Notify_Notification_Record;
Pixbuf : Gdk_Pixbuf);
-- Sets the image in the notification from a GdkPixbuf.
--
-- Notification : The notification.
-- Pixbuf : The image.
procedure Set_Hint
(Notification : not null access Notify_Notification_Record;
Key : String;
Value : GVariant);
-- Sets a hint for Key with value Value. If Value is NULL, a previously
-- set hint for key is unset.
-- If value is floating, it is consumed.
--
-- Notification : A Notify_Notification.
-- Key : The hint key.
-- Value : The hint value, or NULL to unset the hint.
procedure Set_App_Name
(Notification : not null access Notify_Notification_Record;
App_Name : String);
-- Sets the application name for the Notification. If this function is not
-- called or if App_Name is blank, the application name will be set from
-- the value used in Notify_Init or overridden with Notify_Set_App_Name.
--
-- Notification : A Notify_Notification.
-- App_Name : The localised application name.
procedure Clear_Hints
(Notification : not null access Notify_Notification_Record);
-- Clears all hints from the notification.
--
-- Notification : The notification.
type Notify_Action_Callback_Void is not null access procedure
(Notification : Notify_Notification;
Action : UTF8_String);
-- An action callback function.
procedure Add_Action
(Notification : not null access Notify_Notification_Record;
Action : UTF8_String;
Label : UTF8_String;
Callback : Notify_Action_Callback_Void);
-- Adds an Action to a Notification. When the Action is invoked, the
-- specified Callback function will be called, along with the value passed
-- to User_Data.
--
-- Notification : The notification.
-- Action : The action ID.
-- Label : The human-readable action label.
-- Callback : The action's callback function.
procedure Clear_Actions
(Notification : not null access Notify_Notification_Record);
-- Clears all actions from the notification.
--
-- Notification : The notification.
function Close
(Notification : not null access Notify_Notification_Record;
Error : access GError := null) return Boolean;
-- Synchronously tells the notification server to hide the notification on
-- the screen.
--
-- Notification : The notification.
-- Error : The returned error information.
-- Returns : TRUE on success, or FALSE on error with error filled in.
function Get_Closed_Reason
(Notification : not null access Notify_Notification_Record) return Integer;
-- Returns the closed reason code for the Notification. This is valid only
-- after the "closed" signal is emitted.
--
-- Notification : The notification.
-- Returns : The closed reason code.
----------------------------------
-- package Add_Action_User_Data --
----------------------------------
generic
type User_Data_Type (<>) is private;
with procedure Destroy (Data : in out User_Data_Type) is null;
package Add_Action_User_Data is
type Notify_Action_Callback_Void is not null access procedure
(Notification : Notify_Notification;
Action : UTF8_String;
User_Data : User_Data_Type);
-- An action callback function.
procedure Add_Action
(Notification : not null access Notify_Notification_Record'Class;
Action : UTF8_String;
Label : UTF8_String;
Callback : Notify_Action_Callback_Void;
User_Data : User_Data_Type);
-- Adds an Action to a Notification. When the Action is invoked, the
-- specified Callback function will be called, along with the value passed
-- to User_Data.
--
-- Notification : The notification.
-- Action : The action ID.
-- Label : The human-readable action label.
-- Callback : The action's callback function.
-- User_Data : Custom data to pass to callback.
end Add_Action_User_Data;
----------------
-- Properties --
----------------
App_Name_Property : constant Glib.Properties.Property_String;
-- The application name to use for this notification.
-- Default value: ""
Body_Property : constant Glib.Properties.Property_String;
-- The message body text.
-- Default value: ""
Closed_Reason_Property : constant Glib.Properties.Property_Int;
-- The reason code for why the notification was closed.
-- Allowed values: >= -1
-- Default value : -1
Icon_Name_Property : constant Glib.Properties.Property_String;
-- The icon filename or icon theme-compliant name.
-- Default value: ""
Id_Property : constant Glib.Properties.Property_Int;
-- The notification ID.
-- Allowed values: >= 0
-- Default value : 0
Summary_Property : constant Glib.Properties.Property_String;
-- The summary text.
-- Default value: ""
-------------
-- Signals --
-------------
type Cb_Notify_Notification_Void is not null access procedure
(Self : access Notify_Notification_Record'Class);
type Cb_GObject_Void is not null access procedure
(Self : access Glib.Object.GObject_Record'Class);
Signal_Closed : constant Glib.Signal_Name := "closed";
procedure On_Closed
(Self : not null access Notify_Notification_Record;
Call : Cb_Notify_Notification_Void;
After : Boolean := False);
procedure On_Closed
(Self : not null access Notify_Notification_Record;
Call : Cb_GObject_Void;
Slot : not null access Glib.Object.GObject_Record'Class;
After : Boolean := False);
-- The "closed" signal.
-- Emitted when the notification is closed.
private
App_Name_Property : constant Glib.Properties.Property_String :=
Glib.Properties.Build ("app-name");
Body_Property : constant Glib.Properties.Property_String :=
Glib.Properties.Build ("body");
Closed_Reason_Property : constant Glib.Properties.Property_Int :=
Glib.Properties.Build ("closed-reason");
Icon_Name_Property : constant Glib.Properties.Property_String :=
Glib.Properties.Build ("icon-name");
Id_Property : constant Glib.Properties.Property_Int :=
Glib.Properties.Build ("id");
Summary_Property : constant Glib.Properties.Property_String :=
Glib.Properties.Build ("summary");
end Notify.Notification;
| 41.225705 | 81 | 0.623603 |
1dcaa17ddddadd63dcf5532b0d1f886cc9733184 | 80 | ads | Ada | src/common/sp.ads | jquorning/septum | 6c9ccb6ed58429a144f44db0f3e2e72028655890 | [
"Apache-2.0"
] | null | null | null | src/common/sp.ads | jquorning/septum | 6c9ccb6ed58429a144f44db0f3e2e72028655890 | [
"Apache-2.0"
] | null | null | null | src/common/sp.ads | jquorning/septum | 6c9ccb6ed58429a144f44db0f3e2e72028655890 | [
"Apache-2.0"
] | null | null | null | package SP
with Pure
is
Version : constant String := "0.0.5";
end SP;
| 10 | 41 | 0.6 |
0b551dc4ce9e7549be50de37df7710d540731386 | 830 | ads | Ada | contrib/gnu/gdb/dist/gdb/testsuite/gdb.ada/watch_minus_l/pck.ads | TheSledgeHammer/2.11BSD | fe61f0b9aaa273783cd027c7b5ec77e95ead2153 | [
"BSD-3-Clause"
] | 3 | 2021-05-04T17:09:06.000Z | 2021-10-04T07:19:26.000Z | contrib/gnu/gdb/dist/gdb/testsuite/gdb.ada/watch_minus_l/pck.ads | TheSledgeHammer/2.11BSD | fe61f0b9aaa273783cd027c7b5ec77e95ead2153 | [
"BSD-3-Clause"
] | null | null | null | contrib/gnu/gdb/dist/gdb/testsuite/gdb.ada/watch_minus_l/pck.ads | TheSledgeHammer/2.11BSD | fe61f0b9aaa273783cd027c7b5ec77e95ead2153 | [
"BSD-3-Clause"
] | null | null | null | -- Copyright 2018-2020 Free Software Foundation, Inc.
--
-- 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 3 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, see <http://www.gnu.org/licenses/>.
with System;
package Pck is
Global_Var : Integer := 0;
procedure Do_Nothing (A : System.Address);
end Pck;
| 36.086957 | 73 | 0.731325 |
06fb698c2dd7c882a5bd6582ea1d45baab15f1a2 | 6,026 | adb | Ada | regtests/util-beans-objects-record_tests.adb | yrashk/ada-util | 2aaa1d87e92a7137e1c63dce90f0722c549dfafd | [
"Apache-2.0"
] | 60 | 2015-01-18T23:05:34.000Z | 2022-03-20T18:56:30.000Z | regtests/util-beans-objects-record_tests.adb | yrashk/ada-util | 2aaa1d87e92a7137e1c63dce90f0722c549dfafd | [
"Apache-2.0"
] | 20 | 2016-09-15T16:41:30.000Z | 2022-03-29T22:02:32.000Z | regtests/util-beans-objects-record_tests.adb | yrashk/ada-util | 2aaa1d87e92a7137e1c63dce90f0722c549dfafd | [
"Apache-2.0"
] | 10 | 2015-02-13T04:00:45.000Z | 2022-03-20T18:57:54.000Z | -----------------------------------------------------------------------
-- util-beans-objects-record_tests -- Unit tests for objects.records package
-- Copyright (C) 2011, 2017, 2021 Stephane Carrez
-- Written by Stephane Carrez ([email protected])
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you may not use this file except in compliance with the License.
-- You may obtain a copy of the License at
--
-- http://www.apache.org/licenses/LICENSE-2.0
--
-- Unless required by applicable law or agreed to in writing, software
-- distributed under the License is distributed on an "AS IS" BASIS,
-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-- See the License for the specific language governing permissions and
-- limitations under the License.
-----------------------------------------------------------------------
with Util.Test_Caller;
with Util.Strings;
with Util.Beans.Basic;
with Util.Beans.Objects.Vectors;
with Util.Beans.Objects.Records;
package body Util.Beans.Objects.Record_Tests is
use Util.Tests;
package Caller is new Util.Test_Caller (Test, "Beans.Records");
procedure Add_Tests (Suite : in Util.Tests.Access_Test_Suite) is
begin
Caller.Add_Test (Suite, "Test Util.Beans.Objects.Records",
Test_Record'Access);
Caller.Add_Test (Suite, "Test Util.Beans.Basic",
Test_Bean'Access);
end Add_Tests;
type Data is record
Name : Unbounded_String;
Value : Util.Beans.Objects.Object;
end record;
package Data_Bean is new Util.Beans.Objects.Records (Data);
use type Data_Bean.Element_Type_Access;
subtype Data_Access is Data_Bean.Element_Type_Access;
procedure Test_Record (T : in out Test) is
D : Data;
begin
D.Name := To_Unbounded_String ("testing");
D.Value := To_Object (Integer (23));
declare
V : Object := Data_Bean.To_Object (D);
P : constant Data_Access := Data_Bean.To_Element_Access (V);
V2 : constant Object := V;
begin
T.Assert (not Is_Empty (V), "Object with data record should not be empty");
T.Assert (not Is_Null (V), "Object with data record should not be null");
T.Assert (P /= null, "To_Element_Access returned null");
Assert_Equals (T, "testing", To_String (P.Name), "Data name is not the same");
Assert_Equals (T, 23, To_Integer (P.Value), "Data value is not the same");
V := Data_Bean.Create;
declare
D2 : constant Data_Access := Data_Bean.To_Element_Access (V);
begin
T.Assert (D2 /= null, "Null element");
D2.Name := To_Unbounded_String ("second test");
D2.Value := V2;
end;
V := Data_Bean.To_Object (D);
end;
end Test_Record;
type Bean_Type is new Util.Beans.Basic.Readonly_Bean with record
Name : Unbounded_String;
end record;
type Bean_Type_Access is access all Bean_Type'Class;
overriding
function Get_Value (Bean : in Bean_Type;
Name : in String) return Util.Beans.Objects.Object;
overriding
function Get_Value (Bean : in Bean_Type;
Name : in String) return Util.Beans.Objects.Object is
begin
if Name = "name" then
return Util.Beans.Objects.To_Object (Bean.Name);
elsif Name = "length" then
return Util.Beans.Objects.To_Object (Length (Bean.Name));
else
return Util.Beans.Objects.Null_Object;
end if;
end Get_Value;
procedure Test_Bean (T : in out Test) is
use Basic;
Static : aliased Bean_Type;
begin
Static.Name := To_Unbounded_String ("Static");
-- Allocate dynamically several Bean_Type objects and drop the list.
-- The memory held by internal proxy as well as the Bean_Type must be freed.
-- The static bean should never be freed!
for I in 1 .. 10 loop
declare
List : Util.Beans.Objects.Vectors.Vector;
Value : Util.Beans.Objects.Object;
Bean : Bean_Type_Access;
P : access Readonly_Bean'Class;
begin
for J in 1 .. 1_000 loop
if I = J then
Value := To_Object (Static'Unchecked_Access, Objects.STATIC);
List.Append (Value);
end if;
Bean := new Bean_Type;
Bean.Name := To_Unbounded_String ("B" & Util.Strings.Image (J));
Value := To_Object (Bean);
List.Append (Value);
end loop;
-- Verify each bean of the list
for J in 1 .. 1_000 + 1 loop
Value := List.Element (J);
-- Check some common status.
T.Assert (not Is_Null (Value), "The value should hold a bean");
T.Assert (Get_Type (Value) = TYPE_BEAN, "The value should hold a bean");
T.Assert (not Is_Empty (Value), "The value should not be empty");
-- Check the bean access.
P := To_Bean (Value);
T.Assert (P /= null, "To_Bean returned null");
Bean := Bean_Type'Class (P.all)'Unchecked_Access;
-- Check we have the good bean object.
if I = J then
Assert_Equals (T, "Static", To_String (Bean.Name),
"Bean at" & Integer'Image (J) & " is invalid");
elsif J > I then
Assert_Equals (T, "B" & Util.Strings.Image (J - 1), To_String (Bean.Name),
"Bean at" & Integer'Image (J) & " is invalid");
else
Assert_Equals (T, "B" & Util.Strings.Image (J), To_String (Bean.Name),
"Bean at" & Integer'Image (J) & " is invalid");
end if;
end loop;
end;
end loop;
end Test_Bean;
end Util.Beans.Objects.Record_Tests;
| 37.899371 | 92 | 0.579655 |
a18eed400c1230d720ed4f852ac8ac5a02904723 | 7,989 | adb | Ada | deps/gid/test/steg.adb | Roldak/OpenGLAda | 6807605b7321249d71286fa25231bdfd537d3eac | [
"MIT"
] | null | null | null | deps/gid/test/steg.adb | Roldak/OpenGLAda | 6807605b7321249d71286fa25231bdfd537d3eac | [
"MIT"
] | null | null | null | deps/gid/test/steg.adb | Roldak/OpenGLAda | 6807605b7321249d71286fa25231bdfd537d3eac | [
"MIT"
] | null | null | null | --
-- Minimal steganography tool.
--
-- This demo is derived from mini.adb.
--
-- To do:
-- - encryption
with GID;
with Ada.Calendar;
with Ada.Characters.Handling; use Ada.Characters.Handling;
with Ada.Command_Line; use Ada.Command_Line;
with Ada.Numerics.Elementary_Functions; use Ada.Numerics.Elementary_Functions;
with Ada.Streams.Stream_IO; use Ada.Streams.Stream_IO;
with Ada.Text_IO; use Ada.Text_IO;
with Ada.Unchecked_Deallocation;
with Interfaces;
procedure Steg is
procedure Blurb is
begin
Put_Line(Standard_Error, "Steg * Minimal steganography tool");
New_Line(Standard_Error);
Put_Line(Standard_Error, " Encoding: converts any image file to a PPM image file, with");
Put_Line(Standard_Error, " inclusion of a hidden data file. The PPM image can then");
Put_Line(Standard_Error, " be converted to a lossless-compressed format like PNG.");
New_Line(Standard_Error);
Put_Line(Standard_Error, " Decoding: extracts a hidden file from an image.");
New_Line(Standard_Error);
Put_Line(Standard_Error, "GID version " & GID.version & " dated " & GID.reference);
Put_Line(Standard_Error, "URL: " & GID.web);
New_Line(Standard_Error);
Put_Line(Standard_Error, "Syntax:");
Put_Line(Standard_Error, " steg [e|d] <image> <file>");
New_Line(Standard_Error);
end Blurb;
use Interfaces;
type Byte_Array is array(Integer range <>) of Unsigned_8;
type p_Byte_Array is access Byte_Array;
procedure Dispose is new Ada.Unchecked_Deallocation(Byte_Array, p_Byte_Array);
img_buf: p_Byte_Array:= null;
-- Load image into a 24-bit truecolor RGB raw bitmap (for a PPM output)
procedure Load_raw_image(
image : in out GID.Image_descriptor;
buffer: in out p_Byte_Array;
next_frame: out Ada.Calendar.Day_Duration
)
is
subtype Primary_color_range is Unsigned_8;
image_width : constant Positive:= GID.Pixel_width(image);
image_height: constant Positive:= GID.Pixel_height(image);
idx: Natural;
--
procedure Set_X_Y (x, y: Natural) is
begin
idx:= 3 * (x + image_width * (image_height - 1 - y));
end Set_X_Y;
--
procedure Put_Pixel (
red, green, blue : Primary_color_range;
alpha : Primary_color_range
)
is
pragma Warnings(off, alpha); -- alpha is just ignored
begin
buffer(idx..idx+2):= (red, green, blue);
idx:= idx + 3;
-- ^ GID requires us to look to next pixel on the right for next time.
end Put_Pixel;
stars: Natural:= 0;
procedure Feedback(percents: Natural) is
so_far: constant Natural:= percents / 5;
begin
for i in stars+1..so_far loop
Put( Standard_Error, '*');
end loop;
stars:= so_far;
end Feedback;
procedure Load_image is
new GID.Load_image_contents(
Primary_color_range, Set_X_Y,
Put_Pixel, Feedback, GID.fast
);
begin
Dispose(buffer);
buffer:= new Byte_Array(0..3 * image_width * image_height - 1);
Load_image(image, next_frame);
end Load_raw_image;
procedure Dump_PPM(name: String; i: GID.Image_descriptor) is
f: Ada.Streams.Stream_IO.File_Type;
ppm_name: constant String:= name & ".ppm";
begin
Create(f, Out_File, ppm_name);
Put_Line(Standard_Error, "Creating PPM image, name = " & ppm_name & " ...");
-- PPM Header:
String'Write(
Stream(f),
"P6 " &
Integer'Image(GID.Pixel_width(i)) &
Integer'Image(GID.Pixel_height(i)) & " 255" & ASCII.LF
);
-- PPM raw BGR image:
Byte_Array'Write(Stream(f), img_buf.all);
-- ^ slow on some Ada systems, see to_bmp to have a faster version
Close(f);
end Dump_PPM;
type Operation is (encoding, decoding);
Data_too_large: exception;
procedure Process(image_name, data_name: String; op: Operation) is
f_im, f_dt: Ada.Streams.Stream_IO.File_Type;
--
procedure Encode is
idx: Natural:= img_buf'Last;
-- Start with buffer's end (image's bottom), with the hope it is "noisier":
-- often there is a blue sky or something like that on the top...
procedure Encode_byte(b: Unsigned_8) is
begin
img_buf(idx):= (img_buf(idx) and 2#1111_1100#) or (b and 2#0000_0011#); -- B
idx:= idx - 1;
img_buf(idx):= (img_buf(idx) and 2#1111_1000#) or Shift_Right(b and 2#0001_1100#, 2); -- G
idx:= idx - 1;
img_buf(idx):= (img_buf(idx) and 2#1111_1000#) or Shift_Right(b, 5); -- R
idx:= idx - 1;
end Encode_byte;
b: Unsigned_8;
data_size: Unsigned_64;
needed_size: Unsigned_64;
available_size: constant Unsigned_64:= img_buf'Length / 3; -- 1 byte per pixel;
factor: Float;
begin
Open(f_dt, In_File, data_name);
data_size:= Unsigned_64(Size(f_dt));
needed_size:= data_size + 8;
factor:= Float(needed_size) / Float(available_size);
if needed_size > available_size then
raise Data_too_large with
"Needs a" & Integer'Image(1 + Integer(100.0 * factor)) &
"% raw size scaling, i.e. a" &
Integer'Image(1 + Integer(100.0 * Sqrt(factor))) &
"% image scaling in both dimensions";
end if;
Put_Line(Standard_Error,
"Data size:" & Unsigned_64'Image(data_size) &
", using" & Integer'Image(Integer(100.0 * factor)) &
"% of image data"
);
for i in 1..8 loop
Encode_byte(Unsigned_8(data_size and 16#FF#));
data_size:= Shift_Right(data_size, 8);
end loop;
while not End_Of_File(f_dt) loop
Unsigned_8'Read(Stream(f_dt), b);
Encode_byte(b);
end loop;
Close(f_dt);
end Encode;
--
procedure Decode is
idx: Natural:= img_buf'Last;
procedure Decode_byte(b: out Unsigned_8) is
begin
b:= img_buf(idx) and 2#0000_0011#; -- B
idx:= idx - 1;
b:= b + Shift_Left(img_buf(idx) and 2#0000_0111#, 2); -- G
idx:= idx - 1;
b:= b + Shift_Left(img_buf(idx) and 2#0000_0111#, 5); -- R
idx:= idx - 1;
end Decode_byte;
b: Unsigned_8;
data_size: Unsigned_64:= 0;
begin
for i in 0..7 loop
Decode_byte(b);
data_size:= data_size + Shift_Left(Unsigned_64(b), i * 8);
end loop;
Create(f_dt, Out_File, data_name);
for i in 1..data_size loop
Decode_byte(b);
Unsigned_8'Write(Stream(f_dt), b);
end loop;
Close(f_dt);
end Decode;
--
i: GID.Image_descriptor;
up_name: constant String:= To_Upper(image_name);
--
next_frame: Ada.Calendar.Day_Duration;
begin
--
-- Load the image in its original format
--
Open(f_im, In_File, image_name);
Put_Line(Standard_Error, "Processing " & image_name & "...");
--
GID.Load_image_header(
i,
Stream(f_im).all,
try_tga =>
image_name'Length >= 4 and then
up_name(up_name'Last-3..up_name'Last) = ".TGA"
);
Put_Line(Standard_Error, ".........v.........v");
--
Load_raw_image(i, img_buf, next_frame);
New_Line(Standard_Error);
Close(f_im);
case op is
when encoding =>
Encode;
Dump_PPM(image_name, i); -- Output encoded image
when decoding =>
Decode;
end case;
end Process;
op: Operation;
begin
if Argument_Count /= 3 then
Blurb;
return;
end if;
if To_Lower(Argument(1))="e" then
op:= encoding;
elsif To_Lower(Argument(1))="d" then
op:= decoding;
else
Blurb;
return;
end if;
Process(Argument(2), Argument(3), op);
end Steg;
| 32.21371 | 101 | 0.600325 |
2fff917efbaa6e098b8152ad30df7bcc4c51f9bf | 5,347 | ads | Ada | llvm-gcc-4.2-2.9/gcc/ada/g-md5.ads | vidkidz/crossbridge | ba0bf94aee0ce6cf7eb5be882382e52bc57ba396 | [
"MIT"
] | 1 | 2016-04-09T02:58:13.000Z | 2016-04-09T02:58:13.000Z | llvm-gcc-4.2-2.9/gcc/ada/g-md5.ads | vidkidz/crossbridge | ba0bf94aee0ce6cf7eb5be882382e52bc57ba396 | [
"MIT"
] | null | null | null | llvm-gcc-4.2-2.9/gcc/ada/g-md5.ads | vidkidz/crossbridge | ba0bf94aee0ce6cf7eb5be882382e52bc57ba396 | [
"MIT"
] | null | null | null | ------------------------------------------------------------------------------
-- --
-- GNAT LIBRARY COMPONENTS --
-- --
-- G N A T . M D 5 --
-- --
-- S p e c --
-- --
-- Copyright (C) 2002-2005, AdaCore --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
-- ware Foundation; either version 2, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT 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 distributed with GNAT; see file COPYING. If not, write --
-- to the Free Software Foundation, 51 Franklin Street, Fifth Floor, --
-- Boston, MA 02110-1301, USA. --
-- --
-- As a special exception, if other files instantiate generics from this --
-- unit, or you link this unit with other files to produce an executable, --
-- this unit does not by itself cause the resulting executable to be --
-- covered by the GNU General Public License. This exception does not --
-- however invalidate any other reasons why the executable file might be --
-- covered by the GNU Public License. --
-- --
-- GNAT was originally developed by the GNAT team at New York University. --
-- Extensive contributions were provided by Ada Core Technologies Inc. --
-- --
------------------------------------------------------------------------------
-- This package implements the MD5 Message-Digest Algorithm as described in
-- RFC 1321. The complete text of RFC 1321 can be found at:
--
-- http://www.ietf.org/rfc/rfc1321.txt
--
-- The implementation is derived from the RSA Data Secutity, Inc. MD5
-- Message-Digest Algorithm, as described in RFC 1321.
with Ada.Streams;
with Interfaces;
package GNAT.MD5 is
type Context is private;
-- This type is the four-word (16 byte) MD buffer, as described in
-- RFC 1321 (3.3). It initial value is Initial_Context below.
Initial_Context : constant Context;
-- Initial value of a Context object. May be used to reinitialize
-- a Context value by simple assignment of this value to the object.
procedure Update
(C : in out Context;
Input : String);
procedure Wide_Update
(C : in out Context;
Input : Wide_String);
procedure Update
(C : in out Context;
Input : Ada.Streams.Stream_Element_Array);
-- Modify the Context C. If C has the initial value Initial_Context,
-- then, after a call to one of these procedures, Digest (C) will return
-- the Message-Digest of Input.
--
-- These procedures may be called successively with the same context and
-- different inputs, and these several successive calls will produce
-- the same final context as a call with the concatenation of the inputs.
subtype Message_Digest is String (1 .. 32);
-- The string type returned by function Digest
function Digest (C : Context) return Message_Digest;
-- Extracts the Message-Digest from a context. This function should be
-- used after one or several calls to Update.
function Digest (S : String) return Message_Digest;
function Wide_Digest (W : Wide_String) return Message_Digest;
function Digest
(A : Ada.Streams.Stream_Element_Array)
return Message_Digest;
-- These functions are equivalent to the corresponding Update (or
-- Wide_Update) on a default initialized Context, followed by Digest
-- on the resulting Context.
private
-- Magic numbers
Initial_A : constant := 16#67452301#;
Initial_B : constant := 16#EFCDAB89#;
Initial_C : constant := 16#98BADCFE#;
Initial_D : constant := 16#10325476#;
type Context is record
A : Interfaces.Unsigned_32 := Initial_A;
B : Interfaces.Unsigned_32 := Initial_B;
C : Interfaces.Unsigned_32 := Initial_C;
D : Interfaces.Unsigned_32 := Initial_D;
Buffer : String (1 .. 64) := (others => ASCII.NUL);
Last : Natural := 0;
Length : Natural := 0;
end record;
Initial_Context : constant Context :=
(A => Initial_A, B => Initial_B, C => Initial_C, D => Initial_D,
Buffer => (others => ASCII.NUL), Last => 0, Length => 0);
end GNAT.MD5;
| 47.741071 | 78 | 0.544417 |
06f71cbe91d1069ca89c1f5da2b097fb6ed2291f | 532 | adb | Ada | gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/pack3.adb | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 7 | 2020-05-02T17:34:05.000Z | 2021-10-17T10:15:18.000Z | gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/pack3.adb | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | null | null | null | gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/pack3.adb | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 2 | 2020-07-27T00:22:36.000Z | 2021-04-01T09:41:02.000Z | -- { dg-do run }
procedure Pack3 is
type U32 is mod 2 ** 32;
type Key is record
Value : U32;
Valid : Boolean;
end record;
type Key_Buffer is record
Current, Latch : Key;
end record;
type Block is record
Keys : Key_Buffer;
Stamp : U32;
end record;
pragma Pack (Block);
My_Block : Block;
My_Stamp : constant := 16#01234567#;
begin
My_Block.Stamp := My_Stamp;
My_Block.Keys.Latch := My_Block.Keys.Current;
if My_Block.Stamp /= My_Stamp then
raise Program_Error;
end if;
end;
| 16.625 | 47 | 0.648496 |
31ef71d5c3628b0962fc13aa6418e6edf2007f55 | 465 | ads | Ada | ada-blinky-full/src/tasking.ads | hfegran/efx32_ada_examples | ce98ef3042831e6ff6f1dc499205c5043bfa1d6d | [
"BSD-3-Clause"
] | null | null | null | ada-blinky-full/src/tasking.ads | hfegran/efx32_ada_examples | ce98ef3042831e6ff6f1dc499205c5043bfa1d6d | [
"BSD-3-Clause"
] | null | null | null | ada-blinky-full/src/tasking.ads | hfegran/efx32_ada_examples | ce98ef3042831e6ff6f1dc499205c5043bfa1d6d | [
"BSD-3-Clause"
] | null | null | null | with System;
package Tasking is
procedure Wait_Forever;
task Init is
pragma Priority(System.Priority'Last - 2);
end Init;
task Task_1 is
pragma Priority(System.Priority'Last - 1);
end Task_1;
task Task_2 is
pragma Priority(System.Priority'Last);
end Task_2;
procedure Last_Chance_Handler (Msg : System.Address; Line : Integer);
pragma Export (C, Last_Chance_Handler, "__gnat_last_chance_handler");
end Tasking;
| 21.136364 | 72 | 0.703226 |
31021b3d308cf5f06cfe678f62a0be1f6f07c339 | 200,640 | adb | Ada | prj/HLS/solution1/.autopilot/db/DCT_8x8_2D.adb | VenciFreeman/Compress | 2e7b3b82960333c0005a766ae55470e0e7a21327 | [
"Apache-2.0"
] | 5 | 2020-05-11T20:01:54.000Z | 2022-01-26T15:50:35.000Z | prj/HLS/solution1/.autopilot/db/DCT_8x8_2D.adb | VenciFreeman/Compress | 2e7b3b82960333c0005a766ae55470e0e7a21327 | [
"Apache-2.0"
] | null | null | null | prj/HLS/solution1/.autopilot/db/DCT_8x8_2D.adb | VenciFreeman/Compress | 2e7b3b82960333c0005a766ae55470e0e7a21327 | [
"Apache-2.0"
] | 1 | 2021-03-23T20:29:52.000Z | 2021-03-23T20:29:52.000Z | <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE boost_serialization>
<boost_serialization signature="serialization::archive" version="14">
<syndb class_id="0" tracking_level="0" version="0">
<userIPLatency>-1</userIPLatency>
<userIPName/>
<cdfg class_id="1" tracking_level="1" version="0" object_id="_0">
<name>DCT_8x8_2D</name>
<ret_bitwidth>0</ret_bitwidth>
<ports class_id="2" tracking_level="0" version="0">
<count>5</count>
<item_version>0</item_version>
<item class_id="3" tracking_level="1" version="0" object_id="_1">
<Value class_id="4" tracking_level="0" version="0">
<Obj class_id="5" tracking_level="0" version="0">
<type>1</type>
<id>1</id>
<name>G</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo class_id="6" tracking_level="0" version="0">
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName>G</originalName>
<rtlName/>
<coreName>RAM</coreName>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<direction>1</direction>
<if_type>1</if_type>
<array_size>64</array_size>
<bit_vecs class_id="7" tracking_level="0" version="0">
<count>0</count>
<item_version>0</item_version>
</bit_vecs>
</item>
<item class_id_reference="3" object_id="_2">
<Value>
<Obj>
<type>1</type>
<id>2</id>
<name>subimg</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName>subimg</originalName>
<rtlName/>
<coreName>RAM</coreName>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<direction>2</direction>
<if_type>1</if_type>
<array_size>64</array_size>
<bit_vecs>
<count>0</count>
<item_version>0</item_version>
</bit_vecs>
</item>
<item class_id_reference="3" object_id="_3">
<Value>
<Obj>
<type>1</type>
<id>3</id>
<name>shift</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName>shift</originalName>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<direction>0</direction>
<if_type>0</if_type>
<array_size>0</array_size>
<bit_vecs>
<count>0</count>
<item_version>0</item_version>
</bit_vecs>
</item>
<item class_id_reference="3" object_id="_4">
<Value>
<Obj>
<type>1</type>
<id>4</id>
<name>inv</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName>inv</originalName>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<direction>0</direction>
<if_type>0</if_type>
<array_size>0</array_size>
<bit_vecs>
<count>0</count>
<item_version>0</item_version>
</bit_vecs>
</item>
<item class_id_reference="3" object_id="_5">
<Value>
<Obj>
<type>1</type>
<id>5</id>
<name>cosMat</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName>cosMat</originalName>
<rtlName/>
<coreName>RAM</coreName>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<direction>0</direction>
<if_type>1</if_type>
<array_size>64</array_size>
<bit_vecs>
<count>0</count>
<item_version>0</item_version>
</bit_vecs>
</item>
</ports>
<nodes class_id="8" tracking_level="0" version="0">
<count>47</count>
<item_version>0</item_version>
<item class_id="9" tracking_level="1" version="0" object_id="_6">
<Value>
<Obj>
<type>0</type>
<id>12</id>
<name>inv_read</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName>inv</originalName>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>79</item>
<item>80</item>
</oprand_edges>
<opcode>read</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_7">
<Value>
<Obj>
<type>0</type>
<id>13</id>
<name>shift_read</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName>shift</originalName>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>81</item>
<item>82</item>
</oprand_edges>
<opcode>read</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_8">
<Value>
<Obj>
<type>0</type>
<id>14</id>
<name>tmp</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>97</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item class_id="11" tracking_level="0" version="0">
<first>C:\Users\Venci\Videos\Project</first>
<second class_id="12" tracking_level="0" version="0">
<count>1</count>
<item_version>0</item_version>
<item class_id="13" tracking_level="0" version="0">
<first class_id="14" tracking_level="0" version="0">
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>97</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>tmp_fu_142_p2</rtlName>
<coreName/>
</Obj>
<bitwidth>1</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>83</item>
<item>85</item>
</oprand_edges>
<opcode>icmp</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_9">
<Value>
<Obj>
<type>0</type>
<id>15</id>
<name/>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>97</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>97</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>3</count>
<item_version>0</item_version>
<item>86</item>
<item>87</item>
<item>88</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_10">
<Value>
<Obj>
<type>0</type>
<id>17</id>
<name/>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>89</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_11">
<Value>
<Obj>
<type>0</type>
<id>19</id>
<name>i_i</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName>i</originalName>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>4</bitwidth>
</Value>
<oprand_edges>
<count>4</count>
<item_version>0</item_version>
<item>91</item>
<item>92</item>
<item>94</item>
<item>95</item>
</oprand_edges>
<opcode>phi</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_12">
<Value>
<Obj>
<type>0</type>
<id>20</id>
<name>tmp_s</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>88</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>88</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>tmp_s_fu_148_p3</rtlName>
<coreName/>
</Obj>
<bitwidth>7</bitwidth>
</Value>
<oprand_edges>
<count>3</count>
<item_version>0</item_version>
<item>97</item>
<item>98</item>
<item>100</item>
</oprand_edges>
<opcode>bitconcatenate</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_13">
<Value>
<Obj>
<type>0</type>
<id>21</id>
<name>tmp_32_cast</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>88</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>88</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>tmp_32_cast_fu_156_p1</rtlName>
<coreName/>
</Obj>
<bitwidth>8</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>101</item>
</oprand_edges>
<opcode>zext</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_14">
<Value>
<Obj>
<type>0</type>
<id>22</id>
<name>exitcond1_i</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>88</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>88</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>exitcond1_i_fu_160_p2</rtlName>
<coreName/>
</Obj>
<bitwidth>1</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>102</item>
<item>104</item>
</oprand_edges>
<opcode>icmp</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_15">
<Value>
<Obj>
<type>0</type>
<id>24</id>
<name>i_1</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>88</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>88</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName>i</originalName>
<rtlName>i_1_fu_166_p2</rtlName>
<coreName/>
</Obj>
<bitwidth>4</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>105</item>
<item>107</item>
</oprand_edges>
<opcode>add</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_16">
<Value>
<Obj>
<type>0</type>
<id>25</id>
<name/>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>88</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>88</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>3</count>
<item_version>0</item_version>
<item>108</item>
<item>109</item>
<item>110</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_17">
<Value>
<Obj>
<type>0</type>
<id>27</id>
<name/>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>90</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>90</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>111</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_18">
<Value>
<Obj>
<type>0</type>
<id>29</id>
<name>j_i</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName>j</originalName>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>4</bitwidth>
</Value>
<oprand_edges>
<count>4</count>
<item_version>0</item_version>
<item>112</item>
<item>113</item>
<item>114</item>
<item>115</item>
</oprand_edges>
<opcode>phi</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_19">
<Value>
<Obj>
<type>0</type>
<id>30</id>
<name>j_i_cast3_cast</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>90</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>90</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>j_i_cast3_cast_fu_172_p1</rtlName>
<coreName/>
</Obj>
<bitwidth>8</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>116</item>
</oprand_edges>
<opcode>zext</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_20">
<Value>
<Obj>
<type>0</type>
<id>31</id>
<name>tmp_27</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>90</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>90</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>tmp_27_fu_176_p2</rtlName>
<coreName/>
</Obj>
<bitwidth>8</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>117</item>
<item>118</item>
</oprand_edges>
<opcode>add</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_21">
<Value>
<Obj>
<type>0</type>
<id>32</id>
<name>tmp_33_cast</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>90</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>90</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>tmp_33_cast_fu_181_p1</rtlName>
<coreName/>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>119</item>
</oprand_edges>
<opcode>zext</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_22">
<Value>
<Obj>
<type>0</type>
<id>33</id>
<name>subimg_addr</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>90</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>90</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>6</bitwidth>
</Value>
<oprand_edges>
<count>3</count>
<item_version>0</item_version>
<item>120</item>
<item>122</item>
<item>123</item>
</oprand_edges>
<opcode>getelementptr</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_23">
<Value>
<Obj>
<type>0</type>
<id>34</id>
<name>exitcond_i</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>89</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>89</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>exitcond_i_fu_186_p2</rtlName>
<coreName/>
</Obj>
<bitwidth>1</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>124</item>
<item>125</item>
</oprand_edges>
<opcode>icmp</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_24">
<Value>
<Obj>
<type>0</type>
<id>36</id>
<name>j_1</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>89</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>89</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName>j</originalName>
<rtlName>j_1_fu_192_p2</rtlName>
<coreName/>
</Obj>
<bitwidth>4</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>126</item>
<item>127</item>
</oprand_edges>
<opcode>add</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_25">
<Value>
<Obj>
<type>0</type>
<id>37</id>
<name/>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>89</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>89</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>3</count>
<item_version>0</item_version>
<item>128</item>
<item>129</item>
<item>130</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_26">
<Value>
<Obj>
<type>0</type>
<id>39</id>
<name>subimg_load</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>90</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>90</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>131</item>
</oprand_edges>
<opcode>load</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_27">
<Value>
<Obj>
<type>0</type>
<id>40</id>
<name>tmp_i</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>90</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>90</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>DCT_8x8_2D_fadd_3fYi_U9</rtlName>
<coreName/>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>132</item>
<item>134</item>
</oprand_edges>
<opcode>fadd</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_28">
<Value>
<Obj>
<type>0</type>
<id>41</id>
<name/>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>90</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>90</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>3</count>
<item_version>0</item_version>
<item>135</item>
<item>136</item>
<item>237</item>
</oprand_edges>
<opcode>store</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_29">
<Value>
<Obj>
<type>0</type>
<id>42</id>
<name/>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>89</lineNumber>
<contextFuncName>shift128</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>98</second>
</item>
<item>
<first>
<first>definition.cpp</first>
<second>shift128</second>
</first>
<second>89</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>137</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_30">
<Value>
<Obj>
<type>0</type>
<id>44</id>
<name/>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>90</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_31">
<Value>
<Obj>
<type>0</type>
<id>46</id>
<name/>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>138</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_32">
<Value>
<Obj>
<type>0</type>
<id>48</id>
<name/>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>101</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>101</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>139</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_33">
<Value>
<Obj>
<type>0</type>
<id>50</id>
<name>i</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName>i</originalName>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>4</bitwidth>
</Value>
<oprand_edges>
<count>4</count>
<item_version>0</item_version>
<item>141</item>
<item>142</item>
<item>143</item>
<item>144</item>
</oprand_edges>
<opcode>phi</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_34">
<Value>
<Obj>
<type>0</type>
<id>51</id>
<name>tmp_28</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>101</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>101</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>tmp_28_fu_198_p3</rtlName>
<coreName/>
</Obj>
<bitwidth>7</bitwidth>
</Value>
<oprand_edges>
<count>3</count>
<item_version>0</item_version>
<item>145</item>
<item>146</item>
<item>147</item>
</oprand_edges>
<opcode>bitconcatenate</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_35">
<Value>
<Obj>
<type>0</type>
<id>52</id>
<name>tmp_35_cast</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>101</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>101</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>tmp_35_cast_fu_206_p1</rtlName>
<coreName/>
</Obj>
<bitwidth>8</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>148</item>
</oprand_edges>
<opcode>zext</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_36">
<Value>
<Obj>
<type>0</type>
<id>53</id>
<name>exitcond1</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>101</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>101</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>exitcond1_fu_210_p2</rtlName>
<coreName/>
</Obj>
<bitwidth>1</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>149</item>
<item>150</item>
</oprand_edges>
<opcode>icmp</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_37">
<Value>
<Obj>
<type>0</type>
<id>55</id>
<name>i_2</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>101</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>101</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName>i</originalName>
<rtlName>i_2_fu_216_p2</rtlName>
<coreName/>
</Obj>
<bitwidth>4</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>151</item>
<item>152</item>
</oprand_edges>
<opcode>add</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_38">
<Value>
<Obj>
<type>0</type>
<id>56</id>
<name/>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>101</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>101</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>3</count>
<item_version>0</item_version>
<item>153</item>
<item>154</item>
<item>155</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_39">
<Value>
<Obj>
<type>0</type>
<id>58</id>
<name/>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>103</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>103</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>156</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_40">
<Value>
<Obj>
<type>0</type>
<id>60</id>
<name>j</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName>j</originalName>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>4</bitwidth>
</Value>
<oprand_edges>
<count>4</count>
<item_version>0</item_version>
<item>157</item>
<item>158</item>
<item>159</item>
<item>160</item>
</oprand_edges>
<opcode>phi</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_41">
<Value>
<Obj>
<type>0</type>
<id>61</id>
<name>j_cast1_cast</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>103</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>103</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>j_cast1_cast_fu_222_p1</rtlName>
<coreName/>
</Obj>
<bitwidth>8</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>161</item>
</oprand_edges>
<opcode>zext</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_42">
<Value>
<Obj>
<type>0</type>
<id>62</id>
<name>tmp_29</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>103</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>103</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>tmp_29_fu_226_p2</rtlName>
<coreName/>
</Obj>
<bitwidth>8</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>162</item>
<item>163</item>
</oprand_edges>
<opcode>add</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_43">
<Value>
<Obj>
<type>0</type>
<id>63</id>
<name>tmp_36_cast</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>103</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>103</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>tmp_36_cast_fu_231_p1</rtlName>
<coreName/>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>164</item>
</oprand_edges>
<opcode>zext</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_44">
<Value>
<Obj>
<type>0</type>
<id>64</id>
<name>G_addr</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>103</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>103</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>6</bitwidth>
</Value>
<oprand_edges>
<count>3</count>
<item_version>0</item_version>
<item>165</item>
<item>166</item>
<item>167</item>
</oprand_edges>
<opcode>getelementptr</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_45">
<Value>
<Obj>
<type>0</type>
<id>65</id>
<name>exitcond</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>102</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>102</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>exitcond_fu_236_p2</rtlName>
<coreName/>
</Obj>
<bitwidth>1</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>168</item>
<item>169</item>
</oprand_edges>
<opcode>icmp</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_46">
<Value>
<Obj>
<type>0</type>
<id>67</id>
<name>j_2</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>102</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>102</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName>j</originalName>
<rtlName>j_2_fu_242_p2</rtlName>
<coreName/>
</Obj>
<bitwidth>4</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>170</item>
<item>171</item>
</oprand_edges>
<opcode>add</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_47">
<Value>
<Obj>
<type>0</type>
<id>68</id>
<name/>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>102</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>102</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>3</count>
<item_version>0</item_version>
<item>172</item>
<item>173</item>
<item>174</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_48">
<Value>
<Obj>
<type>0</type>
<id>70</id>
<name>tmp_11</name>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>103</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>103</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName>grp_singleGUV_fu_121</rtlName>
<coreName/>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<oprand_edges>
<count>6</count>
<item_version>0</item_version>
<item>176</item>
<item>177</item>
<item>178</item>
<item>179</item>
<item>180</item>
<item>181</item>
</oprand_edges>
<opcode>call</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_49">
<Value>
<Obj>
<type>0</type>
<id>71</id>
<name/>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>103</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>103</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>2</count>
<item_version>0</item_version>
<item>182</item>
<item>183</item>
</oprand_edges>
<opcode>store</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_50">
<Value>
<Obj>
<type>0</type>
<id>72</id>
<name/>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>102</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>102</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>184</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_51">
<Value>
<Obj>
<type>0</type>
<id>74</id>
<name/>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>1</count>
<item_version>0</item_version>
<item>140</item>
</oprand_edges>
<opcode>br</opcode>
<m_Display>0</m_Display>
</item>
<item class_id_reference="9" object_id="_52">
<Value>
<Obj>
<type>0</type>
<id>76</id>
<name/>
<fileName>definition.cpp</fileName>
<fileDirectory>..</fileDirectory>
<lineNumber>104</lineNumber>
<contextFuncName>DCT_8x8_2D</contextFuncName>
<inlineStackInfo>
<count>1</count>
<item_version>0</item_version>
<item>
<first>C:\Users\Venci\Videos\Project</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>definition.cpp</first>
<second>DCT_8x8_2D</second>
</first>
<second>104</second>
</item>
</second>
</item>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>0</bitwidth>
</Value>
<oprand_edges>
<count>0</count>
<item_version>0</item_version>
</oprand_edges>
<opcode>ret</opcode>
<m_Display>0</m_Display>
</item>
</nodes>
<consts class_id="15" tracking_level="0" version="0">
<count>8</count>
<item_version>0</item_version>
<item class_id="16" tracking_level="1" version="0" object_id="_53">
<Value>
<Obj>
<type>2</type>
<id>84</id>
<name>empty</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<const_type>0</const_type>
<content>1</content>
</item>
<item class_id_reference="16" object_id="_54">
<Value>
<Obj>
<type>2</type>
<id>93</id>
<name>empty</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>4</bitwidth>
</Value>
<const_type>0</const_type>
<content>0</content>
</item>
<item class_id_reference="16" object_id="_55">
<Value>
<Obj>
<type>2</type>
<id>99</id>
<name>empty</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>3</bitwidth>
</Value>
<const_type>0</const_type>
<content>0</content>
</item>
<item class_id_reference="16" object_id="_56">
<Value>
<Obj>
<type>2</type>
<id>103</id>
<name>empty</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>4</bitwidth>
</Value>
<const_type>0</const_type>
<content>8</content>
</item>
<item class_id_reference="16" object_id="_57">
<Value>
<Obj>
<type>2</type>
<id>106</id>
<name>empty</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>4</bitwidth>
</Value>
<const_type>0</const_type>
<content>1</content>
</item>
<item class_id_reference="16" object_id="_58">
<Value>
<Obj>
<type>2</type>
<id>121</id>
<name>empty</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<const_type>0</const_type>
<content>0</content>
</item>
<item class_id_reference="16" object_id="_59">
<Value>
<Obj>
<type>2</type>
<id>133</id>
<name>empty</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<const_type>1</const_type>
<content>-128</content>
</item>
<item class_id_reference="16" object_id="_60">
<Value>
<Obj>
<type>2</type>
<id>175</id>
<name>singleGUV</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<bitwidth>32</bitwidth>
</Value>
<const_type>6</const_type>
<content><constant:singleGUV></content>
</item>
</consts>
<blocks class_id="17" tracking_level="0" version="0">
<count>15</count>
<item_version>0</item_version>
<item class_id="18" tracking_level="1" version="0" object_id="_61">
<Obj>
<type>3</type>
<id>16</id>
<name/>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<node_objs>
<count>4</count>
<item_version>0</item_version>
<item>12</item>
<item>13</item>
<item>14</item>
<item>15</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_62">
<Obj>
<type>3</type>
<id>18</id>
<name>.preheader4.preheader</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<node_objs>
<count>1</count>
<item_version>0</item_version>
<item>17</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_63">
<Obj>
<type>3</type>
<id>26</id>
<name>.preheader4</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<node_objs>
<count>6</count>
<item_version>0</item_version>
<item>19</item>
<item>20</item>
<item>21</item>
<item>22</item>
<item>24</item>
<item>25</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_64">
<Obj>
<type>3</type>
<id>28</id>
<name>.preheader.i.preheader</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<node_objs>
<count>1</count>
<item_version>0</item_version>
<item>27</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_65">
<Obj>
<type>3</type>
<id>38</id>
<name>.preheader.i</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<node_objs>
<count>8</count>
<item_version>0</item_version>
<item>29</item>
<item>30</item>
<item>31</item>
<item>32</item>
<item>33</item>
<item>34</item>
<item>36</item>
<item>37</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_66">
<Obj>
<type>3</type>
<id>43</id>
<name/>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<node_objs>
<count>4</count>
<item_version>0</item_version>
<item>39</item>
<item>40</item>
<item>41</item>
<item>42</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_67">
<Obj>
<type>3</type>
<id>45</id>
<name>.preheader4.loopexit</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<node_objs>
<count>1</count>
<item_version>0</item_version>
<item>44</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_68">
<Obj>
<type>3</type>
<id>47</id>
<name>._crit_edge.loopexit</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<node_objs>
<count>1</count>
<item_version>0</item_version>
<item>46</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_69">
<Obj>
<type>3</type>
<id>49</id>
<name>._crit_edge</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<node_objs>
<count>1</count>
<item_version>0</item_version>
<item>48</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_70">
<Obj>
<type>3</type>
<id>57</id>
<name>.loopexit</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<node_objs>
<count>6</count>
<item_version>0</item_version>
<item>50</item>
<item>51</item>
<item>52</item>
<item>53</item>
<item>55</item>
<item>56</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_71">
<Obj>
<type>3</type>
<id>59</id>
<name>.preheader.preheader</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<node_objs>
<count>1</count>
<item_version>0</item_version>
<item>58</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_72">
<Obj>
<type>3</type>
<id>69</id>
<name>.preheader</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<node_objs>
<count>8</count>
<item_version>0</item_version>
<item>60</item>
<item>61</item>
<item>62</item>
<item>63</item>
<item>64</item>
<item>65</item>
<item>67</item>
<item>68</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_73">
<Obj>
<type>3</type>
<id>73</id>
<name/>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<node_objs>
<count>3</count>
<item_version>0</item_version>
<item>70</item>
<item>71</item>
<item>72</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_74">
<Obj>
<type>3</type>
<id>75</id>
<name>.loopexit.loopexit</name>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<node_objs>
<count>1</count>
<item_version>0</item_version>
<item>74</item>
</node_objs>
</item>
<item class_id_reference="18" object_id="_75">
<Obj>
<type>3</type>
<id>77</id>
<name/>
<fileName/>
<fileDirectory/>
<lineNumber>0</lineNumber>
<contextFuncName/>
<inlineStackInfo>
<count>0</count>
<item_version>0</item_version>
</inlineStackInfo>
<originalName/>
<rtlName/>
<coreName/>
</Obj>
<node_objs>
<count>1</count>
<item_version>0</item_version>
<item>76</item>
</node_objs>
</item>
</blocks>
<edges class_id="19" tracking_level="0" version="0">
<count>113</count>
<item_version>0</item_version>
<item class_id="20" tracking_level="1" version="0" object_id="_76">
<id>80</id>
<edge_type>1</edge_type>
<source_obj>4</source_obj>
<sink_obj>12</sink_obj>
</item>
<item class_id_reference="20" object_id="_77">
<id>82</id>
<edge_type>1</edge_type>
<source_obj>3</source_obj>
<sink_obj>13</sink_obj>
</item>
<item class_id_reference="20" object_id="_78">
<id>83</id>
<edge_type>1</edge_type>
<source_obj>13</source_obj>
<sink_obj>14</sink_obj>
</item>
<item class_id_reference="20" object_id="_79">
<id>85</id>
<edge_type>1</edge_type>
<source_obj>84</source_obj>
<sink_obj>14</sink_obj>
</item>
<item class_id_reference="20" object_id="_80">
<id>86</id>
<edge_type>1</edge_type>
<source_obj>14</source_obj>
<sink_obj>15</sink_obj>
</item>
<item class_id_reference="20" object_id="_81">
<id>87</id>
<edge_type>2</edge_type>
<source_obj>49</source_obj>
<sink_obj>15</sink_obj>
</item>
<item class_id_reference="20" object_id="_82">
<id>88</id>
<edge_type>2</edge_type>
<source_obj>18</source_obj>
<sink_obj>15</sink_obj>
</item>
<item class_id_reference="20" object_id="_83">
<id>89</id>
<edge_type>2</edge_type>
<source_obj>26</source_obj>
<sink_obj>17</sink_obj>
</item>
<item class_id_reference="20" object_id="_84">
<id>90</id>
<edge_type>2</edge_type>
<source_obj>26</source_obj>
<sink_obj>44</sink_obj>
</item>
<item class_id_reference="20" object_id="_85">
<id>91</id>
<edge_type>1</edge_type>
<source_obj>24</source_obj>
<sink_obj>19</sink_obj>
</item>
<item class_id_reference="20" object_id="_86">
<id>92</id>
<edge_type>2</edge_type>
<source_obj>45</source_obj>
<sink_obj>19</sink_obj>
</item>
<item class_id_reference="20" object_id="_87">
<id>94</id>
<edge_type>1</edge_type>
<source_obj>93</source_obj>
<sink_obj>19</sink_obj>
</item>
<item class_id_reference="20" object_id="_88">
<id>95</id>
<edge_type>2</edge_type>
<source_obj>18</source_obj>
<sink_obj>19</sink_obj>
</item>
<item class_id_reference="20" object_id="_89">
<id>98</id>
<edge_type>1</edge_type>
<source_obj>19</source_obj>
<sink_obj>20</sink_obj>
</item>
<item class_id_reference="20" object_id="_90">
<id>100</id>
<edge_type>1</edge_type>
<source_obj>99</source_obj>
<sink_obj>20</sink_obj>
</item>
<item class_id_reference="20" object_id="_91">
<id>101</id>
<edge_type>1</edge_type>
<source_obj>20</source_obj>
<sink_obj>21</sink_obj>
</item>
<item class_id_reference="20" object_id="_92">
<id>102</id>
<edge_type>1</edge_type>
<source_obj>19</source_obj>
<sink_obj>22</sink_obj>
</item>
<item class_id_reference="20" object_id="_93">
<id>104</id>
<edge_type>1</edge_type>
<source_obj>103</source_obj>
<sink_obj>22</sink_obj>
</item>
<item class_id_reference="20" object_id="_94">
<id>105</id>
<edge_type>1</edge_type>
<source_obj>19</source_obj>
<sink_obj>24</sink_obj>
</item>
<item class_id_reference="20" object_id="_95">
<id>107</id>
<edge_type>1</edge_type>
<source_obj>106</source_obj>
<sink_obj>24</sink_obj>
</item>
<item class_id_reference="20" object_id="_96">
<id>108</id>
<edge_type>1</edge_type>
<source_obj>22</source_obj>
<sink_obj>25</sink_obj>
</item>
<item class_id_reference="20" object_id="_97">
<id>109</id>
<edge_type>2</edge_type>
<source_obj>28</source_obj>
<sink_obj>25</sink_obj>
</item>
<item class_id_reference="20" object_id="_98">
<id>110</id>
<edge_type>2</edge_type>
<source_obj>47</source_obj>
<sink_obj>25</sink_obj>
</item>
<item class_id_reference="20" object_id="_99">
<id>111</id>
<edge_type>2</edge_type>
<source_obj>38</source_obj>
<sink_obj>27</sink_obj>
</item>
<item class_id_reference="20" object_id="_100">
<id>112</id>
<edge_type>1</edge_type>
<source_obj>36</source_obj>
<sink_obj>29</sink_obj>
</item>
<item class_id_reference="20" object_id="_101">
<id>113</id>
<edge_type>2</edge_type>
<source_obj>43</source_obj>
<sink_obj>29</sink_obj>
</item>
<item class_id_reference="20" object_id="_102">
<id>114</id>
<edge_type>1</edge_type>
<source_obj>93</source_obj>
<sink_obj>29</sink_obj>
</item>
<item class_id_reference="20" object_id="_103">
<id>115</id>
<edge_type>2</edge_type>
<source_obj>28</source_obj>
<sink_obj>29</sink_obj>
</item>
<item class_id_reference="20" object_id="_104">
<id>116</id>
<edge_type>1</edge_type>
<source_obj>29</source_obj>
<sink_obj>30</sink_obj>
</item>
<item class_id_reference="20" object_id="_105">
<id>117</id>
<edge_type>1</edge_type>
<source_obj>21</source_obj>
<sink_obj>31</sink_obj>
</item>
<item class_id_reference="20" object_id="_106">
<id>118</id>
<edge_type>1</edge_type>
<source_obj>30</source_obj>
<sink_obj>31</sink_obj>
</item>
<item class_id_reference="20" object_id="_107">
<id>119</id>
<edge_type>1</edge_type>
<source_obj>31</source_obj>
<sink_obj>32</sink_obj>
</item>
<item class_id_reference="20" object_id="_108">
<id>120</id>
<edge_type>1</edge_type>
<source_obj>2</source_obj>
<sink_obj>33</sink_obj>
</item>
<item class_id_reference="20" object_id="_109">
<id>122</id>
<edge_type>1</edge_type>
<source_obj>121</source_obj>
<sink_obj>33</sink_obj>
</item>
<item class_id_reference="20" object_id="_110">
<id>123</id>
<edge_type>1</edge_type>
<source_obj>32</source_obj>
<sink_obj>33</sink_obj>
</item>
<item class_id_reference="20" object_id="_111">
<id>124</id>
<edge_type>1</edge_type>
<source_obj>29</source_obj>
<sink_obj>34</sink_obj>
</item>
<item class_id_reference="20" object_id="_112">
<id>125</id>
<edge_type>1</edge_type>
<source_obj>103</source_obj>
<sink_obj>34</sink_obj>
</item>
<item class_id_reference="20" object_id="_113">
<id>126</id>
<edge_type>1</edge_type>
<source_obj>29</source_obj>
<sink_obj>36</sink_obj>
</item>
<item class_id_reference="20" object_id="_114">
<id>127</id>
<edge_type>1</edge_type>
<source_obj>106</source_obj>
<sink_obj>36</sink_obj>
</item>
<item class_id_reference="20" object_id="_115">
<id>128</id>
<edge_type>1</edge_type>
<source_obj>34</source_obj>
<sink_obj>37</sink_obj>
</item>
<item class_id_reference="20" object_id="_116">
<id>129</id>
<edge_type>2</edge_type>
<source_obj>43</source_obj>
<sink_obj>37</sink_obj>
</item>
<item class_id_reference="20" object_id="_117">
<id>130</id>
<edge_type>2</edge_type>
<source_obj>45</source_obj>
<sink_obj>37</sink_obj>
</item>
<item class_id_reference="20" object_id="_118">
<id>131</id>
<edge_type>1</edge_type>
<source_obj>33</source_obj>
<sink_obj>39</sink_obj>
</item>
<item class_id_reference="20" object_id="_119">
<id>132</id>
<edge_type>1</edge_type>
<source_obj>39</source_obj>
<sink_obj>40</sink_obj>
</item>
<item class_id_reference="20" object_id="_120">
<id>134</id>
<edge_type>1</edge_type>
<source_obj>133</source_obj>
<sink_obj>40</sink_obj>
</item>
<item class_id_reference="20" object_id="_121">
<id>135</id>
<edge_type>1</edge_type>
<source_obj>40</source_obj>
<sink_obj>41</sink_obj>
</item>
<item class_id_reference="20" object_id="_122">
<id>136</id>
<edge_type>1</edge_type>
<source_obj>33</source_obj>
<sink_obj>41</sink_obj>
</item>
<item class_id_reference="20" object_id="_123">
<id>137</id>
<edge_type>2</edge_type>
<source_obj>38</source_obj>
<sink_obj>42</sink_obj>
</item>
<item class_id_reference="20" object_id="_124">
<id>138</id>
<edge_type>2</edge_type>
<source_obj>49</source_obj>
<sink_obj>46</sink_obj>
</item>
<item class_id_reference="20" object_id="_125">
<id>139</id>
<edge_type>2</edge_type>
<source_obj>57</source_obj>
<sink_obj>48</sink_obj>
</item>
<item class_id_reference="20" object_id="_126">
<id>140</id>
<edge_type>2</edge_type>
<source_obj>57</source_obj>
<sink_obj>74</sink_obj>
</item>
<item class_id_reference="20" object_id="_127">
<id>141</id>
<edge_type>1</edge_type>
<source_obj>93</source_obj>
<sink_obj>50</sink_obj>
</item>
<item class_id_reference="20" object_id="_128">
<id>142</id>
<edge_type>2</edge_type>
<source_obj>49</source_obj>
<sink_obj>50</sink_obj>
</item>
<item class_id_reference="20" object_id="_129">
<id>143</id>
<edge_type>1</edge_type>
<source_obj>55</source_obj>
<sink_obj>50</sink_obj>
</item>
<item class_id_reference="20" object_id="_130">
<id>144</id>
<edge_type>2</edge_type>
<source_obj>75</source_obj>
<sink_obj>50</sink_obj>
</item>
<item class_id_reference="20" object_id="_131">
<id>146</id>
<edge_type>1</edge_type>
<source_obj>50</source_obj>
<sink_obj>51</sink_obj>
</item>
<item class_id_reference="20" object_id="_132">
<id>147</id>
<edge_type>1</edge_type>
<source_obj>99</source_obj>
<sink_obj>51</sink_obj>
</item>
<item class_id_reference="20" object_id="_133">
<id>148</id>
<edge_type>1</edge_type>
<source_obj>51</source_obj>
<sink_obj>52</sink_obj>
</item>
<item class_id_reference="20" object_id="_134">
<id>149</id>
<edge_type>1</edge_type>
<source_obj>50</source_obj>
<sink_obj>53</sink_obj>
</item>
<item class_id_reference="20" object_id="_135">
<id>150</id>
<edge_type>1</edge_type>
<source_obj>103</source_obj>
<sink_obj>53</sink_obj>
</item>
<item class_id_reference="20" object_id="_136">
<id>151</id>
<edge_type>1</edge_type>
<source_obj>50</source_obj>
<sink_obj>55</sink_obj>
</item>
<item class_id_reference="20" object_id="_137">
<id>152</id>
<edge_type>1</edge_type>
<source_obj>106</source_obj>
<sink_obj>55</sink_obj>
</item>
<item class_id_reference="20" object_id="_138">
<id>153</id>
<edge_type>1</edge_type>
<source_obj>53</source_obj>
<sink_obj>56</sink_obj>
</item>
<item class_id_reference="20" object_id="_139">
<id>154</id>
<edge_type>2</edge_type>
<source_obj>59</source_obj>
<sink_obj>56</sink_obj>
</item>
<item class_id_reference="20" object_id="_140">
<id>155</id>
<edge_type>2</edge_type>
<source_obj>77</source_obj>
<sink_obj>56</sink_obj>
</item>
<item class_id_reference="20" object_id="_141">
<id>156</id>
<edge_type>2</edge_type>
<source_obj>69</source_obj>
<sink_obj>58</sink_obj>
</item>
<item class_id_reference="20" object_id="_142">
<id>157</id>
<edge_type>1</edge_type>
<source_obj>67</source_obj>
<sink_obj>60</sink_obj>
</item>
<item class_id_reference="20" object_id="_143">
<id>158</id>
<edge_type>2</edge_type>
<source_obj>73</source_obj>
<sink_obj>60</sink_obj>
</item>
<item class_id_reference="20" object_id="_144">
<id>159</id>
<edge_type>1</edge_type>
<source_obj>93</source_obj>
<sink_obj>60</sink_obj>
</item>
<item class_id_reference="20" object_id="_145">
<id>160</id>
<edge_type>2</edge_type>
<source_obj>59</source_obj>
<sink_obj>60</sink_obj>
</item>
<item class_id_reference="20" object_id="_146">
<id>161</id>
<edge_type>1</edge_type>
<source_obj>60</source_obj>
<sink_obj>61</sink_obj>
</item>
<item class_id_reference="20" object_id="_147">
<id>162</id>
<edge_type>1</edge_type>
<source_obj>52</source_obj>
<sink_obj>62</sink_obj>
</item>
<item class_id_reference="20" object_id="_148">
<id>163</id>
<edge_type>1</edge_type>
<source_obj>61</source_obj>
<sink_obj>62</sink_obj>
</item>
<item class_id_reference="20" object_id="_149">
<id>164</id>
<edge_type>1</edge_type>
<source_obj>62</source_obj>
<sink_obj>63</sink_obj>
</item>
<item class_id_reference="20" object_id="_150">
<id>165</id>
<edge_type>1</edge_type>
<source_obj>1</source_obj>
<sink_obj>64</sink_obj>
</item>
<item class_id_reference="20" object_id="_151">
<id>166</id>
<edge_type>1</edge_type>
<source_obj>121</source_obj>
<sink_obj>64</sink_obj>
</item>
<item class_id_reference="20" object_id="_152">
<id>167</id>
<edge_type>1</edge_type>
<source_obj>63</source_obj>
<sink_obj>64</sink_obj>
</item>
<item class_id_reference="20" object_id="_153">
<id>168</id>
<edge_type>1</edge_type>
<source_obj>60</source_obj>
<sink_obj>65</sink_obj>
</item>
<item class_id_reference="20" object_id="_154">
<id>169</id>
<edge_type>1</edge_type>
<source_obj>103</source_obj>
<sink_obj>65</sink_obj>
</item>
<item class_id_reference="20" object_id="_155">
<id>170</id>
<edge_type>1</edge_type>
<source_obj>60</source_obj>
<sink_obj>67</sink_obj>
</item>
<item class_id_reference="20" object_id="_156">
<id>171</id>
<edge_type>1</edge_type>
<source_obj>106</source_obj>
<sink_obj>67</sink_obj>
</item>
<item class_id_reference="20" object_id="_157">
<id>172</id>
<edge_type>1</edge_type>
<source_obj>65</source_obj>
<sink_obj>68</sink_obj>
</item>
<item class_id_reference="20" object_id="_158">
<id>173</id>
<edge_type>2</edge_type>
<source_obj>73</source_obj>
<sink_obj>68</sink_obj>
</item>
<item class_id_reference="20" object_id="_159">
<id>174</id>
<edge_type>2</edge_type>
<source_obj>75</source_obj>
<sink_obj>68</sink_obj>
</item>
<item class_id_reference="20" object_id="_160">
<id>176</id>
<edge_type>1</edge_type>
<source_obj>175</source_obj>
<sink_obj>70</sink_obj>
</item>
<item class_id_reference="20" object_id="_161">
<id>177</id>
<edge_type>1</edge_type>
<source_obj>2</source_obj>
<sink_obj>70</sink_obj>
</item>
<item class_id_reference="20" object_id="_162">
<id>178</id>
<edge_type>1</edge_type>
<source_obj>50</source_obj>
<sink_obj>70</sink_obj>
</item>
<item class_id_reference="20" object_id="_163">
<id>179</id>
<edge_type>1</edge_type>
<source_obj>60</source_obj>
<sink_obj>70</sink_obj>
</item>
<item class_id_reference="20" object_id="_164">
<id>180</id>
<edge_type>1</edge_type>
<source_obj>12</source_obj>
<sink_obj>70</sink_obj>
</item>
<item class_id_reference="20" object_id="_165">
<id>181</id>
<edge_type>1</edge_type>
<source_obj>5</source_obj>
<sink_obj>70</sink_obj>
</item>
<item class_id_reference="20" object_id="_166">
<id>182</id>
<edge_type>1</edge_type>
<source_obj>70</source_obj>
<sink_obj>71</sink_obj>
</item>
<item class_id_reference="20" object_id="_167">
<id>183</id>
<edge_type>1</edge_type>
<source_obj>64</source_obj>
<sink_obj>71</sink_obj>
</item>
<item class_id_reference="20" object_id="_168">
<id>184</id>
<edge_type>2</edge_type>
<source_obj>69</source_obj>
<sink_obj>72</sink_obj>
</item>
<item class_id_reference="20" object_id="_169">
<id>218</id>
<edge_type>2</edge_type>
<source_obj>16</source_obj>
<sink_obj>18</sink_obj>
</item>
<item class_id_reference="20" object_id="_170">
<id>219</id>
<edge_type>2</edge_type>
<source_obj>16</source_obj>
<sink_obj>49</sink_obj>
</item>
<item class_id_reference="20" object_id="_171">
<id>220</id>
<edge_type>2</edge_type>
<source_obj>18</source_obj>
<sink_obj>26</sink_obj>
</item>
<item class_id_reference="20" object_id="_172">
<id>221</id>
<edge_type>2</edge_type>
<source_obj>26</source_obj>
<sink_obj>47</sink_obj>
</item>
<item class_id_reference="20" object_id="_173">
<id>222</id>
<edge_type>2</edge_type>
<source_obj>26</source_obj>
<sink_obj>28</sink_obj>
</item>
<item class_id_reference="20" object_id="_174">
<id>223</id>
<edge_type>2</edge_type>
<source_obj>28</source_obj>
<sink_obj>38</sink_obj>
</item>
<item class_id_reference="20" object_id="_175">
<id>224</id>
<edge_type>2</edge_type>
<source_obj>38</source_obj>
<sink_obj>45</sink_obj>
</item>
<item class_id_reference="20" object_id="_176">
<id>225</id>
<edge_type>2</edge_type>
<source_obj>38</source_obj>
<sink_obj>43</sink_obj>
</item>
<item class_id_reference="20" object_id="_177">
<id>226</id>
<edge_type>2</edge_type>
<source_obj>43</source_obj>
<sink_obj>38</sink_obj>
</item>
<item class_id_reference="20" object_id="_178">
<id>227</id>
<edge_type>2</edge_type>
<source_obj>45</source_obj>
<sink_obj>26</sink_obj>
</item>
<item class_id_reference="20" object_id="_179">
<id>228</id>
<edge_type>2</edge_type>
<source_obj>47</source_obj>
<sink_obj>49</sink_obj>
</item>
<item class_id_reference="20" object_id="_180">
<id>229</id>
<edge_type>2</edge_type>
<source_obj>49</source_obj>
<sink_obj>57</sink_obj>
</item>
<item class_id_reference="20" object_id="_181">
<id>230</id>
<edge_type>2</edge_type>
<source_obj>57</source_obj>
<sink_obj>77</sink_obj>
</item>
<item class_id_reference="20" object_id="_182">
<id>231</id>
<edge_type>2</edge_type>
<source_obj>57</source_obj>
<sink_obj>59</sink_obj>
</item>
<item class_id_reference="20" object_id="_183">
<id>232</id>
<edge_type>2</edge_type>
<source_obj>59</source_obj>
<sink_obj>69</sink_obj>
</item>
<item class_id_reference="20" object_id="_184">
<id>233</id>
<edge_type>2</edge_type>
<source_obj>69</source_obj>
<sink_obj>75</sink_obj>
</item>
<item class_id_reference="20" object_id="_185">
<id>234</id>
<edge_type>2</edge_type>
<source_obj>69</source_obj>
<sink_obj>73</sink_obj>
</item>
<item class_id_reference="20" object_id="_186">
<id>235</id>
<edge_type>2</edge_type>
<source_obj>73</source_obj>
<sink_obj>69</sink_obj>
</item>
<item class_id_reference="20" object_id="_187">
<id>236</id>
<edge_type>2</edge_type>
<source_obj>75</source_obj>
<sink_obj>57</sink_obj>
</item>
<item class_id_reference="20" object_id="_188">
<id>237</id>
<edge_type>4</edge_type>
<source_obj>39</source_obj>
<sink_obj>41</sink_obj>
</item>
</edges>
</cdfg>
<cdfg_regions class_id="21" tracking_level="0" version="0">
<count>13</count>
<item_version>0</item_version>
<item class_id="22" tracking_level="1" version="0" object_id="_189">
<mId>1</mId>
<mTag>DCT_8x8_2D</mTag>
<mType>0</mType>
<sub_regions>
<count>6</count>
<item_version>0</item_version>
<item>2</item>
<item>3</item>
<item>7</item>
<item>8</item>
<item>9</item>
<item>13</item>
</sub_regions>
<basic_blocks>
<count>0</count>
<item_version>0</item_version>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>-1</mMinTripCount>
<mMaxTripCount>-1</mMaxTripCount>
<mMinLatency>92450</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"/>
</item>
<item class_id_reference="22" object_id="_190">
<mId>2</mId>
<mTag>Entry</mTag>
<mType>0</mType>
<sub_regions>
<count>0</count>
<item_version>0</item_version>
</sub_regions>
<basic_blocks>
<count>2</count>
<item_version>0</item_version>
<item>16</item>
<item>18</item>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>-1</mMinTripCount>
<mMaxTripCount>-1</mMaxTripCount>
<mMinLatency>0</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"/>
</item>
<item class_id_reference="22" object_id="_191">
<mId>3</mId>
<mTag>Loop 1</mTag>
<mType>1</mType>
<sub_regions>
<count>3</count>
<item_version>0</item_version>
<item>4</item>
<item>5</item>
<item>6</item>
</sub_regions>
<basic_blocks>
<count>0</count>
<item_version>0</item_version>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>8</mMinTripCount>
<mMaxTripCount>8</mMaxTripCount>
<mMinLatency>336</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"/>
</item>
<item class_id_reference="22" object_id="_192">
<mId>4</mId>
<mTag>Region 1</mTag>
<mType>0</mType>
<sub_regions>
<count>0</count>
<item_version>0</item_version>
</sub_regions>
<basic_blocks>
<count>2</count>
<item_version>0</item_version>
<item>26</item>
<item>28</item>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>-1</mMinTripCount>
<mMaxTripCount>-1</mMaxTripCount>
<mMinLatency>0</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"/>
</item>
<item class_id_reference="22" object_id="_193">
<mId>5</mId>
<mTag>Loop 1.1</mTag>
<mType>1</mType>
<sub_regions>
<count>0</count>
<item_version>0</item_version>
</sub_regions>
<basic_blocks>
<count>2</count>
<item_version>0</item_version>
<item>38</item>
<item>43</item>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>8</mMinTripCount>
<mMaxTripCount>8</mMaxTripCount>
<mMinLatency>40</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"/>
</item>
<item class_id_reference="22" object_id="_194">
<mId>6</mId>
<mTag>Region 2</mTag>
<mType>0</mType>
<sub_regions>
<count>0</count>
<item_version>0</item_version>
</sub_regions>
<basic_blocks>
<count>1</count>
<item_version>0</item_version>
<item>45</item>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>-1</mMinTripCount>
<mMaxTripCount>-1</mMaxTripCount>
<mMinLatency>0</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"/>
</item>
<item class_id_reference="22" object_id="_195">
<mId>7</mId>
<mTag>Region 3</mTag>
<mType>0</mType>
<sub_regions>
<count>0</count>
<item_version>0</item_version>
</sub_regions>
<basic_blocks>
<count>1</count>
<item_version>0</item_version>
<item>47</item>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>-1</mMinTripCount>
<mMaxTripCount>-1</mMaxTripCount>
<mMinLatency>0</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"/>
</item>
<item class_id_reference="22" object_id="_196">
<mId>8</mId>
<mTag>Region 4</mTag>
<mType>0</mType>
<sub_regions>
<count>0</count>
<item_version>0</item_version>
</sub_regions>
<basic_blocks>
<count>1</count>
<item_version>0</item_version>
<item>49</item>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>-1</mMinTripCount>
<mMaxTripCount>-1</mMaxTripCount>
<mMinLatency>0</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"/>
</item>
<item class_id_reference="22" object_id="_197">
<mId>9</mId>
<mTag>Loop 2</mTag>
<mType>1</mType>
<sub_regions>
<count>3</count>
<item_version>0</item_version>
<item>10</item>
<item>11</item>
<item>12</item>
</sub_regions>
<basic_blocks>
<count>0</count>
<item_version>0</item_version>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>8</mMinTripCount>
<mMaxTripCount>8</mMaxTripCount>
<mMinLatency>92112</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"/>
</item>
<item class_id_reference="22" object_id="_198">
<mId>10</mId>
<mTag>Region 5</mTag>
<mType>0</mType>
<sub_regions>
<count>0</count>
<item_version>0</item_version>
</sub_regions>
<basic_blocks>
<count>2</count>
<item_version>0</item_version>
<item>57</item>
<item>59</item>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>-1</mMinTripCount>
<mMaxTripCount>-1</mMaxTripCount>
<mMinLatency>0</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"/>
</item>
<item class_id_reference="22" object_id="_199">
<mId>11</mId>
<mTag>Loop 2.1</mTag>
<mType>1</mType>
<sub_regions>
<count>0</count>
<item_version>0</item_version>
</sub_regions>
<basic_blocks>
<count>2</count>
<item_version>0</item_version>
<item>69</item>
<item>73</item>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>8</mMinTripCount>
<mMaxTripCount>8</mMaxTripCount>
<mMinLatency>11512</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"/>
</item>
<item class_id_reference="22" object_id="_200">
<mId>12</mId>
<mTag>Region 6</mTag>
<mType>0</mType>
<sub_regions>
<count>0</count>
<item_version>0</item_version>
</sub_regions>
<basic_blocks>
<count>1</count>
<item_version>0</item_version>
<item>75</item>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>-1</mMinTripCount>
<mMaxTripCount>-1</mMaxTripCount>
<mMinLatency>0</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"/>
</item>
<item class_id_reference="22" object_id="_201">
<mId>13</mId>
<mTag>Return</mTag>
<mType>0</mType>
<sub_regions>
<count>0</count>
<item_version>0</item_version>
</sub_regions>
<basic_blocks>
<count>1</count>
<item_version>0</item_version>
<item>77</item>
</basic_blocks>
<mII>-1</mII>
<mDepth>-1</mDepth>
<mMinTripCount>-1</mMinTripCount>
<mMaxTripCount>-1</mMaxTripCount>
<mMinLatency>0</mMinLatency>
<mMaxLatency>-1</mMaxLatency>
<mIsDfPipe>0</mIsDfPipe>
<mDfPipe class_id="-1"/>
</item>
</cdfg_regions>
<fsm class_id="24" tracking_level="1" version="0" object_id="_202">
<states class_id="25" tracking_level="0" version="0">
<count>10</count>
<item_version>0</item_version>
<item class_id="26" tracking_level="1" version="0" object_id="_203">
<id>1</id>
<operations class_id="27" tracking_level="0" version="0">
<count>11</count>
<item_version>0</item_version>
<item class_id="28" tracking_level="1" version="0" object_id="_204">
<id>6</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_205">
<id>7</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_206">
<id>8</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_207">
<id>9</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_208">
<id>10</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_209">
<id>11</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_210">
<id>12</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_211">
<id>13</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_212">
<id>14</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_213">
<id>15</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_214">
<id>17</id>
<stage>1</stage>
<latency>1</latency>
</item>
</operations>
</item>
<item class_id_reference="26" object_id="_215">
<id>2</id>
<operations>
<count>10</count>
<item_version>0</item_version>
<item class_id_reference="28" object_id="_216">
<id>19</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_217">
<id>20</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_218">
<id>21</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_219">
<id>22</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_220">
<id>23</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_221">
<id>24</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_222">
<id>25</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_223">
<id>27</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_224">
<id>46</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_225">
<id>48</id>
<stage>1</stage>
<latency>1</latency>
</item>
</operations>
</item>
<item class_id_reference="26" object_id="_226">
<id>3</id>
<operations>
<count>11</count>
<item_version>0</item_version>
<item class_id_reference="28" object_id="_227">
<id>29</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_228">
<id>30</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_229">
<id>31</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_230">
<id>32</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_231">
<id>33</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_232">
<id>34</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_233">
<id>35</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_234">
<id>36</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_235">
<id>37</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_236">
<id>39</id>
<stage>2</stage>
<latency>2</latency>
</item>
<item class_id_reference="28" object_id="_237">
<id>44</id>
<stage>1</stage>
<latency>1</latency>
</item>
</operations>
</item>
<item class_id_reference="26" object_id="_238">
<id>4</id>
<operations>
<count>2</count>
<item_version>0</item_version>
<item class_id_reference="28" object_id="_239">
<id>39</id>
<stage>1</stage>
<latency>2</latency>
</item>
<item class_id_reference="28" object_id="_240">
<id>40</id>
<stage>4</stage>
<latency>4</latency>
</item>
</operations>
</item>
<item class_id_reference="26" object_id="_241">
<id>5</id>
<operations>
<count>1</count>
<item_version>0</item_version>
<item class_id_reference="28" object_id="_242">
<id>40</id>
<stage>3</stage>
<latency>4</latency>
</item>
</operations>
</item>
<item class_id_reference="26" object_id="_243">
<id>6</id>
<operations>
<count>1</count>
<item_version>0</item_version>
<item class_id_reference="28" object_id="_244">
<id>40</id>
<stage>2</stage>
<latency>4</latency>
</item>
</operations>
</item>
<item class_id_reference="26" object_id="_245">
<id>7</id>
<operations>
<count>3</count>
<item_version>0</item_version>
<item class_id_reference="28" object_id="_246">
<id>40</id>
<stage>1</stage>
<latency>4</latency>
</item>
<item class_id_reference="28" object_id="_247">
<id>41</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_248">
<id>42</id>
<stage>1</stage>
<latency>1</latency>
</item>
</operations>
</item>
<item class_id_reference="26" object_id="_249">
<id>8</id>
<operations>
<count>9</count>
<item_version>0</item_version>
<item class_id_reference="28" object_id="_250">
<id>50</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_251">
<id>51</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_252">
<id>52</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_253">
<id>53</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_254">
<id>54</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_255">
<id>55</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_256">
<id>56</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_257">
<id>58</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_258">
<id>76</id>
<stage>1</stage>
<latency>1</latency>
</item>
</operations>
</item>
<item class_id_reference="26" object_id="_259">
<id>9</id>
<operations>
<count>11</count>
<item_version>0</item_version>
<item class_id_reference="28" object_id="_260">
<id>60</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_261">
<id>61</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_262">
<id>62</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_263">
<id>63</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_264">
<id>64</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_265">
<id>65</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_266">
<id>66</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_267">
<id>67</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_268">
<id>68</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_269">
<id>70</id>
<stage>2</stage>
<latency>2</latency>
</item>
<item class_id_reference="28" object_id="_270">
<id>74</id>
<stage>1</stage>
<latency>1</latency>
</item>
</operations>
</item>
<item class_id_reference="26" object_id="_271">
<id>10</id>
<operations>
<count>3</count>
<item_version>0</item_version>
<item class_id_reference="28" object_id="_272">
<id>70</id>
<stage>1</stage>
<latency>2</latency>
</item>
<item class_id_reference="28" object_id="_273">
<id>71</id>
<stage>1</stage>
<latency>1</latency>
</item>
<item class_id_reference="28" object_id="_274">
<id>72</id>
<stage>1</stage>
<latency>1</latency>
</item>
</operations>
</item>
</states>
<transitions class_id="29" tracking_level="0" version="0">
<count>13</count>
<item_version>0</item_version>
<item class_id="30" tracking_level="1" version="0" object_id="_275">
<inState>1</inState>
<outState>2</outState>
<condition class_id="31" tracking_level="0" version="0">
<id>31</id>
<sop class_id="32" tracking_level="0" version="0">
<count>1</count>
<item_version>0</item_version>
<item class_id="33" tracking_level="0" version="0">
<count>0</count>
<item_version>0</item_version>
</item>
</sop>
</condition>
</item>
<item class_id_reference="30" object_id="_276">
<inState>2</inState>
<outState>3</outState>
<condition>
<id>35</id>
<sop>
<count>1</count>
<item_version>0</item_version>
<item>
<count>2</count>
<item_version>0</item_version>
<item class_id="34" tracking_level="0" version="0">
<first class_id="35" tracking_level="0" version="0">
<first>14</first>
<second>0</second>
</first>
<second>0</second>
</item>
<item>
<first>
<first>22</first>
<second>0</second>
</first>
<second>1</second>
</item>
</item>
</sop>
</condition>
</item>
<item class_id_reference="30" object_id="_277">
<inState>3</inState>
<outState>4</outState>
<condition>
<id>36</id>
<sop>
<count>1</count>
<item_version>0</item_version>
<item>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>34</first>
<second>0</second>
</first>
<second>1</second>
</item>
</item>
</sop>
</condition>
</item>
<item class_id_reference="30" object_id="_278">
<inState>4</inState>
<outState>5</outState>
<condition>
<id>38</id>
<sop>
<count>1</count>
<item_version>0</item_version>
<item>
<count>0</count>
<item_version>0</item_version>
</item>
</sop>
</condition>
</item>
<item class_id_reference="30" object_id="_279">
<inState>5</inState>
<outState>6</outState>
<condition>
<id>39</id>
<sop>
<count>1</count>
<item_version>0</item_version>
<item>
<count>0</count>
<item_version>0</item_version>
</item>
</sop>
</condition>
</item>
<item class_id_reference="30" object_id="_280">
<inState>6</inState>
<outState>7</outState>
<condition>
<id>40</id>
<sop>
<count>1</count>
<item_version>0</item_version>
<item>
<count>0</count>
<item_version>0</item_version>
</item>
</sop>
</condition>
</item>
<item class_id_reference="30" object_id="_281">
<inState>7</inState>
<outState>3</outState>
<condition>
<id>42</id>
<sop>
<count>1</count>
<item_version>0</item_version>
<item>
<count>0</count>
<item_version>0</item_version>
</item>
</sop>
</condition>
</item>
<item class_id_reference="30" object_id="_282">
<inState>3</inState>
<outState>2</outState>
<condition>
<id>44</id>
<sop>
<count>1</count>
<item_version>0</item_version>
<item>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>34</first>
<second>0</second>
</first>
<second>0</second>
</item>
</item>
</sop>
</condition>
</item>
<item class_id_reference="30" object_id="_283">
<inState>2</inState>
<outState>8</outState>
<condition>
<id>46</id>
<sop>
<count>2</count>
<item_version>0</item_version>
<item>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>14</first>
<second>0</second>
</first>
<second>1</second>
</item>
</item>
<item>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>22</first>
<second>0</second>
</first>
<second>0</second>
</item>
</item>
</sop>
</condition>
</item>
<item class_id_reference="30" object_id="_284">
<inState>8</inState>
<outState>9</outState>
<condition>
<id>48</id>
<sop>
<count>1</count>
<item_version>0</item_version>
<item>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>53</first>
<second>0</second>
</first>
<second>1</second>
</item>
</item>
</sop>
</condition>
</item>
<item class_id_reference="30" object_id="_285">
<inState>9</inState>
<outState>10</outState>
<condition>
<id>49</id>
<sop>
<count>1</count>
<item_version>0</item_version>
<item>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>65</first>
<second>0</second>
</first>
<second>1</second>
</item>
</item>
</sop>
</condition>
</item>
<item class_id_reference="30" object_id="_286">
<inState>10</inState>
<outState>9</outState>
<condition>
<id>52</id>
<sop>
<count>1</count>
<item_version>0</item_version>
<item>
<count>0</count>
<item_version>0</item_version>
</item>
</sop>
</condition>
</item>
<item class_id_reference="30" object_id="_287">
<inState>9</inState>
<outState>8</outState>
<condition>
<id>54</id>
<sop>
<count>1</count>
<item_version>0</item_version>
<item>
<count>1</count>
<item_version>0</item_version>
<item>
<first>
<first>65</first>
<second>0</second>
</first>
<second>0</second>
</item>
</item>
</sop>
</condition>
</item>
</transitions>
</fsm>
<res class_id="36" tracking_level="1" version="0" object_id="_288">
<dp_component_resource class_id="37" tracking_level="0" version="0">
<count>2</count>
<item_version>0</item_version>
<item class_id="38" tracking_level="0" version="0">
<first>DCT_8x8_2D_fadd_3fYi_U9 (DCT_8x8_2D_fadd_3fYi)</first>
<second class_id="39" tracking_level="0" version="0">
<count>3</count>
<item_version>0</item_version>
<item class_id="40" tracking_level="0" version="0">
<first>DSP48E</first>
<second>2</second>
</item>
<item>
<first>FF</first>
<second>227</second>
</item>
<item>
<first>LUT</first>
<second>403</second>
</item>
</second>
</item>
<item>
<first>grp_singleGUV_fu_121 (singleGUV)</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>DSP48E</first>
<second>14</second>
</item>
<item>
<first>FF</first>
<second>1571</second>
</item>
<item>
<first>LUT</first>
<second>2716</second>
</item>
</second>
</item>
</dp_component_resource>
<dp_expression_resource>
<count>11</count>
<item_version>0</item_version>
<item>
<first>exitcond1_fu_210_p2 ( icmp ) </first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0P0)</first>
<second>4</second>
</item>
<item>
<first>(1P1)</first>
<second>5</second>
</item>
<item>
<first>FF</first>
<second>0</second>
</item>
<item>
<first>LUT</first>
<second>2</second>
</item>
</second>
</item>
<item>
<first>exitcond1_i_fu_160_p2 ( icmp ) </first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0P0)</first>
<second>4</second>
</item>
<item>
<first>(1P1)</first>
<second>5</second>
</item>
<item>
<first>FF</first>
<second>0</second>
</item>
<item>
<first>LUT</first>
<second>2</second>
</item>
</second>
</item>
<item>
<first>exitcond_fu_236_p2 ( icmp ) </first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0P0)</first>
<second>4</second>
</item>
<item>
<first>(1P1)</first>
<second>5</second>
</item>
<item>
<first>FF</first>
<second>0</second>
</item>
<item>
<first>LUT</first>
<second>2</second>
</item>
</second>
</item>
<item>
<first>exitcond_i_fu_186_p2 ( icmp ) </first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0P0)</first>
<second>4</second>
</item>
<item>
<first>(1P1)</first>
<second>5</second>
</item>
<item>
<first>FF</first>
<second>0</second>
</item>
<item>
<first>LUT</first>
<second>2</second>
</item>
</second>
</item>
<item>
<first>i_1_fu_166_p2 ( + ) </first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0P0)</first>
<second>4</second>
</item>
<item>
<first>(1P1)</first>
<second>1</second>
</item>
<item>
<first>FF</first>
<second>0</second>
</item>
<item>
<first>LUT</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>i_2_fu_216_p2 ( + ) </first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0P0)</first>
<second>4</second>
</item>
<item>
<first>(1P1)</first>
<second>1</second>
</item>
<item>
<first>FF</first>
<second>0</second>
</item>
<item>
<first>LUT</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>j_1_fu_192_p2 ( + ) </first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0P0)</first>
<second>4</second>
</item>
<item>
<first>(1P1)</first>
<second>1</second>
</item>
<item>
<first>FF</first>
<second>0</second>
</item>
<item>
<first>LUT</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>j_2_fu_242_p2 ( + ) </first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0P0)</first>
<second>4</second>
</item>
<item>
<first>(1P1)</first>
<second>1</second>
</item>
<item>
<first>FF</first>
<second>0</second>
</item>
<item>
<first>LUT</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>tmp_27_fu_176_p2 ( + ) </first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0P0)</first>
<second>8</second>
</item>
<item>
<first>(1P1)</first>
<second>8</second>
</item>
<item>
<first>FF</first>
<second>0</second>
</item>
<item>
<first>LUT</first>
<second>8</second>
</item>
</second>
</item>
<item>
<first>tmp_29_fu_226_p2 ( + ) </first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0P0)</first>
<second>8</second>
</item>
<item>
<first>(1P1)</first>
<second>8</second>
</item>
<item>
<first>FF</first>
<second>0</second>
</item>
<item>
<first>LUT</first>
<second>8</second>
</item>
</second>
</item>
<item>
<first>tmp_fu_142_p2 ( icmp ) </first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0P0)</first>
<second>32</second>
</item>
<item>
<first>(1P1)</first>
<second>1</second>
</item>
<item>
<first>FF</first>
<second>0</second>
</item>
<item>
<first>LUT</first>
<second>11</second>
</item>
</second>
</item>
</dp_expression_resource>
<dp_fifo_resource>
<count>0</count>
<item_version>0</item_version>
</dp_fifo_resource>
<dp_memory_resource>
<count>0</count>
<item_version>0</item_version>
</dp_memory_resource>
<dp_multiplexer_resource>
<count>7</count>
<item_version>0</item_version>
<item>
<first>ap_NS_fsm</first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0Size)</first>
<second>11</second>
</item>
<item>
<first>(1Bits)</first>
<second>1</second>
</item>
<item>
<first>(2Count)</first>
<second>11</second>
</item>
<item>
<first>LUT</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>i_i_reg_75</first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0Size)</first>
<second>2</second>
</item>
<item>
<first>(1Bits)</first>
<second>4</second>
</item>
<item>
<first>(2Count)</first>
<second>8</second>
</item>
<item>
<first>LUT</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>i_reg_97</first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0Size)</first>
<second>2</second>
</item>
<item>
<first>(1Bits)</first>
<second>4</second>
</item>
<item>
<first>(2Count)</first>
<second>8</second>
</item>
<item>
<first>LUT</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>j_i_reg_86</first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0Size)</first>
<second>2</second>
</item>
<item>
<first>(1Bits)</first>
<second>4</second>
</item>
<item>
<first>(2Count)</first>
<second>8</second>
</item>
<item>
<first>LUT</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>j_reg_109</first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0Size)</first>
<second>2</second>
</item>
<item>
<first>(1Bits)</first>
<second>4</second>
</item>
<item>
<first>(2Count)</first>
<second>8</second>
</item>
<item>
<first>LUT</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>subimg_address0</first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0Size)</first>
<second>4</second>
</item>
<item>
<first>(1Bits)</first>
<second>6</second>
</item>
<item>
<first>(2Count)</first>
<second>24</second>
</item>
<item>
<first>LUT</first>
<second>6</second>
</item>
</second>
</item>
<item>
<first>subimg_ce0</first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>
<first>(0Size)</first>
<second>3</second>
</item>
<item>
<first>(1Bits)</first>
<second>1</second>
</item>
<item>
<first>(2Count)</first>
<second>3</second>
</item>
<item>
<first>LUT</first>
<second>1</second>
</item>
</second>
</item>
</dp_multiplexer_resource>
<dp_register_resource>
<count>15</count>
<item_version>0</item_version>
<item>
<first>G_addr_reg_301</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>(Bits)</first>
<second>6</second>
</item>
<item>
<first>(Consts)</first>
<second>0</second>
</item>
<item>
<first>FF</first>
<second>6</second>
</item>
</second>
</item>
<item>
<first>ap_CS_fsm</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>(Bits)</first>
<second>10</second>
</item>
<item>
<first>(Consts)</first>
<second>0</second>
</item>
<item>
<first>FF</first>
<second>10</second>
</item>
</second>
</item>
<item>
<first>ap_reg_grp_singleGUV_fu_121_ap_start</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>(Bits)</first>
<second>1</second>
</item>
<item>
<first>(Consts)</first>
<second>0</second>
</item>
<item>
<first>FF</first>
<second>1</second>
</item>
</second>
</item>
<item>
<first>i_1_reg_265</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>(Bits)</first>
<second>4</second>
</item>
<item>
<first>(Consts)</first>
<second>0</second>
</item>
<item>
<first>FF</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>i_2_reg_296</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>(Bits)</first>
<second>4</second>
</item>
<item>
<first>(Consts)</first>
<second>0</second>
</item>
<item>
<first>FF</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>i_i_reg_75</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>(Bits)</first>
<second>4</second>
</item>
<item>
<first>(Consts)</first>
<second>0</second>
</item>
<item>
<first>FF</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>i_reg_97</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>(Bits)</first>
<second>4</second>
</item>
<item>
<first>(Consts)</first>
<second>0</second>
</item>
<item>
<first>FF</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>j_1_reg_278</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>(Bits)</first>
<second>4</second>
</item>
<item>
<first>(Consts)</first>
<second>0</second>
</item>
<item>
<first>FF</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>j_2_reg_309</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>(Bits)</first>
<second>4</second>
</item>
<item>
<first>(Consts)</first>
<second>0</second>
</item>
<item>
<first>FF</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>j_i_reg_86</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>(Bits)</first>
<second>4</second>
</item>
<item>
<first>(Consts)</first>
<second>0</second>
</item>
<item>
<first>FF</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>j_reg_109</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>(Bits)</first>
<second>4</second>
</item>
<item>
<first>(Consts)</first>
<second>0</second>
</item>
<item>
<first>FF</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>subimg_addr_reg_270</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>(Bits)</first>
<second>6</second>
</item>
<item>
<first>(Consts)</first>
<second>0</second>
</item>
<item>
<first>FF</first>
<second>6</second>
</item>
</second>
</item>
<item>
<first>tmp_32_cast_reg_257</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>(Bits)</first>
<second>8</second>
</item>
<item>
<first>(Consts)</first>
<second>4</second>
</item>
<item>
<first>FF</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>tmp_35_cast_reg_288</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>(Bits)</first>
<second>8</second>
</item>
<item>
<first>(Consts)</first>
<second>4</second>
</item>
<item>
<first>FF</first>
<second>4</second>
</item>
</second>
</item>
<item>
<first>tmp_reg_253</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>
<first>(Bits)</first>
<second>1</second>
</item>
<item>
<first>(Consts)</first>
<second>0</second>
</item>
<item>
<first>FF</first>
<second>1</second>
</item>
</second>
</item>
</dp_register_resource>
<dp_component_map class_id="41" tracking_level="0" version="0">
<count>2</count>
<item_version>0</item_version>
<item class_id="42" tracking_level="0" version="0">
<first>DCT_8x8_2D_fadd_3fYi_U9 (DCT_8x8_2D_fadd_3fYi)</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>40</item>
</second>
</item>
<item>
<first>grp_singleGUV_fu_121 (singleGUV)</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>70</item>
</second>
</item>
</dp_component_map>
<dp_expression_map>
<count>11</count>
<item_version>0</item_version>
<item>
<first>exitcond1_fu_210_p2 ( icmp ) </first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>53</item>
</second>
</item>
<item>
<first>exitcond1_i_fu_160_p2 ( icmp ) </first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>22</item>
</second>
</item>
<item>
<first>exitcond_fu_236_p2 ( icmp ) </first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>65</item>
</second>
</item>
<item>
<first>exitcond_i_fu_186_p2 ( icmp ) </first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>34</item>
</second>
</item>
<item>
<first>i_1_fu_166_p2 ( + ) </first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>24</item>
</second>
</item>
<item>
<first>i_2_fu_216_p2 ( + ) </first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>55</item>
</second>
</item>
<item>
<first>j_1_fu_192_p2 ( + ) </first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>36</item>
</second>
</item>
<item>
<first>j_2_fu_242_p2 ( + ) </first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>67</item>
</second>
</item>
<item>
<first>tmp_27_fu_176_p2 ( + ) </first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>31</item>
</second>
</item>
<item>
<first>tmp_29_fu_226_p2 ( + ) </first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>62</item>
</second>
</item>
<item>
<first>tmp_fu_142_p2 ( icmp ) </first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>14</item>
</second>
</item>
</dp_expression_map>
<dp_fifo_map>
<count>0</count>
<item_version>0</item_version>
</dp_fifo_map>
<dp_memory_map>
<count>0</count>
<item_version>0</item_version>
</dp_memory_map>
</res>
<node_label_latency class_id="43" tracking_level="0" version="0">
<count>47</count>
<item_version>0</item_version>
<item class_id="44" tracking_level="0" version="0">
<first>12</first>
<second class_id="45" tracking_level="0" version="0">
<first>0</first>
<second>0</second>
</second>
</item>
<item>
<first>13</first>
<second>
<first>0</first>
<second>0</second>
</second>
</item>
<item>
<first>14</first>
<second>
<first>0</first>
<second>0</second>
</second>
</item>
<item>
<first>15</first>
<second>
<first>0</first>
<second>0</second>
</second>
</item>
<item>
<first>17</first>
<second>
<first>0</first>
<second>0</second>
</second>
</item>
<item>
<first>19</first>
<second>
<first>1</first>
<second>0</second>
</second>
</item>
<item>
<first>20</first>
<second>
<first>1</first>
<second>0</second>
</second>
</item>
<item>
<first>21</first>
<second>
<first>1</first>
<second>0</second>
</second>
</item>
<item>
<first>22</first>
<second>
<first>1</first>
<second>0</second>
</second>
</item>
<item>
<first>24</first>
<second>
<first>1</first>
<second>0</second>
</second>
</item>
<item>
<first>25</first>
<second>
<first>1</first>
<second>0</second>
</second>
</item>
<item>
<first>27</first>
<second>
<first>1</first>
<second>0</second>
</second>
</item>
<item>
<first>29</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>30</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>31</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>32</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>33</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>34</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>36</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>37</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>39</first>
<second>
<first>2</first>
<second>1</second>
</second>
</item>
<item>
<first>40</first>
<second>
<first>3</first>
<second>3</second>
</second>
</item>
<item>
<first>41</first>
<second>
<first>6</first>
<second>0</second>
</second>
</item>
<item>
<first>42</first>
<second>
<first>6</first>
<second>0</second>
</second>
</item>
<item>
<first>44</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>46</first>
<second>
<first>1</first>
<second>0</second>
</second>
</item>
<item>
<first>48</first>
<second>
<first>1</first>
<second>0</second>
</second>
</item>
<item>
<first>50</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>51</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>52</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>53</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>55</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>56</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>58</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
<item>
<first>60</first>
<second>
<first>3</first>
<second>0</second>
</second>
</item>
<item>
<first>61</first>
<second>
<first>3</first>
<second>0</second>
</second>
</item>
<item>
<first>62</first>
<second>
<first>3</first>
<second>0</second>
</second>
</item>
<item>
<first>63</first>
<second>
<first>3</first>
<second>0</second>
</second>
</item>
<item>
<first>64</first>
<second>
<first>3</first>
<second>0</second>
</second>
</item>
<item>
<first>65</first>
<second>
<first>3</first>
<second>0</second>
</second>
</item>
<item>
<first>67</first>
<second>
<first>3</first>
<second>0</second>
</second>
</item>
<item>
<first>68</first>
<second>
<first>3</first>
<second>0</second>
</second>
</item>
<item>
<first>70</first>
<second>
<first>3</first>
<second>1</second>
</second>
</item>
<item>
<first>71</first>
<second>
<first>4</first>
<second>0</second>
</second>
</item>
<item>
<first>72</first>
<second>
<first>4</first>
<second>0</second>
</second>
</item>
<item>
<first>74</first>
<second>
<first>3</first>
<second>0</second>
</second>
</item>
<item>
<first>76</first>
<second>
<first>2</first>
<second>0</second>
</second>
</item>
</node_label_latency>
<bblk_ent_exit class_id="46" tracking_level="0" version="0">
<count>15</count>
<item_version>0</item_version>
<item class_id="47" tracking_level="0" version="0">
<first>16</first>
<second class_id="48" tracking_level="0" version="0">
<first>0</first>
<second>0</second>
</second>
</item>
<item>
<first>18</first>
<second>
<first>0</first>
<second>0</second>
</second>
</item>
<item>
<first>26</first>
<second>
<first>1</first>
<second>1</second>
</second>
</item>
<item>
<first>28</first>
<second>
<first>1</first>
<second>1</second>
</second>
</item>
<item>
<first>38</first>
<second>
<first>2</first>
<second>2</second>
</second>
</item>
<item>
<first>43</first>
<second>
<first>2</first>
<second>6</second>
</second>
</item>
<item>
<first>45</first>
<second>
<first>2</first>
<second>2</second>
</second>
</item>
<item>
<first>47</first>
<second>
<first>1</first>
<second>1</second>
</second>
</item>
<item>
<first>49</first>
<second>
<first>1</first>
<second>1</second>
</second>
</item>
<item>
<first>57</first>
<second>
<first>2</first>
<second>2</second>
</second>
</item>
<item>
<first>59</first>
<second>
<first>2</first>
<second>2</second>
</second>
</item>
<item>
<first>69</first>
<second>
<first>3</first>
<second>3</second>
</second>
</item>
<item>
<first>73</first>
<second>
<first>3</first>
<second>4</second>
</second>
</item>
<item>
<first>75</first>
<second>
<first>3</first>
<second>3</second>
</second>
</item>
<item>
<first>77</first>
<second>
<first>2</first>
<second>2</second>
</second>
</item>
</bblk_ent_exit>
<regions class_id="49" tracking_level="0" version="0">
<count>0</count>
<item_version>0</item_version>
</regions>
<dp_fu_nodes class_id="50" tracking_level="0" version="0">
<count>31</count>
<item_version>0</item_version>
<item class_id="51" tracking_level="0" version="0">
<first>40</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>12</item>
</second>
</item>
<item>
<first>46</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>13</item>
</second>
</item>
<item>
<first>52</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>33</item>
</second>
</item>
<item>
<first>59</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>39</item>
<item>39</item>
<item>41</item>
</second>
</item>
<item>
<first>64</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>64</item>
</second>
</item>
<item>
<first>71</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>71</item>
</second>
</item>
<item>
<first>79</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>19</item>
</second>
</item>
<item>
<first>90</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>29</item>
</second>
</item>
<item>
<first>101</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>50</item>
</second>
</item>
<item>
<first>113</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>60</item>
</second>
</item>
<item>
<first>121</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>70</item>
<item>70</item>
</second>
</item>
<item>
<first>135</first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>40</item>
<item>40</item>
<item>40</item>
<item>40</item>
</second>
</item>
<item>
<first>142</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>14</item>
</second>
</item>
<item>
<first>148</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>20</item>
</second>
</item>
<item>
<first>156</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>21</item>
</second>
</item>
<item>
<first>160</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>22</item>
</second>
</item>
<item>
<first>166</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>24</item>
</second>
</item>
<item>
<first>172</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>30</item>
</second>
</item>
<item>
<first>176</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>31</item>
</second>
</item>
<item>
<first>181</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>32</item>
</second>
</item>
<item>
<first>186</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>34</item>
</second>
</item>
<item>
<first>192</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>36</item>
</second>
</item>
<item>
<first>198</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>51</item>
</second>
</item>
<item>
<first>206</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>52</item>
</second>
</item>
<item>
<first>210</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>53</item>
</second>
</item>
<item>
<first>216</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>55</item>
</second>
</item>
<item>
<first>222</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>61</item>
</second>
</item>
<item>
<first>226</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>62</item>
</second>
</item>
<item>
<first>231</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>63</item>
</second>
</item>
<item>
<first>236</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>65</item>
</second>
</item>
<item>
<first>242</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>67</item>
</second>
</item>
</dp_fu_nodes>
<dp_fu_nodes_expression class_id="53" tracking_level="0" version="0">
<count>25</count>
<item_version>0</item_version>
<item class_id="54" tracking_level="0" version="0">
<first>G_addr_gep_fu_64</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>64</item>
</second>
</item>
<item>
<first>exitcond1_fu_210</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>53</item>
</second>
</item>
<item>
<first>exitcond1_i_fu_160</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>22</item>
</second>
</item>
<item>
<first>exitcond_fu_236</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>65</item>
</second>
</item>
<item>
<first>exitcond_i_fu_186</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>34</item>
</second>
</item>
<item>
<first>i_1_fu_166</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>24</item>
</second>
</item>
<item>
<first>i_2_fu_216</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>55</item>
</second>
</item>
<item>
<first>i_i_phi_fu_79</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>19</item>
</second>
</item>
<item>
<first>i_phi_fu_101</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>50</item>
</second>
</item>
<item>
<first>j_1_fu_192</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>36</item>
</second>
</item>
<item>
<first>j_2_fu_242</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>67</item>
</second>
</item>
<item>
<first>j_cast1_cast_fu_222</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>61</item>
</second>
</item>
<item>
<first>j_i_cast3_cast_fu_172</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>30</item>
</second>
</item>
<item>
<first>j_i_phi_fu_90</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>29</item>
</second>
</item>
<item>
<first>j_phi_fu_113</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>60</item>
</second>
</item>
<item>
<first>subimg_addr_gep_fu_52</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>33</item>
</second>
</item>
<item>
<first>tmp_27_fu_176</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>31</item>
</second>
</item>
<item>
<first>tmp_28_fu_198</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>51</item>
</second>
</item>
<item>
<first>tmp_29_fu_226</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>62</item>
</second>
</item>
<item>
<first>tmp_32_cast_fu_156</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>21</item>
</second>
</item>
<item>
<first>tmp_33_cast_fu_181</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>32</item>
</second>
</item>
<item>
<first>tmp_35_cast_fu_206</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>52</item>
</second>
</item>
<item>
<first>tmp_36_cast_fu_231</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>63</item>
</second>
</item>
<item>
<first>tmp_fu_142</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>14</item>
</second>
</item>
<item>
<first>tmp_s_fu_148</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>20</item>
</second>
</item>
</dp_fu_nodes_expression>
<dp_fu_nodes_module>
<count>2</count>
<item_version>0</item_version>
<item>
<first>grp_fu_135</first>
<second>
<count>4</count>
<item_version>0</item_version>
<item>40</item>
<item>40</item>
<item>40</item>
<item>40</item>
</second>
</item>
<item>
<first>grp_singleGUV_fu_121</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>70</item>
<item>70</item>
</second>
</item>
</dp_fu_nodes_module>
<dp_fu_nodes_io>
<count>2</count>
<item_version>0</item_version>
<item>
<first>inv_read_read_fu_40</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>12</item>
</second>
</item>
<item>
<first>shift_read_read_fu_46</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>13</item>
</second>
</item>
</dp_fu_nodes_io>
<return_ports>
<count>0</count>
<item_version>0</item_version>
</return_ports>
<dp_mem_port_nodes class_id="55" tracking_level="0" version="0">
<count>3</count>
<item_version>0</item_version>
<item class_id="56" tracking_level="0" version="0">
<first class_id="57" tracking_level="0" version="0">
<first>G</first>
<second>0</second>
</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>71</item>
</second>
</item>
<item>
<first>
<first>subimg</first>
<second>0</second>
</first>
<second>
<count>3</count>
<item_version>0</item_version>
<item>39</item>
<item>39</item>
<item>41</item>
</second>
</item>
<item>
<first>
<first>subimg</first>
<second>100</second>
</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>70</item>
</second>
</item>
</dp_mem_port_nodes>
<dp_reg_nodes>
<count>15</count>
<item_version>0</item_version>
<item>
<first>75</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>19</item>
</second>
</item>
<item>
<first>86</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>29</item>
</second>
</item>
<item>
<first>97</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>50</item>
</second>
</item>
<item>
<first>109</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>60</item>
</second>
</item>
<item>
<first>248</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>12</item>
</second>
</item>
<item>
<first>253</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>14</item>
</second>
</item>
<item>
<first>257</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>21</item>
</second>
</item>
<item>
<first>265</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>24</item>
</second>
</item>
<item>
<first>270</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>33</item>
</second>
</item>
<item>
<first>278</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>36</item>
</second>
</item>
<item>
<first>283</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>39</item>
</second>
</item>
<item>
<first>288</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>52</item>
</second>
</item>
<item>
<first>296</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>55</item>
</second>
</item>
<item>
<first>301</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>64</item>
</second>
</item>
<item>
<first>309</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>67</item>
</second>
</item>
</dp_reg_nodes>
<dp_regname_nodes>
<count>15</count>
<item_version>0</item_version>
<item>
<first>G_addr_reg_301</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>64</item>
</second>
</item>
<item>
<first>i_1_reg_265</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>24</item>
</second>
</item>
<item>
<first>i_2_reg_296</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>55</item>
</second>
</item>
<item>
<first>i_i_reg_75</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>19</item>
</second>
</item>
<item>
<first>i_reg_97</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>50</item>
</second>
</item>
<item>
<first>inv_read_reg_248</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>12</item>
</second>
</item>
<item>
<first>j_1_reg_278</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>36</item>
</second>
</item>
<item>
<first>j_2_reg_309</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>67</item>
</second>
</item>
<item>
<first>j_i_reg_86</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>29</item>
</second>
</item>
<item>
<first>j_reg_109</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>60</item>
</second>
</item>
<item>
<first>subimg_addr_reg_270</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>33</item>
</second>
</item>
<item>
<first>subimg_load_reg_283</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>39</item>
</second>
</item>
<item>
<first>tmp_32_cast_reg_257</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>21</item>
</second>
</item>
<item>
<first>tmp_35_cast_reg_288</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>52</item>
</second>
</item>
<item>
<first>tmp_reg_253</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>14</item>
</second>
</item>
</dp_regname_nodes>
<dp_reg_phi>
<count>4</count>
<item_version>0</item_version>
<item>
<first>75</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>19</item>
</second>
</item>
<item>
<first>86</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>29</item>
</second>
</item>
<item>
<first>97</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>50</item>
</second>
</item>
<item>
<first>109</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>60</item>
</second>
</item>
</dp_reg_phi>
<dp_regname_phi>
<count>4</count>
<item_version>0</item_version>
<item>
<first>i_i_reg_75</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>19</item>
</second>
</item>
<item>
<first>i_reg_97</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>50</item>
</second>
</item>
<item>
<first>j_i_reg_86</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>29</item>
</second>
</item>
<item>
<first>j_reg_109</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>60</item>
</second>
</item>
</dp_regname_phi>
<dp_port_io_nodes class_id="58" tracking_level="0" version="0">
<count>4</count>
<item_version>0</item_version>
<item class_id="59" tracking_level="0" version="0">
<first>G(p0)</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>store</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>71</item>
</second>
</item>
</second>
</item>
<item>
<first>inv</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>read</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>12</item>
</second>
</item>
</second>
</item>
<item>
<first>shift</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>
<first>read</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>13</item>
</second>
</item>
</second>
</item>
<item>
<first>subimg(p0)</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>
<first>load</first>
<second>
<count>2</count>
<item_version>0</item_version>
<item>39</item>
<item>39</item>
</second>
</item>
<item>
<first>store</first>
<second>
<count>1</count>
<item_version>0</item_version>
<item>41</item>
</second>
</item>
</second>
</item>
</dp_port_io_nodes>
<port2core class_id="60" tracking_level="0" version="0">
<count>3</count>
<item_version>0</item_version>
<item class_id="61" tracking_level="0" version="0">
<first>1</first>
<second>RAM</second>
</item>
<item>
<first>2</first>
<second>RAM</second>
</item>
<item>
<first>5</first>
<second>RAM</second>
</item>
</port2core>
<node2core>
<count>0</count>
<item_version>0</item_version>
</node2core>
</syndb>
</boost_serialization>
| 30.112562 | 80 | 0.435187 |
06128f808519527e57977e905190c9ebc99c1c4b | 7,638 | adb | Ada | source/nodes/program-nodes-generic_procedure_declarations.adb | reznikmm/gela | 20134f1d154fb763812e73860c6f4b04f353df79 | [
"MIT"
] | null | null | null | source/nodes/program-nodes-generic_procedure_declarations.adb | reznikmm/gela | 20134f1d154fb763812e73860c6f4b04f353df79 | [
"MIT"
] | null | null | null | source/nodes/program-nodes-generic_procedure_declarations.adb | reznikmm/gela | 20134f1d154fb763812e73860c6f4b04f353df79 | [
"MIT"
] | 1 | 2019-10-16T09:05:27.000Z | 2019-10-16T09:05:27.000Z | -- SPDX-FileCopyrightText: 2019 Max Reznik <[email protected]>
--
-- SPDX-License-Identifier: MIT
-------------------------------------------------------------
package body Program.Nodes.Generic_Procedure_Declarations is
function Create
(Generic_Token : not null Program.Lexical_Elements
.Lexical_Element_Access;
Formal_Parameters : Program.Element_Vectors.Element_Vector_Access;
Procedure_Token : not null Program.Lexical_Elements
.Lexical_Element_Access;
Name : not null Program.Elements.Defining_Names
.Defining_Name_Access;
Left_Bracket_Token : Program.Lexical_Elements.Lexical_Element_Access;
Parameters : Program.Elements.Parameter_Specifications
.Parameter_Specification_Vector_Access;
Right_Bracket_Token : Program.Lexical_Elements.Lexical_Element_Access;
With_Token : Program.Lexical_Elements.Lexical_Element_Access;
Aspects : Program.Elements.Aspect_Specifications
.Aspect_Specification_Vector_Access;
Semicolon_Token : not null Program.Lexical_Elements
.Lexical_Element_Access)
return Generic_Procedure_Declaration is
begin
return Result : Generic_Procedure_Declaration :=
(Generic_Token => Generic_Token,
Formal_Parameters => Formal_Parameters,
Procedure_Token => Procedure_Token, Name => Name,
Left_Bracket_Token => Left_Bracket_Token, Parameters => Parameters,
Right_Bracket_Token => Right_Bracket_Token, With_Token => With_Token,
Aspects => Aspects, Semicolon_Token => Semicolon_Token,
Enclosing_Element => null)
do
Initialize (Result);
end return;
end Create;
function Create
(Formal_Parameters : Program.Element_Vectors.Element_Vector_Access;
Name : not null Program.Elements.Defining_Names
.Defining_Name_Access;
Parameters : Program.Elements.Parameter_Specifications
.Parameter_Specification_Vector_Access;
Aspects : Program.Elements.Aspect_Specifications
.Aspect_Specification_Vector_Access;
Is_Part_Of_Implicit : Boolean := False;
Is_Part_Of_Inherited : Boolean := False;
Is_Part_Of_Instance : Boolean := False)
return Implicit_Generic_Procedure_Declaration is
begin
return Result : Implicit_Generic_Procedure_Declaration :=
(Formal_Parameters => Formal_Parameters, Name => Name,
Parameters => Parameters, Aspects => Aspects,
Is_Part_Of_Implicit => Is_Part_Of_Implicit,
Is_Part_Of_Inherited => Is_Part_Of_Inherited,
Is_Part_Of_Instance => Is_Part_Of_Instance, Enclosing_Element => null)
do
Initialize (Result);
end return;
end Create;
overriding function Formal_Parameters
(Self : Base_Generic_Procedure_Declaration)
return Program.Element_Vectors.Element_Vector_Access is
begin
return Self.Formal_Parameters;
end Formal_Parameters;
overriding function Name
(Self : Base_Generic_Procedure_Declaration)
return not null Program.Elements.Defining_Names.Defining_Name_Access is
begin
return Self.Name;
end Name;
overriding function Parameters
(Self : Base_Generic_Procedure_Declaration)
return Program.Elements.Parameter_Specifications
.Parameter_Specification_Vector_Access is
begin
return Self.Parameters;
end Parameters;
overriding function Aspects
(Self : Base_Generic_Procedure_Declaration)
return Program.Elements.Aspect_Specifications
.Aspect_Specification_Vector_Access is
begin
return Self.Aspects;
end Aspects;
overriding function Generic_Token
(Self : Generic_Procedure_Declaration)
return not null Program.Lexical_Elements.Lexical_Element_Access is
begin
return Self.Generic_Token;
end Generic_Token;
overriding function Procedure_Token
(Self : Generic_Procedure_Declaration)
return not null Program.Lexical_Elements.Lexical_Element_Access is
begin
return Self.Procedure_Token;
end Procedure_Token;
overriding function Left_Bracket_Token
(Self : Generic_Procedure_Declaration)
return Program.Lexical_Elements.Lexical_Element_Access is
begin
return Self.Left_Bracket_Token;
end Left_Bracket_Token;
overriding function Right_Bracket_Token
(Self : Generic_Procedure_Declaration)
return Program.Lexical_Elements.Lexical_Element_Access is
begin
return Self.Right_Bracket_Token;
end Right_Bracket_Token;
overriding function With_Token
(Self : Generic_Procedure_Declaration)
return Program.Lexical_Elements.Lexical_Element_Access is
begin
return Self.With_Token;
end With_Token;
overriding function Semicolon_Token
(Self : Generic_Procedure_Declaration)
return not null Program.Lexical_Elements.Lexical_Element_Access is
begin
return Self.Semicolon_Token;
end Semicolon_Token;
overriding function Is_Part_Of_Implicit
(Self : Implicit_Generic_Procedure_Declaration)
return Boolean is
begin
return Self.Is_Part_Of_Implicit;
end Is_Part_Of_Implicit;
overriding function Is_Part_Of_Inherited
(Self : Implicit_Generic_Procedure_Declaration)
return Boolean is
begin
return Self.Is_Part_Of_Inherited;
end Is_Part_Of_Inherited;
overriding function Is_Part_Of_Instance
(Self : Implicit_Generic_Procedure_Declaration)
return Boolean is
begin
return Self.Is_Part_Of_Instance;
end Is_Part_Of_Instance;
procedure Initialize
(Self : in out Base_Generic_Procedure_Declaration'Class) is
begin
for Item in Self.Formal_Parameters.Each_Element loop
Set_Enclosing_Element (Item.Element, Self'Unchecked_Access);
end loop;
Set_Enclosing_Element (Self.Name, Self'Unchecked_Access);
for Item in Self.Parameters.Each_Element loop
Set_Enclosing_Element (Item.Element, Self'Unchecked_Access);
end loop;
for Item in Self.Aspects.Each_Element loop
Set_Enclosing_Element (Item.Element, Self'Unchecked_Access);
end loop;
null;
end Initialize;
overriding function Is_Generic_Procedure_Declaration
(Self : Base_Generic_Procedure_Declaration)
return Boolean is
pragma Unreferenced (Self);
begin
return True;
end Is_Generic_Procedure_Declaration;
overriding function Is_Declaration
(Self : Base_Generic_Procedure_Declaration)
return Boolean is
pragma Unreferenced (Self);
begin
return True;
end Is_Declaration;
overriding procedure Visit
(Self : not null access Base_Generic_Procedure_Declaration;
Visitor : in out Program.Element_Visitors.Element_Visitor'Class) is
begin
Visitor.Generic_Procedure_Declaration (Self);
end Visit;
overriding function To_Generic_Procedure_Declaration_Text
(Self : in out Generic_Procedure_Declaration)
return Program.Elements.Generic_Procedure_Declarations
.Generic_Procedure_Declaration_Text_Access is
begin
return Self'Unchecked_Access;
end To_Generic_Procedure_Declaration_Text;
overriding function To_Generic_Procedure_Declaration_Text
(Self : in out Implicit_Generic_Procedure_Declaration)
return Program.Elements.Generic_Procedure_Declarations
.Generic_Procedure_Declaration_Text_Access is
pragma Unreferenced (Self);
begin
return null;
end To_Generic_Procedure_Declaration_Text;
end Program.Nodes.Generic_Procedure_Declarations;
| 35.691589 | 79 | 0.735795 |
1d4886c6f17afd11d03e11a0c14c13211d8cb3d2 | 1,400 | ada | Ada | gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/ca/ca2007a3.ada | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 7 | 2020-05-02T17:34:05.000Z | 2021-10-17T10:15:18.000Z | gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/ca/ca2007a3.ada | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | null | null | null | gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/ca/ca2007a3.ada | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 2 | 2020-07-27T00:22:36.000Z | 2021-04-01T09:41:02.000Z | -- CA2007A3.ADA
-- Grant of Unlimited Rights
--
-- Under contracts F33600-87-D-0337, F33600-84-D-0280, MDA903-79-C-0687,
-- F08630-91-C-0015, and DCA100-97-D-0025, the U.S. Government obtained
-- unlimited rights in the software and documentation contained herein.
-- Unlimited rights are defined in DFAR 252.227-7013(a)(19). By making
-- this public release, the Government intends to confer upon all
-- recipients unlimited rights equal to those held by the Government.
-- These rights include rights to use, duplicate, release or disclose the
-- released technical data and computer software in whole or in part, in
-- any manner and for any purpose whatsoever, and to have or permit others
-- to do so.
--
-- DISCLAIMER
--
-- ALL MATERIALS OR INFORMATION HEREIN RELEASED, MADE AVAILABLE OR
-- DISCLOSED ARE AS IS. THE GOVERNMENT MAKES NO EXPRESS OR IMPLIED
-- WARRANTY AS TO ANY MATTER WHATSOEVER, INCLUDING THE CONDITIONS OF THE
-- SOFTWARE, DOCUMENTATION OR OTHER INFORMATION RELEASED, MADE AVAILABLE
-- OR DISCLOSED, OR THE OWNERSHIP, MERCHANTABILITY, OR FITNESS FOR A
-- PARTICULAR PURPOSE OF SAID MATERIAL.
--*
-- WKB 7/1/81
SEPARATE (CA2007A0M)
PACKAGE BODY CA2007A3 IS
BEGIN
ELAB_ORDER (NEXT) := '3';
NEXT := NEXT + 1;
END CA2007A3;
| 37.837838 | 79 | 0.670714 |
1de0331b5e4e45072e6db3ff6433b13bc852af52 | 2,107 | ada | Ada | Task/Sierpinski-carpet/Ada/sierpinski-carpet.ada | mullikine/RosettaCodeData | 4f0027c6ce83daa36118ee8b67915a13cd23ab67 | [
"Info-ZIP"
] | 1 | 2018-11-09T22:08:38.000Z | 2018-11-09T22:08:38.000Z | Task/Sierpinski-carpet/Ada/sierpinski-carpet.ada | mullikine/RosettaCodeData | 4f0027c6ce83daa36118ee8b67915a13cd23ab67 | [
"Info-ZIP"
] | null | null | null | Task/Sierpinski-carpet/Ada/sierpinski-carpet.ada | mullikine/RosettaCodeData | 4f0027c6ce83daa36118ee8b67915a13cd23ab67 | [
"Info-ZIP"
] | 1 | 2018-11-09T22:08:40.000Z | 2018-11-09T22:08:40.000Z | with Ada.Text_Io; use Ada.Text_Io;
procedure Sierpinski_Carpet is
subtype Index_Type is Integer range 1..81;
type Pattern_Array is array(Index_Type range <>, Index_Type range <>) of Boolean;
Pattern : Pattern_Array(1..81,1..81) := (Others =>(others => true));
procedure Clear_Center(P : in out Pattern_Array; X1 : Index_Type; X2 : Index_Type;
Y1 : Index_Type; Y2 : Index_Type) is
Xfirst : Index_Type;
Xlast : Index_Type;
Yfirst : Index_Type;
Ylast : Index_Type;
Diff : Integer;
begin
Xfirst :=(X2 - X1 + 1) / 3 + X1;
Diff := Xfirst - X1;
Xlast := Xfirst + Diff;
Yfirst := (Y2 - Y1) / 3 + Y1;
YLast := YFirst + Diff;
for I in XFirst..XLast loop
for J in YFirst..YLast loop
P(I, J) := False;
end loop;
end loop;
end Clear_Center;
procedure Print(P : Pattern_Array) is
begin
for I in P'range(1) loop
for J in P'range(2) loop
if P(I,J) then
Put('*');
else
Put(' ');
end if;
end loop;
New_Line;
end loop;
end Print;
procedure Divide_Square(P : in out Pattern_Array; Order : Positive) is
Factor : Natural := 0;
X1, X2 : Index_Type;
Y1, Y2 : Index_Type;
Division : Index_Type;
Num_Sections : Index_Type;
begin
while Factor < Order loop
Num_Sections := 3**Factor;
Factor := Factor + 1;
X1 := P'First;
Division := P'Last / Num_Sections;
X2 := Division;
Y1 := X1;
Y2 := X2;
loop
loop
Clear_Center(P, X1, X2, Y1, Y2);
exit when X2 = P'Last;
X1 := X2;
X2 := X2 + Division;
end loop;
exit when Y2 = P'Last;
Y1 := Y2;
Y2 := Y2 + Division;
X1 := P'First;
X2 := Division;
end loop;
end loop;
end Divide_Square;
begin
Divide_Square(Pattern, 3);
Print(Pattern);
end Sierpinski_Carpet;
| 27.363636 | 85 | 0.514001 |
2f22f8aaac912897c966ec0327727c02e5e24065 | 4,467 | adb | Ada | gcc-gcc-7_3_0-release/gcc/ada/s-tporft.adb | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 7 | 2020-05-02T17:34:05.000Z | 2021-10-17T10:15:18.000Z | gcc-gcc-7_3_0-release/gcc/ada/s-tporft.adb | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | null | null | null | gcc-gcc-7_3_0-release/gcc/ada/s-tporft.adb | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 2 | 2020-07-27T00:22:36.000Z | 2021-04-01T09:41:02.000Z | ------------------------------------------------------------------------------
-- --
-- GNAT RUN-TIME LIBRARY (GNARL) COMPONENTS --
-- --
-- SYSTEM.TASK_PRIMITIVES.OPERATIONS.REGISTER_FOREIGN_THREAD --
-- --
-- B o d y --
-- --
-- Copyright (C) 2002-2016, Free Software Foundation, Inc. --
-- --
-- GNARL is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
-- ware Foundation; either version 3, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
-- or FITNESS FOR A PARTICULAR PURPOSE. --
-- --
-- As a special exception under Section 7 of GPL version 3, you are granted --
-- additional permissions described in the GCC Runtime Library Exception, --
-- version 3.1, as published by the Free Software Foundation. --
-- --
-- You should have received a copy of the GNU General Public License and --
-- a copy of the GCC Runtime Library Exception along with this program; --
-- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
-- <http://www.gnu.org/licenses/>. --
-- --
-- GNARL was developed by the GNARL team at Florida State University. --
-- Extensive contributions were provided by Ada Core Technologies, Inc. --
-- --
------------------------------------------------------------------------------
with System.Task_Info;
-- Use for Unspecified_Task_Info
with System.Soft_Links;
-- used to initialize TSD for a C thread, in function Self
with System.Multiprocessors;
separate (System.Task_Primitives.Operations)
function Register_Foreign_Thread (Thread : Thread_Id) return Task_Id is
Local_ATCB : aliased Ada_Task_Control_Block (0);
Self_Id : Task_Id;
Succeeded : Boolean;
begin
-- This section is tricky. We must not call anything that might require
-- an ATCB, until the new ATCB is in place. In order to get an ATCB
-- immediately, we fake one, so that it is then possible to e.g allocate
-- memory (which might require accessing self).
-- Record this as the Task_Id for the thread
Local_ATCB.Common.LL.Thread := Thread;
Local_ATCB.Common.Current_Priority := System.Priority'First;
Specific.Set (Local_ATCB'Unchecked_Access);
-- It is now safe to use an allocator
Self_Id := new Ada_Task_Control_Block (0);
-- Finish initialization
Lock_RTS;
System.Tasking.Initialize_ATCB
(Self_Id, null, Null_Address, Null_Task,
Foreign_Task_Elaborated'Access,
System.Priority'First, System.Multiprocessors.Not_A_Specific_CPU, null,
Task_Info.Unspecified_Task_Info, 0, 0, Self_Id, Succeeded);
Unlock_RTS;
pragma Assert (Succeeded);
Self_Id.Master_of_Task := 0;
Self_Id.Master_Within := Self_Id.Master_of_Task + 1;
for L in Self_Id.Entry_Calls'Range loop
Self_Id.Entry_Calls (L).Self := Self_Id;
Self_Id.Entry_Calls (L).Level := L;
end loop;
Self_Id.Common.State := Runnable;
Self_Id.Awake_Count := 1;
Self_Id.Common.Task_Image (1 .. 14) := "foreign thread";
Self_Id.Common.Task_Image_Len := 14;
-- Since this is not an ordinary Ada task, we will start out undeferred
Self_Id.Deferral_Level := 0;
-- We do not provide an alternate stack for foreign threads
Self_Id.Common.Task_Alternate_Stack := Null_Address;
System.Soft_Links.Create_TSD (Self_Id.Common.Compiler_Data);
Enter_Task (Self_Id);
return Self_Id;
end Register_Foreign_Thread;
| 44.227723 | 78 | 0.54578 |
1d3ca98fa49d29c4f457894975414483aaf8c926 | 153 | adb | Ada | llvm-2.9/test/FrontendAda/var_offset.adb | DependableSystemsLab/Trident | 90b38ab3ce8b7ad743986ddf66eaea7d20d921cb | [
"MIT"
] | 5 | 2018-09-23T05:44:31.000Z | 2021-09-08T18:52:37.000Z | llvm-2.9/test/FrontendAda/var_offset.adb | vidkidz/crossbridge | ba0bf94aee0ce6cf7eb5be882382e52bc57ba396 | [
"MIT"
] | 4 | 2019-06-13T16:27:31.000Z | 2021-06-07T07:24:31.000Z | llvm-2.9/test/FrontendAda/var_offset.adb | vidkidz/crossbridge | ba0bf94aee0ce6cf7eb5be882382e52bc57ba396 | [
"MIT"
] | 4 | 2018-09-23T05:44:33.000Z | 2021-04-20T00:29:11.000Z | -- RUN: %llvmgcc -S %s -I%p/Support
package body Var_Offset is
function F (X : T) return Character is
begin
return X.Bad_Field;
end;
end;
| 19.125 | 41 | 0.647059 |
50d2b591750b64603f212c83af2d18073b994376 | 27,776 | adb | Ada | src/zmq.adb | sonneveld/adazmq | ee1a3ad1588f6a298fe1170c0e907052dcb7a1a6 | [
"MIT"
] | null | null | null | src/zmq.adb | sonneveld/adazmq | ee1a3ad1588f6a298fe1170c0e907052dcb7a1a6 | [
"MIT"
] | null | null | null | src/zmq.adb | sonneveld/adazmq | ee1a3ad1588f6a298fe1170c0e907052dcb7a1a6 | [
"MIT"
] | null | null | null | with Ada.Unchecked_Conversion;
with Interfaces.C.Strings;
with ZMQ_Constants;
package body ZMQ is
use type System.Address;
use type Interfaces.C.int;
use type Interfaces.C.size_t;
use type Interfaces.C.unsigned;
-- Conversion
function Convert is new Ada.Unchecked_Conversion
(Source => Interfaces.C.size_t,
Target => Interfaces.C.unsigned_long);
function Convert is new Ada.Unchecked_Conversion
(Source => System.Address,
Target => Interfaces.C.Strings.chars_ptr);
function Convert is new Ada.Unchecked_Conversion
(Source => Interfaces.C.Strings.chars_ptr,
Target => System.Address);
function Convert (Value : Context_Type'Class) return System.Address is (Value.Impl_Ptr);
function Convert (Value : Context_Option_Names) return Interfaces.C.int
is
begin
case Value is
when ZMQ_IO_THREADS => return ZMQ_Constants.ZMQ_IO_THREADS;
when ZMQ_MAX_SOCKETS => return ZMQ_Constants.ZMQ_MAX_SOCKETS;
when ZMQ_IPV6 => return ZMQ_Constants.ZMQ_IPV6;
end case;
end Convert;
function Convert (Value : Socket_Type'Class) return System.Address is (Value.Impl_Ptr);
function Convert (Value : Socket_Types) return Interfaces.C.int
is
begin
case Value is
when ZMQ_PAIR => return ZMQ_Constants.ZMQ_PAIR;
when ZMQ_PUB => return ZMQ_Constants.ZMQ_PUB;
when ZMQ_SUB => return ZMQ_Constants.ZMQ_SUB;
when ZMQ_REQ => return ZMQ_Constants.ZMQ_REQ;
when ZMQ_REP => return ZMQ_Constants.ZMQ_REP;
when ZMQ_DEALER => return ZMQ_Constants.ZMQ_DEALER;
when ZMQ_ROUTER => return ZMQ_Constants.ZMQ_ROUTER;
when ZMQ_PULL => return ZMQ_Constants.ZMQ_PULL;
when ZMQ_PUSH => return ZMQ_Constants.ZMQ_PUSH;
when ZMQ_XPUB => return ZMQ_Constants.ZMQ_XPUB;
when ZMQ_XSUB => return ZMQ_Constants.ZMQ_XSUB;
when ZMQ_STREAM => return ZMQ_Constants.ZMQ_STREAM;
end case;
end Convert;
function Convert (Value : Socket_Option_Names) return Interfaces.C.int
is
begin
case Value is
when ZMQ_AFFINITY => return ZMQ_Constants.ZMQ_AFFINITY;
when ZMQ_IDENTITY => return ZMQ_Constants.ZMQ_IDENTITY;
when ZMQ_SUBSCRIBE => return ZMQ_Constants.ZMQ_SUBSCRIBE;
when ZMQ_UNSUBSCRIBE => return ZMQ_Constants.ZMQ_UNSUBSCRIBE;
when ZMQ_RATE => return ZMQ_Constants.ZMQ_RATE;
when ZMQ_RECOVERY_IVL => return ZMQ_Constants.ZMQ_RECOVERY_IVL;
when ZMQ_SNDBUF => return ZMQ_Constants.ZMQ_SNDBUF;
when ZMQ_RCVBUF => return ZMQ_Constants.ZMQ_RCVBUF;
when ZMQ_RCVMORE => return ZMQ_Constants.ZMQ_RCVMORE;
when ZMQ_FD => return ZMQ_Constants.ZMQ_FD;
when ZMQ_EVENTS => return ZMQ_Constants.ZMQ_EVENTS;
when ZMQ_TYPE => return ZMQ_Constants.ZMQ_TYPE;
when ZMQ_LINGER => return ZMQ_Constants.ZMQ_LINGER;
when ZMQ_RECONNECT_IVL => return ZMQ_Constants.ZMQ_RECONNECT_IVL;
when ZMQ_BACKLOG => return ZMQ_Constants.ZMQ_BACKLOG;
when ZMQ_RECONNECT_IVL_MAX => return ZMQ_Constants.ZMQ_RECONNECT_IVL_MAX;
when ZMQ_MAXMSGSIZE => return ZMQ_Constants.ZMQ_MAXMSGSIZE;
when ZMQ_SNDHWM => return ZMQ_Constants.ZMQ_SNDHWM;
when ZMQ_RCVHWM => return ZMQ_Constants.ZMQ_RCVHWM;
when ZMQ_MULTICAST_HOPS => return ZMQ_Constants.ZMQ_MULTICAST_HOPS;
when ZMQ_RCVTIMEO => return ZMQ_Constants.ZMQ_RCVTIMEO;
when ZMQ_SNDTIMEO => return ZMQ_Constants.ZMQ_SNDTIMEO;
when ZMQ_LAST_ENDPOINT => return ZMQ_Constants.ZMQ_LAST_ENDPOINT;
when ZMQ_ROUTER_MANDATORY => return ZMQ_Constants.ZMQ_ROUTER_MANDATORY;
when ZMQ_TCP_KEEPALIVE => return ZMQ_Constants.ZMQ_TCP_KEEPALIVE;
when ZMQ_TCP_KEEPALIVE_CNT => return ZMQ_Constants.ZMQ_TCP_KEEPALIVE_CNT;
when ZMQ_TCP_KEEPALIVE_IDLE => return ZMQ_Constants.ZMQ_TCP_KEEPALIVE_IDLE;
when ZMQ_TCP_KEEPALIVE_INTVL => return ZMQ_Constants.ZMQ_TCP_KEEPALIVE_INTVL;
when ZMQ_TCP_ACCEPT_FILTER => return ZMQ_Constants.ZMQ_TCP_ACCEPT_FILTER;
when ZMQ_IMMEDIATE => return ZMQ_Constants.ZMQ_IMMEDIATE;
when ZMQ_XPUB_VERBOSE => return ZMQ_Constants.ZMQ_XPUB_VERBOSE;
when ZMQ_ROUTER_RAW => return ZMQ_Constants.ZMQ_ROUTER_RAW;
when ZMQ_IPV6 => return ZMQ_Constants.ZMQ_IPV6;
when ZMQ_MECHANISM => return ZMQ_Constants.ZMQ_MECHANISM;
when ZMQ_PLAIN_SERVER => return ZMQ_Constants.ZMQ_PLAIN_SERVER;
when ZMQ_PLAIN_USERNAME => return ZMQ_Constants.ZMQ_PLAIN_USERNAME;
when ZMQ_PLAIN_PASSWORD => return ZMQ_Constants.ZMQ_PLAIN_PASSWORD;
when ZMQ_CURVE_SERVER => return ZMQ_Constants.ZMQ_CURVE_SERVER;
when ZMQ_CURVE_PUBLICKEY => return ZMQ_Constants.ZMQ_CURVE_PUBLICKEY;
when ZMQ_CURVE_SECRETKEY => return ZMQ_Constants.ZMQ_CURVE_SECRETKEY;
when ZMQ_CURVE_SERVERKEY => return ZMQ_Constants.ZMQ_CURVE_SERVERKEY;
when ZMQ_PROBE_ROUTER => return ZMQ_Constants.ZMQ_PROBE_ROUTER;
when ZMQ_REQ_CORRELATE => return ZMQ_Constants.ZMQ_REQ_CORRELATE;
when ZMQ_REQ_RELAXED => return ZMQ_Constants.ZMQ_REQ_RELAXED;
when ZMQ_CONFLATE => return ZMQ_Constants.ZMQ_CONFLATE;
when ZMQ_ZAP_DOMAIN => return ZMQ_Constants.ZMQ_ZAP_DOMAIN;
end case;
end Convert;
procedure Version (Major : out Natural; Minor : out Natural; Patch : out Natural)
is
c_major : aliased Interfaces.C.int;
c_minor : aliased Interfaces.C.int;
c_patch : aliased Interfaces.C.int;
begin
ZMQ_Thin.zmq_version (c_major'Access, c_minor'Access, c_patch'Access);
Major := Natural (c_major);
Minor := Natural (c_minor);
Patch := Natural (c_patch);
end Version;
function Errno return Integer
is
begin
return Integer (ZMQ_Thin.zmq_errno);
end Errno;
function Strerror (Err_Num : Integer) return String
is
c_errnum : constant Interfaces.C.int := Interfaces.C.int (Err_Num);
c_strerror : constant Interfaces.C.Strings.chars_ptr := ZMQ_Thin.zmq_strerror (c_errnum);
begin
return Interfaces.C.Strings.Value (c_strerror);
end Strerror;
procedure Raise_Errno is
Error_Number : constant Integer := Errno;
begin
raise ZMQ_Error with "[" & Error_Number'Img & "] " & Strerror (Error_Number);
end Raise_Errno;
pragma No_Return (Raise_Errno);
-- Context
-- ------------------------------------------------------------------------
overriding procedure Initialize (Cxt : in out Context_Type) is
begin
Setup (Cxt);
end Initialize;
overriding procedure Finalize (Cxt : in out Context_Type) is
begin
if Cxt.Impl_Ptr /= System.Null_Address then
Term (Cxt);
end if;
end Finalize;
procedure Setup (Cxt : in out Context_Type) is
c_cxt : constant System.Address := ZMQ_Thin.zmq_ctx_new;
begin
if c_cxt /= System.Null_Address then
Cxt.Impl_Ptr := c_cxt;
else
Raise_Errno;
end if;
end Setup;
function New_Context return Context_Type
is
begin
return Cxt : Context_Type do
Setup (Cxt);
end return;
end New_Context;
procedure Term (Context : in out Context_Type)
is
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_ctx_term (Convert (Context));
if c_res = 0 then
Context.Impl_Ptr := System.Null_Address;
return;
else
Raise_Errno;
end if;
end Term;
procedure Shutdown (Context : Context_Type)
is
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_ctx_shutdown (Convert (Context));
if c_res = 0 then
return;
else
Raise_Errno;
end if;
end Shutdown;
procedure Set (Context : Context_Type; Name : Context_Option_Names; Value : Natural)
is
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_ctx_set (Convert (Context), Convert (Name), Interfaces.C.int (Value));
if c_res = 0 then
return;
else
Raise_Errno;
end if;
end Set;
function Get (Context : Context_Type; Name : Context_Option_Names) return Natural
is
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_ctx_get (Convert (Context), Convert (Name));
if c_res >= 0 then
return Natural (c_res);
else
Raise_Errno;
end if;
end Get;
function New_Socket (Context : Context_Type; Instance_Type : Socket_Types) return Socket_Type'Class
is
begin
return S : Socket_Type do
Setup (S, Context, Instance_Type);
end return;
end New_Socket;
-- Message_Type
-- ------------------------------------------------------------------------
overriding procedure Initialize (M : in out Message_Type) is
begin
M.Msg_Internals.u_u := (others => 0);
Setup (M);
end Initialize;
overriding procedure Finalize (M : in out Message_Type) is
begin
Close (M);
end Finalize;
procedure Setup (M : in out Message_Type; Size : Integer := 0)
is
c_size : constant Interfaces.C.size_t := Interfaces.C.size_t (Size);
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_msg_init_size (M.Msg_Internals'Access, c_size);
if c_res = 0 then
return;
else
Raise_Errno;
end if;
end Setup;
function Create_Message (Size : Integer := 0) return Message_Type
is
begin
return M : Message_Type do
M.Msg_Internals.u_u := (others => 0);
Setup (M, Size);
end return;
end Create_Message;
procedure Setup (M : in out Message_Type; Value : String)
is
c_size : constant Interfaces.C.size_t := Interfaces.C.size_t (Value'Length);
c_res : Interfaces.C.int;
c_data : System.Address;
begin
c_res := ZMQ_Thin.zmq_msg_init_size (M.Msg_Internals'Access, c_size);
if c_res /= 0 then
Raise_Errno;
end if;
c_data := ZMQ_Thin.zmq_msg_data (M.Msg_Internals'Access);
if c_data = System.Null_Address then
Raise_Errno;
end if;
declare
Data_String : String (1 .. Value'Length);
for Data_String'Address use c_data;
begin
Data_String (1 .. Value'Length) := Value (Value'First .. Value'Last);
end;
end Setup;
function Create_Message (Value : String) return Message_Type
is
begin
return M : Message_Type do
M.Msg_Internals.u_u := (others => 0);
Setup (M, Value);
end return;
end Create_Message;
procedure Send (M : in out Message_Type; S : Socket_Type'Class; Do_Not_Wait : Boolean := False; Send_More : Boolean := False)
is
Expected_Length : constant Integer := Size (M);
c_flags : Interfaces.C.unsigned := 0;
c_res : Interfaces.C.int;
begin
c_flags := 0;
if Do_Not_Wait then
c_flags := c_flags or ZMQ_Constants.ZMQ_DONTWAIT;
end if;
if Send_More then
c_flags := c_flags or ZMQ_Constants.ZMQ_SNDMORE;
end if;
c_res := ZMQ_Thin.zmq_msg_send (M.Msg_Internals'Access, Convert (S), c_flags);
if c_res >= 0 and then Interfaces.C.int (Expected_Length) = c_res then
return;
elsif c_res >= 0 then
raise ZMQ_Error with "Entire Message_Type wasn't sent.";
else
Raise_Errno;
end if;
end Send;
procedure Recv (M : in out Message_Type; S : Socket_Type'Class; Do_Not_Wait : Boolean := False)
is
c_flags : Interfaces.C.unsigned := 0;
c_res : Interfaces.C.int;
begin
c_flags := 0;
if Do_Not_Wait then
c_flags := c_flags or ZMQ_Constants.ZMQ_DONTWAIT;
end if;
c_res := ZMQ_Thin.zmq_msg_recv (M.Msg_Internals'Access, Convert (S), c_flags);
if c_res >= 0 then
return;
else
Raise_Errno;
end if;
end Recv;
procedure Close (M : in out Message_Type)
is
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_msg_close (M.Msg_Internals'Access);
if c_res = 0 then
return;
else
Raise_Errno;
end if;
end Close;
procedure Move (Dest : in out Message_Type; Src : in out Message_Type)
is
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_msg_move (Dest.Msg_Internals'Access, Src.Msg_Internals'Access);
if c_res = 0 then
return;
else
Raise_Errno;
end if;
end Move;
procedure Copy (Dest : in out Message_Type; Src : in out Message_Type)
is
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_msg_copy (Dest.Msg_Internals'Access, Src.Msg_Internals'Access);
if c_res = 0 then
return;
else
Raise_Errno;
end if;
end Copy;
-- TODO date returning other types..
function Data (M : in out Message_Type) return String
is
c_data : System.Address;
c_size : Interfaces.C.size_t;
begin
c_data := ZMQ_Thin.zmq_msg_data (M.Msg_Internals'Access);
if c_data = System.Null_Address then
Raise_Errno;
end if;
c_size := ZMQ_Thin.zmq_msg_size (M.Msg_Internals'Access);
declare
Result_Str : String (1 .. Integer (c_size));
for Result_Str'Address use c_data;
begin
return Result_Str;
end;
end Data;
function Size (M : in out Message_Type) return Natural
is
c_res : Interfaces.C.size_t;
begin
c_res := ZMQ_Thin.zmq_msg_size (M.Msg_Internals'Access);
return Natural (c_res);
end Size;
function More (M : in out Message_Type) return Boolean
is
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_msg_more (M.Msg_Internals'Access);
return c_res /= 0;
end More;
function Src_FD (M : in out Message_Type) return Integer
is
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_msg_get (M.Msg_Internals'Access, ZMQ_Constants.ZMQ_SRCFD);
if c_res >= 0 then
return Integer (c_res);
else
Raise_Errno;
end if;
end Src_FD;
function Shared (M : in out Message_Type) return Boolean
is
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_msg_get (M.Msg_Internals'Access, ZMQ_Constants.ZMQ_SHARED);
if c_res >= 0 then
return c_res /= 0;
else
Raise_Errno;
end if;
end Shared;
-- Socket
-- ------------------------------------------------------------------------
overriding procedure Initialize (S : in out Socket_Type)
is
begin
S.Impl_Ptr := System.Null_Address;
end Initialize;
overriding procedure Finalize (S : in out Socket_Type)
is
begin
if S.Impl_Ptr /= System.Null_Address then
Close (S);
end if;
end Finalize;
procedure Setup (S : in out Socket_Type; Context : Context_Type'Class; Instance_Type : Socket_Types)
is
c_socket : System.Address;
begin
c_socket := ZMQ_Thin.zmq_socket (Convert (Context), Convert (Instance_Type));
if c_socket /= System.Null_Address then
S.Impl_Ptr := c_socket;
else
Raise_Errno;
end if;
end Setup;
procedure Close (S : in out Socket_Type)
is
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_close (Convert (S));
if c_res = 0 then
S.Impl_Ptr := System.Null_Address;
return;
else
Raise_Errno;
end if;
end Close;
procedure Set_Sock_Opt (S : Socket_Type; Option : Socket_Option_Names; Option_Value : Integer)
is
c_optval : constant Interfaces.C.int := Interfaces.C.int (Option_Value);
c_optval_ptr : constant System.Address := c_optval'Address;
c_optvallen : constant Interfaces.C.size_t := c_optval'Size / 8;
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_setsockopt (Convert (S), Convert (Option), c_optval_ptr, c_optvallen);
if c_res = 0 then
return;
else
Raise_Errno;
end if;
end Set_Sock_Opt;
procedure Set_Sock_Opt (S : Socket_Type; Option : Socket_Option_Names; Option_Value : Long_Long_Integer)
is
c_optval : constant Interfaces.C.long := Interfaces.C.long (Option_Value);
c_optval_ptr : constant System.Address := c_optval'Address;
c_optvallen : constant Interfaces.C.size_t := c_optval'Size / 8;
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_setsockopt (Convert (S), Convert (Option), c_optval_ptr, c_optvallen);
if c_res = 0 then
return;
else
Raise_Errno;
end if;
end Set_Sock_Opt;
procedure Set_Sock_Opt (S : Socket_Type; Option : Socket_Option_Names; Option_Value : String)
is
c_optval : Interfaces.C.Strings.chars_ptr := Interfaces.C.Strings.New_String (Option_Value);
c_optvallen : constant Interfaces.C.size_t := Option_Value'Length;
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_setsockopt (Convert (S), Convert (Option), Convert (c_optval), c_optvallen);
Interfaces.C.Strings.Free (c_optval);
if c_res = 0 then
return;
else
Raise_Errno;
end if;
end Set_Sock_Opt;
-- function zmq_getsockopt (s : System.Address; option : Interfaces.C.int; optval : System.Address; optvallen : access Interfaces.C.size_t) return Interfaces.C.int;
function Get_Sock_Opt (S : Socket_Type; Option : Socket_Option_Names) return Integer
is
c_optval : aliased Interfaces.C.int;
c_optval_ptr : constant System.Address := c_optval'Address;
c_optvallen : aliased Interfaces.C.size_t := c_optval'Size / 8;
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_getsockopt (Convert (S), Convert (Option), c_optval_ptr, c_optvallen'Access);
if c_res = 0 then
return Integer (c_optval);
else
Raise_Errno;
end if;
end Get_Sock_Opt;
function Get_Sock_Opt (S : Socket_Type; Option : Socket_Option_Names) return Long_Long_Integer
is
c_optval : aliased Interfaces.C.long;
c_optval_ptr : constant System.Address := c_optval'Address;
c_optvallen : aliased Interfaces.C.size_t := c_optval'Size / 8;
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_getsockopt (Convert (S), Convert (Option), c_optval_ptr, c_optvallen'Access);
if c_res = 0 then
return Long_Long_Integer (c_optval);
else
Raise_Errno;
end if;
end Get_Sock_Opt;
function Get_Sock_Opt (S : Socket_Type; Option : Socket_Option_Names) return String
is
Buf_Size : constant Integer := 4096;
c_optval : aliased String (1.. Buf_Size);
c_optval_ptr : constant System.Address := c_optval'Address;
c_optvallen : aliased Interfaces.C.size_t := c_optval'Length;
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_getsockopt (Convert (S), Convert (Option), c_optval_ptr, c_optvallen'Access);
if c_optvallen >= Interfaces.C.size_t (Buf_Size) then
raise ZMQ_Error with "string option too large.";
end if;
if c_res = 0 then
return c_optval (1 .. Integer (c_optvallen));
else
Raise_Errno;
end if;
end Get_Sock_Opt;
procedure Bind (S : Socket_Type; Address : String)
is
c_addr : Interfaces.C.Strings.chars_ptr := Interfaces.C.Strings.New_String (Address);
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_bind (Convert (S), c_addr);
Interfaces.C.Strings.Free (c_addr);
if c_res = 0 then
return;
else
Raise_Errno;
end if;
end Bind;
procedure Connect (S : Socket_Type; Address : String)
is
c_addr : Interfaces.C.Strings.chars_ptr := Interfaces.C.Strings.New_String (Address);
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_connect (Convert (S), c_addr);
Interfaces.C.Strings.Free (c_addr);
if c_res = 0 then
return;
else
Raise_Errno;
end if;
end Connect;
procedure Unbind (S : Socket_Type; Address : String)
is
c_addr : Interfaces.C.Strings.chars_ptr := Interfaces.C.Strings.New_String (Address);
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_unbind (Convert (S), c_addr);
Interfaces.C.Strings.Free (c_addr);
if c_res = 0 then
return;
else
Raise_Errno;
end if;
end Unbind;
procedure Disconnect (S : Socket_Type; Address : String)
is
c_addr : Interfaces.C.Strings.chars_ptr := Interfaces.C.Strings.New_String (Address);
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_disconnect (Convert (S), c_addr);
Interfaces.C.Strings.Free (c_addr);
if c_res = 0 then
return;
else
Raise_Errno;
end if;
end Disconnect;
-- TODO: What about an array of flags?
procedure Send (S : Socket_Type; Buf : String; Do_Not_Wait : Boolean := False; Send_More : Boolean := False)
is
c_buf : constant System.Address := Buf'Address; -- TODO is this okay? or ptr to first item better?
c_len : constant Interfaces.C.size_t := Buf'Length;
c_flags : Interfaces.C.unsigned := 0;
c_res : Interfaces.C.int;
begin
c_flags := 0;
if Do_Not_Wait then
c_flags := c_flags or ZMQ_Constants.ZMQ_DONTWAIT;
end if;
if Send_More then
c_flags := c_flags or ZMQ_Constants.ZMQ_SNDMORE;
end if;
c_res := ZMQ_Thin.zmq_send (Convert (S), c_buf, c_len, c_flags);
if c_res >= 0 and then Interfaces.C.size_t (c_res) = c_len then
return;
elsif c_res >= 0 then
raise ZMQ_Error with "Entire Message_Type wasn't sent.";
else
Raise_Errno;
end if;
end Send;
function Recv (S : Socket_Type; Do_Not_Wait : Boolean := False) return String
is
Buf_Size : constant Integer := 32*1024;
Buf : String (1 .. Buf_Size);
c_buf : constant System.Address := Buf (Buf'First)'Address;
c_len : constant Interfaces.C.size_t := Buf'Length;
c_flags : Interfaces.C.unsigned := 0;
c_res : Interfaces.C.int;
begin
c_flags := 0;
if Do_Not_Wait then
c_flags := c_flags or ZMQ_Constants.ZMQ_DONTWAIT;
end if;
c_res := ZMQ_Thin.zmq_recv (Convert (S), c_buf, c_len, c_flags);
if c_res >= 0 and then c_res /= Interfaces.C.int (Buf_Size) then
return Buf (1 .. Integer (c_res));
elsif c_res >= 0 then
raise ZMQ_Error with "Received Message_Type was truncated.";
else
Raise_Errno;
end if;
end Recv;
-- Polling
-- ------------------------------------------------------------------------
procedure Setup (PE : in out Poll_Item_Type; S : Socket_Type'Class; Poll_In : Boolean := False; Poll_Out : Boolean := False)
is
begin
PE.S_Impl_Ptr := S.Impl_Ptr;
PE.FD := 0;
PE.Poll_In := Poll_In;
PE.Poll_Out := Poll_Out;
PE.Poll_Error := False;
PE.Result_In := False;
PE.Result_Out := False;
PE.Result_Error := False;
end Setup;
function New_Poll_Item (S : Socket_Type'Class; Poll_In : Boolean := False; Poll_Out : Boolean := False) return Poll_Item_Type
is
begin
return PE : Poll_Item_Type do
Setup (PE, S, Poll_In, Poll_Out);
end return;
end New_Poll_Item;
procedure Setup (PE : in out Poll_Item_Type; FD : Integer; Poll_In : Boolean := False; Poll_Out : Boolean := False; Poll_Error : Boolean := False)
is
begin
PE.S_Impl_Ptr := System.Null_Address;
PE.FD := Interfaces.C.int (FD);
PE.Poll_In := Poll_In;
PE.Poll_Out := Poll_Out;
PE.Poll_Error := Poll_Error;
PE.Result_In := False;
PE.Result_Out := False;
PE.Result_Error := False;
end Setup;
function New_Poll_Item (FD : Integer; Poll_In : Boolean := False; Poll_Out : Boolean := False; Poll_Error : Boolean := False) return Poll_Item_Type
is
begin
return PE : Poll_Item_Type do
Setup (PE, FD, Poll_In, Poll_Out, Poll_Error);
end return;
end New_Poll_Item;
function Is_Readable (PE : Poll_Item_Type) return Boolean is (PE.Result_In);
function Is_Writable (PE : Poll_Item_Type) return Boolean is (PE.Result_Out);
function Has_Error (PE : Poll_Item_Type) return Boolean is (PE.Result_Error);
type C_Poll_Item_Array is array (Natural range <>) of aliased ZMQ_Thin.zmq_pollitem_t;
pragma Convention (C, C_Poll_Item_Array);
function Convert (PE : Poll_Item_Type) return ZMQ_Thin.zmq_pollitem_t
is
begin
return Result : ZMQ_Thin.zmq_pollitem_t do
Result.socket := PE.S_Impl_Ptr;
Result.fd := PE.FD;
Result.events := 0;
if PE.Poll_In then
Result.events := Interfaces.C.short (Interfaces.C.unsigned (Result.events) or ZMQ_Constants.ZMQ_POLLIN);
end if;
if PE.Poll_Out then
Result.events := Interfaces.C.short (Interfaces.C.unsigned (Result.events) or ZMQ_Constants.ZMQ_POLLOUT);
end if;
if PE.Poll_Error then
Result.events := Interfaces.C.short (Interfaces.C.unsigned (Result.events) or ZMQ_Constants.ZMQ_POLLERR);
end if;
end return;
end Convert;
procedure Transfer_Result (Dest : in out Poll_Item_Type; Src : ZMQ_Thin.zmq_pollitem_t)
is
begin
Dest.Result_In := (Interfaces.C.unsigned(Src.revents) and ZMQ_Constants.ZMQ_POLLIN) /= 0;
Dest.Result_Out := (Interfaces.C.unsigned(Src.revents) and ZMQ_Constants.ZMQ_POLLOUT) /= 0;
end;
function Poll (Entries : in out Poll_Item_Array_Type; Timeout : Long_Long_Integer := -1) return Natural
is
c_items : aliased C_Poll_Item_Array (Entries'First .. Entries'Last);
c_items_ptr : constant access ZMQ_Thin.zmq_pollitem_t := c_items (c_items'First)'Access;
c_nitems : constant Interfaces.C.int := Interfaces.C.int (Entries'Length);
c_timeout : constant Interfaces.C.long := Interfaces.C.long (Timeout);
c_res : Interfaces.C.int;
begin
for I in Entries'Range loop
c_items (I) := Convert (Entries (I));
end loop;
c_res := ZMQ_Thin.zmq_poll (c_items_ptr, c_nitems, c_timeout);
if c_res < 0 then
Raise_Errno;
end if;
for I in Entries'Range loop
Transfer_Result (Entries (I), c_items (I));
end loop;
return Natural (c_res);
end Poll;
procedure Poll (Entries : in out Poll_Item_Array_Type; Timeout : Long_Long_Integer := -1)
is
Dummy : Natural;
begin
Dummy := Poll (Entries, Timeout);
end Poll;
-- Proxy
-- ------------------------------------------------------------------------
-- TODO, merge these? using the optional parameters?
procedure Proxy (Frontend : Socket_Type'Class; Backend : Socket_Type'Class; Capture : Socket_Type'Class := ZMQ.No_Socket)
is
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_proxy (Convert (Frontend), Convert (Backend), Convert (Capture));
-- proxy is expected to always return an error.
if c_res = 0 then
return;
else
Raise_Errno;
end if;
end Proxy;
procedure Proxy_Steerable (Frontend : Socket_Type'Class; Backend : Socket_Type'Class; Capture : Socket_Type'Class := ZMQ.No_Socket; Control : Socket_Type'Class := ZMQ.No_Socket)
is
c_res : Interfaces.C.int;
begin
c_res := ZMQ_Thin.zmq_proxy_steerable (Convert (Frontend), Convert (Backend), Convert (Capture), Convert (Control));
-- proxy_steerable can terminate cleanly
if c_res = 0 then
return;
else
Raise_Errno;
end if;
end Proxy_Steerable;
end ZMQ;
| 32.260163 | 180 | 0.646457 |
067d852b8f6a2cc1e7c61a7947a9e5daada60acf | 1,568 | adb | Ada | source/crypto-sha1.adb | ytomino/openssl-ada | efacd262cec28c773e80246319f25ab316d93d81 | [
"OpenSSL",
"Unlicense"
] | 1 | 2020-09-04T18:05:22.000Z | 2020-09-04T18:05:22.000Z | source/crypto-sha1.adb | ytomino/openssl-ada | efacd262cec28c773e80246319f25ab316d93d81 | [
"OpenSSL",
"Unlicense"
] | null | null | null | source/crypto-sha1.adb | ytomino/openssl-ada | efacd262cec28c773e80246319f25ab316d93d81 | [
"OpenSSL",
"Unlicense"
] | null | null | null | with Ada.Unchecked_Conversion;
with System;
package body Crypto.SHA1 is
use type C.signed_int;
function Initial return Context is
begin
return Result : Context do
if C.openssl.sha.SHA1_Init (Result.SHA'Access) = 0 then
raise Use_Error;
end if;
end return;
end Initial;
procedure Update (
Context : in out SHA1.Context;
Data : in Ada.Streams.Stream_Element_Array)
is
pragma Suppress (Index_Check);
begin
if C.openssl.sha.SHA1_Update (
Context.SHA'Access,
C.void_const_ptr (Data (Data'First)'Address),
Data'Length) = 0
then
raise Use_Error;
end if;
end Update;
procedure Update (Context : in out SHA1.Context; Data : in String) is
pragma Suppress (Index_Check);
begin
if C.openssl.sha.SHA1_Update (
Context.SHA'Access,
C.void_const_ptr (Data (Data'First)'Address),
Data'Length) = 0
then
raise Use_Error;
end if;
end Update;
procedure Final (Context : in out SHA1.Context; Digest : out Fingerprint) is
function To_Pointer is
new Ada.Unchecked_Conversion (System.Address, C.unsigned_char_ptr);
begin
if C.openssl.sha.SHA1_Final (
To_Pointer (Digest (Digest'First)'Address),
Context.SHA'Access) = 0
then
raise Use_Error;
end if;
end Final;
function Value (S : Message_Digest) return Fingerprint is
begin
return Result : Fingerprint do
Value (S, Result);
end return;
end Value;
function Image (Digest : in Fingerprint) return Message_Digest is
begin
return Result : Message_Digest do
Image (Digest, Result);
end return;
end Image;
end Crypto.SHA1;
| 22.724638 | 77 | 0.716837 |
317bf40cef7448fcaf690d9c0a65d7e383d7a93d | 2,753 | adb | Ada | examples/Unleashed/blinky/src/main.adb | shakram02/Ada_Drivers_Library | a407ca7ddbc2d9756647016c2f8fd8ef24a239ff | [
"BSD-3-Clause"
] | 192 | 2016-06-01T18:32:04.000Z | 2022-03-26T22:52:31.000Z | examples/Unleashed/blinky/src/main.adb | shakram02/Ada_Drivers_Library | a407ca7ddbc2d9756647016c2f8fd8ef24a239ff | [
"BSD-3-Clause"
] | 239 | 2016-05-26T20:02:01.000Z | 2022-03-31T09:46:56.000Z | examples/Unleashed/blinky/src/main.adb | shakram02/Ada_Drivers_Library | a407ca7ddbc2d9756647016c2f8fd8ef24a239ff | [
"BSD-3-Clause"
] | 142 | 2016-06-05T08:12:20.000Z | 2022-03-24T17:37:17.000Z | ------------------------------------------------------------------------------
-- --
-- Copyright (C) 2019, AdaCore --
-- --
-- Redistribution and use in source and binary forms, with or without --
-- modification, are permitted provided that the following conditions are --
-- met: --
-- 1. Redistributions of source code must retain the above copyright --
-- notice, this list of conditions and the following disclaimer. --
-- 2. Redistributions in binary form must reproduce the above copyright --
-- notice, this list of conditions and the following disclaimer in --
-- the documentation and/or other materials provided with the --
-- distribution. --
-- 3. Neither the name of the copyright holder nor the names of its --
-- contributors may be used to endorse or promote products derived --
-- from this software without specific prior written permission. --
-- --
-- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS --
-- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT --
-- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR --
-- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT --
-- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, --
-- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT --
-- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, --
-- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY --
-- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT --
-- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE --
-- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. --
-- --
------------------------------------------------------------------------------
with Unleashed.LEDs; use Unleashed.LEDs;
procedure Main is
begin
Enable;
loop
for X in reverse 0 .. 100 loop
for Id in LED_Id loop
Set_Brightness (Id, LED_Brightness (Float (X) / 100.0));
end loop;
-- Busy loop
for Cnt in 1 .. 1_000_000 loop
null;
end loop;
end loop;
end loop;
end Main;
| 53.980392 | 78 | 0.508899 |
12b9e7efe375cca99cb6cff1956a2f2b8afda24b | 8,809 | adb | Ada | Des_Ada/src/mainParallel.adb | VMika/Des_Ada | fcadb38aa9118e668329c3443d3b6e4c83456acc | [
"MIT"
] | null | null | null | Des_Ada/src/mainParallel.adb | VMika/Des_Ada | fcadb38aa9118e668329c3443d3b6e4c83456acc | [
"MIT"
] | null | null | null | Des_Ada/src/mainParallel.adb | VMika/Des_Ada | fcadb38aa9118e668329c3443d3b6e4c83456acc | [
"MIT"
] | null | null | null | WITH P_StepHandler.InputHandler;
USE P_StepHandler.InputHandler;
WITH P_StepHandler.IPHandler;
USE P_StepHandler.IPHandler;
WITH P_StepHandler.KeyHandler;
USE P_StepHandler.KeyHandler;
WITH P_StepHandler.FeistelHandler;
USE P_StepHandler.FeistelHandler;
WITH P_StepHandler.ReverseIPHandler;
USE P_StepHandler.ReverseIPHandler;
WITH P_StepHandler.OutputHandler;
USE P_StepHandler.OutputHandler;
with Ada.Strings;
use Ada.Strings;
with Ada.Text_IO;
use Ada.Text_IO;
with Ada.Integer_Text_IO;
use Ada.Integer_Text_IO;
with Ada.Strings.Unbounded.Text_IO;
with P_StructuralTypes;
use P_StructuralTypes;
with Ada.Strings.Unbounded;
use Ada.Strings.Unbounded;
with Ada.Real_Time;
use Ada.Real_Time;
procedure mainParallel is
--------------------------------------------------------------------------------
--- PROCEDURES ---
--------------------------------------------------------------------------------
function Request_Input_Name return Unbounded_String is
begin
Put ("Choose the input file : ");
return Ada.Strings.Unbounded.Text_IO.Get_Line;
end;
function Request_Output_Name return Unbounded_String is
begin
Put ("Choose the output file (a new file will be created) : ");
return Ada.Strings.Unbounded.Text_IO.Get_Line;
end;
function Request_Mode return Character is
Mode : Character := '.';
begin
while (Mode /= 'D' and Mode /= 'E') loop
Put ("Choose mode of algorithm (E for encryption, D for deciphering) : ");
Mode := To_String(Ada.Strings.Unbounded.Text_IO.Get_Line)(1);
end loop;
return Mode;
end;
function Request_Key return T_Key is
Tmp_Key : Unbounded_String;
begin
while Length(Tmp_Key) /= 8 loop
Put ("Choose a key (must be exactly 8 characters long) : ");
Tmp_Key := Ada.Strings.Unbounded.Text_IO.Get_Line;
end loop;
return To_String (Tmp_Key);
end;
--------------------------------------------------------------------------------
--- TASK TYPE ---
--------------------------------------------------------------------------------
type IP_Task;
type Feistel_Task;
type ReverseIP_Task;
type Output_Task;
type Ptr_IP_Task is access all IP_Task;
type Ptr_Feistel_Task is access all Feistel_Task;
type Ptr_ReverseIP_Task is access all ReverseIP_Task;
type Ptr_Output_Task is access all Output_Task;
task type IP_Task (Handler : Ptr_IPHandler) is
entry Next_Task (Next_Step : Ptr_Feistel_Task);
entry Process_Token (Token : T_BinaryBlock ; Id : Integer);
end IP_Task;
task type Feistel_Task (Handler : Ptr_FeistelHandler) is
entry Next_Task (Next_Step : Ptr_ReverseIP_Task);
entry Process_Token (Token : T_BinaryBlock ; Id : Integer);
end Feistel_Task;
task type ReverseIP_Task (Handler : Ptr_ReverseIPHandler) is
entry Next_Task (Next_Step : Ptr_Output_Task);
entry Process_Token (Token : T_BinaryBlock ; Id : Integer);
end ReverseIP_Task;
task type Output_Task (Ptr_Output : BinaryContainer_Access) is
entry Process_Token (Token : T_BinaryBlock ; Id : Integer);
end Output_Task;
--------------------------------------------------------------------------------
--- TASK DEFINITION ---
--------------------------------------------------------------------------------
task body IP_Task is
Next : Ptr_Feistel_Task;
Block : T_BinaryBlock;
Index : Integer;
begin
accept Next_Task (Next_Step : in Ptr_Feistel_Task) do
Next := Next_Step;
end Next_Task;
loop
select
accept Process_Token (Token : in T_BinaryBlock; Id : in Integer) do
Block := Token;
Index := Id;
end Process_Token;
Block := Handler.Process_Block (Block);
Next.Process_Token (Block, Index);
or
terminate;
end select;
end loop;
end IP_Task;
task body Feistel_Task is
Next : Ptr_ReverseIP_Task;
Block : T_BinaryBlock;
Index : Integer;
begin
accept Next_Task (Next_Step : in Ptr_ReverseIP_Task) do
Next := Next_Step;
end Next_Task;
loop
select
accept Process_Token (Token : in T_BinaryBlock; Id : in Integer) do
Block := Token;
Index := Id;
end Process_Token;
Block := Handler.Process_Block (Block);
Next.Process_Token (Block, Index);
or
terminate;
end select;
end loop;
end Feistel_Task;
task body ReverseIP_Task is
Next : Ptr_Output_Task;
Block : T_BinaryBlock;
Index : Integer;
begin
accept Next_Task (Next_Step : in Ptr_Output_Task) do
Next := Next_Step;
end Next_Task;
loop
select
accept Process_Token (Token : in T_BinaryBlock; Id : in Integer) do
Block := Token;
Index := Id;
end Process_Token;
Block := Handler.Process_Block (Block);
Next.Process_Token (Block, Index);
or
terminate;
end select;
end loop;
end ReverseIP_Task;
task body Output_Task is
Block : T_BinaryBlock;
Index : Integer;
begin
loop
select
accept Process_Token (Token : in T_BinaryBlock; Id : in Integer) do
Block := Token;
Index := Id;
end Process_Token;
Ptr_Output.all(Index) := Block;
or
terminate;
end select;
end loop;
end Output_Task;
--------------------------------------------------------------------------------
--- VARIABLES DEFINITION ---
--------------------------------------------------------------------------------
-- User's input
Input_Name : Unbounded_String;
Output_Name : Unbounded_String;
Ptr_Key : Key_Access := new T_Key;
Mode : Character;
-- Handlers
InputLink : aliased InputHandler;
IPLink : aliased IPHandler;
KeyGenLink : aliased KeyHandler;
FeistelLink : aliased FeistelHandler;
ReverseIPLink : aliased ReverseIPHandler;
OutputLink : aliased OutputHandler;
-- SubKey array
Ptr_SubKey_Array : BinarySubKeyArray_Access := new T_BinarySubKeyArray;
begin
--- Request user's informations
Input_Name := Request_Input_Name;
Output_Name := Request_Output_Name;
Mode := Request_Mode;
Ptr_Key.all := Request_Key;
--- Creating all the new link (handlers)
InputLink := Make (InputLink, Input_Name);
KeyGenLink := Make (KeyGenLink);
IPLink := Make (IPLink);
FeistelLink := Make (FeistelLink);
ReverseIPLink := Make (ReverseIPLink);
OutputLink := Make (OutputLink);
--- Setting parameters for key generation
KeyGenLink.Set_KeyAccess(Ptr_Key);
KeyGenLink.Set_SubKeyArrayAccess(Ptr_SubKey_Array);
declare
Ptr_BinaryContainer : constant BinaryContainer_Access
:= new T_BinaryContainer(1..InputLink.Get_Input_Size);
Ptr_OutputContainer : constant BinaryContainer_Access
:= new T_BinaryContainer(1..InputLink.Get_Input_Size);
begin
InputLink.Set_BinaryContainer(Ptr_BinaryContainer);
IPLink.Set_BinaryContainer(Ptr_BinaryContainer);
FeistelLink.Set_BinaryContainer(Ptr_BinaryContainer);
ReverseIPLink.Set_BinaryContainer(Ptr_BinaryContainer);
FeistelLink.Set_SubKeyArrayAccess(Ptr_SubKey_Array);
FeistelLink.Set_Mode(Mode);
OutputLink.Set_BinaryContainer(Ptr_OutputContainer);
OutputLink.Set_Output_Name(Output_Name);
end;
InputLink.Handle;
KeyGenLink.Handle;
declare
IP : aliased IP_Task (IPLink'Unchecked_Access);
Feistel : aliased Feistel_Task (FeistelLink'Unchecked_Access);
ReverseIP : aliased ReverseIP_Task (ReverseIPLink'Unchecked_Access);
Output : aliased Output_Task (OutputLink.Get_BinaryContainer);
begin
IP.Next_Task (Feistel'Unchecked_Access);
Feistel.Next_Task (ReverseIP'Unchecked_Access);
ReverseIP.Next_Task (Output'Unchecked_Access);
for i in InputLink.Get_BinaryContainer'Range loop
IP.Process_Token (InputLink.Get_BinaryContainer.all(i), i);
end loop;
end;
OutputLink.Handle;
end mainParallel;
| 30.271478 | 83 | 0.582245 |
31808616e9c2771e2068508c601ec7bf77d9ab84 | 2,432 | ads | Ada | src/vulkan-math/gentype/vulkan-math-genbtype.ads | zrmyers/VulkanAda | ed8c46d923bc8936db3a5d55d36afebb928a9ede | [
"MIT"
] | 1 | 2021-01-29T21:10:45.000Z | 2021-01-29T21:10:45.000Z | src/vulkan-math/gentype/vulkan-math-genbtype.ads | zrmyers/VulkanAda | ed8c46d923bc8936db3a5d55d36afebb928a9ede | [
"MIT"
] | 8 | 2020-04-22T14:55:20.000Z | 2021-11-22T03:58:08.000Z | src/vulkan-math/gentype/vulkan-math-genbtype.ads | zrmyers/VulkanAda | ed8c46d923bc8936db3a5d55d36afebb928a9ede | [
"MIT"
] | 1 | 2021-04-05T13:19:21.000Z | 2021-04-05T13:19:21.000Z | --------------------------------------------------------------------------------
-- MIT License
--
-- Copyright (c) 2020 Zane Myers
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy
-- of this software and associated documentation files (the "Software"), to deal
-- in the Software without restriction, including without limitation the rights
-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-- copies of the Software, and to permit persons to whom the Software is
-- furnished to do so, subject to the following conditions:
--
-- The above copyright notice and this permission notice shall be included in all
-- copies or substantial portions of the Software.
--
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-- SOFTWARE.
--------------------------------------------------------------------------------
with Vulkan.Math.GenType;
--------------------------------------------------------------------------------
--< @group Vulkan Math GenType
--------------------------------------------------------------------------------
--< @summary
--< This package describes any length vector of Vkm_Bool type.
--<
--< @description
--< Provides an instantiation of the generic GenType package with a Base_Type of
--< Vkm_Bool. This is used to provide the Vkm_GenBType subtype for the Vulkan Math
--< library.
--------------------------------------------------------------------------------
package Vulkan.Math.GenBType is
pragma Preelaborate;
pragma Pure;
--< @private
--< An instance of the generic GenType package, with Vkm_Bool as the Base_Type.
package GBT is new Vulkan.Math.GenType(
Base_Type => Vkm_Bool,
Default_Value => false,
Image => Vkm_Bool'Image,
Unary_Minus => "-",
Multiply => "*");
--< A subtype of the instantiated Vkm_GenType that represents the GenBType
--< described in the GLSL specification.
subtype Vkm_GenBType is GBT.Vkm_GenType;
end Vulkan.Math.GenBType;
| 43.428571 | 83 | 0.609375 |
5043fa1dbabc750db2bc3530cc65ec35bb2e1f6b | 3,663 | ada | Ada | gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/c9/c97303b.ada | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 7 | 2020-05-02T17:34:05.000Z | 2021-10-17T10:15:18.000Z | gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/c9/c97303b.ada | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | null | null | null | gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/c9/c97303b.ada | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 2 | 2020-07-27T00:22:36.000Z | 2021-04-01T09:41:02.000Z | -- C97303B.ADA
-- Grant of Unlimited Rights
--
-- Under contracts F33600-87-D-0337, F33600-84-D-0280, MDA903-79-C-0687,
-- F08630-91-C-0015, and DCA100-97-D-0025, the U.S. Government obtained
-- unlimited rights in the software and documentation contained herein.
-- Unlimited rights are defined in DFAR 252.227-7013(a)(19). By making
-- this public release, the Government intends to confer upon all
-- recipients unlimited rights equal to those held by the Government.
-- These rights include rights to use, duplicate, release or disclose the
-- released technical data and computer software in whole or in part, in
-- any manner and for any purpose whatsoever, and to have or permit others
-- to do so.
--
-- DISCLAIMER
--
-- ALL MATERIALS OR INFORMATION HEREIN RELEASED, MADE AVAILABLE OR
-- DISCLOSED ARE AS IS. THE GOVERNMENT MAKES NO EXPRESS OR IMPLIED
-- WARRANTY AS TO ANY MATTER WHATSOEVER, INCLUDING THE CONDITIONS OF THE
-- SOFTWARE, DOCUMENTATION OR OTHER INFORMATION RELEASED, MADE AVAILABLE
-- OR DISCLOSED, OR THE OWNERSHIP, MERCHANTABILITY, OR FITNESS FOR A
-- PARTICULAR PURPOSE OF SAID MATERIAL.
--*
-- CHECK THAT A TIMED_ENTRY_CALL CAN APPEAR IN PLACES WHERE A
-- SELECTIVE_WAIT CANNOT.
-- PART 2: PROCEDURE BODY EMBEDDED IN TASK BODY.
-- RM 4/12/1982
with Impdef;
WITH REPORT;
USE REPORT;
PROCEDURE C97303B IS
BEGIN
TEST ( "C97303B" , "CHECK THAT A TIMED_ENTRY_CALL CAN" &
" APPEAR WHERE A SELECTIVE_WAIT CANNOT" );
-------------------------------------------------------------------
DECLARE
TASK TT IS
ENTRY A ( AUTHORIZED : IN BOOLEAN );
END TT ;
TASK BODY TT IS
PROCEDURE WITHIN_TASK_BODY ;
PROCEDURE WITHIN_TASK_BODY IS
BEGIN
SELECT -- NOT A SELECTIVE_WAIT
A ( FALSE ) ; -- CALLING (OWN) ENTRY
OR
DELAY 1.0 * Impdef.One_Second;
COMMENT( "ALTERNATIVE BRANCH TAKEN" );
END SELECT;
END WITHIN_TASK_BODY ;
BEGIN
-- CALL THE INNER PROC. TO FORCE EXEC. OF TIMED_E_CALL
WITHIN_TASK_BODY ;
ACCEPT A ( AUTHORIZED : IN BOOLEAN ) DO
IF AUTHORIZED THEN
COMMENT( "AUTHORIZED ENTRY_CALL" );
ELSE
FAILED( "UNAUTHORIZED ENTRY_CALL" );
END IF;
END A ;
END TT ;
PROCEDURE OUTSIDE_TASK_BODY IS
BEGIN
SELECT -- NOT A SELECTIVE_WAIT
TT.A ( FALSE ) ; -- UNBORN
OR
DELAY 1.0 * Impdef.One_Second;
COMMENT( "(OUT:) ALTERNATIVE BRANCH TAKEN" );
END SELECT;
END OUTSIDE_TASK_BODY ;
PACKAGE CREATE_OPPORTUNITY_TO_CALL IS END;
PACKAGE BODY CREATE_OPPORTUNITY_TO_CALL IS
BEGIN
-- CALL THE OTHER PROC. TO FORCE EXEC. OF TIMED_E_CALL
OUTSIDE_TASK_BODY ;
END CREATE_OPPORTUNITY_TO_CALL ;
BEGIN
TT.A ( TRUE );
EXCEPTION
WHEN TASKING_ERROR =>
FAILED( "TASKING ERROR" );
END ;
-------------------------------------------------------------------
RESULT ;
END C97303B ;
| 27.335821 | 79 | 0.521977 |
1c61c6af740ebf7ddb6c110ce46a89343c3bed8d | 12,799 | adb | Ada | source/zlib-streams.adb | ytomino/zlib-ada | 432310c122c25c703171f4c3883bd5c47d3bfd22 | [
"Zlib",
"Unlicense"
] | null | null | null | source/zlib-streams.adb | ytomino/zlib-ada | 432310c122c25c703171f4c3883bd5c47d3bfd22 | [
"Zlib",
"Unlicense"
] | null | null | null | source/zlib-streams.adb | ytomino/zlib-ada | 432310c122c25c703171f4c3883bd5c47d3bfd22 | [
"Zlib",
"Unlicense"
] | null | null | null | with System.Address_To_Access_Conversions;
package body zlib.Streams is
generic
with procedure Deflate_Or_Inflate (
Stream : in out zlib.Stream;
In_Item : in Ada.Streams.Stream_Element_Array;
In_Last : out Ada.Streams.Stream_Element_Offset;
Out_Item : out Ada.Streams.Stream_Element_Array;
Out_Last : out Ada.Streams.Stream_Element_Offset;
Finish : in Boolean;
Finished : out Boolean);
procedure Generic_Finish (
Stream : not null access Ada.Streams.Root_Stream_Type'Class;
Object : in out zlib.Stream);
procedure Generic_Finish (
Stream : not null access Ada.Streams.Root_Stream_Type'Class;
Object : in out zlib.Stream)
is
Dummy_In_Item : Ada.Streams.Stream_Element_Array (1 .. 0);
Dummy_In_Used : Ada.Streams.Stream_Element_Offset;
Out_Item : Ada.Streams.Stream_Element_Array (1 .. 2 ** 15);
Out_Last : Ada.Streams.Stream_Element_Offset;
Finished : Boolean;
begin
loop
Deflate_Or_Inflate (
Object,
Dummy_In_Item,
Dummy_In_Used,
Out_Item,
Out_Last,
True,
Finished);
Ada.Streams.Write (Stream.all, Out_Item (Out_Item'First .. Out_Last));
exit when Finished;
end loop;
end Generic_Finish;
generic
with procedure Deflate_Or_Inflate (
Stream : in out zlib.Stream;
In_Item : in Ada.Streams.Stream_Element_Array;
In_Last : out Ada.Streams.Stream_Element_Offset;
Out_Item : out Ada.Streams.Stream_Element_Array;
Out_Last : out Ada.Streams.Stream_Element_Offset;
Finish : in Boolean;
Finished : out Boolean);
procedure Generic_Read (
Stream : not null access Ada.Streams.Root_Stream_Type'Class;
Item : out Ada.Streams.Stream_Element_Array;
Last : out Ada.Streams.Stream_Element_Offset;
Object : in out zlib.Stream;
Reading_In_First : in out Ada.Streams.Stream_Element_Offset;
Reading_In_Last : in out Ada.Streams.Stream_Element_Offset;
Reading_In_Buffer : in out Ada.Streams.Stream_Element_Array);
procedure Generic_Read (
Stream : not null access Ada.Streams.Root_Stream_Type'Class;
Item : out Ada.Streams.Stream_Element_Array;
Last : out Ada.Streams.Stream_Element_Offset;
Object : in out zlib.Stream;
Reading_In_First : in out Ada.Streams.Stream_Element_Offset;
Reading_In_Last : in out Ada.Streams.Stream_Element_Offset;
Reading_In_Buffer : in out Ada.Streams.Stream_Element_Array) is
begin
if Controlled.Reference (Object).Stream_End then
Last := Item'First - 1;
else
declare
In_Used : Ada.Streams.Stream_Element_Offset;
Out_First : Ada.Streams.Stream_Element_Offset := Item'First;
Finish : Boolean := False;
Finished : Boolean;
begin
loop
if Reading_In_First > Reading_In_Last then
Reading_In_First := Reading_In_Buffer'First;
begin
Ada.Streams.Read (Stream.all, Reading_In_Buffer, Reading_In_Last);
exception
when End_Error =>
Reading_In_Last := Reading_In_First - 1;
end;
if Reading_In_Last < Reading_In_Buffer'First then
Finish := True;
end if;
end if;
Deflate_Or_Inflate (
Object,
Reading_In_Buffer (Reading_In_First .. Reading_In_Last),
In_Used,
Item (Out_First .. Item'Last),
Last,
Finish,
Finished);
Reading_In_First := In_Used + 1;
exit when Finished or else Last >= Item'Last;
Out_First := Last + 1;
end loop;
end;
end if;
if Last = Item'First - 1 then
raise End_Error;
end if;
end Generic_Read;
generic
with procedure Deflate_Or_Inflate (
Stream : in out zlib.Stream;
In_Item : in Ada.Streams.Stream_Element_Array;
In_Last : out Ada.Streams.Stream_Element_Offset;
Out_Item : out Ada.Streams.Stream_Element_Array;
Out_Last : out Ada.Streams.Stream_Element_Offset;
Finish : in Boolean;
Finished : out Boolean);
procedure Generic_Write (
Stream : not null access Ada.Streams.Root_Stream_Type'Class;
Item : in Ada.Streams.Stream_Element_Array;
Object : in out zlib.Stream);
procedure Generic_Write (
Stream : not null access Ada.Streams.Root_Stream_Type'Class;
Item : in Ada.Streams.Stream_Element_Array;
Object : in out zlib.Stream) is
begin
if Item'First <= Item'Last then
declare
In_First : Ada.Streams.Stream_Element_Offset := Item'First;
In_Used : Ada.Streams.Stream_Element_Offset;
Out_Item : Ada.Streams.Stream_Element_Array (1 .. 2 ** 15);
Out_Last : Ada.Streams.Stream_Element_Offset;
Finished : Boolean;
begin
loop
Deflate_Or_Inflate (
Object,
Item (In_First .. Item'Last),
In_Used,
Out_Item,
Out_Last,
False,
Finished);
Ada.Streams.Write (Stream.all, Out_Item (Out_Item'First .. Out_Last));
exit when Finished or else In_Used >= Item'Last;
In_First := In_Used + 1;
end loop;
end;
end if;
end Generic_Write;
-- only writing with deflation
function Open (
Stream : not null access Ada.Streams.Root_Stream_Type'Class;
Level : Compression_Level := Default_Compression;
Method : Compression_Method := Deflated;
Window_Bits : zlib.Window_Bits := Default_Window_Bits;
Header : Deflation_Header := Default;
Memory_Level : zlib.Memory_Level := Default_Memory_Level;
Strategy : zlib.Strategy := Default_Strategy)
return Out_Type
is
package Conv is
new System.Address_To_Access_Conversions (Ada.Streams.Root_Stream_Type'Class);
begin
return (Ada.Streams.Root_Stream_Type
with
Variable_View => <>, -- default value
Stream => Conv.To_Address (Conv.Object_Pointer (Stream)),
Deflator =>
Deflate_Init (
Level => Level,
Method => Method,
Window_Bits => Window_Bits,
Header => Header,
Memory_Level => Memory_Level,
Strategy => Strategy));
end Open;
procedure Close (Object : in out Out_Type) is
pragma Check (Dynamic_Predicate,
Check => Is_Open (Object) or else raise Status_Error);
begin
Close (Object.Deflator);
end Close;
function Is_Open (Object : Out_Type) return Boolean is
begin
return Is_Open (Object.Deflator);
end Is_Open;
function Stream (
Object : in out Out_Type)
return not null access Ada.Streams.Root_Stream_Type'Class
is
pragma Check (Dynamic_Predicate,
Check => Is_Open (Object) or else raise Status_Error);
begin
return Object.Variable_View;
end Stream;
procedure Finish (
Object : in out Out_Type)
is
pragma Check (Dynamic_Predicate,
Check => Is_Open (Object) or else raise Status_Error);
package Conv is
new System.Address_To_Access_Conversions (Ada.Streams.Root_Stream_Type'Class);
procedure Deflating_Finish is new Generic_Finish (Deflate);
begin
Deflating_Finish (Conv.To_Pointer (Object.Stream), Object.Deflator);
end Finish;
overriding procedure Read (
Object : in out Out_Type;
Item : out Ada.Streams.Stream_Element_Array;
Last : out Ada.Streams.Stream_Element_Offset)
is
pragma Check (Dynamic_Predicate, Check => Boolean'(raise Mode_Error));
begin
raise Program_Error; -- exclusive use for writing
end Read;
overriding procedure Write (
Object : in out Out_Type;
Item : in Ada.Streams.Stream_Element_Array)
is
package Conv is
new System.Address_To_Access_Conversions (Ada.Streams.Root_Stream_Type'Class);
procedure Deflating_Write is new Generic_Write (Deflate);
begin
Deflating_Write (Conv.To_Pointer (Object.Stream), Item, Object.Deflator);
end Write;
-- only reading with inflation
function Open (
Stream : not null access Ada.Streams.Root_Stream_Type'Class;
Window_Bits : zlib.Window_Bits := Default_Window_Bits;
Header : Inflation_Header := Auto;
Buffer_Length : Ada.Streams.Stream_Element_Count := Default_Buffer_Length)
return In_Type
is
package Conv is
new System.Address_To_Access_Conversions (Ada.Streams.Root_Stream_Type'Class);
begin
return (Ada.Streams.Root_Stream_Type
with
Variable_View => <>, -- default value
Buffer_Length => Buffer_Length,
Stream => Conv.To_Address (Conv.Object_Pointer (Stream)),
Inflator => Inflate_Init (Window_Bits => Window_Bits, Header => Header),
In_Buffer => <>,
In_First => 0,
In_Last => -1);
end Open;
procedure Close (Object : in out In_Type) is
pragma Check (Dynamic_Predicate,
Check => Is_Open (Object) or else raise Status_Error);
begin
Close (Object.Inflator);
end Close;
function Is_Open (Object : In_Type) return Boolean is
begin
return Is_Open (Object.Inflator);
end Is_Open;
function Stream (
Object : in out In_Type)
return not null access Ada.Streams.Root_Stream_Type'Class
is
pragma Check (Dynamic_Predicate,
Check => Is_Open (Object) or else raise Status_Error);
begin
return Object.Variable_View;
end Stream;
overriding procedure Read (
Object : in out In_Type;
Item : out Ada.Streams.Stream_Element_Array;
Last : out Ada.Streams.Stream_Element_Offset)
is
package Conv is
new System.Address_To_Access_Conversions (Ada.Streams.Root_Stream_Type'Class);
procedure Deflating_Read is new Generic_Read (Inflate);
begin
Deflating_Read (
Conv.To_Pointer (Object.Stream),
Item,
Last,
Object.Inflator,
Object.In_First,
Object.In_Last,
Object.In_Buffer);
end Read;
overriding procedure Write (
Object : in out In_Type;
Item : in Ada.Streams.Stream_Element_Array)
is
pragma Check (Dynamic_Predicate, Check => Boolean'(raise Mode_Error));
begin
raise Program_Error; -- exclusive use for reading
end Write;
-- compatibility
procedure Create (
Stream : in out Stream_Type'Class;
Mode : in Stream_Mode;
Back : access Ada.Streams.Root_Stream_Type'Class;
Back_Compressed : in Boolean;
Level : in Compression_Level := Default_Compression;
Strategy : in Strategy_Type := Default_Strategy;
Header : in Header_Type := Default)
is
pragma Check (Dynamic_Predicate,
Check => not Is_Open (Stream) or else raise Status_Error);
package Conv is
new System.Address_To_Access_Conversions (Ada.Streams.Root_Stream_Type'Class);
begin
Stream.Direction := Mode;
Stream.Target := Conv.To_Address (Conv.Object_Pointer (Back));
Stream.In_First := 0;
Stream.In_Last := -1;
if (Mode = Out_Stream) = Back_Compressed then
Deflate_Init (
Stream.Raw,
Level => Level,
Header => Header,
Strategy => Strategy);
else
Inflate_Init (Stream.Raw, Header => Header);
end if;
end Create;
procedure Close (Object : in out Stream_Type'Class) is
pragma Check (Dynamic_Predicate,
Check => Is_Open (Object) or else raise Status_Error);
begin
Close (Object.Raw);
end Close;
function Is_Open (Object : Stream_Type'Class) return Boolean is
begin
return Is_Open (Object.Raw);
end Is_Open;
procedure Flush (Stream : in out Stream_Type'Class; Mode : in Flush_Mode) is
pragma Check (Dynamic_Predicate,
Check => Is_Open (Stream) or else raise Status_Error);
package Conv is
new System.Address_To_Access_Conversions (Ada.Streams.Root_Stream_Type'Class);
begin
if Mode then
declare
procedure DI_Finish is new Generic_Finish (Deflate_Or_Inflate);
begin
DI_Finish (Conv.To_Pointer (Stream.Target), Stream.Raw);
end;
end if;
end Flush;
function Read_Total_In (Stream : Stream_Type'Class) return Count is
begin
return Total_In (Stream.Raw);
end Read_Total_In;
function Read_Total_Out (Stream : Stream_Type'Class) return Count is
begin
return Total_Out (Stream.Raw);
end Read_Total_Out;
function Write_Total_In (Stream : Stream_Type'Class) return Count
renames Read_Total_Out;
function Write_Total_Out (Stream : Stream_Type'Class) return Count
renames Read_Total_Out;
overriding procedure Read (
Object : in out Stream_Type;
Item : out Ada.Streams.Stream_Element_Array;
Last : out Ada.Streams.Stream_Element_Offset)
is
pragma Check (Dynamic_Predicate,
Check => Is_Open (Object) or else raise Status_Error);
pragma Check (Dynamic_Predicate,
Check => Object.Direction = In_Stream or else raise Mode_Error);
package Conv is
new System.Address_To_Access_Conversions (Ada.Streams.Root_Stream_Type'Class);
procedure DI_Read is new Generic_Read (Deflate_Or_Inflate);
begin
DI_Read (
Conv.To_Pointer (Object.Target),
Item,
Last,
Object.Raw,
Object.In_First,
Object.In_Last,
Object.In_Buffer);
end Read;
overriding procedure Write (
Object : in out Stream_Type;
Item : in Ada.Streams.Stream_Element_Array)
is
pragma Check (Dynamic_Predicate,
Check => Is_Open (Object) or else raise Status_Error);
pragma Check (Dynamic_Predicate,
Check => Object.Direction = Out_Stream or else raise Mode_Error);
package Conv is
new System.Address_To_Access_Conversions (Ada.Streams.Root_Stream_Type'Class);
procedure DI_Write is new Generic_Write (Deflate_Or_Inflate);
begin
DI_Write (Conv.To_Pointer (Object.Target), Item, Object.Raw);
end Write;
end zlib.Streams;
| 30.257683 | 81 | 0.731385 |
4d66ecc50c31db2793017e212b077a48082f1dc4 | 7,893 | ads | Ada | SVD2ada/svd/stm32_svd-dbgmcu.ads | JCGobbi/Nucleo-STM32G474RE | 8dc1c4948ffeb11841eed10f1c3708f00fa1d832 | [
"BSD-3-Clause"
] | null | null | null | SVD2ada/svd/stm32_svd-dbgmcu.ads | JCGobbi/Nucleo-STM32G474RE | 8dc1c4948ffeb11841eed10f1c3708f00fa1d832 | [
"BSD-3-Clause"
] | null | null | null | SVD2ada/svd/stm32_svd-dbgmcu.ads | JCGobbi/Nucleo-STM32G474RE | 8dc1c4948ffeb11841eed10f1c3708f00fa1d832 | [
"BSD-3-Clause"
] | null | null | null | pragma Style_Checks (Off);
-- This spec has been automatically generated from STM32G474xx.svd
pragma Restrictions (No_Elaboration_Code);
with HAL;
with System;
package STM32_SVD.DBGMCU is
pragma Preelaborate;
---------------
-- Registers --
---------------
subtype IDCODE_DEV_ID_Field is HAL.UInt16;
subtype IDCODE_REV_ID_Field is HAL.UInt16;
-- MCU Device ID Code Register
type IDCODE_Register is record
-- Read-only. Device Identifier
DEV_ID : IDCODE_DEV_ID_Field;
-- Read-only. Revision Identifier
REV_ID : IDCODE_REV_ID_Field;
end record
with Volatile_Full_Access, Object_Size => 32,
Bit_Order => System.Low_Order_First;
for IDCODE_Register use record
DEV_ID at 0 range 0 .. 15;
REV_ID at 0 range 16 .. 31;
end record;
subtype CR_TRACE_MODE_Field is HAL.UInt2;
-- Debug MCU Configuration Register
type CR_Register is record
-- Debug Sleep Mode
DBG_SLEEP : Boolean := False;
-- Debug Stop Mode
DBG_STOP : Boolean := False;
-- Debug Standby Mode
DBG_STANDBY : Boolean := False;
-- unspecified
Reserved_3_4 : HAL.UInt2 := 16#0#;
-- Trace pin assignment control
TRACE_IOEN : Boolean := False;
-- Trace pin assignment control
TRACE_MODE : CR_TRACE_MODE_Field := 16#0#;
-- unspecified
Reserved_8_31 : HAL.UInt24 := 16#0#;
end record
with Volatile_Full_Access, Object_Size => 32,
Bit_Order => System.Low_Order_First;
for CR_Register use record
DBG_SLEEP at 0 range 0 .. 0;
DBG_STOP at 0 range 1 .. 1;
DBG_STANDBY at 0 range 2 .. 2;
Reserved_3_4 at 0 range 3 .. 4;
TRACE_IOEN at 0 range 5 .. 5;
TRACE_MODE at 0 range 6 .. 7;
Reserved_8_31 at 0 range 8 .. 31;
end record;
-- APB Low Freeze Register 1
type APB1L_FZ_Register is record
-- Debug Timer 2 stopped when Core is halted
DBG_TIMER2_STOP : Boolean := False;
-- TIM3 counter stopped when core is halted
DBG_TIM3_STOP : Boolean := False;
-- TIM4 counter stopped when core is halted
DBG_TIM4_STOP : Boolean := False;
-- TIM5 counter stopped when core is halted
DBG_TIM5_STOP : Boolean := False;
-- Debug Timer 6 stopped when Core is halted
DBG_TIMER6_STOP : Boolean := False;
-- TIM7 counter stopped when core is halted
DBG_TIM7_STOP : Boolean := False;
-- unspecified
Reserved_6_9 : HAL.UInt4 := 16#0#;
-- Debug RTC stopped when Core is halted
DBG_RTC_STOP : Boolean := False;
-- Debug Window Wachdog stopped when Core is halted
DBG_WWDG_STOP : Boolean := False;
-- Debug Independent Wachdog stopped when Core is halted
DBG_IWDG_STOP : Boolean := False;
-- unspecified
Reserved_13_20 : HAL.UInt8 := 16#0#;
-- I2C1 SMBUS timeout mode stopped when core is halted
DBG_I2C1_STOP : Boolean := False;
-- I2C2 SMBUS timeout mode stopped when core is halted
DBG_I2C2_STOP : Boolean := False;
-- unspecified
Reserved_23_29 : HAL.UInt7 := 16#0#;
-- I2C3 SMBUS timeout mode stopped when core is halted
DBG_I2C3_STOP : Boolean := False;
-- LPTIM1 counter stopped when core is halted
DBG_LPTIMER_STOP : Boolean := False;
end record
with Volatile_Full_Access, Object_Size => 32,
Bit_Order => System.Low_Order_First;
for APB1L_FZ_Register use record
DBG_TIMER2_STOP at 0 range 0 .. 0;
DBG_TIM3_STOP at 0 range 1 .. 1;
DBG_TIM4_STOP at 0 range 2 .. 2;
DBG_TIM5_STOP at 0 range 3 .. 3;
DBG_TIMER6_STOP at 0 range 4 .. 4;
DBG_TIM7_STOP at 0 range 5 .. 5;
Reserved_6_9 at 0 range 6 .. 9;
DBG_RTC_STOP at 0 range 10 .. 10;
DBG_WWDG_STOP at 0 range 11 .. 11;
DBG_IWDG_STOP at 0 range 12 .. 12;
Reserved_13_20 at 0 range 13 .. 20;
DBG_I2C1_STOP at 0 range 21 .. 21;
DBG_I2C2_STOP at 0 range 22 .. 22;
Reserved_23_29 at 0 range 23 .. 29;
DBG_I2C3_STOP at 0 range 30 .. 30;
DBG_LPTIMER_STOP at 0 range 31 .. 31;
end record;
-- APB Low Freeze Register 2
type APB1H_FZ_Register is record
-- unspecified
Reserved_0_0 : HAL.Bit := 16#0#;
-- DBG_I2C4_STOP
DBG_I2C4_STOP : Boolean := False;
-- unspecified
Reserved_2_31 : HAL.UInt30 := 16#0#;
end record
with Volatile_Full_Access, Object_Size => 32,
Bit_Order => System.Low_Order_First;
for APB1H_FZ_Register use record
Reserved_0_0 at 0 range 0 .. 0;
DBG_I2C4_STOP at 0 range 1 .. 1;
Reserved_2_31 at 0 range 2 .. 31;
end record;
-- APB High Freeze Register
type APB2_FZ_Register is record
-- unspecified
Reserved_0_10 : HAL.UInt11 := 16#0#;
-- TIM1 counter stopped when core is halted
DBG_TIM1_STOP : Boolean := False;
-- unspecified
Reserved_12_12 : HAL.Bit := 16#0#;
-- TIM8 counter stopped when core is halted
DBG_TIM8_STOP : Boolean := False;
-- unspecified
Reserved_14_15 : HAL.UInt2 := 16#0#;
-- TIM15 counter stopped when core is halted
DBG_TIM15_STOP : Boolean := False;
-- TIM16 counter stopped when core is halted
DBG_TIM16_STOP : Boolean := False;
-- TIM17 counter stopped when core is halted
DBG_TIM17_STOP : Boolean := False;
-- unspecified
Reserved_19_19 : HAL.Bit := 16#0#;
-- TIM20counter stopped when core is halted
DBG_TIM20_STOP : Boolean := False;
-- unspecified
Reserved_21_25 : HAL.UInt5 := 16#0#;
-- DBG_HRTIM0_STOP
DBG_HRTIM0_STOP : Boolean := False;
-- DBG_HRTIM0_STOP
DBG_HRTIM1_STOP : Boolean := False;
-- DBG_HRTIM0_STOP
DBG_HRTIM2_STOP : Boolean := False;
-- DBG_HRTIM0_STOP
DBG_HRTIM3_STOP : Boolean := False;
-- unspecified
Reserved_30_31 : HAL.UInt2 := 16#0#;
end record
with Volatile_Full_Access, Object_Size => 32,
Bit_Order => System.Low_Order_First;
for APB2_FZ_Register use record
Reserved_0_10 at 0 range 0 .. 10;
DBG_TIM1_STOP at 0 range 11 .. 11;
Reserved_12_12 at 0 range 12 .. 12;
DBG_TIM8_STOP at 0 range 13 .. 13;
Reserved_14_15 at 0 range 14 .. 15;
DBG_TIM15_STOP at 0 range 16 .. 16;
DBG_TIM16_STOP at 0 range 17 .. 17;
DBG_TIM17_STOP at 0 range 18 .. 18;
Reserved_19_19 at 0 range 19 .. 19;
DBG_TIM20_STOP at 0 range 20 .. 20;
Reserved_21_25 at 0 range 21 .. 25;
DBG_HRTIM0_STOP at 0 range 26 .. 26;
DBG_HRTIM1_STOP at 0 range 27 .. 27;
DBG_HRTIM2_STOP at 0 range 28 .. 28;
DBG_HRTIM3_STOP at 0 range 29 .. 29;
Reserved_30_31 at 0 range 30 .. 31;
end record;
-----------------
-- Peripherals --
-----------------
-- Debug support
type DBGMCU_Peripheral is record
-- MCU Device ID Code Register
IDCODE : aliased IDCODE_Register;
-- Debug MCU Configuration Register
CR : aliased CR_Register;
-- APB Low Freeze Register 1
APB1L_FZ : aliased APB1L_FZ_Register;
-- APB Low Freeze Register 2
APB1H_FZ : aliased APB1H_FZ_Register;
-- APB High Freeze Register
APB2_FZ : aliased APB2_FZ_Register;
end record
with Volatile;
for DBGMCU_Peripheral use record
IDCODE at 16#0# range 0 .. 31;
CR at 16#4# range 0 .. 31;
APB1L_FZ at 16#8# range 0 .. 31;
APB1H_FZ at 16#C# range 0 .. 31;
APB2_FZ at 16#10# range 0 .. 31;
end record;
-- Debug support
DBGMCU_Periph : aliased DBGMCU_Peripheral
with Import, Address => DBGMCU_Base;
end STM32_SVD.DBGMCU;
| 34.168831 | 67 | 0.617382 |
065bc839583c330ff2d4dcd02fe60ec45be74335 | 1,271 | ads | Ada | examples/shared/hello_world_blinky/src/control.ads | webgeeks/Ada_Drivers_Library | bcd4ca187f004ec2e5d7d7147870f1e713cf7db3 | [
"BSD-3-Clause"
] | null | null | null | examples/shared/hello_world_blinky/src/control.ads | webgeeks/Ada_Drivers_Library | bcd4ca187f004ec2e5d7d7147870f1e713cf7db3 | [
"BSD-3-Clause"
] | null | null | null | examples/shared/hello_world_blinky/src/control.ads | webgeeks/Ada_Drivers_Library | bcd4ca187f004ec2e5d7d7147870f1e713cf7db3 | [
"BSD-3-Clause"
] | null | null | null | with STM32.Board; use STM32.Board;
with HAL; use HAL;
with STM32.GPIO; use STM32.GPIO;
with STM32.Device; use STM32.Device;
with Ada.Real_Time; use Ada.Real_Time;
with STM32.Timers; use STM32.Timers;
with STM32.PWM; use STM32.PWM;
package control is
Selected_Timer : STM32.Timers.Timer renames Timer_4;
Timer_AF : constant STM32.GPIO_Alternate_Function := GPIO_AF_TIM4_2;
Servo_Channel : constant Timer_Channel := Channel_1;
Motor_Channel : constant Timer_Channel := Channel_2;
Seed_Channel : constant Timer_Channel := Channel_3;
Soil_Channel : constant Timer_Channel := Channel_4;
LED_For : constant array (Timer_Channel) of User_LED :=
(Channel_1 => Green_LED,
Channel_2 => Orange_LED,
Channel_3 => Red_LED,
Channel_4 => Blue_LED);
Requested_Frequency : constant Hertz := 50; -- arbitrary
Servo_Control : PWM_Modulator;
Motor_Control : PWM_Modulator;
Soil_Control : PWM_Modulator;
Seed_Control : PWM_Modulator;
procedure Intialize_Controls;
procedure right;
procedure left;
procedure forward;
procedure backward;
procedure front;
procedure stop;
procedure Drop_Seed;
procedure Measure;
end control;
| 25.42 | 71 | 0.693155 |
065b373f07c73201be079a1c8537ad4052ed81f6 | 377 | adb | Ada | gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/trampoline1.adb | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 7 | 2020-05-02T17:34:05.000Z | 2021-10-17T10:15:18.000Z | gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/trampoline1.adb | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | null | null | null | gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/trampoline1.adb | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 2 | 2020-07-27T00:22:36.000Z | 2021-04-01T09:41:02.000Z | -- { dg-do compile }
-- { dg-options "-gnatws" }
with System; use System;
procedure Trampoline1 is
A : Integer;
function F (I : Integer) return Integer is
begin
return A + I;
end F;
CA : System.Address := F'Code_Address;
begin
if CA = System.Null_Address then
raise Program_Error;
end if;
end;
-- { dg-final { scan-assembler-not "GNU-stack.*x" } }
| 15.708333 | 53 | 0.639257 |
126df544298b93ca51c9e3985bf3fa25d4dc867d | 1,624 | ads | Ada | src/natools-static_maps-s_expressions-templates.ads | faelys/natools | 947c004e6f69ca144942c6af40e102d089223cf8 | [
"0BSD"
] | null | null | null | src/natools-static_maps-s_expressions-templates.ads | faelys/natools | 947c004e6f69ca144942c6af40e102d089223cf8 | [
"0BSD"
] | null | null | null | src/natools-static_maps-s_expressions-templates.ads | faelys/natools | 947c004e6f69ca144942c6af40e102d089223cf8 | [
"0BSD"
] | null | null | null | ------------------------------------------------------------------------------
-- Copyright (c) 2014, Natacha Porté --
-- --
-- Permission to use, copy, modify, and distribute this software for any --
-- purpose with or without fee is hereby granted, provided that the above --
-- copyright notice and this permission notice appear in all copies. --
-- --
-- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES --
-- WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF --
-- MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR --
-- ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES --
-- WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN --
-- ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF --
-- OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. --
------------------------------------------------------------------------------
------------------------------------------------------------------------------
-- Natools.Static_Maps.S_Expressions.Templates is a common parent to --
-- generated static hash maps related to S-expression template system. --
------------------------------------------------------------------------------
package Natools.Static_Maps.S_Expressions.Templates is
pragma Pure;
end Natools.Static_Maps.S_Expressions.Templates;
| 62.461538 | 78 | 0.497537 |
a1c53c2e3e58f570d1745bd6827c9dc1dba5ffdb | 572 | ads | Ada | tests/bases-ship-test_data.ads | thindil/steamsky | d5d7fea622f7994c91017c4cd7ba5e188153556c | [
"TCL",
"MIT"
] | 80 | 2017-04-08T23:14:07.000Z | 2022-02-10T22:30:51.000Z | tests/bases-ship-test_data.ads | thindil/steamsky | d5d7fea622f7994c91017c4cd7ba5e188153556c | [
"TCL",
"MIT"
] | 89 | 2017-06-24T08:18:26.000Z | 2021-11-12T04:37:36.000Z | tests/bases-ship-test_data.ads | thindil/steamsky | d5d7fea622f7994c91017c4cd7ba5e188153556c | [
"TCL",
"MIT"
] | 9 | 2018-04-14T16:37:25.000Z | 2020-03-21T14:33:49.000Z | -- This package is intended to set up and tear down the test environment.
-- Once created by GNATtest, this package will never be overwritten
-- automatically. Contents of this package can be modified in any way
-- except for sections surrounded by a 'read only' marker.
with AUnit.Test_Fixtures;
package Bases.Ship.Test_Data is
-- begin read only
type Test is new AUnit.Test_Fixtures.Test_Fixture
-- end read only
with null record;
procedure Set_Up(Gnattest_T: in out Test);
procedure Tear_Down(Gnattest_T: in out Test);
end Bases.Ship.Test_Data;
| 30.105263 | 75 | 0.755245 |
3911b57b00c0fbb48b107ebab6303c04607f9d56 | 3,288 | adb | Ada | tests/src/tests.adb | Fabien-Chouteau/littlefs-ada | ecc2fb25b7c1b711dfc83d510f1b727f11cc98fe | [
"BSD-3-Clause"
] | 1 | 2020-12-26T10:19:58.000Z | 2020-12-26T10:19:58.000Z | tests/src/tests.adb | Fabien-Chouteau/littlefs-ada | ecc2fb25b7c1b711dfc83d510f1b727f11cc98fe | [
"BSD-3-Clause"
] | null | null | null | tests/src/tests.adb | Fabien-Chouteau/littlefs-ada | ecc2fb25b7c1b711dfc83d510f1b727f11cc98fe | [
"BSD-3-Clause"
] | null | null | null | pragma Assertion_Policy (Check);
with Ada.Text_IO; use Ada.Text_IO;
with Littlefs; use Littlefs;
with RAM_BD;
with Interfaces; use Interfaces;
with Interfaces.C; use Interfaces.C;
with System.Storage_Elements; use System.Storage_Elements;
procedure Tests is
FS : aliased LFS_T;
Block : constant access constant LFS_Config := RAM_BD.Create (2048 * 200);
procedure Create_File (Path : String);
procedure Read_File (Path : String);
procedure Tree (Path : String);
-----------------
-- Create_File --
-----------------
procedure Create_File (Path : String) is
FD : aliased LFS_File;
Data : Storage_Array (1 .. 42);
begin
pragma Assert (Open (FS, FD, Path, LFS_O_CREAT + LFS_O_RDWR) = 0);
Data := (others => 42);
pragma Assert (Write (FS, FD, Data (Data'First)'Address,
Data'Length) = Data'Length);
pragma Assert (Close (FS, FD) = 0);
end Create_File;
---------------
-- Read_File --
---------------
procedure Read_File (Path : String) is
FD : aliased LFS_File;
Data : Storage_Array (1 .. 42);
begin
pragma Assert (Open (FS, FD, Path, LFS_O_RDONLY) = 0);
pragma Assert (Read (FS, FD, Data (Data'First)'Address,
Data'Length + 20) = Data'Length);
for Elt of Data loop
pragma Assert (Elt = 42);
end loop;
pragma Assert (Close (FS, FD) = 0);
end Read_File;
----------
-- Tree --
----------
procedure Tree (Path : String) is
Dir : aliased LFS_Dir;
Err : int;
Info : aliased Entry_Info;
begin
Err := Open (FS, Dir, Path);
if Err = 0 then
while Read (FS, Dir, Info) > 0 loop
declare
Name : constant String := Littlefs.Name (Info);
Sub : constant String := (if Path = "/"
then "/" & Name
else Path & "/" & Name);
begin
if Name /= "." and then Name /= ".." then
Put_Line (Sub);
if Kind (Info) = Directory then
Tree (Sub);
end if;
end if;
end;
end loop;
Err := Close (FS, Dir);
end if;
end Tree;
begin
pragma Assert (Format (FS, Block.all) = 0);
pragma Assert (Mount (FS, Block.all) = 0);
pragma Assert (Mkdir (FS, "/dir1") = 0);
pragma Assert (Mkdir (FS, "/dir2") = 0);
pragma Assert (Mkdir (FS, "/dir1/sub1") = 0);
pragma Assert (Mkdir (FS, "/dir1/sub2") = 0);
pragma Assert (Mkdir (FS, "/dir1/sub2/subsub1") = 0);
Create_File ("/test1.txt");
Create_File ("/test2.txt");
Create_File ("/test3.txt");
Create_File ("/dir1/test1.txt");
Create_File ("/dir1/sub2/subsub1/test1.txt");
Read_File ("/test1.txt");
Read_File ("/test2.txt");
Read_File ("/test3.txt");
Read_File ("/dir1/test1.txt");
Read_File ("/dir1/sub2/subsub1/test1.txt");
declare
FD : aliased LFS_File;
begin
pragma Assert
(Open (FS, FD, "/doesnt_exists", LFS_O_RDONLY) = LFS_ERR_NOENT);
pragma Assert
(Open (FS, FD, "/dir1/doesnt_exists", LFS_O_RDONLY) = LFS_ERR_NOENT);
end;
Tree ("/");
end Tests;
| 27.173554 | 77 | 0.535584 |
2f6cd879d266b16aabaf1fe5bd8564be9f896544 | 3,390 | ads | Ada | boards/stm32l476_sensortile/src/stm32-board.ads | morbos/Ada_Drivers_Library | a4ab26799be60997c38735f4056160c4af597ef7 | [
"BSD-3-Clause"
] | 2 | 2018-05-16T03:56:39.000Z | 2019-07-31T13:53:56.000Z | boards/stm32l496_nucleo/src/stm32-board.ads | morbos/Ada_Drivers_Library | a4ab26799be60997c38735f4056160c4af597ef7 | [
"BSD-3-Clause"
] | null | null | null | boards/stm32l496_nucleo/src/stm32-board.ads | morbos/Ada_Drivers_Library | a4ab26799be60997c38735f4056160c4af597ef7 | [
"BSD-3-Clause"
] | null | null | null | ------------------------------------------------------------------------------
-- --
-- Copyright (C) 2015-2016, AdaCore --
-- --
-- Redistribution and use in source and binary forms, with or without --
-- modification, are permitted provided that the following conditions are --
-- met: --
-- 1. Redistributions of source code must retain the above copyright --
-- notice, this list of conditions and the following disclaimer. --
-- 2. Redistributions in binary form must reproduce the above copyright --
-- notice, this list of conditions and the following disclaimer in --
-- the documentation and/or other materials provided with the --
-- distribution. --
-- 3. Neither the name of STMicroelectronics nor the names of its --
-- contributors may be used to endorse or promote products derived --
-- from this software without specific prior written permission. --
-- --
-- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS --
-- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT --
-- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR --
-- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT --
-- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, --
-- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT --
-- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, --
-- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY --
-- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT --
-- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE --
-- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. --
-- --
-- --
-- This file is based on: --
-- --
-- @file stm32f4_discovery.h --
-- @author MCD Application Team --
-- @version V1.1.0 --
-- @date 19-June-2014 --
-- @brief This file contains definitions for STM32F4-Discovery Kit --
-- LEDs, push-buttons hardware resources. --
-- --
-- COPYRIGHT(c) 2014 STMicroelectronics --
------------------------------------------------------------------------------
-- This file provides declarations for devices on the STM32L4 kits
-- manufactured by ST Microelectronics.
package STM32.Board is
end STM32.Board;
| 70.625 | 78 | 0.448083 |
0beb0ac1b4d5168665e2b222c465e0d9e3118759 | 4,156 | adb | Ada | src/sdl-video-textures-makers.adb | Fabien-Chouteau/sdlada | f08d72e3f5dcec228d68fb5b6681ea831f81ef47 | [
"Zlib"
] | 1 | 2021-10-30T14:41:56.000Z | 2021-10-30T14:41:56.000Z | src/sdl-video-textures-makers.adb | Fabien-Chouteau/sdlada | f08d72e3f5dcec228d68fb5b6681ea831f81ef47 | [
"Zlib"
] | null | null | null | src/sdl-video-textures-makers.adb | Fabien-Chouteau/sdlada | f08d72e3f5dcec228d68fb5b6681ea831f81ef47 | [
"Zlib"
] | null | null | null | --------------------------------------------------------------------------------------------------------------------
-- Copyright (c) 2013-2020, Luke A. Guest
--
-- This software is provided 'as-is', without any express or implied
-- warranty. In no event will the authors be held liable for any damages
-- arising from the use of this software.
--
-- Permission is granted to anyone to use this software for any purpose,
-- including commercial applications, and to alter it and redistribute it
-- freely, subject to the following restrictions:
--
-- 1. The origin of this software must not be misrepresented; you must not
-- claim that you wrote the original software. If you use this software
-- in a product, an acknowledgment in the product documentation would be
-- appreciated but is not required.
--
-- 2. Altered source versions must be plainly marked as such, and must not be
-- misrepresented as being the original software.
--
-- 3. This notice may not be removed or altered from any source
-- distribution.
--------------------------------------------------------------------------------------------------------------------
with Ada.Unchecked_Conversion;
with Interfaces.C;
private with SDL.C_Pointers;
with SDL.Error;
package body SDL.Video.Textures.Makers is
package C renames Interfaces.C;
use type C.int;
use type SDL.C_Pointers.Texture_Pointer;
function Get_Internal_Surface (Self : in SDL.Video.Surfaces.Surface)
return SDL.Video.Surfaces.Internal_Surface_Pointer with
Import => True,
Convention => Ada;
function Get_Internal_Renderer (Self : in SDL.Video.Renderers.Renderer) return SDL.C_Pointers.Renderer_Pointer with
Import => True,
Convention => Ada;
procedure Create
(Tex : in out Texture;
Renderer : in SDL.Video.Renderers.Renderer;
Format : in SDL.Video.Pixel_Formats.Pixel_Format_Names;
Kind : in Kinds;
Size : in SDL.Positive_Sizes) is
-- Convert the Pixel_Format_Name to an Unsigned_32 because the compiler is changing the value somewhere along
-- the lines from the start of this procedure to calling SDL_Create_Texture.
function To_Unsigned32 is new Ada.Unchecked_Conversion (Source => SDL.Video.Pixel_Formats.Pixel_Format_Names,
Target => Interfaces.Unsigned_32);
function SDL_Create_Texture
(R : in SDL.C_Pointers.Renderer_Pointer;
Format : in Interfaces.Unsigned_32;
Kind : in Kinds;
W, H : in C.int) return SDL.C_Pointers.Texture_Pointer with
Import => True,
Convention => C,
External_Name => "SDL_CreateTexture";
begin
Tex.Internal := SDL_Create_Texture (Get_Internal_Renderer (Renderer),
To_Unsigned32 (Format),
Kind,
Size.Width,
Size.Height);
if Tex.Internal = null then
raise Texture_Error with SDL.Error.Get;
end if;
Tex.Size := Size;
Tex.Pixel_Format := Format;
end Create;
procedure Create
(Tex : in out Texture;
Renderer : in SDL.Video.Renderers.Renderer;
Surface : in SDL.Video.Surfaces.Surface) is
function SDL_Create_Texture_From_Surface (R : in SDL.C_Pointers.Renderer_Pointer;
S : in SDL.Video.Surfaces.Internal_Surface_Pointer)
return SDL.C_Pointers.Texture_Pointer with
Import => True,
Convention => C,
External_Name => "SDL_CreateTextureFromSurface";
begin
Tex.Internal := SDL_Create_Texture_From_Surface (Get_Internal_Renderer (Renderer),
Get_Internal_Surface (Surface));
if Tex.Internal = null then
raise Texture_Error with SDL.Error.Get;
end if;
end Create;
end SDL.Video.Textures.Makers;
| 41.979798 | 118 | 0.589269 |
314b4f2e522a76d1dd815e6e82c1fc338dd589b4 | 1,273 | ads | Ada | src/cupcake-primitives.ads | skordal/cupcake | 42d8549c64966fc4077db89c2e62fa2f5733512c | [
"MIT"
] | 2 | 2017-10-07T05:41:44.000Z | 2018-06-12T14:05:12.000Z | src/cupcake-primitives.ads | skordal/cupcake | 42d8549c64966fc4077db89c2e62fa2f5733512c | [
"MIT"
] | null | null | null | src/cupcake-primitives.ads | skordal/cupcake | 42d8549c64966fc4077db89c2e62fa2f5733512c | [
"MIT"
] | null | null | null | -- The Cupcake GUI Toolkit
-- (c) Kristian Klomsten Skordal 2012 <[email protected]>
-- Report bugs and issues on <http://github.com/skordal/cupcake/issues>
-- vim:ts=3:sw=3:et:si:sta
package Cupcake.Primitives is
-- Simple point type:
type Point is record
X, Y : Integer;
end record;
-- Point operators:
function "+" (Left, Right : in Point) return Point
with Inline, Pure_Function;
function "-" (Left, Right : in Point) return Point
with Inline, Pure_Function;
function "=" (Left, Right : in Point) return Boolean
with Inline, Pure_Function;
-- Type for specifying dimensions:
type Dimension is record
Width, Height : Natural;
end record;
-- Dimension operators:
function "<" (Left, Right : in Dimension) return Boolean
with Inline, Pure_Function;
function ">" (Left, Right : in Dimension) return Boolean
with Inline, Pure_Function;
function "=" (Left, Right : in Dimension) return Boolean
with Inline, Pure_Function;
-- Rectangle type:
type Rectangle is record
Origin : Point;
Size : Dimension;
end record;
-- Line type:
type Line is record
Start : Point;
Endpoint : Point;
end record;
end Cupcake.Primitives;
| 26.520833 | 72 | 0.655931 |
063a0ee3ebf733d47503932b44bdff25a0431ca4 | 1,296 | ads | Ada | vole_tokens.ads | davidkristola/vole | aa8e19d9deff2efe98fcd4dc0028c2895d624693 | [
"Unlicense"
] | 4 | 2015-02-02T12:11:41.000Z | 2020-12-19T02:14:21.000Z | vole_tokens.ads | davidkristola/vole | aa8e19d9deff2efe98fcd4dc0028c2895d624693 | [
"Unlicense"
] | null | null | null | vole_tokens.ads | davidkristola/vole | aa8e19d9deff2efe98fcd4dc0028c2895d624693 | [
"Unlicense"
] | 3 | 2017-02-22T10:44:02.000Z | 2021-05-16T09:34:39.000Z | with Kv.avm.vole_Tree;
package Vole_Tokens is
type YYSType is
record
Node : kv.avm.vole_tree.Node_Pointer;
end record;
YYLVal, YYVal : YYSType;
type Token is
(End_Of_Input, Error, Key_Import, Id_Token,
Eos_Token, Block_Begin, Block_End,
Key_Attribute, Key_Predicate, Key_Message,
Key_Returns, Key_Actor, Key_Constructor,
Key_Extends, Key_Assert, Key_Method,
Key_Emit, Key_If, Key_Then,
Key_Self, Key_Super, Key_Send,
Key_Else, Key_Elseif, Key_Endif,
Key_When, Key_While, Key_Loop,
Key_For, Key_Case, Key_Local,
Key_New, Op_And, Op_Not,
Op_Or, Op_Xor, Op_Mod,
Op_Eq, Op_Not_Eq, Op_Gt,
Op_Gt_Eq, Op_Lt_Eq, Op_Lt,
Key_Return, Key_Tuple, Float_Literal,
Integer_Literal, String_Literal, True_Literal,
False_Literal, Actor_Type, Boolean_Type,
Tuple_Type, Unsigned_Type, Integer_Type,
Float_Type, String_Type, Colon_Token,
Dot_Token, Paren_Begin, Paren_End,
Comma_Token, Tuple_Begin, Tuple_End,
Op_Shift_Left, Op_Shift_Right, Op_Add,
Op_Sub, Op_Mul, Op_Div,
High_Right_Precedence, Op_Exp, Op_Assign );
Syntax_Error : exception;
end Vole_Tokens;
| 32.4 | 55 | 0.654321 |
Subsets and Splits
No saved queries yet
Save your SQL queries to embed, download, and access them later. Queries will appear here once saved.