Tabnine Logo
StringUtils.isEmpty
Code IndexAdd Tabnine to your IDE (free)

How to use
isEmpty
method
in
org.stagemonitor.util.StringUtils

Best Java code snippets using org.stagemonitor.util.StringUtils.isEmpty (Showing top 9 results out of 315)

origin: stagemonitor/stagemonitor

public static boolean isNotEmpty(String s) {
  return !isEmpty(s);
}
origin: stagemonitor/stagemonitor

public static String getSignature(String fullClassName, String methodName, String nameFromAnnotation, boolean absolute) {
  String name = StringUtils.isEmpty(nameFromAnnotation) ? methodName : nameFromAnnotation;
  if (absolute) {
    return name;
  }
  return getSignature(fullClassName, name);
}
origin: stagemonitor/stagemonitor

private String getSql(String prepared, String sql) {
  if (StringUtils.isEmpty(sql) || !jdbcPlugin.isCollectPreparedStatementParameters()) {
    sql = prepared;
  }
  return sql.trim();
}
origin: stagemonitor/stagemonitor

private String getReferringSite() {
  final String refererHeader = httpServletRequest.getHeader("Referer");
  if (StringUtils.isEmpty(refererHeader)) {
    return null;
  }
  String referrerHost;
  try {
    referrerHost = new URI(refererHeader).getHost();
  } catch (URISyntaxException e) {
    referrerHost = null;
  }
  if (httpServletRequest.getServerName().equals(referrerHost)) {
    return null;
  } else {
    return referrerHost;
  }
}
origin: stagemonitor/stagemonitor

/**
 * Creates a MimeMessage containing given Multipart.
 * Subject, sender and content and session will be set.
 * @param session current mail session
 * @return MimeMessage without recipients
 * @throws MessagingException
 */
public MimeMessage createMimeMessage(Session session) throws MessagingException {
  if (isEmpty(htmlPart) && isEmpty(textPart)) {
    throw new IllegalArgumentException("Missing email content");
  }
  final MimeMessage msg = new MimeMessage(session);
  msg.setSubject(subject);
  msg.setFrom(new InternetAddress(from));
  msg.setContent(createMultiPart());
  msg.setRecipients(Message.RecipientType.TO, InternetAddress.parse(recipients, false));
  return msg;
}
origin: stagemonitor/stagemonitor

protected boolean shouldProcess(Map<String, String[]> requestParams) {
  for (String requiredParam : requiredParams) {
    if (StringUtils.isEmpty(getParameterValueOrNull(requiredParam, requestParams))) {
      return false;
    }
  }
  if (typeToProcess.equals(TYPE_ALL)) {
    return true;
  }
  final String type = getParameterValueOrNull(ClientSpanServlet.PARAMETER_TYPE, requestParams);
  return typeToProcess.equals(type);
}
origin: stagemonitor/stagemonitor

@Override
public void interceptReport(PostExecutionInterceptorContext context) {
  final Collection<String> onlyReportRequestsWithName = tracingPlugin
      .getOnlyReportSpansWithName();
  if (StringUtils.isEmpty(context.getSpanContext().getOperationName())) {
    context.shouldNotReport(getClass());
  } else if (!onlyReportRequestsWithName.isEmpty() && !onlyReportRequestsWithName.contains(context.getSpanContext().getOperationName())) {
    context.shouldNotReport(getClass());
  }
}
origin: stagemonitor/stagemonitor

@Override
public void alert(AlertArguments alertArguments) {
  String target = alertArguments.getSubscription().getTarget();
  if (StringUtils.isEmpty(target)) {
    target = "/stagemonitor/alerts";
  }
  httpClient.send(HttpRequestBuilder.<Integer>jsonRequest("POST", corePlugin.getElasticsearchUrl() + target, alertArguments.getIncident()).build());
}
origin: org.stagemonitor/stagemonitor-jdbc

private String getSql(String prepared, String sql) {
  if (StringUtils.isEmpty(sql) || !jdbcPlugin.isCollectPreparedStatementParameters()) {
    sql = prepared;
  }
  return sql.trim();
}
org.stagemonitor.utilStringUtilsisEmpty

Popular methods of StringUtils

  • getLogstashStyleDate
  • isNotEmpty
  • sha1Hash
  • asCsv
  • removeStart
  • removeTrailingSlash
  • replaceWhitespacesWithDash
  • timestampAsIsoString
  • toCommaSeparatedString
  • bytesToHex
  • capitalize
  • dateAsIsoString
  • capitalize,
  • dateAsIsoString,
  • slugify,
  • split,
  • splitCamelCase

Popular in Java

  • Start an intent from android
  • startActivity (Activity)
  • getResourceAsStream (ClassLoader)
  • setRequestProperty (URLConnection)
  • Font (java.awt)
    The Font class represents fonts, which are used to render text in a visible way. A font provides the
  • Rectangle (java.awt)
    A Rectangle specifies an area in a coordinate space that is enclosed by the Rectangle object's top-
  • InputStreamReader (java.io)
    A class for turning a byte stream into a character stream. Data read from the source input stream is
  • SocketException (java.net)
    This SocketException may be thrown during socket creation or setting options, and is the superclass
  • MessageFormat (java.text)
    Produces concatenated messages in language-neutral way. New code should probably use java.util.Forma
  • CountDownLatch (java.util.concurrent)
    A synchronization aid that allows one or more threads to wait until a set of operations being perfor
  • From CI to AI: The AI layer in your organization
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now