Class FitsHeaderEntry
- Namespace
- FitsModel
- Assembly
- FitsModel.dll
Represents a single 80 byte record in a FITS header.
public class FitsHeaderEntry
- Inheritance
-
FitsHeaderEntry
- Inherited Members
Constructors
FitsHeaderEntry()
Creates an empty 80 byte record in a FITS header.
public FitsHeaderEntry()
FitsHeaderEntry(string)
Represents one record in a FitsHeader. Each record must be of the proper RecordSize
public FitsHeaderEntry(string entry)
Parameters
entry
string
FitsHeaderEntry(string, string)
Creates a new FitsHeaderEntry from the provided keyword and value.
public FitsHeaderEntry(string keyword, string value)
Parameters
Exceptions
- FitsModelException
Thrown if the keyword is null or emtpy or the resulting entry is greater than 80 characters.
Properties
IsEndRecord
True if this record is the end record of a FITS header.
public bool IsEndRecord { get; }
Property Value
Keyword
If this record is a keyword record, this will be the keyword name.
public string? Keyword { get; }
Property Value
RawEntry
The raw 80 character string for this entry.
public string RawEntry { get; }
Property Value
Value
If this record is a keyword record, this will be the value associated with the keyword.
public string? Value { get; }
Property Value
Methods
CreateRawValue(string, string)
Converts the provided key and value into a raw FITS header entry string.
public static string CreateRawValue(string key, string value)
Parameters
Returns
Exceptions
Equals(object?)
public override bool Equals(object? obj)
Parameters
obj
object
Returns
GetBytes()
Converts this FITS header entry to an ASCII byte array.
public byte[] GetBytes()
Returns
- byte[]
GetHashCode()
public override int GetHashCode()
Returns
ToString()
public override string ToString()
Returns
WriteToStream(Stream)
Writes this FITS header entry to the provided stream.
public Task WriteToStream(Stream stream)
Parameters
stream
Stream
Returns
WriteToStream(Stream, CancellationToken)
Writes this FITS header entry to the provided stream.
public Task WriteToStream(Stream stream, CancellationToken cancellationToken)
Parameters
stream
StreamcancellationToken
CancellationToken