| Modifier and Type | Method and Description |
|---|---|
LogEntry.Builder |
addLabel(String key,
String value)
Adds a label to the log entry's labels.
|
LogEntry |
build()
Creates a
LogEntry object for this builder. |
LogEntry.Builder |
clearLabels()
Clears all the labels of the log entry.
|
LogEntry.Builder |
httpRequest(HttpRequest httpRequest)
Sets information about the HTTP request associated with this log entry, if applicable.
|
LogEntry.Builder |
insertId(String insertId)
Sets a unique ID for the log entry.
|
LogEntry.Builder |
labels(Map<String,String> labels)
Sets an optional set of user-defined (key, value) data that provides additional information
about the log entry.
|
LogEntry.Builder |
logName(String logName)
Sets the name of the log to which this log entry belongs.
|
LogEntry.Builder |
operation(Operation operation)
Sets information about an operation associated with the log entry, if applicable.
|
LogEntry.Builder |
payload(Payload payload)
Sets the payload for this log entry.
|
LogEntry.Builder |
resource(MonitoredResource resource)
Sets the monitored resource associated with this log entry.
|
LogEntry.Builder |
severity(Severity severity)
Sets the severity of the log entry.
|
LogEntry.Builder |
timestamp(long timestamp)
Sets the time at which the event described by the log entry occurred, in milliseconds.
|
public LogEntry.Builder logName(String logName)
[A-Za-z0-9]; and punctuation characters: _-./. The
forward-slash (/) characters in the log name must be URL-encoded. Examples:
syslog, library.googleapis.com%2Fbook_log.public LogEntry.Builder resource(MonitoredResource resource)
public LogEntry.Builder timestamp(long timestamp)
public LogEntry.Builder severity(Severity severity)
Severity.DEFAULT is used.public LogEntry.Builder insertId(String insertId)
public LogEntry.Builder httpRequest(HttpRequest httpRequest)
public LogEntry.Builder labels(Map<String,String> labels)
public LogEntry.Builder addLabel(String key, String value)
public LogEntry.Builder clearLabels()
public LogEntry.Builder operation(Operation operation)
public LogEntry.Builder payload(Payload payload)
Payload.StringPayload), a JSON object (see Payload.JsonPayload, or
a protobuf object (see Payload.ProtoPayload).public LogEntry build()
LogEntry object for this builder.Copyright © 2016 Google. All rights reserved.