PropertyDefinition

class astro_metadata_translator.PropertyDefinition(doc: str, str_type: str, py_type: type, to_simple: Callable[[Any], Any] | None = None, from_simple: Callable[[Any], Any] | None = None)

Bases: object

Definition of an instrumental property.

Attributes Summary

from_simple

Function to convert from simple form back to required type (can be None).

to_simple

Function to convert value to simple form (can be None).

Attributes Documentation

from_simple: Callable[[Any], Any] | None = None

Function to convert from simple form back to required type (can be None).

to_simple: Callable[[Any], Any] | None = None

Function to convert value to simple form (can be None).