text:
from django import forms
import models
from usuarios import models as usuarios
from Piscix.middleware import get_current_user
from django_autocomplete.widgets import AutocompleteWidget
from exile_ui.widgets import DatePickerWidget
from django_select2.forms import Select2Widget

class SeguimientoForm(forms.ModelForm):
    class Meta:
        model = models.Seguimiento
        exclude = ('usuario', )
        widgets = {
            #"fecha_proxima": DatePickerWidget(attrs={'class': 'date'}, format="%m/%d/%Y
            "inicio": Select2Widget
        }
    # end class

    def save(self, commit=True):
        user = get_current_user()
        seguimiento = super(SeguimientoForm, self).save(commit=False)
        seguimiento.usuario = user
        seguimiento.save()
        return seguimiento
    # end defreporte
# end class

class InicioSeguimientoForm(forms.ModelForm):

    class Meta:
        model = models.InicioSeguimiento
        exclude = ('usuario', )
        widgets = {
            # "fecha_proxima": DatePickerWidget(attrs={'class': 'date'}, format="%m/%d/%Y"),
            "cliente": Select2Widget
        }
    # end class

    def __init__(self, *args, **kwargs):
        super(InicioSeguimientoForm, self).__init__(*args, **kwargs)
        self.fields['fecha_proxima'].input_formats = ['%d/%m/%Y']
    # end def

    def save(self, commit=True):
        user = get_current_user()
        seguimiento = super(InicioSeguimientoForm, self).save(commit=False)
        seguimiento.usuario = user
        seguimiento.save()
        return seguimiento
    # end defreporte
# end class


text:
package net.mentalarray.doozie

import scala.collection.mutable

/**
 * An iterable collection of WorkflowTasks.
 */
class TasksSequence extends Seq[WorkflowTask] {

  private val _tasks = mutable.MutableList.empty[WorkflowTask]

  /**
   * Operator '+=' appends a WorkflowTask to an existing TaskSequence.
   * @param nextTask The WorkflowTask to append.
   * @return The current instance of TaskSequence, which has the 'nextTask' appended to it.
   */
  def +=(nextTask: WorkflowTask) : TasksSequence = {
    _tasks += nextTask
    this
  }

  /**
   * Operator '++' concatenates two TaskSequences together.
   * @param taskSeq The TaskSequence to append.
   * @return The current instance of TaskSequence, which has been concatenated with 'taskSeq'.
   */
  def ++(taskSeq: Seq[WorkflowTask]) : TasksSequence = {
    taskSeq.map { _tasks += _ }
    this
  }

  /**
   * The number of items in this TaskSequence.
   * @return The integer number of items in this TaskSequence.
   */
  override def length: Int = _tasks.length

  /**
   * Indexer - used for retrieving items from the TaskSequence by index.
   * @param idx The integer index of the item within the TaskSequence to retrieve.
   * @return The instance of the WorkflowTask at the specified index.
   */
  override def apply(idx: Int): WorkflowTask = _tasks(idx)

  /**
   * An iterator over the TaskSequence.
   * @return The Iterator[WorkflowTask] instance.
   */
  override def iterator: Iterator[WorkflowTask] = _tasks.iterator

  /**
   * TaskSequence foreach extension.
   * @param f A function with takes each element of this TaskSequence to type 'U'.
   * @tparam U The resultant type of each iteration of the foreach function 'f'.
   */
  override def foreach[U](f: (WorkflowTask) => U): Unit = _tasks.foreach(f)
}

/**
 * Companion object for TaskSequence class.
 */
object TasksSequence {

  /**
   * Implicit conversion from a single WorkflowTask into a new TaskSequence of WorkflowTasks.
   * @param nextTask The initial WorkflowTask which will be inserted into a new TaskSequence.
   * @return An instance of TaskSequence.
   */
  implicit def taskToTasks(nextTask: WorkflowTask) : TasksSequence = {
    val tasks = new TasksSequence
    tasks += nextTask
    tasks
  }

  /**
   * Allows for creation of a new TaskSequence from an ensemble of WorkflowTasks.
   * @param tasksList An ensemble of WorkflowTasks, separated by commas.
   * @return
   */
  def apply(tasksList: WorkflowTask*) : TasksSequence = {
    val tasks = new TasksSequence
    tasks ++ tasksList
    tasks
  }

}

redpajama_set_name: RedPajamaGithub


