Codota Logo
JSONArray.optBoolean
Code IndexAdd Codota to your IDE (free)

How to use
optBoolean
method
in
org.opencms.json.JSONArray

Best Java code snippets using org.opencms.json.JSONArray.optBoolean (Showing top 2 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
ScheduledThreadPoolExecutor s =
  • Codota Iconnew ScheduledThreadPoolExecutor(corePoolSize)
  • Codota IconThreadFactory threadFactory;new ScheduledThreadPoolExecutor(corePoolSize, threadFactory)
  • Codota IconString str;new ScheduledThreadPoolExecutor(1, new ThreadFactoryBuilder().setNameFormat(str).build())
  • Smart code suggestions by Codota
}
origin: org.opencms/opencms-core

/**
 * Get the optional boolean value associated with an index.<p>
 *
 * It returns false if there is no value at that index,
 * or if the value is not Boolean.TRUE or the String "true".<p>
 *
 * @param index the index must be between 0 and length() - 1
 * @return the truth
 */
public boolean optBoolean(int index) {
  return optBoolean(index, false);
}
origin: org.opencms/opencms-solr

/**
 * Get the optional boolean value associated with an index.<p>
 * 
 * It returns false if there is no value at that index,
 * or if the value is not Boolean.TRUE or the String "true".<p>
 *
 * @param index the index must be between 0 and length() - 1
 * @return the truth
 */
public boolean optBoolean(int index) {
  return optBoolean(index, false);
}
org.opencms.jsonJSONArrayoptBoolean

Javadoc

Get the optional boolean value associated with an index.

It returns false if there is no value at that index, or if the value is not Boolean.TRUE or the String "true".

Popular methods of JSONArray

  • <init>
    Construct a JSONArray from a JSONTokener.
  • toString
    Make a pretty printed JSON text of this JSONArray. Warning: This method assumes that the data struct
  • get
    Get the object value associated with an index.
  • getBoolean
    Get the boolean value associated with an index. The string values "true" and "false" are converted t
  • getDouble
    Get the double value associated with an index.
  • getInt
    Get the int value associated with an index.
  • getLong
    Get the long value associated with an index.
  • getString
    Get the string associated with an index.
  • join
    Make a string from the contents of this JSONArray. The separator string is inserted between each ele
  • length
    Get the number of elements in the JSONArray, included nulls.
  • opt
    Get the optional object value associated with an index.
  • optDouble
    Get the optional double value associated with an index. The defaultValue is returned if there is no
  • opt,
  • optDouble,
  • optInt,
  • optJSONObject,
  • optLong,
  • optString,
  • put,
  • toJSONObject,
  • write

Popular in Java

  • Reactive rest calls using spring rest template
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • startActivity (Activity)
  • scheduleAtFixedRate (Timer)
    Schedules the specified task for repeated fixed-rate execution, beginning after the specified delay.
  • ObjectMapper (com.fasterxml.jackson.databind)
    This mapper (or, data binder, or codec) provides functionality for converting between Java objects (
  • Path (java.nio.file)
  • Date (java.util)
    A specific moment in time, with millisecond precision. Values typically come from System#currentTime
  • TimerTask (java.util)
    A task that can be scheduled for one-time or repeated execution by a Timer.
  • TreeSet (java.util)
    A NavigableSet implementation based on a TreeMap. The elements are ordered using their Comparable, o
  • JFileChooser (javax.swing)
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