Documentation ¶
Index ¶
- Variables
- type Reader
- type Writer
- func (w *Writer) GetTransferSyntax() (binary.ByteOrder, bool)
- func (w *Writer) SetTransferSyntax(bo binary.ByteOrder, implicit bool)
- func (w *Writer) WriteByte(v byte) error
- func (w *Writer) WriteBytes(v []byte) error
- func (w *Writer) WriteFloat32(v float32) error
- func (w *Writer) WriteFloat64(v float64) error
- func (w *Writer) WriteString(v string) error
- func (w *Writer) WriteUInt16(v uint16) error
- func (w *Writer) WriteUInt32(v uint32) error
- func (w *Writer) WriteUInt64(v uint64) error
- func (w *Writer) WriteZeros(len int) error
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrorInsufficientBytesLeft = errors.New("not enough bytes left until buffer limit to complete this operation")
)
Functions ¶
This section is empty.
Types ¶
type Reader ¶
type Reader interface { io.Reader // ReadUInt8 reads a uint16 from the underlying reader. ReadUInt8() (uint8, error) // ReadUInt16 reads a uint16 from the underlying reader. ReadUInt16() (uint16, error) // ReadUInt32 reads a uint32 from the underlying reader. ReadUInt32() (uint32, error) // ReadUInt64 reads a uint64 from the underlying reader. ReadUInt64() (uint64, error) // ReadInt16 reads a int16 from the underlying reader. ReadInt16() (int16, error) // ReadInt32 reads a int32 from the underlying reader. ReadInt32() (int32, error) // ReadInt64 reads a int64 from the underlying reader. ReadInt64() (int64, error) // ReadFloat32 reads a float32 from the underlying reader. ReadFloat32() (float32, error) // ReadFloat64 reads a float32 from the underlying reader. ReadFloat64() (float64, error) // ReadString reads an n byte string from the underlying reader. Uses the charset.CodingSystem encoding. // Decoders to read the string, if set. ReadString(n uint32) (string, error) // Skip skips the reader ahead by n bytes. Skip(n int64) error // Peek returns the next n bytes without advancing the reader. This will // return bufio.ErrBufferFull if the buffer is full. Peek(n int) ([]byte, error) // PushLimit sets a read limit of n bytes from the current position of the reader. Once the limit is reached, // IsLimitExhausted will return true, and other attempts to read data from dicomio.Reader will return io.EOF. PushLimit(n int64) error // PopLimit removes the most recent limit set, and restores the limit before that one. PopLimit() // IsLimitExhausted indicates whether or not we have read up to the currently set limit position. IsLimitExhausted() bool // BytesLeftUntilLimit returns the number of bytes remaining until we reach the currently set limit positon. BytesLeftUntilLimit() int64 // SetTransferSyntax sets the byte order and whether the current transfer syntax is implicit or not. SetTransferSyntax(bo binary.ByteOrder, implicit bool) // IsImplicit returns if the currently set transfer syntax on this Reader is implicit or not. IsImplicit() bool // SetCodingSystem sets the charset.CodingSystem to be used when ReadString is called. SetCodingSystem(cs charset.CodingSystem) }
Reader provides common functionality for reading underlying DICOM data.
type Writer ¶
type Writer struct {
// contains filtered or unexported fields
}
Writer is a lower level encoder that manages writing out entities to an io.Reader.
func (*Writer) SetTransferSyntax ¶
func (*Writer) WriteBytes ¶
func (*Writer) WriteFloat32 ¶
func (*Writer) WriteFloat64 ¶
func (*Writer) WriteString ¶
func (*Writer) WriteUInt16 ¶
func (*Writer) WriteUInt32 ¶
func (*Writer) WriteUInt64 ¶
func (*Writer) WriteZeros ¶
Click to show internal directories.
Click to hide internal directories.