Table of Contents

Class FileTimecodeDateTimeSection

Namespace
Hi.Mappings
Assembly
HiGeom.dll

(C) Time window carrying both forms. The timecode form is authoritative for mapping (timecode-first); the absolute form is retained for the anchor and for projecting to a single-form section (new FileTimecodeSection(c) / new FileDateTimeSection(c)) when the two forms do not agree.

public sealed class FileTimecodeDateTimeSection : IFileTimeSection, IMakeXmlSource
Inheritance
FileTimecodeDateTimeSection
Implements
Inherited Members
Extension Methods

Constructors

FileTimecodeDateTimeSection()

Initializes an empty instance.

public FileTimecodeDateTimeSection()

FileTimecodeDateTimeSection(string, TimeSpan, TimeSpan, DateTime, DateTime)

Initializes from a file, a timecode range and an absolute range.

public FileTimecodeDateTimeSection(string file, TimeSpan beginTimecode, TimeSpan endTimecode, DateTime beginDateTime, DateTime endDateTime)

Parameters

file string
beginTimecode TimeSpan
endTimecode TimeSpan
beginDateTime DateTime
endDateTime DateTime

FileTimecodeDateTimeSection(XElement)

Initializes from XML.

public FileTimecodeDateTimeSection(XElement src)

Parameters

src XElement

Properties

BeginDateTime

Window start as an absolute controller instant.

public DateTime BeginDateTime { get; set; }

Property Value

DateTime

BeginTimecode

Window start as a timecode (authoritative for mapping).

public TimeSpan BeginTimecode { get; set; }

Property Value

TimeSpan

EndDateTime

Window end as an absolute controller instant.

public DateTime EndDateTime { get; set; }

Property Value

DateTime

EndTimecode

Window end as a timecode (authoritative for mapping).

public TimeSpan EndTimecode { get; set; }

Property Value

TimeSpan

File

Relative path of the referenced (sensor) file.

public string File { get; set; }

Property Value

string

XName

XML element name for XFactory registration.

public static string XName { get; }

Property Value

string

Methods

MakeXmlSource(string, string, bool)

Creates an XML representation of the object. This method may also generate additional resources such as related files.

public XElement MakeXmlSource(string baseDirectory, string relFile, bool exhibitionOnly)

Parameters

baseDirectory string

The base directory for resolving relative paths

relFile string

The relative file path for the XML source

exhibitionOnly bool

if true, the extended file creation is suppressed.

Returns

XElement

An XML element representing the object's state

Remarks

For the demand of easy moving source folder (especially project folder) without configuration file path corruption, the relative file path is applied. The baseDirectory is typically the folder at the nearest configuration file folder. Since the folder can be moving with the configuration file.

Reg(XFactory)

Registers this type with the factory. Idempotent.

public static void Reg(XFactory factory = null)

Parameters

factory XFactory

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

A string that represents the current object.