|
|
DataMuseum.dkPresents historical artifacts from the history of: Rational R1000/400 |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about Rational R1000/400 Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - download
Length: 20480 (0x5000)
Types: Ada Source
Notes: 03_class, FILE, R1k_Segment, e3_tag, generic, package Xlbmp_Get, seg_004f08
└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000
└─⟦5a81ac88f⟧ »Space Info Vol 1«
└─⟦this⟧
with Xlbt_Arithmetic;
use Xlbt_Arithmetic;
with Xlbt_Basic;
use Xlbt_Basic;
with Xlbt_Request;
use Xlbt_Request;
with Xlbmt_Network_Types;
use Xlbmt_Network_Types;
package Xlbmp_Get is
------------------------------------------------------------------------------
-- X Library X Server Get Routines
--
-- Xlbmp_Get - Receive info from the X Server
------------------------------------------------------------------------------
-- Copyright 1989 - 1991 by Rational, Santa Clara, California.
--
-- All Rights Reserved.
--
-- Permission to use, copy, modify, and distribute this software and its
-- documentation for any purpose and without fee is hereby granted,
-- provided that the above copyright notice(s) appear in all copies and that
-- both that copyright notice(s) and this permission notice appear in
-- supporting documentation, and that the name of Rational not be used in
-- advertising or publicity pertaining to distribution of the software
-- without specific, written prior permission.
--
-- Rational disclaims all warranties with regard to this software, including
-- all implied warranties of merchantability and fitness, in no event shall
-- Rational be liable for any special, 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.
------------------------------------------------------------------------------
subtype Only_Zero is Integer range 0 .. 0;
subtype Only_Non_Zero is X_Raw_Data_Index range 8 .. 16;
--\x0c
generic
type Reply_Record is private;
with procedure Wire_To_Reply
(Code : X_Request_Code;
Raw : X_Raw_Data_Array;
Send_Event : Boolean;
Reply : out Reply_Record;
Length : out S_Natural);
procedure Get_Reply_Generic (Display : X_Display;
Code : X_Request_Code;
Reply : out Reply_Record;
Extra : S_Natural;
Discard : Boolean;
Status : out X_Status);
------------------------------------------------------------------------------
-- Display - the display to read from
-- Code - the code for the request indicates the format of the reply
-- Reply - where to put the reply; if one is received
-- Extra - many replies receive extra data; we require at least this
-- much extra to be present or we regard it as an I/O error
-- Discard - True to discard any extra extra data that may appear with the
-- reply
-- Status - Failed if we got an Error instead of a Reply
--
-- Read a reply to a request out of the network connection. You should only
-- request multiples of 4 bytes.
--
-- The Wire_To_Reply procedure has these arguments.
--
-- Code - Specifies the X_Request_Code of the reply
-- Raw - Specifies the raw 32-bytes of data representing the reply
-- Send_Event - Specifies True if this reply was not sent by the server
-- Reply - Receives the converted reply record
-- Length - Specifies the number of additions words (groups of 4 bytes)
-- that make up the rest of the reply; including all variable
-- length data.
------------------------------------------------------------------------------
generic
type Original is private;
with procedure From_Raw (D : out Original;
Raw : X_Raw_Data_Array);
Original_Size : in X_Raw_Data_Index := Original'Size / 8;
Multiple_Of_32 : Only_Zero := Original'Size rem 32;
procedure Get_Data_Private (Display : X_Display;
D : out Original);
------------------------------------------------------------------------------
-- For Discrete and ordinary Private types whose size is N*32.
--
-- If you get a Constraint_Error when elaborating this generic then you have
-- tried to instantiate it with a type whose 'Size is not N*32.
--
-- Read some data from the network connection. Typically only called when
-- you've previously called Get_Reply or some such and you now want to read
-- data that you know is there.
-- Original - this is the type of data that needs to be sent
-- Original_Size - all X protocol requests are 32 bytes long, this value
-- corresponds to the number of X_Raw_Data items
-- From_Raw - converts the data to X_Raw_Data
-- Display - display to receive the request
-- D - the data to send
------------------------------------------------------------------------------
generic
type Original is private;
type Index is range <>;
type Original_Array is array (Index range <>) of Original;
with procedure From_Raw (D : out Original_Array;
Raw : X_Raw_Data_Array);
Original_Size : in X_Raw_Data_Index := Original'Size / 8;
Multiple_Of_32 : in Only_Zero := Original'Size rem 32;
procedure Get_Large_Data_1d (Display : X_Display;
D : out Original_Array);
------------------------------------------------------------------------------
-- For one-dimensional array types where the element type is "large". A
-- "large" type is any type whose 'Size is a multiple of 32 bits.
--
-- If you get a Constraint_Error when elaborating this generic then you have
-- tried to instantiate it with a type whose 'Size is not N*32.
--
-- Read some data from the network connection. Typically only called when
-- you've previously called Get_Reply or some such and you now want to read
-- data that you know is there.
-- Original - this is the type of data that needs to be sent
-- Original_Size - all X protocol requests are 32 bytes long, this value
-- corresponds to the number of X_Raw_Data items
-- Index - this is the index type for the array type
-- Original_Array - this is the array type
-- From_Raw - converts the data to X_Raw_Data
-- Display - display to receive the request
-- D - the data to send
------------------------------------------------------------------------------
generic
type Original is private;
type Index is range <>;
type Original_Array is array (Index range <>) of Original;
with procedure From_Raw (D : out Original_Array;
Raw : X_Raw_Data_Array);
Original_Size : in X_Raw_Data_Index := Original'Size / 8;
Less_Than_32 : in Only_Non_Zero := Original'Size;
procedure Get_Small_Data_1d (Display : X_Display;
D : out Original_Array);
------------------------------------------------------------------------------
-- For one-dimensional array types where the element type is "small". A
-- "small" type is any type whose 'Size is less than 32 bits. This is
-- expected to be used for 8 and 16 bit data types. Other sizes of
-- data will not probably work properly.
--
-- If you get a Constraint_Error when elaborating this generic then you have
-- tried to instantiate it with a type whose 'Size is greater than 32.
--
-- Read some data from the network connection. Typically only called when
-- you've previously called Get_Reply or some such and you now want to read
-- data that you know is there.
-- Original - this is the type of data that needs to be sent
-- Original_Size - all X protocol requests are 32 bytes long, this value
-- corresponds to the number of X_Raw_Data items
-- Index - this is the index type for the array type
-- Original_Array - this is the array type
-- From_Raw - converts the data to X_Raw_Data
-- Display - display to receive the request
-- D - the data to send
------------------------------------------------------------------------------
generic
type Original is private;
type Index1 is range <>;
type Index2 is range <>;
type Original_Array is array (Index1 range <>,
Index2 range <>) of Original;
with procedure From_Raw (D : out Original;
Raw : X_Raw_Data_Array);
with procedure From_Raw (D : out Original_Array;
Raw : X_Raw_Data_Array);
Original_Size : in X_Raw_Data_Index := Original'Size / 8;
Multiple_Of_8 : Only_Zero := Original'Size rem 8;
procedure Get_Data_2d (Display : X_Display;
D : out Original_Array);
------------------------------------------------------------------------------
-- For two-dimensional array types where the element type is 8, 16, or N*32
-- bits in length.
--
-- If you get a Constraint_Error when elaborating this generic then you have
-- tried to instantiate it with a type whose 'Size is not N*8.
--
-- Read some data from the network connection. Typically only called when
-- you've previously called Get_Reply or some such and you now want to read
-- data that you know is there.
-- Original - this is the type of data that needs to be sent
-- Original_Size - all X protocol requests are 32 bytes long, this value
-- corresponds to the number of X_Raw_Data items
-- Index1 - this is the first index type for the array type
-- Index2 - this is the second index type for the array type
-- Original_Array - this is the array type
-- From_Raw - converts the data to X_Raw_Data
-- Display - display to receive the request
-- D - the data to send
------------------------------------------------------------------------------
procedure Eat_Data_Raw (Display : X_Display;
Amount : S_Natural);
------------------------------------------------------------------------------
-- Read and discard some data from the network connection. Typically only
-- called when we are trying to recover from some error, e.g. a Storage_Error
-- exception, and we need to get rid of junque in the protocol stream that
-- we requested but which we cannot allocate heap space to hold.
-- We read and discard Amount X_Raw_Data items.
------------------------------------------------------------------------------
end Xlbmp_Get;
nblk1=13
nid=0
hdr6=26
[0x00] rec0=1a rec1=00 rec2=01 rec3=068
[0x01] rec0=15 rec1=00 rec2=02 rec3=044
[0x02] rec0=00 rec1=00 rec2=0d rec3=008
[0x03] rec0=10 rec1=00 rec2=03 rec3=098
[0x04] rec0=16 rec1=00 rec2=04 rec3=018
[0x05] rec0=10 rec1=00 rec2=05 rec3=06a
[0x06] rec0=01 rec1=00 rec2=13 rec3=014
[0x07] rec0=12 rec1=00 rec2=06 rec3=048
[0x08] rec0=00 rec1=00 rec2=12 rec3=02e
[0x09] rec0=13 rec1=00 rec2=07 rec3=080
[0x0a] rec0=01 rec1=00 rec2=11 rec3=010
[0x0b] rec0=10 rec1=00 rec2=08 rec3=066
[0x0c] rec0=00 rec1=00 rec2=10 rec3=008
[0x0d] rec0=13 rec1=00 rec2=09 rec3=06c
[0x0e] rec0=01 rec1=00 rec2=0f rec3=014
[0x0f] rec0=11 rec1=00 rec2=0a rec3=05c
[0x10] rec0=00 rec1=00 rec2=0e rec3=014
[0x11] rec0=11 rec1=00 rec2=0b rec3=014
[0x12] rec0=04 rec1=00 rec2=0c rec3=000
tail 0x21500954c819780465ccf 0x42a00088462063203