text
stringlengths
0
234
:= Job_Impl (Object.Get_Load_Object.all)'Access;
begin
return Impl.Priority;
end Get_Priority;
procedure Set_User (Object : in out Job_Ref;
Value : in AWA.Users.Models.User_Ref'Class) is
Impl : Job_Access;
begin
Set_Field (Object, Impl);
ADO.Objects.Set_Field_Object (Impl.all, 12, Impl.User, Value);
end Set_User;
function Get_User (Object : in Job_Ref)
return AWA.Users.Models.User_Ref'Class is
Impl : constant Job_Access
:= Job_Impl (Object.Get_Load_Object.all)'Access;
begin
return Impl.User;
end Get_User;
procedure Set_Event (Object : in out Job_Ref;
Value : in AWA.Events.Models.Message_Ref'Class) is
Impl : Job_Access;
begin
Set_Field (Object, Impl);
ADO.Objects.Set_Field_Object (Impl.all, 13, Impl.Event, Value);
end Set_Event;
function Get_Event (Object : in Job_Ref)
return AWA.Events.Models.Message_Ref'Class is
Impl : constant Job_Access
:= Job_Impl (Object.Get_Load_Object.all)'Access;
begin
return Impl.Event;
end Get_Event;
procedure Set_Session (Object : in out Job_Ref;
Value : in AWA.Users.Models.Session_Ref'Class) is
Impl : Job_Access;
begin
Set_Field (Object, Impl);
ADO.Objects.Set_Field_Object (Impl.all, 14, Impl.Session, Value);
end Set_Session;
function Get_Session (Object : in Job_Ref)
return AWA.Users.Models.Session_Ref'Class is
Impl : constant Job_Access
:= Job_Impl (Object.Get_Load_Object.all)'Access;
begin
return Impl.Session;
end Get_Session;
-- Copy of the object.
procedure Copy (Object : in Job_Ref;
Into : in out Job_Ref) is
Result : Job_Ref;
begin
if not Object.Is_Null then
declare
Impl : constant Job_Access
:= Job_Impl (Object.Get_Load_Object.all)'Access;
Copy : constant Job_Access
:= new Job_Impl;
begin
ADO.Objects.Set_Object (Result, Copy.all'Access);
Copy.Copy (Impl.all);
Copy.Status := Impl.Status;
Copy.Name := Impl.Name;
Copy.Start_Date := Impl.Start_Date;
Copy.Create_Date := Impl.Create_Date;
Copy.Finish_Date := Impl.Finish_Date;
Copy.Progress := Impl.Progress;
Copy.Parameters := Impl.Parameters;
Copy.Results := Impl.Results;
Copy.Version := Impl.Version;
Copy.Priority := Impl.Priority;
Copy.User := Impl.User;
Copy.Event := Impl.Event;
Copy.Session := Impl.Session;
Function Definition: procedure Unchecked_Free is new Ada.Unchecked_Deallocation
Function Body: (Job_Impl, Job_Impl_Ptr);
pragma Warnings (Off, "*redundant conversion*");
Ptr : Job_Impl_Ptr := Job_Impl (Object.all)'Access;
pragma Warnings (On, "*redundant conversion*");
begin
Unchecked_Free (Ptr);
end Destroy;
procedure Find (Object : in out Job_Impl;
Session : in out ADO.Sessions.Session'Class;
Query : in ADO.SQL.Query'Class;
Found : out Boolean) is
Stmt : ADO.Statements.Query_Statement
:= Session.Create_Statement (Query, JOB_DEF'Access);
begin