ajresourceread.c
Datatypes: AjPResourcein none AjPTable AjPResourceall none
Data resource input objects
Sections: Data input constructors data input destructors data input modifiers casts Data data inputs
All constructors return a new data input object by pointer. It
is the responsibility of the user to first destroy any previous
data input object. The target pointer does not need to be
initialised to NULL, but it is good programming practice to do so
anyway.
Functions: ajResourceinNew ajResourceinNewDrcat
Creates a new data input object.
Synopsis
Prototype
AjPResourcein ajResourceinNew (
void
);
Type | Name | Read/Write | Description |
AjPResourcein | | RETURN | New data input object. |
Returns
AjPResourcein: | New data input object. |
Description
Creates a new data input object.
See Also
See other functions in this section
Availability
In release 6.4.0
Creates a new data input object with a resolved DRCAT query
Synopsis
Prototype
AjPResourcein ajResourceinNewDrcat (
const AjPStr dbname
);
Type | Name | Read/Write | Description |
const AjPStr | dbname | Input | DRCAT identifier |
AjPResourcein | | RETURN | New data input object. |
Input
dbname: | (Input) | DRCAT identifier |
Returns
AjPResourcein: | New data input object. |
Description
Creates a new data input object with a resolved DRCAT query
See Also
See other functions in this section
Availability
In release 6.4.0
Destruction destroys all internal data structures and frees the
memory allocated for the data input object.
Functions: ajResourceinDel
Deletes a data input object.
Synopsis
Prototype
void ajResourceinDel (
AjPResourcein* pthis
);
Type | Name | Read/Write | Description |
AjPResourcein* | pthis | Delete | Data resource input |
void | | RETURN | |
Output
pthis: | (Delete) | Data resource input |
Returns
Description
Deletes a data input object.
See Also
See other functions in this section
Availability
In release 6.4.0
These functions use the contents of a data input object and
update them.
Functions: ajResourceinClear ajResourceinQryC ajResourceinQryS
Clears a data input object back to "as new" condition, except
for the query list which must be preserved.
Synopsis
Prototype
void ajResourceinClear (
AjPResourcein thys
);
Type | Name | Read/Write | Description |
AjPResourcein | thys | Output | Data resource input |
void | | RETURN | |
Output
thys: | (Output) | Data resource input |
Returns
Description
Clears a data input object back to "as new" condition, except
for the query list which must be preserved.
See Also
See other functions in this section
Availability
In release 6.4.0
Resets a data input object using a new Universal
Query Address
Synopsis
Prototype
void ajResourceinQryC (
AjPResourcein thys,
const char* txt
);
Type | Name | Read/Write | Description |
AjPResourcein | thys | Modify | Data resource input object. |
const char* | txt | Input | Query |
void | | RETURN | |
Input
Input & Output
thys: | (Modify) | Data resource input object. |
Returns
Description
Resets a data input object using a new Universal
Query Address
See Also
See other functions in this section
Availability
In release 6.4.0
Resets a data input object using a new Universal
Query Address
Synopsis
Prototype
void ajResourceinQryS (
AjPResourcein thys,
const AjPStr str
);
Type | Name | Read/Write | Description |
AjPResourcein | thys | Modify | Data resource input object. |
const AjPStr | str | Input | Query |
void | | RETURN | |
Input
Input & Output
thys: | (Modify) | Data resource input object. |
Returns
Description
Resets a data input object using a new Universal
Query Address
See Also
See other functions in this section
Availability
In release 6.4.0
Return values
Functions: ajResourceinTrace
Debug calls to trace the data in a data input object.
Synopsis
Prototype
void ajResourceinTrace (
const AjPResourcein thys
);
Type | Name | Read/Write | Description |
const AjPResourcein | thys | Input | Data resource input object. |
void | | RETURN | |
Input
thys: | (Input) | Data resource input object. |
Returns
Description
Debug calls to trace the data in a data input object.
See Also
See other functions in this section
Availability
In release 6.4.0
These functions read the wxyxdesc data provided by the first argument
Functions: ajResourceinRead
If the file is not yet open, calls resourceinQryProcess to convert the query
into an open file stream.
Uses resourceinRead for the actual file reading.
Returns the results in the AjPResource object.
Synopsis
Prototype
AjBool ajResourceinRead (
AjPResourcein resourcein,
AjPResource resource
);
Type | Name | Read/Write | Description |
AjPResourcein | resourcein | Modify | Data resource data input definitions |
AjPResource | resource | Output | Data resource data returned. |
AjBool | | RETURN | ajTrue on success. |
Output
resource: | (Output) | Data resource data returned. |
Input & Output
resourcein: | (Modify) | Data resource data input definitions |
Returns
AjBool: | ajTrue on success. |
Description
If the file is not yet open, calls resourceinQryProcess to convert the query
into an open file stream.
Uses resourceinRead for the actual file reading.
Returns the results in the AjPResource object.
See Also
See other functions in this section
Availability
In release 6.4.0
Miscellaneous
Sections: Print Miscellaneous Internals
Printing to a file
Functions: ajResourceinprintBook ajResourceinprintHtml ajResourceinprintText ajResourceinprintWiki
Reports the internal data structures as a Docbook table
Synopsis
Prototype
void ajResourceinprintBook (
AjPFile outf
);
Type | Name | Read/Write | Description |
AjPFile | outf | Modify | Output file |
void | | RETURN | |
Input & Output
Returns
Description
Reports the internal data structures as a Docbook table
See Also
See other functions in this section
Availability
In release 6.4.0
Reports the internal data structures as an HTML table
Synopsis
Prototype
void ajResourceinprintHtml (
AjPFile outf
);
Type | Name | Read/Write | Description |
AjPFile | outf | Modify | Output file |
void | | RETURN | |
Input & Output
Returns
Description
Reports the internal data structures as an HTML table
See Also
See other functions in this section
Availability
In release 6.4.0
Reports the internal data structures
Synopsis
Prototype
void ajResourceinprintText (
AjPFile outf,
AjBool full
);
Type | Name | Read/Write | Description |
AjPFile | outf | Modify | Output file |
AjBool | full | Input | Full report (usually ajFalse) |
void | | RETURN | |
Input
full: | (Input) | Full report (usually ajFalse) |
Input & Output
Returns
Description
Reports the internal data structures
See Also
See other functions in this section
Availability
In release 6.4.0
Reports the internal data structures as a wiki table
Synopsis
Prototype
void ajResourceinprintWiki (
AjPFile outf
);
Type | Name | Read/Write | Description |
AjPFile | outf | Modify | Output file |
void | | RETURN | |
Input & Output
Returns
Description
Reports the internal data structures as a wiki table
See Also
See other functions in this section
Availability
In release 6.4.0
Functions to initialise and clean up internals
Functions: ajResourceinExit
Cleans up data input internal memory
Synopsis
Prototype
void ajResourceinExit (
void
);
Type | Name | Read/Write | Description |
void | | RETURN | |
Returns
Description
Cleans up data input internal memory
See Also
See other functions in this section
Availability
In release 6.4.0
Functions to return internal values
Functions: ajResourceinTypeGetFields ajResourceinTypeGetQlinks
Returns the listof known field names for ajResourceinRead
Synopsis
Prototype
const char* ajResourceinTypeGetFields (
void
);
Type | Name | Read/Write | Description |
const char* | | RETURN | List of field names |
Returns
const char*: | List of field names |
Description
Returns the listof known field names for ajResourceinRead
See Also
See other functions in this section
Availability
In release 6.4.0
Returns the listof known query link operators for ajResourceinRead
Synopsis
Prototype
const char* ajResourceinTypeGetQlinks (
void
);
Type | Name | Read/Write | Description |
const char* | | RETURN | List of field names |
Returns
const char*: | List of field names |
Description
Returns the listof known query link operators for ajResourceinRead
See Also
See other functions in this section
Availability
In release 6.4.0
Internal call register table
Sections: Cast
Return a reference to the call table
Functions: ajResourceaccessGetDb ajResourceaccessMethodGetQlinks ajResourceaccessMethodGetScope ajResourceaccessMethodTest
Returns the table in which data database access details are registered
Synopsis
Prototype
AjPTable ajResourceaccessGetDb (
void
);
Type | Name | Read/Write | Description |
AjPTable | | RETURN | Access functions hash table |
Returns
AjPTable: | Access functions hash table |
Description
Returns the table in which data database access details are registered
See Also
See other functions in this section
Availability
In release 6.4.0
Tests for a named method for data data reading and returns the
known query link operators
Synopsis
Prototype
const char* ajResourceaccessMethodGetQlinks (
const AjPStr method
);
Type | Name | Read/Write | Description |
const AjPStr | method | Input | Method required. |
const char* | | RETURN | Known link operators |
Input
method: | (Input) | Method required. |
Returns
const char*: | Known link operators |
Description
Tests for a named method for data data reading and returns the
known query link operators
See Also
See other functions in this section
Availability
In release 6.4.0
Tests for a named method for data data reading and returns the scope
(entry, query or all).
Synopsis
Prototype
ajuint ajResourceaccessMethodGetScope (
const AjPStr method
);
Type | Name | Read/Write | Description |
const AjPStr | method | Input | Method required. |
ajuint | | RETURN | Scope flags |
Input
method: | (Input) | Method required. |
Returns
Description
Tests for a named method for data data reading and returns the scope
(entry, query or all).
See Also
See other functions in this section
Availability
In release 6.4.0
Tests for a named method for data data reading.
Synopsis
Prototype
AjBool ajResourceaccessMethodTest (
const AjPStr method
);
Type | Name | Read/Write | Description |
const AjPStr | method | Input | Method required. |
AjBool | | RETURN | ajTrue on success. |
Input
method: | (Input) | Method required. |
Returns
AjBool: | ajTrue on success. |
Description
Tests for a named method for data data reading.
See Also
See other functions in this section
Availability
In release 6.4.0
Data Resource Input Stream
Sections: Data Resource Input Constructors Data Resource Input Stream Destructors data resource input stream modifiers Data resource input stream casts resource input
All constructors return a new data resource input stream object by pointer.
It is the responsibility of the user to first destroy any previous
data resource input object. The target pointer does not need to be
initialised to NULL, but it is good programming practice to do so
anyway.
Functions: ajResourceallNew
Creates a new data resource input stream object.
Synopsis
Prototype
AjPResourceall ajResourceallNew (
void
);
Type | Name | Read/Write | Description |
AjPResourceall | | RETURN | New data resource input stream object. |
Returns
AjPResourceall: | New data resource input stream object. |
Description
Creates a new data resource input stream object.
See Also
See other functions in this section
Availability
In release 6.4.0
Destruction destroys all internal data structures and frees the
memory allocated for the data resource input stream object.
Functions: ajResourceallDel
Deletes a data resource input stream object.
Synopsis
Prototype
void ajResourceallDel (
AjPResourceall* pthis
);
Type | Name | Read/Write | Description |
AjPResourceall* | pthis | Delete | Data resource input stream |
void | | RETURN | |
Output
pthis: | (Delete) | Data resource input stream |
Returns
Description
Deletes a data resource input stream object.
See Also
See other functions in this section
Availability
In release 6.4.0
These functions use the contents of an data resource input stream object and
update them.
Functions: ajResourceallClear
Clears a data resource term input stream object back to "as new" condition,
except for the query list which must be preserved.
Synopsis
Prototype
void ajResourceallClear (
AjPResourceall thys
);
Type | Name | Read/Write | Description |
AjPResourceall | thys | Output | Data resource input stream |
void | | RETURN | |
Output
thys: | (Output) | Data resource input stream |
Returns
Description
Clears a data resource term input stream object back to "as new" condition,
except for the query list which must be preserved.
See Also
See other functions in this section
Availability
In release 6.4.0
These functions return the contents of a data resource input stream object
Functions: ajResourceallGetresourceId
Returns the identifier of the current data resource in an input stream
Synopsis
Prototype
const AjPStr ajResourceallGetresourceId (
const AjPResourceall thys
);
Type | Name | Read/Write | Description |
const AjPResourceall | thys | Input | Data resource term input stream |
const AjPStr | | RETURN | Identifier |
Input
thys: | (Input) | Data resource term input stream |
Returns
Description
Returns the identifier of the current data resource in an input stream
See Also
See other functions in this section
Availability
In release 6.4.0
These functions use a data resource input stream object to read data
Functions: ajResourceallNext
Parse a data resource query into format, access, file and entry
Split at delimiters. Check for the first part as a valid format
Check for the remaining first part as a database name or as a file
that can be opened.
Anything left is an entryname spec.
Return the results in the AjPResource object but leave the file open for
future calls.
Synopsis
Prototype
AjBool ajResourceallNext (
AjPResourceall thys,
AjPResource* Presource
);
Type | Name | Read/Write | Description |
AjPResourceall | thys | Output | Data resource input stream |
AjPResource* | Presource | Modify | Data resource returned |
AjBool | | RETURN | ajTrue on success. |
Output
thys: | (Output) | Data resource input stream |
Input & Output
Presource: | (Modify) | Data resource returned |
Returns
AjBool: | ajTrue on success. |
Description
Parse a data resource query into format, access, file and entry
Split at delimiters. Check for the first part as a valid format
Check for the remaining first part as a database name or as a file
that can be opened.
Anything left is an entryname spec.
Return the results in the AjPResource object but leave the file open for
future calls.
See Also
See other functions in this section
Availability
In release 6.4.0
Input formats
Sections: cast
Values for input formats
Functions: ajResourceinformatTerm ajResourceinformatTest
Tests whether a data resource data input format term is known
Synopsis
Prototype
AjBool ajResourceinformatTerm (
const AjPStr term
);
Type | Name | Read/Write | Description |
const AjPStr | term | Input | Format term EDAM ID |
AjBool | | RETURN | ajTrue if term was accepted |
Input
term: | (Input) | Format term EDAM ID |
Returns
AjBool: | ajTrue if term was accepted |
Description
Tests whether a data resource data input format term is known
See Also
See other functions in this section
Availability
In release 6.4.0
Tests whether a named data data input format is known
Synopsis
Prototype
AjBool ajResourceinformatTest (
const AjPStr format
);
Type | Name | Read/Write | Description |
const AjPStr | format | Input | Format term EDAM ID |
AjBool | | RETURN | ajTrue if format was accepted |
Input
format: | (Input) | Format term EDAM ID |
Returns
AjBool: | ajTrue if format was accepted |
Description
Tests whether a named data data input format is known
See Also
See other functions in this section
Availability
In release 6.4.0