Skip to content

Commit

Permalink
refactor: Renamed a property
Browse files Browse the repository at this point in the history
  • Loading branch information
yoheimuta committed Jul 30, 2018
1 parent 7b358bd commit 9c64a18
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions BufferedLogger/Entry.swift
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,14 @@ import Foundation

/// Entry represents an entity to be written by a writer.
public struct Entry: Codable, Hashable {
/// createdDate is the date the entry is created.
public var createdDate: Date
/// createTime is the date the entry is created.
public let createTime: Date

/// payload is a log content.
public let payload: Data

private let identifier: UUID = UUID()
/// identifier is an unique entry ID.
public let identifier: UUID = UUID()

public var hashValue: Int {
return identifier.hashValue
Expand All @@ -26,8 +27,8 @@ public struct Entry: Codable, Hashable {
return lhs.identifier == rhs.identifier
}

init(_ payload: Data, createdDate: Date = Date()) {
init(_ payload: Data, createTime: Date = Date()) {
self.payload = payload
self.createdDate = createdDate
self.createTime = createTime
}
}

0 comments on commit 9c64a18

Please sign in to comment.