Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 59 lines (48 sloc) 1.659 kb
7378c1b Final messing
amosteo authored
1 with Interfaces.C; use Interfaces;
2 with Player.Aux;
3
4 package body Player.Blobfinder is
5
6 ------------
7 -- Create --
8 ------------
9
10 procedure Create
11 (This : in out Object;
12 Conn : in Client.Connection_Type;
13 Index : in Natural := 0)
14 is
15 function C_Create (Conn : in Types.Handle; Index : in C.int)
16 return Types.Handle;
17 pragma Import (C, C_Create, "playerc_blobfinder_create");
18 begin
19 Interfaces.Create (Interfaces.Object (This), Conn, Index);
20 Set_Handle (This, C_Create (Client.Get_Handle (Conn), C.int (Index)));
21 end Create;
22
23 ---------------
24 -- Subscribe --
25 ---------------
26
27 procedure Subscribe (This : in out Object; Mode : in Access_Modes) is
28 function C_Subscribe (This : in Types.Handle; Mode : in Access_Modes)
29 return C.int;
30 pragma Import (C, C_Subscribe, "playerc_blobfinder_subscribe");
31 begin
32 Aux.Check (C_Subscribe (-This, Mode));
33 Interfaces.Subscribe (Interfaces.Object (This), Mode);
34 end Subscribe;
35
36 -----------------
37 -- Unsubscribe --
38 -----------------
39
40 procedure Unsubscribe (This : in out Object) is
41 function C_Unsubscribe (This : in Types.Handle) return C.Int;
42 pragma Import (C, C_Unsubscribe, "playerc_blobfinder_unsubscribe");
43 begin
44 Aux.Check (C_Unsubscribe (-This));
45 Interfaces.Unsubscribe (Interfaces.Object (This));
46 end Unsubscribe;
47
48 -------------
49 -- Destroy --
50 -------------
51
52 procedure Destroy (This : in out Object) is
53 begin
54 Destroy_Handle (-This);
55 Clear_Handle (This);
56 end Destroy;
57
58 end Player.Blobfinder;
Something went wrong with that request. Please try again.