QueryResponseTable

class sunpy.net.base_client.QueryResponseTable(*args, **kwargs)[source]

Bases: astropy.table.QTable

Attributes Summary

blocks

Deprecated since version 2.1.

client

Descriptor to define a custom attribute for a Table subclass.

display_keys

Descriptor to define a custom attribute for a Table subclass.

hide_keys

Descriptor to define a custom attribute for a Table subclass.

Methods Summary

build_table()

Deprecated since version 2.1.

path_format_keys()

Returns all the names that can be used to format filenames.

response_block_properties()

Deprecated since version 2.1.

show(*cols)

Return a table with only cols present.

unhide_columns()

Modify this table so that all columns are displayed.

Attributes Documentation

blocks

Deprecated since version 2.1: Slice the table instead.

A collections.abc.Sequence object which contains the records contained within the Query Response.

client

Descriptor to define a custom attribute for a Table subclass.

The value of the TableAttribute will be stored in a dict named __attributes__ that is stored in the table meta. The attribute can be accessed and set in the usual way, and it can be provided when creating the object.

Defining an attribute by this mechanism ensures that it will persist if the table is sliced or serialized, for example as a pickle or ECSV file.

See the MetaAttribute documentation for additional details.

Parameters

default (object) – Default value for attribute

Examples

>>> from astropy.table import Table, TableAttribute
>>> class MyTable(Table):
...     identifier = TableAttribute(default=1)
>>> t = MyTable(identifier=10)
>>> t.identifier
10
>>> t.meta
OrderedDict([('__attributes__', {'identifier': 10})])
display_keys

Descriptor to define a custom attribute for a Table subclass.

The value of the TableAttribute will be stored in a dict named __attributes__ that is stored in the table meta. The attribute can be accessed and set in the usual way, and it can be provided when creating the object.

Defining an attribute by this mechanism ensures that it will persist if the table is sliced or serialized, for example as a pickle or ECSV file.

See the MetaAttribute documentation for additional details.

Parameters

default (object) – Default value for attribute

Examples

>>> from astropy.table import Table, TableAttribute
>>> class MyTable(Table):
...     identifier = TableAttribute(default=1)
>>> t = MyTable(identifier=10)
>>> t.identifier
10
>>> t.meta
OrderedDict([('__attributes__', {'identifier': 10})])
hide_keys

Descriptor to define a custom attribute for a Table subclass.

The value of the TableAttribute will be stored in a dict named __attributes__ that is stored in the table meta. The attribute can be accessed and set in the usual way, and it can be provided when creating the object.

Defining an attribute by this mechanism ensures that it will persist if the table is sliced or serialized, for example as a pickle or ECSV file.

See the MetaAttribute documentation for additional details.

Parameters

default (object) – Default value for attribute

Examples

>>> from astropy.table import Table, TableAttribute
>>> class MyTable(Table):
...     identifier = TableAttribute(default=1)
>>> t = MyTable(identifier=10)
>>> t.identifier
10
>>> t.meta
OrderedDict([('__attributes__', {'identifier': 10})])

Methods Documentation

build_table()[source]

Deprecated since version 2.1: The object is a table.

Return an astropy.table.Table representation of the query response.

path_format_keys()[source]

Returns all the names that can be used to format filenames.

Each one corresponds to a single column in the table, and the format syntax should match the dtype of that column, i.e. for a Time object or a Quantity.

response_block_properties()[source]

Deprecated since version 2.1: use path_format_keys instead

show(*cols)[source]

Return a table with only cols present.

If no cols are specified, all columns will be shown, including any hidden by default.

This differs slightly from QueryResponseTable[cols] as it allows keys which are not in the table to be requested.

unhide_columns()[source]

Modify this table so that all columns are displayed.