In Files

Parent

WinEx::Struct::SYSTEMTIME

typedef struct _SYSTEMTIME

Wrapper for the SYSTEMTIME struct.

Public Class Methods

new(string = "\000" * 16) click to toggle source

If string_data is not provided, a NULL padded string buffer with the size of the struct is returned.

# File WinEx.rb, line 96
                def initialize(string = "\000" * 16)
                        super(string) #if string.is_a?(String)
                end

Public Instance Methods

day() click to toggle source

Returns an Integer representing the day.

# File WinEx.rb, line 116
                def day
                        return self.to_a[3]
                end
day_of_week() click to toggle source

Returns an Integer representing the day of the week.

# File WinEx.rb, line 112
                def day_of_week
                        return self.to_a[2]
                end
hour() click to toggle source

Returns an Integer representing the hour.

# File WinEx.rb, line 120
                def hour
                        return self.to_a[4]
                end
milliseconds() click to toggle source

Returns an Integer representing the milliseconds.

# File WinEx.rb, line 132
                def milliseconds
                        return self.to_a[7]
                end
minute() click to toggle source

Returns an Integer representing the minute.

# File WinEx.rb, line 124
                def minute
                        return self.to_a[5]
                end
month() click to toggle source

Returns an Integer representing the month.

# File WinEx.rb, line 108
                def month
                        return self.to_a[1]
                end
second() click to toggle source

Returns an Integer representing the second.

# File WinEx.rb, line 128
                def second
                        return self.to_a[6]
                end
time() click to toggle source

Returns a Time object.

# File WinEx.rb, line 136
                def time
                        year, month, day_of_week, day, hour, minute, second, millisecond = self.to_a
                        return Time.utc(year, month, day, hour, minute, second)
                end
to_a() click to toggle source

Returns an Array of the data extracted from the data string.

# File WinEx.rb, line 100
                def to_a
                        return self.unpack('SSSSSSSS')
                end
year() click to toggle source

Returns an Integer representing the year.

# File WinEx.rb, line 104
                def year
                        return self.to_a[0]
                end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.