Codota Logo
Preconditions.checkArgumentNotNull
Code IndexAdd Codota to your IDE (free)

How to use
checkArgumentNotNull
method
in
org.metricssampler.util.Preconditions

Best Java code snippets using org.metricssampler.util.Preconditions.checkArgumentNotNull (Showing top 20 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
ArrayList a =
  • Codota Iconnew ArrayList<String>()
  • Codota Iconnew ArrayList()
  • Codota Iconnew ArrayList<Object>()
  • Smart code suggestions by Codota
}
origin: com.github.dimovelev/metrics-sampler-extension-base

public ConsoleMetricsWriter(final ConsoleOutputConfig config) {
  checkArgumentNotNull(config, "config");
  this.config = config;
}
origin: com.github.dimovelev/metrics-sampler-extension-jdbc

public JdbcInputConfig(final String name, final Map<String, Object> variables, final String pool, final List<String> queries) {
  super(name, variables);
  checkArgumentNotNull(pool, "pool");
  checkArgumentNotNullNorEmpty(queries, "queries");
  this.pool= pool;
  this.queries = Collections.unmodifiableList(queries);
}
origin: com.github.dimovelev/metrics-sampler-extension-base

public RegExpSelectorConfig(final String namePattern, final String descriptionPattern, final String keyExpression) {
  checkArgumentNotNull(keyExpression, "keyExpression");
  this.namePattern = namePattern;
  this.descriptionPattern = descriptionPattern;
  this.keyExpression = keyExpression;
}
origin: com.github.dimovelev/metrics-sampler-extension-jmx

public JmxMetricName(final ObjectName objectName, final String attributeName, final PropertyPath propertyPath, final String description) {
  checkArgumentNotNull(objectName, "objectName");
  checkArgumentNotNull(propertyPath, "propertyPath");
  checkArgumentNotNullNorEmpty(attributeName, "attributeName");
  this.objectName = objectName;
  this.attributeName = attributeName;
  this.propertyPath = propertyPath;
  this.description = description;
  this.name = generateName();
}
origin: dimovelev/metrics-sampler

public DefaultSampler addWriter(final MetricsWriter writer) {
  checkArgumentNotNull(writer, "writer");
  writers.add(writer);
  return this;
}
origin: dimovelev/metrics-sampler

public InputConfig(final String name, final Map<String, Object> variables) {
  super(name);
  checkArgumentNotNull(variables, "variables");
  this.variables = unmodifiableMap(variables);
}
origin: com.github.dimovelev/metrics-sampler-extension-base

public DefaultSampler addValueTransformer(final ValueTransformer valueTransformer) {
  checkArgumentNotNull(valueTransformer, "valueTransformer");
  valueTransformers.add(valueTransformer);
  return this;
}
origin: com.github.dimovelev/metrics-sampler-extension-base

public DefaultSampler addWriter(final MetricsWriter writer) {
  checkArgumentNotNull(writer, "writer");
  writers.add(writer);
  return this;
}
origin: com.github.dimovelev/metrics-sampler-core

public InputConfig(final String name, final Map<String, Object> variables) {
  super(name);
  checkArgumentNotNull(variables, "variables");
  this.variables = unmodifiableMap(variables);
}
origin: com.github.dimovelev/metrics-sampler-core

public Configuration(final Collection<InputConfig> inputs, final Collection<OutputConfig> outputs, final Collection<SamplerConfig> samplers, final Map<String, Object> variables, final Map<String, SharedResourceConfig> sharedResources) {
  checkArgumentNotNull(inputs, "inputs");
  checkArgumentNotNull(outputs, "outputs");
  checkArgumentNotNull(samplers, "samplers");
  checkArgumentNotNull(variables, "variables");
  checkArgumentNotNull(sharedResources, "sharedResources");
  this.inputs = unmodifiableCollection(inputs);
  this.outputs = unmodifiableCollection(outputs);
  this.samplers = unmodifiableCollection(samplers);
  this.variables = unmodifiableMap(variables);
  this.sharedResources = unmodifiableMap(sharedResources);
}
origin: dimovelev/metrics-sampler

public Configuration(final Collection<InputConfig> inputs, final Collection<OutputConfig> outputs, final Collection<SamplerConfig> samplers, final Map<String, Object> variables, final Map<String, SharedResourceConfig> sharedResources) {
  checkArgumentNotNull(inputs, "inputs");
  checkArgumentNotNull(outputs, "outputs");
  checkArgumentNotNull(samplers, "samplers");
  checkArgumentNotNull(variables, "variables");
  checkArgumentNotNull(sharedResources, "sharedResources");
  this.inputs = unmodifiableCollection(inputs);
  this.outputs = unmodifiableCollection(outputs);
  this.samplers = unmodifiableCollection(samplers);
  this.variables = unmodifiableMap(variables);
  this.sharedResources = unmodifiableMap(sharedResources);
}
origin: com.github.dimovelev/metrics-sampler-extension-webmethods

