Table of Contents

Class FileTimecodeSection

Namespace
Hi.Mappings
Assembly
HiGeom.dll

(A) Time window expressed in relative TimeSpan timecodes only.

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

Constructors

FileTimecodeSection()

Initializes an empty instance.

public FileTimecodeSection()

FileTimecodeSection(FileTimecodeDateTimeSection)

Projects a both-form (C) section onto its timecode form (independent copy).

public FileTimecodeSection(FileTimecodeDateTimeSection c)

Parameters

c FileTimecodeDateTimeSection

FileTimecodeSection(string, Range<TimeSpan>)

Initializes from a file and a timecode range.

public FileTimecodeSection(string file, Range<TimeSpan> timeRange)

Parameters

file string
timeRange Range<TimeSpan>

FileTimecodeSection(string, TimeSpan, TimeSpan)

Initializes from a file and begin/end timecodes.

public FileTimecodeSection(string file, TimeSpan beginTimecode, TimeSpan endTimecode)

Parameters

file string
beginTimecode TimeSpan
endTimecode TimeSpan

FileTimecodeSection(XElement)

Initializes from XML; accepts new BeginTimecode and legacy BeginTime / BeginTime_s.

public FileTimecodeSection(XElement src)

Parameters

src XElement

Fields

LegacyXName

Legacy element name; pre-rename projects wrote <FileTimeSection> for this form.

public const string LegacyXName = "FileTimeSection"

Field Value

string

Properties

BeginTimecode

Window start as a timecode (position from run start).

public TimeSpan BeginTimecode { get; set; }

Property Value

TimeSpan

EndTimecode

Window end as a timecode (position from run start).

public TimeSpan EndTimecode { get; set; }

Property Value

TimeSpan

File

Relative path of the referenced (sensor) file.

public string File { get; set; }

Property Value

string

TimeRange

The timecode range backing BeginTimecode / EndTimecode.

public Range<TimeSpan> TimeRange { get; set; }

Property Value

Range<TimeSpan>

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 (and its legacy element name) 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.