text:
This is a simple tool to symbolically encode and detect deadlocks in Java multithreaded programs.
This tool is being used in the _Sherlock_ deadlock detector which is being presented in [FSE'14](http://fse22.gatech.edu/).
Requirements:
  - [Yices](http://yices.csl.sri.com/)
  - [Soot](https://sable.github.io/soot/)


text:
<!DOCTYPE html>

    <meta charset="utf-8">
    <title>JSDoc: Source: index.js</title>

    <link type="text/css" rel="stylesheet" href="styles/prettify-tomorrow.css">
    <link type="text/css" rel="stylesheet" href="styles/jsdoc-default.css">

Source: index.js

/**
 * WebMerge module.
 * @module webmerge
 */

'use strict'

const request = require('request')

const WEB_MERGE_BASE_URL = 'https://www.webmerge.me'
const API_ENDPOINT = '/api/documents'
const MERGE_ENDPOINT = '/merge'
const ROUTE_ENDPOINT = '/route'
const TOOLS_ENDPOINT = '/tools'

const done = callback => (err, response, body) => {
  if (err) throw err
  if ('error' in body) throw new Error(body.error)

  return callback(null, body)
}

/**
 * API client with a callback API
 */
class WebMergeAPI {

  /**
   * Create an API client that uses callbacks.
   * @param {string} key - API key
   * @param {string} secret - API secret
   */
  constructor(key, secret) {
    this.client = request.defaults({
      baseUrl: WEB_MERGE_BASE_URL,
      auth: {
        username: key,
        password: secret,
        sendImmediately: true,
      },
      json: true,
    })
  }

  /**
   * Retrieve a list of documents.
   * @param {Object} options
   * @param {string} [options.search] - Search term
   * @param {string} [options.folder] - Folder name
   * @param callback
   */
  getDocuments(options, callback) {
    return this.client.get({
      url: `${API_ENDPOINT}`,
      qs: options,
    }, done(callback))
  }

  /**
   * Retrieve a specific document.
   * @param {number} id - Document ID
   * @param callback
   */
  getDocument(id, callback) {
    return this.client.get({
      url: `${API_ENDPOINT}/${id}`,
    }, done(callback))
  }

  /**
   * Retrieve a list of fields for a specific document.
   * @param {number} id - Document ID
   * @param callback
   */
  getDocumentFields(id, callback) {
    return this.client.get({
      url: `${API_ENDPOINT}/${id}/fields`,
    }, done(callback))
  }

  /**
   * Retrieve the file that was uploaded for a specific document (pdf, docx, xlsx, or pptx).
   * @param {number} id - Document ID
   * @param callback
   */
  getDocumentFiles(id, callback) {
    return this.client.get({
      url: `${API_ENDPOINT}/${id}/file`,
    }, done(callback))
  }

  /**
   * Create a new document.
   * Depending on the type of document you are creating, different parameters are required
   * @param {Object} data - See {@link https://www.webmerge.me/developers/documents}
   * @param {string} data.name - Document name
   * @param {string} data.type - The type of document
   * @param {string} data.output - The type of document to produce from merge
   * @param {string} [data.output_name] - A customized filename for the merged document
   * @param {string} [data.folder] - The name of the folder to save the document in.
   * @param {string} [data.html] - The HTML of the document (required if data.type == 'html')
   * @param {number} [data.size_width] - The width of the document (required if data.type == 'html')
   * @param {number} [data.size_height] - The height of the document (required if data.type == 'html')
   * @param {string} [data.file_contents] - The (base64 encoded) contents of the file (required if data.type != 'html')
   * @param {Object} [data.notification] - The default email notification
   * @param {string} [data.notification.to]
   * @param {string} [data.notification.from]
   * @param {string} [data.notification.subject]
   * @param {string} [data.notification.html]
   * @param {string} [data.notification.security]
   * @param {string} [data.notification.password]
   * @param callback
   */
  createDocument(data, callback) {
    return this.client.post({
      url: `${API_ENDPOINT}`,
      body: data,
    }, done(callback))
  }

  /**
   * Update a document.
   * You cannot change the type of document, but you can change many of the other settings as well as change the
   * contents of the document. Only parameters that are sent in the request will be updated.
   * @param {number} id - Document ID
   * @param {Object} data
   * @param callback
   */
  updateDocument(id, data, callback) {
    return this.client.put({
      url: `${API_ENDPOINT}/${id}`,
      body: data,
    }, done(callback))
  }

  /**
   * Merge a document.
   * @param {number} id - Document ID
   * @param {string} key - Document key
   * @param {Object} data - Data to be merged
   * @param {boolean} isTestMode - Merge the document in "test" mode
   * @param {boolean} downloadFile - Return the merged document in response
   * @param callback
   */
  mergeDocument(id, key, data, isTestMode, downloadFile, callback) {
    return this.client.post({
      url: `${MERGE_ENDPOINT}/${id}/${key}`,
      qs: {
        test: isTestMode ? 1 : 0,
        download: downloadFile ? 1 : 0,
      },
      body: data,
    }, done(callback))
  }

  /**
   * Create a copy of a document.
   * @param {number} id - Document ID
   * @param {Object} data
   * @param {string} data.name - Name of the new document
   * @param callback
   */
  copyDocument(id, data, callback) {
    return this.client.post({
      url: `${API_ENDPOINT}/${id}/copy`,
      body: data,
    }, done(callback))
  }

  /**
   * Delete a document.
   * @param {number} id - Document ID
   * @param callback
   */
  deleteDocument(id, callback) {
    return this.client.delete({
      url: `${API_ENDPOINT}/${id}`,
    }, done(callback))
  }

  /**
   * Retrieve a list of data routes.
   * @param callback
   */
  getDataRoutes(callback) {
    return this.client.get({
      url: `${ROUTE_ENDPOINT}`,
    }, done(callback))
  }

  /**
   * Retrieve a specific data route.
   * @param {number} id - Data Route ID
   * @param callback
   */
  getDataRoute(id, callback) {
    return this.client.get({
      url: `${ROUTE_ENDPOINT}/${id}`,
    }, done(callback))
  }

  /**
   * Retrieve a list of fields for a specific data route.
   * This includes fields from all documents in routing rules.
   * @param {number} id - Data Route ID
   * @param callback
   */
  getDataRouteFields(id, callback) {
    return this.client.get({
      url: `${ROUTE_ENDPOINT}/${id}/fields`,
    }, done(callback))
  }

  /**
   * Retrieve a list of rules for a specific data route.
   * @param {number} id - Data Route ID
   * @param callback
   */
  getDataRouteRules(id, callback) {
    return this.client.get({
      url: `${ROUTE_ENDPOINT}/${id}/rules`,
    }, done(callback))
  }

  /**
   * Merge a data route.
   * @param {number} id - Document ID
   * @param {string} key - Document key
   * @param {Object} data - Data to be merged
   * @param {boolean} isTestMode - Merge the document in "test" mode
   * @param {boolean} downloadFile - Return the merged document in response
   * @param callback
   */
  mergeDataRoute(id, key, data, isTestMode, downloadFile, callback) {
    return this.client.post({
      url: `${ROUTE_ENDPOINT}/${id}/${key}`,
      qs: {
        test: isTestMode ? 1 : 0,
        download: downloadFile ? 1 : 0,
      },
      body: data,
    }, done(callback))
  }

  /**
   * Create a new data route.
   * @param {Object} data - https://www.webmerge.me/developers/routes
   * @param callback
   */
  createDataRoute(data, callback) {
    return this.client.post({
      url: `${ROUTE_ENDPOINT}`,
      body: data,
    }, done(callback))
  }

  /**
   * Update a data route.
   * @param {number} id - Data Route ID
   * @param {Object} data
   * @param callback
   */
  updateDataRoute(id, data, callback) {
    return this.client.put({
      url: `${ROUTE_ENDPOINT}/${id}`,
      body: data,
    }, done(callback))
  }

  /**
   * Delete a data route.
   * @param {number} id - Data Route ID
   * @param callback
   */
  deleteDataRoute(id, callback) {
    return this.client.delete({
      url: `${ROUTE_ENDPOINT}/${id}`,
    }, done(callback))
  }

  /**
   * Combine multiple files (pages) into a single file.
   * See {@link https://www.webmerge.me/developers/tools}
   * @param {Object} data
   * @param {string} data.output - The type of file to produce
   * @param {Object[]} data.files - The files to be combined
   * @param {string} data.files[].name - File Name
   * @param {string} data.files[].url - Remote File URL (required if 'contents' is empty)
   * @param {string} data.files[].contents - Base64-encoded file (required if 'url' is empty)
   * @param callback
   */
  combineFiles(data, callback) {
    return this.client.post({
      url: `${TOOLS_ENDPOINT}/combine`,
      body: data,
    }, done(callback))
  }

  /**
   * Convert file to PDF.
   * @param {Object} data
   * @param {Object} data.file
   * @param {string} data.file.name - File Name
   * @param {string} data.file.url - Remote File URL (required if 'contents' is empty)
   * @param {string} data.file.contents - Base64-encoded file (required if 'url' is empty)
   * @param callback
   */
  convertToPDF(data, callback) {
    return this.client.post({
      url: `${TOOLS_ENDPOINT}/convert_to_pdf`,
      body: data,
    }, done(callback))
  }
}

/**
 * API client with a Promise API
 * @extends WebMergeAPI
 */
class WebMergePromiseAPI extends WebMergeAPI {

  /**
   * Create an API client that uses Promises.
   * @param {string} key - API key
   * @param {string} secret - API secret
   * @param {Function} [PromiseImplementation] - Promise Constructor
   */
  constructor(key, secret, PromiseImplementation) {
    super(key, secret)
    this.Promise = PromiseImplementation || Promise
  }

  /**
   * Retrieve a list of documents.
   * @param {Object} options
   * @param {string} options.search - Search term
   * @param {string} options.folder - Folder name
   */
  getDocuments(options) {
    return this.promisify(cb => super.getDocuments(options, cb))
  }

  /**
   * Retrieve a specific document.
   * @param {number} id - Document ID
   */
  getDocument(id) {
    return this.promisify(cb => super.getDocument(id, cb))
  }

  /**
   * Retrieve a list of fields for a specific document.
   * @param id - Document ID
   */
  getDocumentFields(id) {
    return this.promisify(cb => super.getDocumentFields(id, cb))
  }

  /**
   * Retrieve the file that was uploaded for a specific document (pdf, docx, xlsx, or pptx).
   * @param id - Document ID
   */
  getDocumentFiles(id) {
    return this.promisify(cb => super.getDocumentFiles(id, cb))
  }

  /**
   * Create a new document.
   * Depending on the type of document you are creating, different parameters are required
   * @param {Object} data - See {@link https://www.webmerge.me/developers/documents}
   */
  createDocument(data) {
    return this.promisify(cb => super.createDocument(data, cb))
  }

  /**
   * Update a document.
   * You cannot change the type of document, but you can change many of the other settings as well as change the
   * contents of the document. Only parameters that are sent in the request will be updated.
   * @param {number} id - Document ID
   * @param data
   */
  updateDocument(id, data) {
    return this.promisify(cb => super.updateDocument(id, data, cb))
  }

  /**
   * Merge a data route.
   * @param {number} id - Document ID
   * @param {string} key - Document key
   * @param {Object} data - Data to be merged
   * @param {boolean} isTestMode - Merge the document in "test" mode
   * @param {boolean} downloadFile - Return the merged document in response
   */
  mergeDocument(id, key, data, isTestMode, downloadFile) {
    return this.promisify(cb => super.mergeDocument(id, key, data, isTestMode, downloadFile, cb))
  }

  /**
   * Create a copy of a document.
   * @param {number} id - Document ID
   * @param {Object} data
   * @param {string} data.name - Name of the new document
   */
  copyDocument(id, data) {
    return this.promisify(cb => super.copyDocument(id, data, cb))
  }

  /**
   * Delete a document.
   * @param {number} id - Document ID
   */
  deleteDocument(id) {
    return this.promisify(cb => super.deleteDocument(id, cb))
  }

  /**
   * Retrieve a list of data routes.
   */
  getDataRoutes() {
    return this.promisify(cb => super.getDataRoutes(cb))
  }

  /**
   * Retrieve a specific data route.
   * @param {number} id - Data Route ID
   */
  getDataRoute(id) {
    return this.promisify(cb => super.getDataRoute(id, cb))
  }

  /**
   * Retrieve a list of fields for a specific data route.
   * This includes fields from all documents in routing rules.
   * @param {number} id - Data Route ID
   */
  getDataRouteFields(id) {
    return this.promisify(cb => super.getDataRouteFields(id, cb))
  }

  /**
   * Retrieve a list of rules for a specific data route.
   * @param {number} id - Data Route ID
   */
  getDataRouteRules(id) {
    return this.promisify(cb => super.getDataRouteRules(id, cb))
  }

  /**
   * Merge a data route.
   * @param {number} id - Document ID
   * @param {string} key - Document key
   * @param {Object} data - Data to be merged
   * @param {boolean} isTestMode - Merge the document in "test" mode
   * @param {boolean} downloadFile - Return the merged document in response
   */
  mergeDataRoute(id, key, data, isTestMode, downloadFile) {
    return this.promisify(cb => super.mergeDataRoute(id, key, data, isTestMode, downloadFile, cb))
  }

  /**
   * Create a new data route.
   * @param {Object} data - https://www.webmerge.me/developers/routes
   */
  createDataRoute(data) {
    return this.promisify(cb => super.createDataRoute(data, cb))
  }

  /**
   * Update a data route.
   * @param {number} id - Data Route ID
   * @param {Object} data
   */
  updateDataRoute(id, data) {
    return this.promisify(cb => super.updateDataRoute(id, data, cb))
  }

  /**
   * Delete a data route.
   * @param {number} id - Data Route ID
   */
  deleteDataRoute(id) {
    return this.promisify(cb => super.deleteDataRoute(id, cb))
  }

  /**
   * Combine multiple files (pages) into a single file.
   * See {@link https://www.webmerge.me/developers/tools}
   * @param {Object} data
   * @param {string} data.output - The type of file to produce
   * @param {Object[]} data.files - The files to be combined
   * @param {string} data.files[].name - File Name
   * @param {string} [data.files[].url] - Remote File URL (required if 'contents' is empty)
   * @param {string} [data.files[].contents] - Base64-encoded file (required if 'url' is empty)
   */
  combineFiles(data) {
    return this.promisify(cb => super.combineFiles(data, cb))
  }

  /**
   * Convert file to PDF
   * @param {Object} data
   * @param {Object} data.file
   * @param {string} data.file.name - File Name
   * @param {string} [data.file.url] - Remote File URL (required if 'contents' is empty)
   * @param {string} [data.file.contents] - Base64-encoded file (required if 'url' is empty)
   */
  convertToPDF(data) {
    return this.promisify(cb => super.convertToPDF(data, cb))
  }

  /**
   * Utility function to promisify a callback function
   * @param fn - Callback function
   * @returns {Promise}
   */
  promisify(fn) {
    return new this.Promise((resolve, reject) => {
      fn((err, response) => {
        if (err) return reject(err)
        return resolve(response)
      })
    })
  }
}

module.exports = {
  WebMergeAPI,
  WebMergePromiseAPI,
}

Home

Modules

webmerge

Classes

WebMergeAPI

WebMergePromiseAPI

    Documentation generated by JSDoc 3.4.3 on Fri Jun 09 2017 05:48:33 GMT+1000 (AEST)


text:
<!DOCTYPE html>

	<meta name="google-site-verification" content="iXeuDSWh4LPaiEFS54cAl5IWl1JyGEuqh-KAXFRFH_Q"/>
    <title>sman dua bogor</title>

    <link href="http://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">

    <link rel="stylesheet" href="<?php echo base_url();?>assets/dropzone/demos.css">
    <link rel="stylesheet" href="<?php echo base_url();?>assets/css/materialize.css"  media="screen,projection" type="text/css"/>

    <meta charset="utf-8"  name="viewport" content="width=device-width, initial-scale=1.0"/>

    <link href='https://fonts.googleapis.com/css?family=Raleway:400,700' rel='stylesheet' type='text/css'>

selamat datang!

<img src="<?php echo base_url();?>assets/img/parallax1_1.png">

            <form class="col s12" action="<?php echo base_url();?>home/opsi" method="post">

                         <input name="email" type="text" placeholder="e.g. fikry@seveid.com">
                         Email

                         <input  name="password" type="password" placeholder="*****">
                         Password

                       <button type="submit" class="btn" style="margin-top: 2em">LOGIN</button>
            </form>

SMAN 2 BOGOR | fikry.labsky08@gmail.com


text:
title: Welcome
chapter: true
weight: 0
---

### Welcome to R4All

We specialise in teaching R to those who've never used it before. Just as good is if you've used it, or are using it, but want to improve your foundation and workflow.

A tried and tested course, The Booster Course, helps you up the initially steep learning curve, while providing an efficient, reliable, and simple method for using R.

Our book, [Getting Started with R, An Introduction for Biologists, Second Edition](../the-book), is great for those who can't (or don't want to) take a course with us.

<img src="images/SecondEd.png" alt="Drawing" style="width: 200px;"/>


text:
SYNONYM

#### According to
The Catalogue of Life, 3rd January 2011

#### Published in
Bull. Soc. mycol. Fr. 11: 85 (1895)

#### Original name
Lentinus dybowskii Pat., 1895

### Remarks
null


text:
<!doctype html>

<meta charset="utf-8">
<title>定制管理 -
<@cm.sysName />
</title>
<@cm.css />
<@cm.javascript />

  <@cm.top />
  <form id="searchForm" name="searchForm" method="post" action="" class="form-inline form-search">

 目的地
      <select name="destination" id="destination" class="form-control input-sm required">
        <option value="">-请选择-</option>
        <@ValueSet code="destination" value="${RequestParameters.destination!}" />
      </select>

 关键字
      <input type="text" class="form-control input-sm" name="keyword" id="keyword"  value="${RequestParameters.keyword!}" placeholder="请输入关键字">

    <button type="button" class="searchBtn btn btn-primary btn-sm">  搜索 </button>
  </form>
  <form id="controlForm" name="controlForm" method="post" action="">

 定制列表

  修改   新增   删除

            编号
            目的地
            标题

        <#list retList as item>

          <input type="checkbox" name="id" id="id" value="${item.id}">
          ${item.id!}
          <@ValueSetWrite code="destination" value="${item.destination!}" />
          ${item.title1!}

        </#list>

  </form>
  <@cm.page />
  <@cm.bottom />


text:
package com.navercorp.pinpoint.plugin.jetty;

import com.navercorp.pinpoint.bootstrap.config.ExcludePathFilter;
import com.navercorp.pinpoint.bootstrap.config.Filter;
import com.navercorp.pinpoint.bootstrap.config.ProfilerConfig;
import com.navercorp.pinpoint.bootstrap.config.SkipFilter;

import java.util.List;

public class JettyConfiguration {

    private final boolean jettyEnabled;
    private final List<String> jettyBootstrapMains;
    private final Filter<String> jettyExcludeUrlFilter;
    private final boolean hidePinpointHeader;

    public JettyConfiguration(ProfilerConfig config) {
        this.jettyEnabled = config.readBoolean("profiler.jetty.enable", true);
        this.jettyBootstrapMains = config.readList("profiler.jetty.bootstrap.main");
        final String jettyExcludeURL = config.readString("profiler.jetty.excludeurl", "");

        if (!jettyExcludeURL.isEmpty()) {
            this.jettyExcludeUrlFilter = new ExcludePathFilter(jettyExcludeURL);
        } else {
            this.jettyExcludeUrlFilter = new SkipFilter<String>();
        }
        boolean hidePinpointHeader = config.readBoolean("profiler.jetty.hide-pinpoint-header", true);
        if (hidePinpointHeader) {
            hidePinpointHeader = config.readBoolean("profiler.jetty.hidepinpointheader", true);
        }
        this.hidePinpointHeader = hidePinpointHeader;
    }

    public boolean isJettyEnabled() {
        return jettyEnabled;
    }

    public List<String> getJettyBootstrapMains() {
        return jettyBootstrapMains;
    }

    public Filter<String> getJettyExcludeUrlFilter() {
        return jettyExcludeUrlFilter;
    }

    public boolean isHidePinpointHeader() {
        return hidePinpointHeader;
    }
}


text:
namespace rocksdb {

#ifndef ROCKSDB_LITE
// Take a map of option name and option value, apply them into the
// base_options, and return the new options as a result
Status GetColumnFamilyOptionsFromMap(
    const ColumnFamilyOptions& base_options,
    const std::unordered_map<std::string, std::string>& opts_map,
    ColumnFamilyOptions* new_options);

Status GetDBOptionsFromMap(
    const DBOptions& base_options,
    const std::unordered_map<std::string, std::string>& opts_map,
    DBOptions* new_options);

Status GetBlockBasedTableOptionsFromMap(
    const BlockBasedTableOptions& table_options,
    const std::unordered_map<std::string, std::string>& opts_map,
    BlockBasedTableOptions* new_table_options);

// Take a string representation of option names and  values, apply them into the
// base_options, and return the new options as a result. The string has the
// following format:
//   "write_buffer_size=1024;max_write_buffer_number=2"
// Nested options config is also possible. For example, you can define
// BlockBasedTableOptions as part of the string for block-based table factory:
//   "write_buffer_size=1024;block_based_table_factory={block_size=4k};"
//   "max_write_buffer_num=2"
Status GetColumnFamilyOptionsFromString(
    const ColumnFamilyOptions& base_options,
    const std::string& opts_str,
    ColumnFamilyOptions* new_options);

Status GetDBOptionsFromString(
    const DBOptions& base_options,
    const std::string& opts_str,
    DBOptions* new_options);

Status GetBlockBasedTableOptionsFromString(
    const BlockBasedTableOptions& table_options,
    const std::string& opts_str,
    BlockBasedTableOptions* new_table_options);

Status GetOptionsFromString(const Options& base_options,
                            const std::string& opts_str, Options* new_options);

/// Request stopping background work, if wait is true wait until it's done
void CancelAllBackgroundWork(DB* db, bool wait = false);
#endif  // ROCKSDB_LITE

}  // namespace rocksdb


text:
package com.hazelcast.client.impl.protocol.task.map;

import com.hazelcast.client.impl.protocol.ClientMessage;
import com.hazelcast.client.impl.protocol.codec.MapPutIfAbsentWithMaxIdleCodec;
import com.hazelcast.instance.Node;
import com.hazelcast.map.impl.operation.MapOperation;
import com.hazelcast.map.impl.operation.MapOperationProvider;
import com.hazelcast.nio.Connection;
import com.hazelcast.spi.Operation;

import java.util.concurrent.TimeUnit;

public class MapPutIfAbsentWithMaxIdleMessageTask
        extends AbstractMapPutWithMaxIdleMessageTask<MapPutIfAbsentWithMaxIdleCodec.RequestParameters> {

    public MapPutIfAbsentWithMaxIdleMessageTask(ClientMessage clientMessage, Node node, Connection connection) {
        super(clientMessage, node, connection);
    }

    @Override
    protected MapPutIfAbsentWithMaxIdleCodec.RequestParameters decodeClientMessage(ClientMessage clientMessage) {
        return MapPutIfAbsentWithMaxIdleCodec.decodeRequest(clientMessage);
    }

    @Override
    protected ClientMessage encodeResponse(Object response) {
        return MapPutIfAbsentWithMaxIdleCodec.encodeResponse(serializationService.toData(response));
    }

    protected Operation prepareOperation() {
        MapOperationProvider operationProvider = getMapOperationProvider(parameters.name);
        MapOperation op = operationProvider.createPutIfAbsentOperation(parameters.name, parameters.key,
                parameters.value, parameters.ttl, parameters.maxIdle);
        op.setThreadId(parameters.threadId);
        return op;
    }

    @Override
    public String getDistributedObjectName() {
        return parameters.name;
    }

    @Override
    public String getMethodName() {
        return "putIfAbsent";
    }

    @Override
    public Object[] getParameters() {
        return new Object[]{parameters.key, parameters.value, parameters.ttl, TimeUnit.MILLISECONDS,
                parameters.maxIdle, TimeUnit.MILLISECONDS};
    }
}


text:
/*
 * Lob
 * The Lob API is organized around REST. Our API is designed to have predictable, resource-oriented URLs and uses HTTP response codes to indicate any API errors.
 Looking for our [previous documentation](https://lob.github.io/legacy-docs/)?
 *
 * The version of the OpenAPI document: 1.3.0
 * Contact: lob-openapi@lob.com
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */

package com.lob.api.client;

import com.lob.api.ApiCallback;
import com.lob.api.ApiClient;
import com.lob.api.ApiException;
import com.lob.api.ApiResponse;
import com.lob.api.Configuration;
import com.lob.api.Pair;
import com.lob.api.ProgressRequestBody;
import com.lob.api.ProgressResponseBody;

import com.google.gson.reflect.TypeToken;

import java.io.IOException;

import com.lob.model.Letter;
import com.lob.model.LetterDeletion;
import com.lob.model.LetterEditable;
import com.lob.model.LetterList;
import com.lob.model.LobError;
import com.lob.model.MailType;
import java.time.OffsetDateTime;
import com.lob.model.SortBy3;

import java.lang.reflect.Type;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

public class LettersApi {
    private ApiClient localVarApiClient;

    public LettersApi() {
        this(Configuration.getDefaultApiClient());
    }

    public LettersApi(ApiClient apiClient) {
        this.localVarApiClient = apiClient;
    }

    public ApiClient getApiClient() {
        return localVarApiClient;
    }

    public void setApiClient(ApiClient apiClient) {
        this.localVarApiClient = apiClient;
    }

    /**
     * Build call for cancel
     * @param ltrId id of the letter (required)
     * @param _callback Callback for upload/download progress
     * @return Call to execute
     * @throws ApiException If fail to serialize the request body object
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 Deleted 	  -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public okhttp3.Call cancelCall(String ltrId, final ApiCallback _callback) throws ApiException {
        Object localVarPostBody = null;

        // create path and map variables
        String localVarPath = "/letters/{ltr_id}"
            .replaceAll("\\{" + "ltr_id" + "\\}", localVarApiClient.escapeString(ltrId.toString()));

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        final String[] localVarAccepts = {
            "application/json"
        };
        final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
        if (localVarAccept != null) {
            localVarHeaderParams.put("Accept", localVarAccept);
        }

        final String[] localVarContentTypes = {

        };
        final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
        localVarHeaderParams.put("Content-Type", localVarContentType);

        String[] localVarAuthNames = new String[] { "basicAuth" };
        return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @SuppressWarnings("rawtypes")
    private okhttp3.Call cancelValidateBeforeCall(String ltrId, final ApiCallback _callback) throws ApiException {

        // verify the required parameter 'ltrId' is set
        if (ltrId == null) {
            throw new ApiException("Missing the required parameter 'ltrId' when calling cancel(Async)");
        }

        okhttp3.Call localVarCall = cancelCall(ltrId, _callback);
        return localVarCall;

    }

    /**
     * cancel
     * Completely removes a letter from production. This can only be done if the letter has a `send_date` and the `send_date` has not yet passed. If the letter is successfully canceled, you will not be charged for it. Read more on [cancellation windows](#section/Cancellation-Windows) and [scheduling](#section/Scheduled-Mailings). Scheduling and cancellation is a premium feature. Upgrade to the appropriate [Print & Mail Edition](https://dashboard.lob.com/#/settings/editions) to gain access.
     * @param ltrId id of the letter (required)
     * @return LetterDeletion
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 Deleted 	  -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public LetterDeletion cancel(String ltrId) throws ApiException {
        try {
            ApiResponse<LetterDeletion> localVarResp = cancelWithHttpInfo(ltrId);
            return localVarResp.getData();
        } catch (ApiException e) {
            throw e;
        }
    }

    /**
     * cancel
     * Completely removes a letter from production. This can only be done if the letter has a `send_date` and the `send_date` has not yet passed. If the letter is successfully canceled, you will not be charged for it. Read more on [cancellation windows](#section/Cancellation-Windows) and [scheduling](#section/Scheduled-Mailings). Scheduling and cancellation is a premium feature. Upgrade to the appropriate [Print & Mail Edition](https://dashboard.lob.com/#/settings/editions) to gain access.
     * @param ltrId id of the letter (required)
     * @return ApiResponse<LetterDeletion>
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 Deleted 	  -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public ApiResponse<LetterDeletion> cancelWithHttpInfo(String ltrId) throws ApiException {
        try {
            okhttp3.Call localVarCall = cancelValidateBeforeCall(ltrId, null);
            Type localVarReturnType = new TypeToken<LetterDeletion>(){}.getType();
            return localVarApiClient.execute(localVarCall, localVarReturnType);
        } catch (ApiException e) {
            throw e;
        }
    }

    /**
     * cancel (asynchronously)
     * Completely removes a letter from production. This can only be done if the letter has a `send_date` and the `send_date` has not yet passed. If the letter is successfully canceled, you will not be charged for it. Read more on [cancellation windows](#section/Cancellation-Windows) and [scheduling](#section/Scheduled-Mailings). Scheduling and cancellation is a premium feature. Upgrade to the appropriate [Print & Mail Edition](https://dashboard.lob.com/#/settings/editions) to gain access.
     * @param ltrId id of the letter (required)
     * @param _callback The callback to be executed when the API call finishes
     * @return The request call
     * @throws ApiException If fail to process the API call, e.g. serializing the request body object
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 Deleted 	  -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public okhttp3.Call cancelAsync(String ltrId, final ApiCallback<LetterDeletion> _callback) throws ApiException {

        okhttp3.Call localVarCall = cancelValidateBeforeCall(ltrId, _callback);
        Type localVarReturnType = new TypeToken<LetterDeletion>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
    /**
     * Build call for create
     * @param letterEditable  (required)
     * @param idempotencyKey A string of no longer than 256 characters that uniquely identifies this resource. For more help integrating idempotency keys, refer to our [implementation guide](https://www.lob.com/guides#idempotent_request).  (optional)
     * @param _callback Callback for upload/download progress
     * @return Call to execute
     * @throws ApiException If fail to serialize the request body object
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 Returns a letter object 	  * ratelimit-limit -
  * ratelimit-remaining -
  * ratelimit-reset -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public okhttp3.Call createCall(LetterEditable letterEditable, String idempotencyKey, final ApiCallback _callback) throws ApiException {
        Object localVarPostBody = letterEditable;

        // create path and map variables
        String localVarPath = "/letters";

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        if (idempotencyKey != null) {
            localVarHeaderParams.put("Idempotency-Key", localVarApiClient.parameterToString(idempotencyKey));
        }

        final String[] localVarAccepts = {
            "application/json"
        };
        final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
        if (localVarAccept != null) {
            localVarHeaderParams.put("Accept", localVarAccept);
        }

        final String[] localVarContentTypes = {
            "application/json", "application/x-www-form-urlencoded", "multipart/form-data"
        };
        final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
        localVarHeaderParams.put("Content-Type", localVarContentType);

        String[] localVarAuthNames = new String[] { "basicAuth" };
        return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @SuppressWarnings("rawtypes")
    private okhttp3.Call createValidateBeforeCall(LetterEditable letterEditable, String idempotencyKey, final ApiCallback _callback) throws ApiException {

        // verify the required parameter 'letterEditable' is set
        if (letterEditable == null) {
            throw new ApiException("Missing the required parameter 'letterEditable' when calling create(Async)");
        }

        okhttp3.Call localVarCall = createCall(letterEditable, idempotencyKey, _callback);
        return localVarCall;

    }

    /**
     * create
     * Creates a new letter given information
     * @param letterEditable  (required)
     * @param idempotencyKey A string of no longer than 256 characters that uniquely identifies this resource. For more help integrating idempotency keys, refer to our [implementation guide](https://www.lob.com/guides#idempotent_request).  (optional)
     * @return Letter
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 Returns a letter object 	  * ratelimit-limit -
  * ratelimit-remaining -
  * ratelimit-reset -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public Letter create(LetterEditable letterEditable, String idempotencyKey) throws ApiException {
        try {
            ApiResponse<Letter> localVarResp = createWithHttpInfo(letterEditable, idempotencyKey);
            return localVarResp.getData();
        } catch (ApiException e) {
            throw e;
        }
    }

    /**
     * create
     * Creates a new letter given information
     * @param letterEditable  (required)
     * @param idempotencyKey A string of no longer than 256 characters that uniquely identifies this resource. For more help integrating idempotency keys, refer to our [implementation guide](https://www.lob.com/guides#idempotent_request).  (optional)
     * @return ApiResponse<Letter>
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 Returns a letter object 	  * ratelimit-limit -
  * ratelimit-remaining -
  * ratelimit-reset -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public ApiResponse<Letter> createWithHttpInfo(LetterEditable letterEditable, String idempotencyKey) throws ApiException {
        try {
            okhttp3.Call localVarCall = createValidateBeforeCall(letterEditable, idempotencyKey, null);
            Type localVarReturnType = new TypeToken<Letter>(){}.getType();
            return localVarApiClient.execute(localVarCall, localVarReturnType);
        } catch (ApiException e) {
            throw e;
        }
    }

    /**
     * create (asynchronously)
     * Creates a new letter given information
     * @param letterEditable  (required)
     * @param idempotencyKey A string of no longer than 256 characters that uniquely identifies this resource. For more help integrating idempotency keys, refer to our [implementation guide](https://www.lob.com/guides#idempotent_request).  (optional)
     * @param _callback The callback to be executed when the API call finishes
     * @return The request call
     * @throws ApiException If fail to process the API call, e.g. serializing the request body object
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 Returns a letter object 	  * ratelimit-limit -
  * ratelimit-remaining -
  * ratelimit-reset -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public okhttp3.Call createAsync(LetterEditable letterEditable, String idempotencyKey, final ApiCallback<Letter> _callback) throws ApiException {

        okhttp3.Call localVarCall = createValidateBeforeCall(letterEditable, idempotencyKey, _callback);
        Type localVarReturnType = new TypeToken<Letter>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
    /**
     * Build call for get
     * @param ltrId id of the letter (required)
     * @param _callback Callback for upload/download progress
     * @return Call to execute
     * @throws ApiException If fail to serialize the request body object
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 Returns a letter object 	  -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public okhttp3.Call getCall(String ltrId, final ApiCallback _callback) throws ApiException {
        Object localVarPostBody = null;

        // create path and map variables
        String localVarPath = "/letters/{ltr_id}"
            .replaceAll("\\{" + "ltr_id" + "\\}", localVarApiClient.escapeString(ltrId.toString()));

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        final String[] localVarAccepts = {
            "application/json"
        };
        final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
        if (localVarAccept != null) {
            localVarHeaderParams.put("Accept", localVarAccept);
        }

        final String[] localVarContentTypes = {

        };
        final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
        localVarHeaderParams.put("Content-Type", localVarContentType);

        String[] localVarAuthNames = new String[] { "basicAuth" };
        return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @SuppressWarnings("rawtypes")
    private okhttp3.Call getValidateBeforeCall(String ltrId, final ApiCallback _callback) throws ApiException {

        // verify the required parameter 'ltrId' is set
        if (ltrId == null) {
            throw new ApiException("Missing the required parameter 'ltrId' when calling get(Async)");
        }

        okhttp3.Call localVarCall = getCall(ltrId, _callback);
        return localVarCall;

    }

    /**
     * get
     * Retrieves the details of an existing letter. You need only supply the unique letter identifier that was returned upon letter creation.
     * @param ltrId id of the letter (required)
     * @return Letter
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 Returns a letter object 	  -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public Letter get(String ltrId) throws ApiException {
        try {
            ApiResponse<Letter> localVarResp = getWithHttpInfo(ltrId);
            return localVarResp.getData();
        } catch (ApiException e) {
            throw e;
        }
    }

    /**
     * get
     * Retrieves the details of an existing letter. You need only supply the unique letter identifier that was returned upon letter creation.
     * @param ltrId id of the letter (required)
     * @return ApiResponse<Letter>
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 Returns a letter object 	  -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public ApiResponse<Letter> getWithHttpInfo(String ltrId) throws ApiException {
        try {
            okhttp3.Call localVarCall = getValidateBeforeCall(ltrId, null);
            Type localVarReturnType = new TypeToken<Letter>(){}.getType();
            return localVarApiClient.execute(localVarCall, localVarReturnType);
        } catch (ApiException e) {
            throw e;
        }
    }

    /**
     * get (asynchronously)
     * Retrieves the details of an existing letter. You need only supply the unique letter identifier that was returned upon letter creation.
     * @param ltrId id of the letter (required)
     * @param _callback The callback to be executed when the API call finishes
     * @return The request call
     * @throws ApiException If fail to process the API call, e.g. serializing the request body object
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 Returns a letter object 	  -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public okhttp3.Call getAsync(String ltrId, final ApiCallback<Letter> _callback) throws ApiException {

        okhttp3.Call localVarCall = getValidateBeforeCall(ltrId, _callback);
        Type localVarReturnType = new TypeToken<Letter>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
    /**
     * Build call for list
     * @param limit How many results to return. (optional, default to 10)
     * @param before A reference to a list entry used for paginating to the previous set of entries. This field is pre-populated in the `previous_url` field in the return response.  (optional)
     * @param after A reference to a list entry used for paginating to the next set of entries. This field is pre-populated in the `next_url` field in the return response.  (optional)
     * @param include Request that the response include the total count by specifying `include[]=total_count`.  (optional)
     * @param dateCreated Filter by date created. (optional)
     * @param metadata Filter by metadata key-value pair`. (optional)
     * @param color Set to `true` to return only color letters. Set to `false` to return only black & white letters. (optional)
     * @param scheduled * `true` - only return orders (past or future) where `send_date` is greater than `date_created` * `false` - only return orders where `send_date` is equal to `date_created`  (optional)
     * @param sendDate Filter by date sent. (optional)
     * @param mailType A string designating the mail postage type: * `usps_first_class` - (default) * `usps_standard` - a [cheaper option](https://lob.com/pricing/print-mail#compare) which is less predictable and takes longer to deliver. `usps_standard` cannot be used with `4x6` postcards or for any postcards sent outside of the United States.  (optional, default to usps_first_class)
     * @param sortBy Sorts items by ascending or descending dates. Use either `date_created` or `send_date`, not both.  (optional)
     * @param _callback Callback for upload/download progress
     * @return Call to execute
     * @throws ApiException If fail to serialize the request body object
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 A dictionary with a data property that contains an array of up to `limit` letters. Each entry in the array is a separate letter. The previous and next page of letters can be retrieved by calling the endpoint contained in the `previous_url` and `next_url` fields in the API response respectively. If no more letters are available beyond the current set of returned results, the `next_url` field will be empty. 	  -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public okhttp3.Call listCall(Integer limit, String before, String after, List<String> include, Map<String, OffsetDateTime> dateCreated, Map<String, String> metadata, Boolean color, Boolean scheduled, Map<String, String> sendDate, MailType mailType, SortBy3 sortBy, final ApiCallback _callback) throws ApiException {
        Object localVarPostBody = null;

        // create path and map variables
        String localVarPath = "/letters";

        List<Pair> localVarQueryParams = new ArrayList<Pair>();
        List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
        Map<String, String> localVarHeaderParams = new HashMap<String, String>();
        Map<String, String> localVarCookieParams = new HashMap<String, String>();
        Map<String, Object> localVarFormParams = new HashMap<String, Object>();

        if (limit != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("limit", limit));
        }

        if (before != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("before", before));
        }

        if (after != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("after", after));
        }

        if (include != null) {
            localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "include", include));
        }

        if (dateCreated != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("date_created", dateCreated));
        }

        if (metadata != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("metadata", metadata));
        }

        if (color != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("color", color));
        }

        if (scheduled != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("scheduled", scheduled));
        }

        if (sendDate != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("send_date", sendDate));
        }

        if (mailType != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("mail_type", mailType));
        }

        if (sortBy != null) {
            localVarQueryParams.addAll(localVarApiClient.parameterToPair("sort_by", sortBy));
        }

        final String[] localVarAccepts = {
            "application/json"
        };
        final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
        if (localVarAccept != null) {
            localVarHeaderParams.put("Accept", localVarAccept);
        }

        final String[] localVarContentTypes = {

        };
        final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
        localVarHeaderParams.put("Content-Type", localVarContentType);

        String[] localVarAuthNames = new String[] { "basicAuth" };
        return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
    }

    @SuppressWarnings("rawtypes")
    private okhttp3.Call listValidateBeforeCall(Integer limit, String before, String after, List<String> include, Map<String, OffsetDateTime> dateCreated, Map<String, String> metadata, Boolean color, Boolean scheduled, Map<String, String> sendDate, MailType mailType, SortBy3 sortBy, final ApiCallback _callback) throws ApiException {

        okhttp3.Call localVarCall = listCall(limit, before, after, include, dateCreated, metadata, color, scheduled, sendDate, mailType, sortBy, _callback);
        return localVarCall;

    }

    /**
     * list
     * Returns a list of your letters. The letters are returned sorted by creation date, with the most recently created letters appearing first.
     * @param limit How many results to return. (optional, default to 10)
     * @param before A reference to a list entry used for paginating to the previous set of entries. This field is pre-populated in the `previous_url` field in the return response.  (optional)
     * @param after A reference to a list entry used for paginating to the next set of entries. This field is pre-populated in the `next_url` field in the return response.  (optional)
     * @param include Request that the response include the total count by specifying `include[]=total_count`.  (optional)
     * @param dateCreated Filter by date created. (optional)
     * @param metadata Filter by metadata key-value pair`. (optional)
     * @param color Set to `true` to return only color letters. Set to `false` to return only black & white letters. (optional)
     * @param scheduled * `true` - only return orders (past or future) where `send_date` is greater than `date_created` * `false` - only return orders where `send_date` is equal to `date_created`  (optional)
     * @param sendDate Filter by date sent. (optional)
     * @param mailType A string designating the mail postage type: * `usps_first_class` - (default) * `usps_standard` - a [cheaper option](https://lob.com/pricing/print-mail#compare) which is less predictable and takes longer to deliver. `usps_standard` cannot be used with `4x6` postcards or for any postcards sent outside of the United States.  (optional, default to usps_first_class)
     * @param sortBy Sorts items by ascending or descending dates. Use either `date_created` or `send_date`, not both.  (optional)
     * @return LetterList
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 A dictionary with a data property that contains an array of up to `limit` letters. Each entry in the array is a separate letter. The previous and next page of letters can be retrieved by calling the endpoint contained in the `previous_url` and `next_url` fields in the API response respectively. If no more letters are available beyond the current set of returned results, the `next_url` field will be empty. 	  -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public LetterList list(Integer limit, String before, String after, List<String> include, Map<String, OffsetDateTime> dateCreated, Map<String, String> metadata, Boolean color, Boolean scheduled, Map<String, String> sendDate, MailType mailType, SortBy3 sortBy) throws ApiException {
        try {
            ApiResponse<LetterList> localVarResp = listWithHttpInfo(limit, before, after, include, dateCreated, metadata, color, scheduled, sendDate, mailType, sortBy);
            return localVarResp.getData();
        } catch (ApiException e) {
            throw e;
        }
    }

    /**
     * list
     * Returns a list of your letters. The letters are returned sorted by creation date, with the most recently created letters appearing first.
     * @param limit How many results to return. (optional, default to 10)
     * @param before A reference to a list entry used for paginating to the previous set of entries. This field is pre-populated in the `previous_url` field in the return response.  (optional)
     * @param after A reference to a list entry used for paginating to the next set of entries. This field is pre-populated in the `next_url` field in the return response.  (optional)
     * @param include Request that the response include the total count by specifying `include[]=total_count`.  (optional)
     * @param dateCreated Filter by date created. (optional)
     * @param metadata Filter by metadata key-value pair`. (optional)
     * @param color Set to `true` to return only color letters. Set to `false` to return only black & white letters. (optional)
     * @param scheduled * `true` - only return orders (past or future) where `send_date` is greater than `date_created` * `false` - only return orders where `send_date` is equal to `date_created`  (optional)
     * @param sendDate Filter by date sent. (optional)
     * @param mailType A string designating the mail postage type: * `usps_first_class` - (default) * `usps_standard` - a [cheaper option](https://lob.com/pricing/print-mail#compare) which is less predictable and takes longer to deliver. `usps_standard` cannot be used with `4x6` postcards or for any postcards sent outside of the United States.  (optional, default to usps_first_class)
     * @param sortBy Sorts items by ascending or descending dates. Use either `date_created` or `send_date`, not both.  (optional)
     * @return ApiResponse<LetterList>
     * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 A dictionary with a data property that contains an array of up to `limit` letters. Each entry in the array is a separate letter. The previous and next page of letters can be retrieved by calling the endpoint contained in the `previous_url` and `next_url` fields in the API response respectively. If no more letters are available beyond the current set of returned results, the `next_url` field will be empty. 	  -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public ApiResponse<LetterList> listWithHttpInfo(Integer limit, String before, String after, List<String> include, Map<String, OffsetDateTime> dateCreated, Map<String, String> metadata, Boolean color, Boolean scheduled, Map<String, String> sendDate, MailType mailType, SortBy3 sortBy) throws ApiException {
        try {
            okhttp3.Call localVarCall = listValidateBeforeCall(limit, before, after, include, dateCreated, metadata, color, scheduled, sendDate, mailType, sortBy, null);
            Type localVarReturnType = new TypeToken<LetterList>(){}.getType();
            return localVarApiClient.execute(localVarCall, localVarReturnType);
        } catch (ApiException e) {
            throw e;
        }
    }

    /**
     * list (asynchronously)
     * Returns a list of your letters. The letters are returned sorted by creation date, with the most recently created letters appearing first.
     * @param limit How many results to return. (optional, default to 10)
     * @param before A reference to a list entry used for paginating to the previous set of entries. This field is pre-populated in the `previous_url` field in the return response.  (optional)
     * @param after A reference to a list entry used for paginating to the next set of entries. This field is pre-populated in the `next_url` field in the return response.  (optional)
     * @param include Request that the response include the total count by specifying `include[]=total_count`.  (optional)
     * @param dateCreated Filter by date created. (optional)
     * @param metadata Filter by metadata key-value pair`. (optional)
     * @param color Set to `true` to return only color letters. Set to `false` to return only black & white letters. (optional)
     * @param scheduled * `true` - only return orders (past or future) where `send_date` is greater than `date_created` * `false` - only return orders where `send_date` is equal to `date_created`  (optional)
     * @param sendDate Filter by date sent. (optional)
     * @param mailType A string designating the mail postage type: * `usps_first_class` - (default) * `usps_standard` - a [cheaper option](https://lob.com/pricing/print-mail#compare) which is less predictable and takes longer to deliver. `usps_standard` cannot be used with `4x6` postcards or for any postcards sent outside of the United States.  (optional, default to usps_first_class)
     * @param sortBy Sorts items by ascending or descending dates. Use either `date_created` or `send_date`, not both.  (optional)
     * @param _callback The callback to be executed when the API call finishes
     * @return The request call
     * @throws ApiException If fail to process the API call, e.g. serializing the request body object
     * @http.response.details

 Status Code 	 Description 	 Response Headers

 200 	 A dictionary with a data property that contains an array of up to `limit` letters. Each entry in the array is a separate letter. The previous and next page of letters can be retrieved by calling the endpoint contained in the `previous_url` and `next_url` fields in the API response respectively. If no more letters are available beyond the current set of returned results, the `next_url` field will be empty. 	  -

 0 	 Lob uses RESTful HTTP response codes to indicate success or failure of an API request. 	  -

     */
    public okhttp3.Call listAsync(Integer limit, String before, String after, List<String> include, Map<String, OffsetDateTime> dateCreated, Map<String, String> metadata, Boolean color, Boolean scheduled, Map<String, String> sendDate, MailType mailType, SortBy3 sortBy, final ApiCallback<LetterList> _callback) throws ApiException {

        okhttp3.Call localVarCall = listValidateBeforeCall(limit, before, after, include, dateCreated, metadata, color, scheduled, sendDate, mailType, sortBy, _callback);
        Type localVarReturnType = new TypeToken<LetterList>(){}.getType();
        localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
        return localVarCall;
    }
}


text:
#include <X11/ICE/ICElib.h>

typedef struct _server_list {
    char *serverAddress;
    struct _server_list *next;
} server_list;

typedef struct _request_list {
    char *serviceName;
    char *serverAddress;
    char *hostAddress;
    char *startOptions;
    PMconn *requestor;
    char *listData;
    int authLen;
    char *authName;
    char *authData;
    struct _request_list *next;
} request_list;

typedef struct _running_proxy {
    Bool active;
    PMconn *pmConn;
    request_list *requests;
    server_list *servers;
    Bool refused_service;
    struct _running_proxy *next;
} running_proxy;

typedef struct _proxy_service {
    char *serviceName;
    int proxyCount;
    running_proxy *proxyList;
    struct _proxy_service *next;
} proxy_service;

typedef struct {
    int count;
    int current;
    running_proxy **list;
} running_proxy_list;

proxy_service
*FindProxyService (
	char *serviceName,
	Bool createIf);

running_proxy *
StartNewProxy (
	char *serviceName,
	char *startCommand);

running_proxy *
ConnectToProxy (
	int pmOpcode,
	char *serviceName,
	char *proxyAddress);

Status
ActivateProxyService (
	char *serviceName,
	PMconn *proxy);

void
ProxyGone (
    IceConn proxyIceConn,
    Bool *activeReqs);

running_proxy_list *
GetRunningProxyList (
	char *serviceName,
	char *serverAddress);

void
FreeProxyList (
	running_proxy_list *list);

Status
PushRequestorQueue (
	running_proxy *proxy,
	PMconn *requestor,
	running_proxy_list *runList,
	char *serviceName,
	char *serverAddress,
	char *hostAddress,
	char *startOptions,
	int authLen,
	char *authName,
	char *authData);

Status
PeekRequestorQueue (
	PMconn *proxy,
	PMconn **requestor,
	running_proxy_list **runList,
	char **serviceName,
	char **serverAddress,
	char **hostAddress,
	char **startOptions,
	int *authLen,
	char **authName,
	char **authData);

PMconn*
PopRequestorQueue (
	PMconn *pmConn,
	Bool addServer,
	Bool freeProxyList);

running_proxy *
ProxyForPMconn(
	PMconn *pmConn);


text:
import templateUrl from 'views/templates/confirm.tpl.pug';

// Confirm popup service.
export default ['IgniteConfirm', ['$rootScope', '$q', '$modal', '$animate', ($root, $q, $modal, $animate) => {
    const scope = $root.$new();

    const modal = $modal({templateUrl, scope, placement: 'center', show: false, backdrop: true});

    const _hide = () => {
        $animate.enabled(modal.$element, false);

        modal.hide();
    };

    let deferred;

    scope.confirmYes = () => {
        _hide();

        deferred.resolve(true);
    };

    scope.confirmNo = () => {
        _hide();

        deferred.resolve(false);
    };

    scope.confirmCancel = () => {
        _hide();

        deferred.reject('cancelled');
    };

    /**
     *
     * @param {String } content
     * @param {Boolean} [yesNo]
     * @returns {Promise}
     */
    modal.confirm = (content, yesNo) => {
        scope.content = content || 'Confirm?';
        scope.yesNo = !!yesNo;

        deferred = $q.defer();

        modal.$promise.then(modal.show);

        return deferred.promise;
    };

    return modal;
}]];


text:
import restea.formats as formats

class BaseResourceWrapper(object):
    '''
    BaseResourceWrapper is added to have common interface between frameworks.
    '''
    request_wrapper_class = None

    def __init__(self, resource_class):
        '''
        :param resource_class: :class:`restea.resource.Resource` -- resource
        object implementing methods to create/edit/delete data
        '''
        self._resource_class = resource_class

    def _get_format_name(self, view_kwargs):
        '''
        Returns format for serialization and unserialization of data

        :param view_kwargs: dict -- kwargs of the view catched from the
        url router

        :returns: tuple -- data_format found and modified kwargs
        '''
        data_format = view_kwargs.pop('data_format', None)
        if not data_format:
            data_format = formats.DEFAULT_FORMATTER.name
        return data_format, view_kwargs

    def get_routes(self, path='', iden=''):
        '''
        Prepare routes for the given REST resource

        :param path: string -- base path for the REST resource
        :param iden: string -- format for identifier, for instance might be
        used to make composite identifier
        '''
        raise NotImplementedError

    def prepare_response(self, content, status_code, content_type, headers):
        '''
        Prepares response for the given arguments.

        :param content: string -- response content
        :param status_code: string -- response status code
        :param content_type: string -- response content type
        :param headers: string -- response headers
        '''
        raise NotImplementedError

    def split_request_and_arguments(self, *args, **kwargs):
        '''
        Hook to return the original request object and arguments.

        This method receives all arguments that the `wrap_request` method
        receives and return the first argument as the request object by
        default which is commonly received in that order.
        Override this method in your subclass wrapper if the behavior is
        different for your framework.
        '''
        return args[0], args[1:], kwargs

    def wrap_request(self, *args, **kwargs):
        '''
        Prepares data and pass control to `restea.Resource` object
        :returns: Response object for corresponding framework
        '''
        data_format, kwargs = self._get_format_name(kwargs)
        formatter = formats.get_formatter(data_format)
        original_request, args, kwargs = self.split_request_and_arguments(
            *args, **kwargs
        )

        if not self.request_wrapper_class:
            raise RuntimeError(
                '{} must have a request_wrapper_class attribute '
                'configured.'.format(self.__class__.__name__)
            )

        resource = self._resource_class(
            self.request_wrapper_class(original_request), formatter
        )
        response_tuple = resource.dispatch(*args, **kwargs)

        if len(response_tuple) == 3:
            # For backward compatibility, it adds an empty dict as headers
            response_tuple += ({},)

        return self.prepare_response(*response_tuple)

class BaseRequestWrapper(object):
    '''
    BaseRequestWrapper wraps the `restea.request.Request` objects to abstract
    implementation between different frameworks
    '''
    def __init__(self, original_request):
        '''
        :param original_request: -- request object from the given framework
        '''
        self._original_request = original_request

    @property
    def data(self):
        '''
        Returns a payload sent to server

        :returns: string -- raw value of payload sent to server
        '''
        raise NotImplementedError

    @property
    def headers(self):
        '''
        Returns a headers dict

        :returns: dict -- received request headers
        '''
        raise NotImplementedError

    @property
    def method(self):
        '''
        Returns HTTP method for the current request

        :returns: string -- HTTP method name
        '''
        raise NotImplementedError

    def get(self, value):
        '''
        Returns a value from the HTTP GET "map"

        :param value: string -- key from GET
        :returns: string -- value from GET or None if anything is found
        '''
        raise NotImplementedError


text:
@interface TNUIActionSheet : UIActionSheet {
 @private
}
@end

@implementation TNUIActionSheet

@end

@implementation UIActionSheetPlugin

- (void)actionSheet:(UIActionSheet*)actionSheet
  clickedButtonAtIndex:(NSInteger)buttonIndex
{
  NSDictionary* clickData =
      [NSDictionary dictionaryWithObject:
          [NSNumber numberWithInt:buttonIndex] forKey:@"index"];
  [[self class] fireEvent:@"actionSheetClick"
                 withData:clickData
             forComponent:actionSheet];
}

+ (Class)uiKitSubclass
{
  return [TNUIActionSheet class];
}

- (void)setupComponent:(TNUIActionSheet*)actionSheet
           withOptions:(NSDictionary*)options
{
  [super setupComponent:actionSheet withOptions:options];

  actionSheet.delegate = self;

  NSArray* buttons = [options objectForKey:@"buttons"];
  if (![buttons isKindOfClass:[NSNull class]]) {
    for (NSDictionary* buttonOptions in buttons) {
      NSString* title = [buttonOptions objectForKey:@"title"];
      assert(title);

      NSInteger buttonIndex = [actionSheet addButtonWithTitle:title];

      NSString* type = [buttonOptions objectForKey:@"type"];
      if (type) {
        if ([type isEqual:@"cancel"]) {
          actionSheet.cancelButtonIndex = buttonIndex;
        } else if ([type isEqual:@"destructive"]) {
          actionSheet.destructiveButtonIndex = buttonIndex;
        } else {
          assert(false);
        }
      }
    }
  }

  [self setProperties:
    [NSArray arrayWithObjects:@"title", nil]
    forComponent:actionSheet
    fromOptions:options];
}

- (id)getProperty:(NSString*)name
     forComponent:(TNUIActionSheet*)actionSheet
{
  if (false) {
  } else {
    return [super getProperty:name forComponent:actionSheet];
  }
}

- (void)setProperty:(NSString*)name
          withValue:(id)value
       forComponent:(TNUIActionSheet*)actionSheet
{
  if ([name isEqual:@"title"]) {
    actionSheet.title = value;
  } else {
    [super setProperty:name
             withValue:value
          forComponent:actionSheet];
  }
}

- (void)show:(NSMutableArray*)arguments
    withDict:(NSMutableDictionary*)options
{
  NSDictionary* actionSheetOptions = [options objectForKey:@"actionSheet"];
  TNUIActionSheet* actionSheet =
      [[self class] componentWithOptions:actionSheetOptions];

  [actionSheet showInView:[UIWindowPlugin topViewController].view];
}

@end


text:
package info.plichta.maven.plugins.changelog.handlers;

import info.plichta.maven.plugins.changelog.model.CommitWrapper;

/**
 * {@link CommitHandler} is responsible for processing GIT commits. Its implementation may change {@link CommitWrapper}
 * data and add any additional ones.
 */
public interface CommitHandler {

    /**
     * Takes provided commit, processes its information and enhances it.
     *
     * @param commit commit to be processed
     */
    void handle(CommitWrapper commit);
}


text:
'use strict';

/**
 * @typedef {import('../lib/types').XastElement} XastElement
 */

const csso = require('csso');

exports.type = 'visitor';
exports.name = 'minifyStyles';
exports.active = true;
exports.description =
  'minifies styles and removes unused styles based on usage data';

/**
 * Minifies styles (<style> element + style attribute) using CSSO
 *
 * @author strarsis <strarsis@gmail.com>
 *
 * @type {import('../lib/types').Plugin<csso.MinifyOptions & Omit<csso.CompressOptions, 'usage'> & {
 *   usage?: boolean | {
 *     force?: boolean,
 *     ids?: boolean,
 *     classes?: boolean,
 *     tags?: boolean
 *   }
 * }>}
 */
exports.fn = (_root, { usage, ...params }) => {
  let enableTagsUsage = true;
  let enableIdsUsage = true;
  let enableClassesUsage = true;
  // force to use usage data even if it unsafe (document contains <script> or on* attributes)
  let forceUsageDeoptimized = false;
  if (typeof usage === 'boolean') {
    enableTagsUsage = usage;
    enableIdsUsage = usage;
    enableClassesUsage = usage;
  } else if (usage) {
    enableTagsUsage = usage.tags == null ? true : usage.tags;
    enableIdsUsage = usage.ids == null ? true : usage.ids;
    enableClassesUsage = usage.classes == null ? true : usage.classes;
    forceUsageDeoptimized = usage.force == null ? false : usage.force;
  }
  /**
   * @type {Array<XastElement>}
   */
  const styleElements = [];
  /**
   * @type {Array<XastElement>}
   */
  const elementsWithStyleAttributes = [];
  let deoptimized = false;
  /**
   * @type {Set<string>}
   */
  const tagsUsage = new Set();
  /**
   * @type {Set<string>}
   */
  const idsUsage = new Set();
  /**
   * @type {Set<string>}
   */
  const classesUsage = new Set();

  return {
    element: {
      enter: (node) => {
        // detect deoptimisations
        if (node.name === 'script') {
          deoptimized = true;
        }
        for (const name of Object.keys(node.attributes)) {
          if (name.startsWith('on')) {
            deoptimized = true;
          }
        }
        // collect tags, ids and classes usage
        tagsUsage.add(node.name);
        if (node.attributes.id != null) {
          idsUsage.add(node.attributes.id);
        }
        if (node.attributes.class != null) {
          for (const className of node.attributes.class.split(/\s+/)) {
            classesUsage.add(className);
          }
        }
        // collect style elements or elements with style attribute
        if (node.name === 'style' && node.children.length !== 0) {
          styleElements.push(node);
        } else if (node.attributes.style != null) {
          elementsWithStyleAttributes.push(node);
        }
      },
    },

    root: {
      exit: () => {
        /**
         * @type {csso.Usage}
         */
        const cssoUsage = {};
        if (deoptimized === false || forceUsageDeoptimized === true) {
          if (enableTagsUsage && tagsUsage.size !== 0) {
            cssoUsage.tags = Array.from(tagsUsage);
          }
          if (enableIdsUsage && idsUsage.size !== 0) {
            cssoUsage.ids = Array.from(idsUsage);
          }
          if (enableClassesUsage && classesUsage.size !== 0) {
            cssoUsage.classes = Array.from(classesUsage);
          }
        }
        // minify style elements
        for (const node of styleElements) {
          if (
            node.children[0].type === 'text' ||
            node.children[0].type === 'cdata'
          ) {
            const cssText = node.children[0].value;
            const minified = csso.minify(cssText, {
              ...params,
              usage: cssoUsage,
            }).css;
            // preserve cdata if necessary
            // TODO split cdata -> text optimisation into separate plugin
            if (cssText.indexOf('>') >= 0 || cssText.indexOf('<') >= 0) {
              node.children[0].type = 'cdata';
              node.children[0].value = minified;
            } else {
              node.children[0].type = 'text';
              node.children[0].value = minified;
            }
          }
        }
        // minify style attributes
        for (const node of elementsWithStyleAttributes) {
          // style attribute
          const elemStyle = node.attributes.style;
          node.attributes.style = csso.minifyBlock(elemStyle, {
            ...params,
          }).css;
        }
      },
    },
  };
};


text:
var assert = require('chai').assert;
var helper = require('./helper.js');
//require('grunt-testing/libs/instrument.js');

describe('Suite one', function(){
  it('run',function(done){
  	assert.isTrue(true);
	helper.grunt('examples/qunit-advanced-example', 'default', function(){
		done();
	});
  });
});


text:
```sh
# from https://www.drupal.org/requirements/php#drupalversions
FROM php:5.6-apache

RUN a2enmod rewrite

# install the PHP extensions we need
RUN apt-get update && apt-get install -y libpng12-dev libjpeg-dev libpq-dev \
	&& rm -rf /var/lib/apt/lists/* \
	&& docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \
	&& docker-php-ext-install gd mbstring pdo pdo_mysql pdo_pgsql

WORKDIR /var/www/html
```


text:
<?php

namespace App\Form;

use App\Entity\Address;
use App\Entity\Person;
use App\Entity\WorkingGroup;
use Doctrine\ORM\EntityRepository;
use Symfony\Bridge\Doctrine\Form\Type\EntityType;
use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilderInterface;
use Symfony\Component\Form\Extension\Core\Type\ChoiceType;
use Symfony\Component\Form\Extension\Core\Type\DateType;
use Symfony\Component\Form\Extension\Core\Type\TextareaType;
use Symfony\Component\Form\Extension\Core\Type\TextType;
use Symfony\Component\OptionsResolver\OptionsResolver;
use Symfony\Contracts\Translation\TranslatorInterface;

class PersonType extends AbstractType
{
    private $translator;

    public function __construct(TranslatorInterface $translator)
    {
        $this->translator = $translator;
    }

    /**
     * @param FormBuilderInterface $builder
     * @param array $options
     */
    public function buildForm(FormBuilderInterface $builder, array $options)
    {
        if ($options['add_address_field']) {
            $builder->add('address', EntityType::class, [
                'class' => Address::class,
                'choice_label' => 'dropdownLabel',
                'query_builder' => function (EntityRepository $repo) {
                    return $repo->createQueryBuilder('address')
                        ->select('address')
                        ->orderBy('address.familyName', 'asc')
                    ;
                }
            ]);
        }

        $builder
            ->add('lastname', TextType::class, [
                'label' => 'Differing Last Name',
                'required' => false,
                'help' => 'Leave this field empty to use the family name of the address.',
            ])
            ->add('firstname', TextType::class, [
                'label' => 'First Name',
            ])
            ->add('dob', DateType::class, [
                'label' => 'Date of Birth',
                'widget' => 'single_text',
            ])
            ->add('gender', ChoiceType::class, [
                'choices' => [
                    'male' => Person::GENDER_MALE,
                    'female' => Person::GENDER_FEMALE
                ],
            ])
            ->add('mobile', TextType::class, [
                'required' => false,
            ])
            ->add('email', TextType::class, [
                'label' => 'E-mail',
                'required' => false,
            ])
            ->add('workingGroup', EntityType::class, [
                'class' => WorkingGroup::class,
                'choice_label' => function ($workingGroup) {
                    return $workingGroup->getDisplayName($this->translator);
                },
                'label' => 'Working Group',
                'required' => false,
            ])
            ->add('workerStatus', ChoiceType::class, [
                'choices' => array_flip(Person::getAllWorkerStatus()),
                'label' => 'Able to work',
            ])
            ->add('notice', TextareaType::class, [
                'required' => false,
            ])
        ;
    }

    /**
     * @param OptionsResolver $resolver
     */
    public function configureOptions(OptionsResolver $resolver)
    {
        $resolver->setDefaults([
            'data_class' => Person::class,
            'add_address_field' => false,
        ]);
    }

    /**
     * @return string
     */
    public function getBlockPrefix()
    {
        return 'person';
    }
}


text:
var View = function(controler) {
  this.divisionSize = 100;
  this.playerElement = $('#player');
  this.spotLight = $('#spotlight');

  $(document).keyup( function(e){

    controler.keyCodeProcessor(e);
     e.preventDefault();
  }).bind(controler);

//stopping scrolling on keydown
 $(document).keydown( function(e){
    //swallow
     e.preventDefault();
  });

}

View.prototype.setPlayerLocation = function(location, win) {
  var row = parseInt(location[1])
  var col = parseInt(location[0])
  var leftPosition = (row * this.divisionSize) + 'px';
  this.playerElement.css('left', leftPosition);
  var topPosition = (col * this.divisionSize) + 'px';
  this.playerElement.css('top', topPosition);
  if (win == true){
    alert("YOU WIN :D  !!!!!1!!1") ;
  }
  if (location == "13"){
    this.playerElement.css("background-image", "url(images/octolorde.png)");
  }
}

View.prototype.toggleSpotlight = function() {

}


text:
export class Mastery {
  public masteryId: number;
  public rank: number;
}


text:
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

package com.azure.search.documents.implementation.converters;

import com.azure.search.documents.indexes.models.InputFieldMappingEntry;
import com.azure.search.documents.indexes.models.SentimentSkill;

import java.util.List;
import java.util.stream.Collectors;

/**
 * A converter between {@link com.azure.search.documents.indexes.implementation.models.SentimentSkill} and
 * {@link SentimentSkill}.
 */
public final class SentimentSkillConverter {
    /**
     * Maps from {@link com.azure.search.documents.indexes.implementation.models.SentimentSkill} to {@link SentimentSkill}.
     */
    public static SentimentSkill map(com.azure.search.documents.indexes.implementation.models.SentimentSkill obj) {
        if (obj == null) {
            return null;
        }

        List<InputFieldMappingEntry> inputs = obj.getInputs() == null ? null
            : obj.getInputs().stream().map(InputFieldMappingEntryConverter::map).collect(Collectors.toList());

        SentimentSkill sentimentSkill = new SentimentSkill(inputs, obj.getOutputs());

        String name = obj.getName();
        sentimentSkill.setName(name);

        String context = obj.getContext();
        sentimentSkill.setContext(context);

        String description = obj.getDescription();
        sentimentSkill.setDescription(description);

        if (obj.getDefaultLanguageCode() != null) {
            sentimentSkill.setDefaultLanguageCode(obj.getDefaultLanguageCode());
        }
        return sentimentSkill;
    }

    /**
     * Maps from {@link SentimentSkill} to {@link com.azure.search.documents.indexes.implementation.models.SentimentSkill}.
     */
    public static com.azure.search.documents.indexes.implementation.models.SentimentSkill map(SentimentSkill obj) {
        if (obj == null) {
            return null;
        }

        List<com.azure.search.documents.indexes.implementation.models.InputFieldMappingEntry> inputs =
            obj.getOutputs() == null ? null
                : obj.getInputs().stream().map(InputFieldMappingEntryConverter::map).collect(Collectors.toList());

        com.azure.search.documents.indexes.implementation.models.SentimentSkill sentimentSkill =
            new com.azure.search.documents.indexes.implementation.models.SentimentSkill(inputs, obj.getOutputs());

        String name = obj.getName();
        sentimentSkill.setName(name);

        String context = obj.getContext();
        sentimentSkill.setContext(context);

        String description = obj.getDescription();
        sentimentSkill.setDescription(description);

        if (obj.getDefaultLanguageCode() != null) {
            sentimentSkill.setDefaultLanguageCode(obj.getDefaultLanguageCode());
        }

        return sentimentSkill;
    }

    private SentimentSkillConverter() {
    }
}


text:
package org.apache.sling.sample.slingshot;

import org.apache.sling.api.SlingHttpServletRequest;
import org.apache.sling.api.resource.Resource;

public abstract class SlingshotUtil {

    public static String getUserId(final Resource resource) {
        final String prefix = SlingshotConstants.APP_ROOT_PATH + "/";

        String id = null;
        if ( resource.getPath().startsWith(prefix) ) {
            final int areaEnd = resource.getPath().indexOf('/', prefix.length());
            if ( areaEnd != -1 ) {
                final int userEnd = resource.getPath().indexOf('/', areaEnd + 1);
                if ( userEnd == -1 ) {
                    id = resource.getPath().substring(areaEnd + 1);
                } else {
                    id = resource.getPath().substring(areaEnd + 1, userEnd);
                }
            }
        }
        return id;
    }

    public static String getContentPath(final Resource resource) {
        final String prefix = SlingshotConstants.APP_ROOT_PATH + "/users/" + getUserId(resource) + "/";

        final String path = resource.getPath();
        if ( path != null && path.startsWith(prefix) ) {
            return path.substring(prefix.length() - 1);
        }
        return null;
    }

    public static boolean isUser(final SlingHttpServletRequest request) {
        final boolean isUser = request.getRemoteUser() != null && !request.getRemoteUser().equals("anonymous");
        return isUser;
    }

}


text:
package com.react_audio_player;

import android.os.Handler;
import android.os.Message;

import com.facebook.react.ReactActivity;

import java.lang.ref.WeakReference;

public class MainActivity extends ReactActivity {

    public Handler getSongProgressHandler() {
        return songProgressHandler;
    }

    /**
     * Instances of static inner classes do not hold an implicit
     * reference to their outer class.
     */
    private static class NonLeakyHandler extends Handler {
        private final WeakReference<MainActivity> mActivity;

        public NonLeakyHandler(MainActivity activity) {
            mActivity = new WeakReference<MainActivity>(activity);
        }

        @Override
        public void handleMessage(Message msg) {
            MainActivity activity = mActivity.get();
            if (activity != null) {
                // ...
            }
        }
    }

    //Song progress Update Handler
    private Handler songProgressHandler = new NonLeakyHandler(MainActivity.this);

    /**
     * Returns the name of the main component registered from JavaScript.
     * This is used to schedule rendering of the component.
     */
    @Override
    protected String getMainComponentName() {
        return "React_Audio_Player";
    }
}


text:
package br.com.wagnersoft.esculapio.services;

import br.com.wagnersoft.esculapio.dao.OcsPmDao;
import br.com.wagnersoft.esculapio.model.Ocs;
import br.com.wagnersoft.esculapio.model.OcsPm;

import java.io.File;
import java.io.FileInputStream;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Iterator;
import java.util.List;

import javax.inject.Inject;
import javax.inject.Named;

import org.apache.poi.hssf.usermodel.HSSFCell;
import org.apache.poi.hssf.usermodel.HSSFRow;
import org.apache.poi.hssf.usermodel.HSSFWorkbook;
import org.apache.poi.poifs.filesystem.POIFSFileSystem;
import org.apache.poi.ss.usermodel.Cell;
import org.apache.poi.ss.usermodel.Row;
import org.directwebremoting.annotations.RemoteMethod;
import org.directwebremoting.annotations.RemoteProxy;
import org.springframework.transaction.annotation.Transactional;

/** Serviço para OCS-PM. (Tabela OCS_PM)
 * @author Abreu Lopes
 * @since 1.0
 * @version $Id$
 */
@Named("ocsPmService")
@RemoteProxy(name="ocsPmService")
public class OcsPmService {

  @Inject
  private OcsPmDao dao;

  @Inject
  private ProcedimentoMedicoService pmService;

  public OcsPmService() {
  }

  @Transactional
  public void excluir(final Integer id) throws Exception {
    if (id == null) {
      throw new IllegalArgumentException("Excluir: ID do OCS/PM não foi informado");
    }
    this.dao.delete(new OcsPm(id));
  }

  public List<OcsPm> listar(final Integer ocsId) throws Exception {
    final List<OcsPm> lista = this.dao.findByNamedQuery("OcsPm.findByOCS", ocsId);
    if (lista == null || lista.isEmpty()) {
      throw new Exception("Não há procedimentos cadastrados para este OCS.");
    }
    return lista;
  }

  @RemoteMethod
  public OcsPm[] listarOcsPM(final Integer id, final String tipo) throws Exception {
    List<OcsPm> lista = null;
    if ("ocs".equals(tipo)){
      lista = this.dao.findByNamedQuery("OcsPm.findByOCS", id);
    }
    else {
      lista = this.dao.findByNamedQuery("OcsPm.findByPM", id);
    }
    Collections.sort(lista);
    return lista.toArray(new OcsPm[0]);
  }

  @RemoteMethod
  public OcsPm recuperar(final Integer id) throws Exception {
    if (id == null) {
      throw new IllegalArgumentException("ID do OCS/PM não foi informado");
    }
    return this.dao.findById(id);
  }

  @Transactional
  public void salvar(final OcsPm entidade) throws Exception {
    if (entidade == null) {
      throw new IllegalArgumentException("OCS/PM não foi informado");
    }
    if (entidade.getOcs() == null) {
      throw new IllegalArgumentException("OCS não foi informado");
    }
    if (entidade.getPm() == null) {
      throw new IllegalArgumentException("PM não foi informado");
    }
    if (entidade.getId() != null) {
      final OcsPm o = this.dao.findById(entidade.getId());
      o.setOcs(entidade.getOcs());
      o.setPm(entidade.getPm());
      o.setChQtd(entidade.getChQtd());
      o.setValor(entidade.getValor());
      this.dao.save(o);
    } else {
      this.dao.save(entidade);
    }
  }

  @SuppressWarnings("resource")
@Transactional
  public String carregarPlanilha(final Ocs ocs, final File arquivo) throws Exception {
    if (arquivo == null) {
      throw new IllegalArgumentException("Planilha não foi informada");
    }
    final List<OcsPm> lista = new ArrayList<>();
    int x = this.dao.execute("OcsPm.excluirPorOcs", ocs.getId());
    final Iterator<Row> rows = new HSSFWorkbook(new POIFSFileSystem(new FileInputStream(arquivo))).getSheetAt(0).rowIterator();
    int cont = 0;
    inicio:
    while(rows.hasNext()) {
      cont += 1;
      final HSSFRow row = (HSSFRow) rows.next();
      if (cont == 1) {
        continue inicio;
      }
      final OcsPm opm = new OcsPm();
      opm.setOcs(ocs);
      final Iterator<Cell> cells = row.cellIterator();
      while(cells.hasNext()) {
        final HSSFCell cell = (HSSFCell) cells.next();
        //cell.setCellType(0);
        switch (cell.getColumnIndex()) {
        case 0:
          //final String cod = cell.getStringCellValue();
          final String cod = Long.toString((long) cell.getNumericCellValue());
          if (cod != null) {
            try {
              opm.setPm(this.pmService.listarPorCodigo(cod.trim()).get(0));
            } catch(Exception e){
              continue inicio;
            }
          }
          break;
        case 2:
          double valor = 0;
          try {
            valor = cell.getNumericCellValue();
          } catch (Exception e) {
          }
          opm.setValor(BigDecimal.valueOf(valor));
          break;
        default:
          break;
        }
      }
      opm.setChQtd(0);
      lista.add(this.dao.save(opm));
    }
    return "Excluídos = " + x + " - Incluídos = " + lista.size();
  }

}


text:
package com.vsm.stockmarket.enums;

/**
 * @author sam sundar K
 *
 */
public enum VALIDATION_MODE {
	SAVE, UPDATE, CHANGE_PASSWORD
}


text:
class Parent
  include Mongoid::Document
  embeds_many :sub_items
  embeds_one :first_child, class_name: "Child", as: :childable
end


text:
class Window_Base
  class ContentBitmap < Bitmap
  end

  alias_method :initialize_wo_padding, :initialize

  def initialize(*args, &block)
    initialize_wo_padding(*args, &block)
    self.padding = 16
  end

  def create_contents
    self.contents.dispose
    self.contents = ContentBitmap.new(width - 32, height - 32)
  end
end


text:
<?php

/**
 *
 * @package CRM
 * @copyright CiviCRM LLC (c) 2004-2015
 * $Id$
 *
 */

/**
 * This class generates form components for Activity Links
 *
 */
class CRM_Activity_Form_ActivityLinks extends CRM_Core_Form {
  public function buildQuickForm() {
    self::commonBuildQuickForm($this);
  }

  /**
   * @param $self
   */
  public static function commonBuildQuickForm($self) {
    $contactId = CRM_Utils_Request::retrieve('cid', 'Positive', $self);
    if (!$contactId) {
      $contactId = CRM_Utils_Request::retrieve('cid', 'Positive', CRM_Core_DAO::$_nullObject, FALSE, NULL, $_REQUEST);
    }
    $urlParams = "action=add&reset=1&cid={$contactId}&selectedChild=activity&atype=";

    $activityTypes = $urls = array();

    $emailTypeId = CRM_Core_OptionGroup::getValue('activity_type',
      'Email',
      'name'
    );

    $letterTypeId = CRM_Core_OptionGroup::getValue('activity_type',
      'Print PDF Letter',
      'name'
    );
    $SMSId = CRM_Core_OptionGroup::getValue('activity_type',
      'Text Message (SMS)',
      'label'
    );

    if (CRM_Utils_Mail::validOutBoundMail() && $contactId) {
      list($name, $email, $doNotEmail, $onHold, $isDeseased) = CRM_Contact_BAO_Contact::getContactDetails($contactId);
      if (!$doNotEmail && $email && !$isDeseased) {
        $activityTypes = array($emailTypeId => ts('Send an Email'));
      }
    }

    if ($contactId && CRM_SMS_BAO_Provider::activeProviderCount()) {
      // Check for existence of a mobile phone and ! do not SMS privacy setting
      $mobileTypeID = CRM_Core_OptionGroup::getValue('phone_type', 'Mobile', 'name');
      list($name, $phone, $doNotSMS) = CRM_Contact_BAO_Contact_Location::getPhoneDetails($contactId, $mobileTypeID);

      if (!$doNotSMS && $phone) {
        $sendSMS = array($SMSId => ts('Send SMS'));
        $activityTypes += $sendSMS;
      }
    }
    // this returns activity types sorted by weight
    $otherTypes = CRM_Core_PseudoConstant::activityType(FALSE);

    $activityTypes += $otherTypes;

    foreach (array_keys($activityTypes) as $typeId) {
      if ($typeId == $emailTypeId) {
        $urls[$typeId] = CRM_Utils_System::url('civicrm/activity/email/add',
          "{$urlParams}{$typeId}", FALSE, NULL, FALSE
        );
      }
      elseif ($typeId == $SMSId) {
        $urls[$typeId] = CRM_Utils_System::url('civicrm/activity/sms/add',
          "{$urlParams}{$typeId}", FALSE, NULL, FALSE
        );
      }
      elseif ($typeId == $letterTypeId) {
        $urls[$typeId] = CRM_Utils_System::url('civicrm/activity/pdf/add',
          "{$urlParams}{$typeId}", FALSE, NULL, FALSE
        );
      }
      else {
        $urls[$typeId] = CRM_Utils_System::url('civicrm/activity/add',
          "{$urlParams}{$typeId}", FALSE, NULL, FALSE
        );
      }
    }

    $self->assign('activityTypes', $activityTypes);
    $self->assign('urls', $urls);

    $self->assign('suppressForm', TRUE);
  }

}


text:
from __future__ import unicode_literals

from django.db import migrations, models

class Migration(migrations.Migration):

    dependencies = [
        ('lexicon', '0039_languagebranches_to_sndcomp'),
    ]

    operations = [
        migrations.RemoveField(
            model_name='language',
            name='languageBranch',
        ),
        migrations.AddField(
            model_name='language',
            name='clade',
            field=models.ForeignKey(to='lexicon.Clade', null=True),
        ),
        migrations.DeleteModel(
            name='LanguageBranches',
        ),
    ]