com.netflix.servo.monitor
Class MonitorConfig.Builder

java.lang.Object
  extended by com.netflix.servo.monitor.MonitorConfig.Builder
Enclosing class:
MonitorConfig

public static class MonitorConfig.Builder
extends java.lang.Object

A builder to assist in creating monitor config objects.


Constructor Summary
MonitorConfig.Builder(MonitorConfig config)
          Create a new builder initialized with the specified config.
MonitorConfig.Builder(java.lang.String name)
          Create a new builder initialized with the specified name.
 
Method Summary
 MonitorConfig build()
          Create the monitor config object.
 MonitorConfig.Builder withPublishingPolicy(PublishingPolicy policy)
          Add the publishing policy to the config.
 MonitorConfig.Builder withTag(java.lang.String key, java.lang.String val)
          Add a tag to the config.
 MonitorConfig.Builder withTag(Tag tag)
          Add a tag to the config.
 MonitorConfig.Builder withTags(java.util.Collection<Tag> tagCollection)
          Add all tags in the list to the config.
 MonitorConfig.Builder withTags(TagList tagList)
          Add all tags in the list to the config.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MonitorConfig.Builder

public MonitorConfig.Builder(MonitorConfig config)
Create a new builder initialized with the specified config.


MonitorConfig.Builder

public MonitorConfig.Builder(java.lang.String name)
Create a new builder initialized with the specified name.

Method Detail

withTag

public MonitorConfig.Builder withTag(java.lang.String key,
                                     java.lang.String val)
Add a tag to the config.


withTag

public MonitorConfig.Builder withTag(Tag tag)
Add a tag to the config.


withTags

public MonitorConfig.Builder withTags(TagList tagList)
Add all tags in the list to the config.


withTags

public MonitorConfig.Builder withTags(java.util.Collection<Tag> tagCollection)
Add all tags in the list to the config.


withPublishingPolicy

public MonitorConfig.Builder withPublishingPolicy(PublishingPolicy policy)
Add the publishing policy to the config.


build

public MonitorConfig build()
Create the monitor config object.