C# Класс Contrequarte.SmartPlug.Core.TimePeriod

Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
EdimaxScheduleList2ScheduledEntries ( string edimaxScheduleList ) : IEnumerable

Converting the value of an Edimax node to a List. the node value looks like following e.g.: 00011-0c0m1-m0mu1-n0nP1

IsIntersectionFree ( IEnumerable timePeriods ) : bool

Checking, if an enumeration of TimePeriod objects doesn't contain intersecting TimePeriods

TimePeriod ( PointInTime begin, PointInTime end ) : System

Приватные методы

Метод Описание
CharToNumber ( char charToConvert ) : int

Converting the characters used in to the corresponding number to get the times coded mor human readable

EdimaxScheduledEntryPart2ScheduledEntry ( string scheduledListPart ) : ScheduledEntry

Converting a single schedule entry of the smartplug to a ScheduledEntry object such a single schedule entry consists of 5 characters [hour][minute][hour][minute][on/Off] [hour] is one single char representing the numbers from 0 to 23/24 [minute] is one single char representing the numbers from 0 to 59 [on/off] char '1' stands for 'on' char '0' represents 'off'

Описание методов

EdimaxScheduleList2ScheduledEntries() публичный статический Метод

Converting the value of an Edimax node to a List. the node value looks like following e.g.: 00011-0c0m1-m0mu1-n0nP1
public static EdimaxScheduleList2ScheduledEntries ( string edimaxScheduleList ) : IEnumerable
edimaxScheduleList string string representing the schedule list from an Edimax SmartPlug
Результат IEnumerable

IsIntersectionFree() публичный статический Метод

Checking, if an enumeration of TimePeriod objects doesn't contain intersecting TimePeriods
public static IsIntersectionFree ( IEnumerable timePeriods ) : bool
timePeriods IEnumerable enumeration of Timeperiod objects to check
Результат bool

TimePeriod() публичный Метод

public TimePeriod ( PointInTime begin, PointInTime end ) : System
begin PointInTime
end PointInTime
Результат System