public WebMethodsInputConfig(final String name, final Map<String, Object> variables, final URL url, final String username,
    final String password, final Map<String, String> headers, final boolean preemptiveAuthEnabled, final SocketOptionsConfig socketOptions,
    final long maxEntrySize, final DateFormat dateFormat) {
  super(name, variables, url, username, password, headers, preemptiveAuthEnabled, socketOptions, null);
  checkArgumentNotNull(dateFormat, "dateFormat");
  checkArgument(maxEntrySize > 0, "maxEntrySize must greater than 0");
  this.maxEntrySize = maxEntrySize;
  this.dateFormat = dateFormat;
}
origin: com.github.dimovelev/metrics-sampler-extension-graphite

public GraphiteMetricsWriter(final GraphiteOutputConfig config) {
  checkArgumentNotNull(config, "config");
  this.config = config;
  this.logger = LoggerFactory.getLogger("writer."+config.getName());
}
origin: com.github.dimovelev/metrics-sampler-extension-base

public DefaultSampler addSelector(final MetricsSelector selector) {
  checkArgumentNotNull(selector, "selector");
  selectors.add(selector);
  selector.setVariables(variables);
  return this;
}

origin: com.github.dimovelev/metrics-sampler-extension-base

public DefaultSampler(final DefaultSamplerConfig config, final MetricsReader reader) {
  checkArgumentNotNull(config, "config");
  checkArgumentNotNull(reader, "reader");
  this.config = config;
  this.reader = reader;
  this.variables = prepareVariables();
  logger = LoggerFactory.getLogger("sampler." + this.config.getName());
  timingsLogger = LoggerFactory.getLogger("timings.sampler");
}
origin: dimovelev/metrics-sampler

public GraphiteMetricsWriter(final GraphiteOutputConfig config) {
  checkArgumentNotNull(config, "config");
  this.config = config;
  this.logger = LoggerFactory.getLogger("writer."+config.getName());
}
origin: dimovelev/metrics-sampler

public DefaultSampler(final DefaultSamplerConfig config, final MetricsReader reader) {
  checkArgumentNotNull(config, "config");
  checkArgumentNotNull(reader, "reader");
  this.config = config;
  this.reader = reader;
  this.variables = prepareVariables();
  logger = LoggerFactory.getLogger("sampler." + this.config.getName());
  timingsLogger = LoggerFactory.getLogger("timings.sampler");
}
origin: com.github.dimovelev/metrics-sampler-extension-graphite

protected String serializeValue(final String name, final MetricValue value) {
  checkArgumentNotNull(name, "name");
  checkArgumentNotNull(value, "value");
  final long timestamp = value.getTimestamp()/1000;
  final String prefixedName = (config.getPrefix() != null ? config.getPrefix() : "") + name;
  final String graphiteName = prefixedName.replaceAll(" ", "_");
  return graphiteName + " " + value.getValue()+" " + timestamp + "\n";
}
origin: com.github.dimovelev/metrics-sampler-extension-base

@Override
public void write(final Metrics metrics) {
  checkArgumentNotNull(metrics, "metrics");
  for (final Metric entry : metrics) {
    final MetricValue value = entry.getValue();
    final String timestampPrefix = dateFormat.format(new Date(value.getTimestamp())) + " ";
    System.out.println(timestampPrefix + entry.getName().getName() + "=" + value.getValue());
  }
}
origin: com.github.dimovelev/metrics-sampler-extension-base

public DefaultSamplerThreadPool(final ThreadPoolConfig config, boolean suspended) {
  checkArgumentNotNull(config, "config");
  this.config = config;
  this.suspended = suspended;
  startup();
  GlobalRegistry.getInstance().addSharedResource(this);
}
org.metricssampler.utilPreconditionscheckArgumentNotNull

Popular methods of Preconditions

  • checkArgumentNotNullNorEmpty
  • checkArgument
  • checkArgumentPresent
  • checkStateNotNull

Popular in Java

  • Making http requests using okhttp
  • getExternalFilesDir (Context)
  • scheduleAtFixedRate (Timer)
    Schedules the specified task for repeated fixed-rate execution, beginning after the specified delay.
  • startActivity (Activity)
  • HashSet (java.util)
    This class implements the Set interface, backed by a hash table (actually a HashMap instance). It m
  • AtomicInteger (java.util.concurrent.atomic)
    An int value that may be updated atomically. See the java.util.concurrent.atomic package specificati
  • ServletException (javax.servlet)
    Defines a general exception a servlet can throw when it encounters difficulty.
  • JList (javax.swing)
  • StringUtils (org.apache.commons.lang)
    Operations on java.lang.String that arenull safe. * IsEmpty/IsBlank - checks if a String contains
  • SAXParseException (org.xml.sax)
    Encapsulate an XML parse error or warning.This exception may include information for locating the er
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now