STK Vector Geometry ToolSend comments on this topic.
CreateSmartEpochFromTime Method (IAgCrdnEventFactory)
See Also
Epoch
Windows





Windows & Linux

Description

Creates a smart epoch from STK epoch.

Syntax

[Visual Basic .NET]
Public Function CreateSmartEpochFromTime( _
    ByVal Epoch As System.Object _
) As IAgCrdnEventSmartEpoch
[C#]
public IAgCrdnEventSmartEpoch CreateSmartEpochFromTime(
    System.Object Epoch
);
[Managed C++]
public: IAgCrdnEventSmartEpoch^ CreateSmartEpochFromTime(
    VARIANT Epoch
);
[Unmanaged C++]
public: HRESULT CreateSmartEpochFromTime(
    VARIANT Epoch,
    IAgCrdnEventSmartEpoch ** ppRetVal
);
[Java]
public IAgCrdnEventSmartEpoch createSmartEpochFromTime(
    AgVariant Epoch
);
[Python - STK API ]
def CreateSmartEpochFromTime(self, Epoch:typing.Any) -> "IAgCrdnEventSmartEpoch":

Parameters

Epoch

See Also

Example

Create and configure explicit smart epoch event.
[C#]
IAgCrdnEventSmartEpoch smartEpoch = provider.Events.Factory.CreateSmartEpochFromTime("1 May 2016 04:00:00.000");

// Smart epochs can be set explicitly (Uses current DateTime unit preference, this code snippet assumes UTCG)
smartEpoch.SetExplicitTime("1 May 2015 01:00:00.000");

Console.WriteLine("Event occurred at: " + smartEpoch.TimeInstant);
Create and configure implicit smart epoch event.
[C#]
IAgCrdnEvent referencedEvent = provider.Events["AvailabilityStartTime"];
IAgCrdnEventSmartEpoch smartEpoch = provider.Events.Factory.CreateSmartEpochFromEvent(referencedEvent);

// Smart epochs can be set implicitly using the another epoch.
IAgCrdnEvent anotherEvent = provider.Events["AvailabilityStopTime"];
smartEpoch.SetImplicitTime(anotherEvent);

Console.WriteLine("Event occurred at: " + smartEpoch.TimeInstant);
Create and configure explicit smart epoch event.
[Visual Basic .NET]
Dim smartEpoch As IAgCrdnEventSmartEpoch = provider.Events.Factory.CreateSmartEpochFromTime("1 May 2016 04:00:00.000")

' Smart epochs can be set explicitly (Uses current DateTime unit preference, this code snippet assumes UTCG)
smartEpoch.SetExplicitTime("1 May 2015 01:00:00.000")

Console.WriteLine("Event occurred at: " + smartEpoch.TimeInstant)
Create and configure implicit smart epoch event.
[Visual Basic .NET]
Dim referencedEvent As IAgCrdnEvent = provider.Events("AvailabilityStartTime")
Dim smartEpoch As IAgCrdnEventSmartEpoch = provider.Events.Factory.CreateSmartEpochFromEvent(referencedEvent)

' Smart epochs can be set implicitly using the another epoch.
Dim anotherEvent As IAgCrdnEvent = provider.Events("AvailabilityStopTime")
smartEpoch.SetImplicitTime(anotherEvent)

Console.WriteLine("Event occurred at: " + smartEpoch.TimeInstant)
© 2024 Analytical Graphics, Inc. All Rights Reserved.