text:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<title>Deprecated List (JSFML API)</title>
<meta name="date" content="2013-11-20">
<link rel="stylesheet" type="text/css" href="stylesheet.css" title="Style">

JavaScript is disabled on your browser.

Overview

Package

Class

Tree

Deprecated

Index

Help

Prev

Next

Frames

No Frames

All Classes

Deprecated API

Contents

Deprecated Methods

Deprecated Constructors

Deprecated Methods

Method and Description

org.jsfml.audio.SoundStream.nativeCreate()

org.jsfml.audio.SoundRecorder.nativeCreate()

org.jsfml.audio.SoundBufferRecorder.nativeCreate()

org.jsfml.audio.SoundBuffer.nativeCreate()

org.jsfml.audio.Sound.nativeCreate()

org.jsfml.audio.Music.nativeCreate()

org.jsfml.graphics.View.nativeCreate()

org.jsfml.graphics.Texture.nativeCreate()

org.jsfml.graphics.Text.nativeCreate()

org.jsfml.graphics.Sprite.nativeCreate()

org.jsfml.graphics.Shader.nativeCreate()

org.jsfml.graphics.RenderWindow.nativeCreate()

org.jsfml.graphics.RenderTexture.nativeCreate()

org.jsfml.graphics.RectangleShape.nativeCreate()

org.jsfml.graphics.Image.nativeCreate()

org.jsfml.graphics.Font.nativeCreate()

org.jsfml.graphics.ConvexShape.nativeCreate()

org.jsfml.graphics.CircleShape.nativeCreate()

org.jsfml.internal.SFMLNativeObject.nativeCreate()

Use of this method may cause undefined behaviour and is not supported.

org.jsfml.window.Window.nativeCreate()

org.jsfml.window.Context.nativeCreate()

org.jsfml.audio.SoundStream.nativeDelete()

org.jsfml.audio.SoundRecorder.nativeDelete()

org.jsfml.audio.SoundBufferRecorder.nativeDelete()

org.jsfml.audio.SoundBuffer.nativeDelete()

org.jsfml.audio.Sound.nativeDelete()

org.jsfml.audio.Music.nativeDelete()

org.jsfml.graphics.View.nativeDelete()

org.jsfml.graphics.Texture.nativeDelete()

org.jsfml.graphics.Text.nativeDelete()

org.jsfml.graphics.Sprite.nativeDelete()

org.jsfml.graphics.Shader.nativeDelete()

org.jsfml.graphics.RenderWindow.nativeDelete()

org.jsfml.graphics.RenderTexture.nativeDelete()

org.jsfml.graphics.RectangleShape.nativeDelete()

org.jsfml.graphics.Image.nativeDelete()

org.jsfml.graphics.Font.nativeDelete()

org.jsfml.graphics.ConvexShape.nativeDelete()

org.jsfml.graphics.CircleShape.nativeDelete()

org.jsfml.internal.SFMLNativeObject.nativeDelete()

Use of this method may cause undefined behaviour and is not supported.

org.jsfml.window.Window.nativeDelete()

org.jsfml.window.Context.nativeDelete()

org.jsfml.audio.SoundStream.nativeSetExPtr()

org.jsfml.audio.SoundRecorder.nativeSetExPtr()

org.jsfml.audio.SoundBufferRecorder.nativeSetExPtr()

org.jsfml.audio.SoundBuffer.nativeSetExPtr()

org.jsfml.audio.Sound.nativeSetExPtr()

org.jsfml.audio.Music.nativeSetExPtr()

org.jsfml.graphics.View.nativeSetExPtr()

org.jsfml.graphics.Texture.nativeSetExPtr()

org.jsfml.graphics.Text.nativeSetExPtr()

org.jsfml.graphics.Sprite.nativeSetExPtr()

org.jsfml.graphics.Shader.nativeSetExPtr()

org.jsfml.graphics.RenderWindow.nativeSetExPtr()

org.jsfml.graphics.RenderTexture.nativeSetExPtr()

org.jsfml.graphics.RectangleShape.nativeSetExPtr()

org.jsfml.graphics.Image.nativeSetExPtr()

org.jsfml.graphics.Font.nativeSetExPtr()

org.jsfml.graphics.ConvexShape.nativeSetExPtr()

org.jsfml.graphics.CircleShape.nativeSetExPtr()

org.jsfml.internal.SFMLNativeObject.nativeSetExPtr()

Use of this method may cause undefined behaviour and is not supported.

org.jsfml.window.Window.nativeSetExPtr()

org.jsfml.window.Context.nativeSetExPtr()

Deprecated Constructors

Constructor and Description

org.jsfml.internal.SFMLNativeObject(long)

Use of this constructor may cause undefined behaviour and is not supported.

org.jsfml.window.Window(long)

Use of this method may cause undefined behaviour and is not supported.

Overview

Package

Class

Tree

Deprecated

Index

Help

Prev

Next

Frames

No Frames

All Classes

redpajama_set_name: RedPajamaGithub


text:
CFLAGS=$(shell python-config --cflags)
LDFLAGS=$(shell python-config --ldflags)

all: helloc hellof hellopy hellocy

helloc: hello.c
	gcc -o helloc hello.c

hellof: hello.f
	gfortran -o hellof hello.f

hellopy: hello.py
	chmod +x hello.py

hellocy.c: hello.pyx
	cython -2 --embed -o hellocy.c hello.pyx

hellocy: hellocy.c
	gcc $(CFLAGS) -o hellocy hellocy.c -lpython2.7

clean:
	rm helloc hellof hellocy hellocy.c


text:
package io.github.furti.jmxhealth.server.validation;

import io.github.furti.jmxhealth.HealthState;

public class ValidationResult {
	private HealthState state;
	private String message;

	public ValidationResult(HealthState state, String message) {
		super();
		this.state = state;
		this.message = message;
	}

	public ValidationResult(HealthState state) {
		super();
		this.state = state;
	}

	public HealthState getState() {
		return state;
	}

	public String getMessage() {
		return message;
	}
}


text:
from django.contrib.syndication.views import Feed
from models import Post
import markdown
import settings

class LatestEntriesFeed(Feed):
    title = settings.FEED_TITLE
    link = settings.FEED_LINK
    description = settings.FEED_DESCRIPTION

    def items(self):
        return Post.objects.order_by('-date')[:10]

    def item_title(self, item):
        return item.title

    def item_description(self, item):
        return markdown.markdown(item.content)

    def item_pubdate(self, item):
        return item.date


text:
'use strict';

(function(){
	describe('Bakery', function() {

		beforeEach(module(ApplicationConfiguration.applicationModuleName));

		var Bakery, StackUtils, PanelUtils, mockDataBuilder, mockData;

		beforeEach(inject(['Bakery', function (_Bakery_) {
			Bakery = _Bakery_;
		}]));

		beforeEach(inject(['StackUtils', function (_StackUtils_) {
            StackUtils = _StackUtils_;
        }]));

		beforeEach(inject(['PanelUtils', function (_PanelUtils_) {
            PanelUtils = _PanelUtils_;
        }]));

		beforeEach(inject(['mockDataBuilder', function (_mockDataBuilder_) {
            mockDataBuilder = _mockDataBuilder_;
        }]));

		beforeEach(function(){
			mockData = mockDataBuilder.newMockData();
		});

		it('Bakery.getCardResource(cardType) should not return false', function(){
            var cardTypes = [ 'Aspect', 'Trait', 'Feat', 'Augment', 'Item', 'Origin' ];
            for(var i = 0; i < cardTypes.length; i++){
                var cardResource = Bakery.getCardResource(cardTypes[i]);
                expect(cardResource).not.toBeFalsy();
            }
        });

        it('Bakery.getNewCardResource(panel) should not return false', function(){
            for(var i = 0; i < mockData.aspectDeck.cardList.length; i++){
                var newCardResource = Bakery.getNewCardResource(mockData.aspectDeck.cardList[i]);
                expect(newCardResource).not.toBeFalsy();
            }
        });

	});
})();


text:
#import "NSObject.h"

// Not exported
@interface WXNote : NSObject
{
}

+ (void)readFrom:(struct _xmlNode *)arg1 to:(id)arg2 state:(id)arg3;

@end


text:
<?php

defined('_JEXEC') or die('RESTRICTED');

// load base model
require_once (dirname(__FILE__) . '/model.php');

class WFModelUpdates extends WFModel {

    protected static $updateURL = 'https://www.joomlacontenteditor.net/index.php?option=com_updates&format=raw';

    public static function canUpdate() {
        if (!function_exists('curl_init')) {
            return function_exists('file_get_contents') && function_exists('ini_get') && ini_get('allow_url_fopen');
        }

        return true;
    }

    /**
     * Get extension versions
     * @return Array
     */
    public function getVersions() {
        $db = JFactory::getDBO();

        $versions = array('joomla' => array(), 'jce' => array());

        // Get Component xml
        $com_xml = WFXMLHelper::parseInstallManifest(JPATH_ADMINISTRATOR . '/components/com_jce/jce.xml');

        // set component version
        $versions['joomla']['com_jce'] = $com_xml['version'];
        // get mediabox version
        $mediabox_xml_file = WF_JOOMLA15 ? JPATH_PLUGINS . '/system/jcemediabox.xml' : JPATH_PLUGINS . '/system/jcemediabox/jcemediabox.xml';
        // set mediabox version
        if (file_exists($mediabox_xml_file)) {
            $mediabox_xml = WFXMLHelper::parseInstallManifest($mediabox_xml_file);
            $versions['joomla']['plg_jcemediabox'] = $mediabox_xml['version'];
        }

        wfimport('admin.models.plugins');
        $model = new WFModelPlugins();

        // get all plugins
        $plugins = $model->getPlugins();
        // get all extensions
        $extensions = $model->getExtensions();

        foreach ($plugins as $plugin) {
            if ($plugin->core == 0) {

                $file = WF_EDITOR_PLUGINS . '/' . $plugin->name . '/' . $plugin->name . '.xml';

                $xml = WFXMLHelper::parseInstallManifest($file);
                $versions['jce']['jce_' . $plugin->name] = $xml['version'];
            }
        }

        foreach ($extensions as $extension) {
            if ($extension->core == 0) {

                $file = WF_EDITOR_EXTENSIONS . '/' . $extension->folder . '/' . $extension->extension . '.xml';

                $xml = WFXMLHelper::parseInstallManifest($file);
                $versions['jce']['jce_' . $extension->folder . '_' . $extension->extension] = $xml['version'];
            }
        }

        return $versions;
    }

    /**
     * Check for extension updates
     * @return String JSON string of updates
     */
    public function check() {
        $result = false;

        // Get all extensions and version numbers
        $data = array('task' => 'check', 'jversion' => WF_JOOMLA15 ? '1.5' : '2.5');

        wfimport('admin.helpers.extension');

        $component = WFExtensionHelper::getComponent();
        $params = new WFParameter($component->params, '', 'preferences');

        // get update key
        $key = $params->get('updates_key', '');
        $type = $params->get('updates_type', '');

        // encode it
        if (!empty($key)) {
            $data['key'] = urlencode($key);
        }

        if ($type) {
            $data['type'] = $type;
        }

        $req = array();

        // create request data
        foreach ($this->getVersions() as $type => $extension) {
            foreach ($extension as $item => $value) {
                $data[$type . '[' . urlencode($item) . ']'] = urlencode($value);
            }
        }

        foreach ($data as $key => $value) {
            $req[] = $key . '=' . urlencode($value);
        }

        // connect
        $result = $this->connect(self::$updateURL, implode('&', $req));

        return $result;
    }

    /**
     * Download update
     * @return String JSON string
     */
    public function download() {
        $app = JFactory::getApplication();

        jimport('joomla.filesystem.folder');
        jimport('joomla.filesystem.file');

        $config = JFactory::getConfig();

        $result = array('error' => WFText::_('WF_UPDATES_DOWNLOAD_ERROR'));

        $id = JRequest::getInt('id');

        $data = $this->connect(self::$updateURL, 'task=download&id=' . $id);

        if ($data) {
            $data = json_decode($data);

            if (isset($data->error)) {
                return json_encode(array('error' => $data->error));
            }

            // get update file
            if ($data->name && $data->url && $data->hash) {
                // create path for package file
                $path = $app->getCfg('tmp_path') . '/' . basename($data->name);
                // download file
                if ($this->connect($data->url, null, $path)) {
                    if (JFile::exists($path) && @filesize($path) > 0) {
                        // check hash and file type
                        if ($data->hash == md5(md5_file($path)) && preg_match('/\.(zip|tar|gz)$/', $path)) {
                            $result = array('file' => basename($path), 'hash' => $data->hash, 'installer' => $data->installer, 'type' => isset($data->type) ? $data->type : '');
                        } else {
                            // fail and delete file
                            $result = array('error' => WFText::_('WF_UPDATES_ERROR_FILE_VERIFICATION_FAIL'));
                            if (JFile::exists($path)) {
                                @JFile::delete($path);
                            }
                        }
                    } else {
                        $result = array('error' => WFText::_('WF_UPDATES_ERROR_FILE_MISSING_OR_INVALID'));
                    }
                } else {
                    $result = array('error' => WFText::_('WF_UPDATES_DOWNLOAD_ERROR_DATA_TRANSFER'));
                }
            } else {
                $result = array('error' => WFText::_('WF_UPDATES_DOWNLOAD_ERROR_MISSING_DATA'));
            }
        }

        return json_encode($result);
    }

    /**
     * Method to detect the extension type from a package directory
     *
     * @param   string  $dir  Path to package directory
     * @return  mixed  Extension type string or boolean false on fail
     *
     * @copyright   Copyright (C) 2005 - 2012 Open Source Matters, Inc. All rights reserved.
     */
    public static function detectType($dir) {
        // Search the install dir for an XML file
        $files = JFolder::files($dir, '\.xml$', 1, true);

        if (!count($files)) {
            return false;
        }

        foreach ($files as $file) {
            $xml = simplexml_load_file($file);
            if (!$xml) {
                continue;
            }

            $name = $xml->getName();

            if ($name != 'extension' && $name != 'install') {
                unset($xml);
                continue;
            }

            $type = (string) $xml->attributes()->type;

            // Free up memory
            unset($xml);
            return $type;
        }

        // Free up memory.
        unset($xml);
        return false;
    }

    /**
     * Unpacks a file and verifies it as a Joomla element package
     * Supports .gz .tar .tar.gz and .zip
     *
     * @param   string  $archive  The uploaded package filename or install directory
     * @return  mixed  Array on success or boolean false on failure
     *
     * @copyright   Copyright (C) 2005 - 2012 Open Source Matters, Inc. All rights reserved.
     */
    private static function unpack($archive) {
        jimport('joomla.filesystem.file');
        jimport('joomla.filesystem.archive');

        // Temporary folder to extract the archive into
        $tmpdir = uniqid('install_');

        // Clean the paths to use for archive extraction
        $extractdir = JPath::clean(dirname($archive) . '/' . $tmpdir);

        // Do the unpacking of the archive
        try {
            JArchive::extract($archive, $extractdir);
        } catch (Exception $e) {
            return false;
        }

        /*
         * Let's set the extraction directory and package file in the result array so we can
         * cleanup everything properly later on.
         */
        $retval['extractdir'] = $extractdir;
        $retval['packagefile'] = $archive;

        /*
         * Try to find the correct install directory.  In case the package is inside a
         * subdirectory detect this and set the install directory to the correct path.
         *
         * List all the items in the installation directory.  If there is only one, and
         * it is a folder, then we will set that folder to be the installation folder.
         */
        $dirList = array_merge(JFolder::files($extractdir, ''), JFolder::folders($extractdir, ''));

        if (count($dirList) == 1) {
            if (JFolder::exists($extractdir . '/' . $dirList[0])) {
                $extractdir = JPath::clean($extractdir . '/' . $dirList[0]);
            }
        }

        $retval['dir'] = $extractdir;

        /*
         * Get the extension type and return the directory/type array on success or
         * false on fail.
         */
        $retval['type'] = self::detectType($extractdir);

        if ($retval['type']) {
            return $retval;
        } else {
            return false;
        }
    }

    /**
     * Install extension update
     * @return String JSON string
     */
    public function install() {
        jimport('joomla.installer.installer');
        jimport('joomla.installer.helper');
        jimport('joomla.filesystem.file');

        $app = JFactory::getApplication();
        $result = array('error' => WFText::_('WF_UPDATES_INSTALL_ERROR'));

        // get vars
        $file = JRequest::getCmd('file');
        $hash = JRequest::getVar('hash', '', 'POST', 'alnum');
        $method = JRequest::getWord('installer');
        $type = JRequest::getWord('type');

        // check for vars
        if ($file && $hash && $method) {
            $path = $app->getCfg('tmp_path') . '/' . $file;
            // check if file exists
            if (JFile::exists($path)) {
                // check hash
                if ($hash == md5(md5_file($path))) {
                    if ($package = self::unpack($path)) {

                        // Install a JCE Add-on
                        if ($method == 'jce') {
                            wfimport('admin.classes.installer');

                            $installer = WFInstaller::getInstance();

                            // install
                            if ($installer->install($package['dir'])) {
                                // installer message
                                $result = array('error' => '', 'text' => WFText::_($installer->get('message'), $installer->get('message')));
                            }
                            // Install a Joomla! Extension
                        } else {
                            jimport('joomla.installer.installer');

                            // get new Installer instance
                            $installer = JInstaller::getInstance();

                            if ($installer->install($package['dir'])) {
                                // installer message
                                $result = array('error' => '', 'text' => WFText::_($installer->get('message'), $installer->get('message')));
                            }
                        }
                        // Cleanup the install files
                        if (!is_file($package['packagefile'])) {
                            $package['packagefile'] = $app->getCfg('tmp_path') . '/' . $package['packagefile'];
                        }
                        if (is_file($package['packagefile'])) {
                            JInstallerHelper::cleanupInstall($package['packagefile'], $package['extractdir']);
                        }
                    } else {
                        $result = array('error' => WFText::_('WF_UPDATES_ERROR_FILE_EXTRACT_FAIL'));
                    }
                } else {
                    $result = array('error' => WFText::_('WF_UPDATES_ERROR_FILE_VERIFICATION_FAIL'));
                }
            } else {
                $result = array('error' => WFText::_('WF_UPDATES_ERROR_FILE_MISSING_OR_INVALID'));
            }
        }
        return json_encode($result);
    }

    /**
     * @copyright   Copyright (C) 2009 Ryan Demmer. All rights reserved.
     * @copyright   Copyright (C) 2006-2010 Nicholas K. Dionysopoulos
     * @param 	String 	$url URL to resource
     * @param 	Array  	$data [optional] Array of key value pairs
     * @param 	String 	$download [optional] path to file to write to
     * @return 	Mixed 	Boolean or JSON String on error
     */
    protected function connect($url, $data = '', $download = '') {
        @error_reporting(E_ERROR);

        jimport('joomla.filesystem.file');

        $fp = false;

        // get wrappers
        $wrappers = stream_get_wrappers();

        // check for support
        $fopen = function_exists('file_get_contents') && function_exists('ini_get') && ini_get('allow_url_fopen') && in_array('https', $wrappers);

        // try file_get_contents first (requires allow_url_fopen)
        if ($fopen) {
            if ($download) {
                // use Joomla! installer function
                jimport('joomla.installer.helper');
                return @JInstallerHelper::downloadPackage($url, $download);
            } else {
                $options = array('http' => array('method' => 'POST', 'timeout' => 10, 'content' => $data));

                $context = stream_context_create($options);
                $result = @file_get_contents($url, false, $context);

                if ($result === false) {
                    return array('error' => WFText::_('Update check failed : Invalid response from update server'));
                }

                return $result;
            }
            // Use curl if it exists
        } else if (function_exists('curl_init')) {

            // check for SSL support
            $version = curl_version();
            $ssl_supported = ($version['features'] & CURL_VERSION_SSL);

            if (!$ssl_supported) {
                return array('error' => WFText::_('Update check failed : OpenSSL support for CURL is required'));
            }

            $ch = curl_init($url);
            curl_setopt($ch, CURLOPT_HEADER, 0);

            // Pretend we are IE7, so that webservers play nice with us
            curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CLR 1.0.3705; .NET CLR 1.1.4322; Media Center PC 4.0)');
            //curl_setopt($ch, CURLOPT_ENCODING, 'gzip');
            curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 10);
            curl_setopt($ch, CURLOPT_TIMEOUT, 30);
            curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);

            // The @ sign allows the next line to fail if open_basedir is set or if safe mode is enabled
            @curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
            @curl_setopt($ch, CURLOPT_MAXREDIRS, 20);

            @curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);

            if ($data && !$download) {
                curl_setopt($ch, CURLOPT_POST, 1);
                curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
            }

            // file download
            if ($download) {
                $fp = @fopen($download, 'wb');
                @curl_setopt($ch, CURLOPT_FILE, $fp);
            }

            $result = curl_exec($ch);

            // file download
            if ($download && $result === false) {
                return array('error' => 'TRANSFER ERROR : ' . curl_error($ch));
            }

            curl_close($ch);

            // close fopen handler
            if ($fp) {
                @fclose($fp);
            }

            return $result;

            // error - no update support
        } else {
            return array('error' => WFText::_('WF_UPDATES_DOWNLOAD_ERROR_NO_CONNECT'));
        }

        return array('error' => WFText::_('WF_UPDATES_DOWNLOAD_ERROR_NO_CONNECT'));
    }
}

?>


text:
/**
 * 简单的复选下拉框控件, 适用于数据量少的情况
 * 封装了字段处理逻辑
 *
 * Created by GUY on 2015/10/29.
 * @class BI.AbstractValueChooser
 * @extends BI.Widget
 */
BI.AbstractValueChooser = BI.inherit(BI.Widget, {

    _const: {
        perPage: 100
    },

    _defaultConfig: function () {
        return BI.extend(BI.AbstractValueChooser.superclass._defaultConfig.apply(this, arguments), {
            items: null,
            itemsCreator: BI.emptyFn,
            cache: true
        });
    },

    _valueFormatter: function (v) {
        var text = v;
        if (this.options.valueFormatter) {
            return this.options.valueFormatter(v);
        }
        if (BI.isNotNull(this.items)) {
            BI.some(this.items, function (i, item) {
                // 把value都换成字符串
                if (item.value === v || item.value + "" === v) {
                    text = item.text;
                    return true;
                }
            });
        }
        return text;
    },

    _getItemsByTimes: function (items, times) {
        var res = [];
        for (var i = (times - 1) * this._const.perPage; items[i] && i < times * this._const.perPage; i++) {
            res.push(items[i]);
        }
        return res;
    },

    _hasNextByTimes: function (items, times) {
        return times * this._const.perPage < items.length;
    },

    _itemsCreator: function (options, callback) {
        var self = this, o = this.options;
        if (!o.cache || !this.items) {
            o.itemsCreator({}, function (items) {
                self.items = items;
                call(items);
            });
        } else {
            call(this.items);
        }
        function call (items) {
            var keywords = (options.keywords || []).slice();
            var resultItems = items;
            if(BI.isNotEmptyArray(keywords)) {
                resultItems = [];
                BI.each(keywords, function (i, kw) {
                    var search = BI.Func.getSearchResult(items, kw);
                    resultItems = resultItems.concat(search.match).concat(search.find);
                });
                resultItems = BI.uniq(resultItems);
            }
            if (options.selectedValues) {// 过滤
                var filter = BI.makeObject(options.selectedValues, true);
                resultItems = BI.filter(resultItems, function (i, ob) {
                    return !filter[ob.value];
                });
            }
            if (options.type === BI.MultiSelectCombo.REQ_GET_ALL_DATA) {
                callback({
                    items: resultItems
                });
                return;
            }
            if (options.type === BI.MultiSelectCombo.REQ_GET_DATA_LENGTH) {
                callback({count: resultItems.length});
                return;
            }
            callback({
                items: self._getItemsByTimes(resultItems, options.times),
                hasNext: self._hasNextByTimes(resultItems, options.times)
            });
        }
    },

    _assertValue: function (v) {
        v = v || {};
        var value = v;
        if (v.type === BI.Selection.Multi && BI.isNotNull(this.items)) {
            var isAllSelect = BI.difference(BI.map(this.items, "value"), v.value).length === 0;
            if (isAllSelect) {
                value = {
                    type: BI.Selection.All,
                    value: [],
                };
            }
        }
        return value;
    },
});


text:
class Solution {
public:
    vector<string> addOperators(string num, int target) {
        vector<string> answers;
        string operation;
        dfs(0, 0, operation, num, target, answers);
        return answers;
    }
    // change all numbers to long long to avoid overflow
    void dfs(size_t pos, long long prev, string &operation, const string &num, long long target, vector<string> &answers) {
        if (pos >= num.length()) {
            if (0 == target) {
                answers.push_back(operation);
            }
            return;
        }
        long long current = 0;
        for (size_t i = pos; i < num.length(); ++ i) {
            // avoid numbers starting with 0, i.e. 01
            if ('0' == num[pos] && i > pos) {
                break;
            }
            current = current * 10 + static_cast<int> (num[i] - '0');
            if (pos > 0) {
                operation += "+";
            }
            operation += num.substr(pos, i - pos + 1);
            dfs(i + 1, current, operation, num, target - current, answers);
            operation.erase(operation.length() - (i - pos + 1));
            if (pos > 0) {
                operation.pop_back();
            }
            if (pos > 0) {
                operation += "-";
                operation += num.substr(pos, i - pos + 1);
                dfs(i + 1, - current, operation, num, target + current, answers);
                operation.erase(operation.length() - (i - pos + 2));
                operation += "*";
                operation += num.substr(pos, i - pos + 1);
                // keep previous result to respect precedence of multiplication
                dfs(i + 1, prev * current, operation, num, target + prev - prev * current, answers);
                operation.erase(operation.length() - (i - pos + 2));
            }
        }
    }
};


text:
'use strict';

Object.defineProperty(exports, "__esModule", {
  value: true
});

var _react = require('react');

var _react2 = _interopRequireDefault(_react);

var _reactAddonsPureRenderMixin = require('react-addons-pure-render-mixin');

var _reactAddonsPureRenderMixin2 = _interopRequireDefault(_reactAddonsPureRenderMixin);

var _svgIcon = require('../../svg-icon');

var _svgIcon2 = _interopRequireDefault(_svgIcon);

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }

var PlacesKitchen = _react2.default.createClass({
  displayName: 'PlacesKitchen',

  mixins: [_reactAddonsPureRenderMixin2.default],

  render: function render() {
    return _react2.default.createElement(
      _svgIcon2.default,
      this.props,
      _react2.default.createElement('path', { d: 'M18 2.01L6 2c-1.1 0-2 .89-2 2v16c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.11-.9-1.99-2-1.99zM18 20H6v-9.02h12V20zm0-11H6V4h12v5zM8 5h2v3H8zm0 7h2v5H8z' })
    );
  }
});

exports.default = PlacesKitchen;
module.exports = exports['default'];


text:
package space.gatt.GasaiBot.commands.Memes;

import de.btobastian.javacord.DiscordAPI;
import de.btobastian.javacord.entities.User;
import de.btobastian.javacord.entities.message.Message;
import space.gatt.GasaiBot.Main;
import space.gatt.JavacordCommander.annotations.*;

import java.io.File;

/**
 * Created by Zach G on 06-Apr-16.
 */

@Command("nope")
@Syntax("nope")
@Usage("nope")
@Permissions()
@Group("Meme")
@Description("Nope.")
@CommandSettings(deleteInitatingMsg = false, sendResponseViaPM = false)
public class Nope {
	@IMethod
	public static File command(DiscordAPI api, Message message, User user, String[] args) {
		return Main.getImageStorer().getImage("nope");
	}
}


text:
// Copyright (c) Microsoft.  All Rights Reserved.  Licensed under the Apache License, Version 2.0.  See License.txt in the project root for license information.

using System;

namespace Microsoft.NodejsTools.Npm.SPI
{
    internal abstract class AbstractNpmLogSource : INpmLogSource
    {
        public event EventHandler CommandStarted;

        protected void OnCommandStarted()
        {
            var handlers = CommandStarted;
            if (null != handlers)
            {
                handlers(this, EventArgs.Empty);
            }
        }

        protected void FireNpmLogEvent(string logText, EventHandler<NpmLogEventArgs> handlers)
        {
            if (null != handlers && !string.IsNullOrEmpty(logText))
            {
                handlers(this, new NpmLogEventArgs(logText));
            }
        }

        public event EventHandler<NpmLogEventArgs> OutputLogged;

        protected void OnOutputLogged(string logText)
        {
            FireNpmLogEvent(logText, OutputLogged);
        }

        public event EventHandler<NpmLogEventArgs> ErrorLogged;

        protected void OnErrorLogged(string logText)
        {
            FireNpmLogEvent(logText, ErrorLogged);
        }

        public event EventHandler<NpmExceptionEventArgs> ExceptionLogged;

        protected void OnExceptionLogged(Exception e)
        {
            var handlers = ExceptionLogged;
            if (null != handlers)
            {
                handlers(this, new NpmExceptionEventArgs(e));
            }
        }

        public event EventHandler<NpmCommandCompletedEventArgs> CommandCompleted;

        protected void OnCommandCompleted(
            string arguments,
            bool withErrors,
            bool cancelled)
        {
            var handlers = CommandCompleted;
            if (null != handlers)
            {
                handlers(this, new NpmCommandCompletedEventArgs(arguments, withErrors, cancelled));
            }
        }
    }
}


text: sudo docker build -t deepdoomde-cpu .


text:
from Adafruit_CharLCDPlate import Adafruit_CharLCDPlate
from itertools import cycle
from threading import Timer

class LCDLinearScroll:
	"""
	A class which enables one to display a linear list of items.
	The list of items can be scrolled through
	"""

	def __init__(self, items, display=Adafruit_CharLCDPlate(), select_callback=None):
		self.select_callback = select_callback
		self.display = display
		self.items = items
		self.index = -1
		self.colours = {'Red' : self.display.RED ,
			'Yellow': self.display.YELLOW,
			'Green' : self.display.GREEN,
			'Teal': self.display.TEAL,
			'Blue'  : self.display.BLUE,
			'Violet': self.display.VIOLET}

	def display_message(self, msg):
		"Displays an arbitrary message regardless of items"
		self.display.clear()
		self.display.message(msg)

	def display_next(self):
		"Displays the next item in the cycle of items"
		self.index += 1
		if self.index == len(self.items):
			self.index = 0
		self.display_current()

	def display_prev(self):
		"Displays the previous item in the cycle of items"
		self.index -= 1
		if self.index <= -1:
			self.index = len(self.items) - 1
		self.display_current()

	def display_current(self):
		"Displays the current message"
		if len(items) > 0:
			self.display_message(self.items[self.index])

	def change_colour(self, colour):
		self.display.backlight(self.colours[colour])

	def cycle_colours(self):
		c_iter = cycle(self.colours.iterkeys())
		def repeat():
			self.change_colour(next(c_iter))
			self.timer = Timer(0.5, repeat)
			self.timer.start()

		self.timer = Timer(0.5, repeat)
		self.timer.start()

	def stop_cycle(self):
		self.timer.cancel()

	def setup_scroll_events(self):
		"""Sets up the scroll events such that left is cycles backwards
		and right cycles forwards"""

		buttons = {'select': self.display.LCD, 'left': self.display.LEFT, 'right': self.display.RIGHT}

		while True:
			if self.display.buttonPressed(buttons['left']):
				while self.display.buttonPressed(buttons['left']):
					pass
				self.display_prev()

			if self.display.buttonPressed(buttons['right']):
				while self.display.buttonPressed(buttons['right']):
					pass

			if self.display.buttonPressed(buttons['select']):
				while self.display.buttonPressed(buttons['select']):
					pass
				if self.select_callback is not None:
					self.select_callback()

if __name__ == '__main__':
	items = ('Item 1', 'Item 2', 'Item 3', 'Item 4', 'Item 5', 'Item 6')
	scroller = LCDLinearScroll(items)
	scroller.display_message("hello")
	scroller.cycle_colours()
	#scroller.setup_scroll_events()


text:
{-# LANGUAGE TemplateHaskell, PackageImports, FlexibleInstances #-}
import Prelude hiding (foldr)
import Text.Trifecta
import System.IO
import Control.Monad.State
import Control.Lens
import Data.Foldable
import Control.Applicative
import qualified Data.Map as Map
import qualified Control.Exception as E
import Data.Void
import System.IO.Unsafe
import System.IO.Error hiding (try)
import Data.Monoid
import qualified Data.ByteString as BS
import System.Directory
import qualified Data.Serialize as S
import System.Environment

import "combinator-interactive" Data.Combinator

data Command = Eval (Expr String)
    | Run (Expr String)
    | Define String (Expr String)
    | Load FilePath String
    | Save FilePath (Expr String)
    | Del String
    | Quit

parseCommand :: Parser Command
parseCommand = try define <|> run <|> load <|> save <|> del <|> quit <|> eval where
    run = do
        symbol ":run"
        Run <$> ccParser
    eval = do
        Eval <$> ccParser
    define = do
        var <- variable
        symbol "="
        Define var <$> ccParser
    load = do
        symbol ":load"
        path <- stringLiteral
        name <- option "main" $ variable
        return $ Load path name
    save = do
        symbol ":save"
        path <- stringLiteral
        expr <- ccParser
        return $ Save path expr
    del = do
        symbol ":del"
        Del <$> variable
    quit = Quit <$ symbol ":quit"

consE x xs = S :$ (S :$ I :$ (K :$ x)) :$ (K :$ xs)

runLazy :: Expr Void -> IO ()
runLazy expr = input >>= output . vacuous . eval . (expr :$)

end = consE (churchNumeral # 256) end

input :: IO (Expr Void)
input = unsafeInterleaveIO $ E.catch g $ \e -> if isEOFError e then return end else fail (show e) where
    g = do
        ch <- getChar
        consE (_Combinator # churchNumeral # enum # ch) <$> input

output :: Expr () -> IO ()
output e = case e `apply` Var () of
    Var () :$ x :$ xs -> case x ^? churchNumeral of
        Just n
            | n >= 256 -> return ()
            | otherwise -> putChar (n ^. enum) >> output xs
        Nothing -> fail "The result is not a number"
    _ -> fail "The result is not a list"

data Env = Env
    { _definitions :: Map.Map String (Expr String)
    }
makeLenses ''Env

applyDefs :: Map.Map String (Expr String) -> Expr String -> Expr String
applyDefs = foldr (.) id . map (uncurry subst) . Map.toList

prompt :: StateT Env IO ()
prompt = do
    lift $ putStr "lazy> "
    lift $ hFlush stdout
    cmd <- lift getLine
    case parseString parseCommand mempty cmd of
        Success a -> case a of
            Eval expr -> do
                m <- use definitions
                lift $ putStrLn $ ccExpression # eval (applyDefs m expr)
                prompt
            Run expr -> do
                m <- use definitions
                lift $ runLazy (fmap (\x -> error $ "Unexpected free variable: " ++ x) (applyDefs m expr))
                    `E.catch` \(E.ErrorCall msg) -> hPutStrLn stderr msg
                    `E.catch` \e -> hPutStrLn stderr (show (e :: E.IOException))
                prompt
            Define name expr
                | name `Data.Foldable.elem` expr -> do
                    lift $ hPutStrLn stderr "Recursive definitions are not allowed"
                    prompt
                | otherwise -> do
                    m <- use definitions
                    definitions . at name ?= applyDefs m expr
                    dump
                    prompt
            Load path name -> do
                r <- parseFromFile ccParser path
                case r of
                    Just expr -> do
                        definitions . at name ?= expr
                        dump
                        lift $ putStrLn $ "Loaded: " ++ name ++ "."
                        prompt
                    Nothing -> prompt
            Save path expr -> do
                m <- use definitions
                lift $ writeFile path $ ccExpression # eval (applyDefs m expr)
                prompt
            Del name -> do
                definitions . at name .= Nothing
                prompt
            Quit -> return ()
        Failure doc -> do
            lift $ hPutStrLn stderr $ show doc
            prompt

dump = do
    path <- lift $ (++"/.lazyi-env") <$> getHomeDirectory
    env <- get
    lift $ BS.writeFile path $ S.encode env

defaultEnv = Env Map.empty

instance S.Serialize (Expr String) where
    put expr = S.put (ccExpression # expr)
    get = S.get >>= maybe (fail "parse error") return . preview ccExpression

instance S.Serialize Env where
    put (Env m) = S.put m
    get = Env <$> S.get

main = getArgs >>= \r -> case r of
    [] -> do
        path <- (++"/.lazyi-env") <$> getHomeDirectory
        b <- doesFileExist path
        let w = hPutStrLn stderr "Warning: .lazyi-env is broken." >> return defaultEnv
        env <- if b
            then S.decode <$> BS.readFile path >>= either (const w) return
            else return defaultEnv
        evalStateT prompt env


text:
package net.hillsdon.reviki.wiki.renderer.creole.ast;

public class Anchor extends ASTNode {
  private final String _anchor;

  public Anchor(final String anchor) {
    _anchor = anchor;
  }

  /**
   * Get the name of this anchor.
   */
  public String getAnchor() {
    return _anchor;
  }
}


text:
<?php

class Application_Model_DbTable_DbUsers extends Zend_Db_Table_Abstract
{

    protected $_name = 'rsv_acl_user';

    public function setName($name)
    {
    	$this->_name=$name;
    }
	//function get user info from database
	public function getUserInfo($user_id)	{
		$sql = "SELECT au.`fullname`,au.`email`, au.`username`, au.`user_type_id`, aut.`user_type`, au.`LocationId`
				FROM `rsv_acl_user` AS au
				INNER JOIN `rsv_acl_user_type` AS aut ON(au.`user_type_id` = aut.`user_type_id`)
				WHERE user_id=" . $user_id;
		$row = $this->getAdapter()->fetchRow($sql);
		if(!$row) return NULL;
		return $row;
	}

	//function get user id from database
	public function getUserID($email)
	{
		$select=$this->select();
			$select->from($this,'user_id')
			->where('email=?',$email);
		$row=$this->fetchRow($select);
		if(!$row) return NULL;
		return $row['user_id'];
	}

	/**
	 * To check email have or not
	 * have before allow to user register
	 * @param string $email
	 */
	public function checkEmail($email){
		$db = $this->getAdapter();
		$sql = "SELECT user_id FROM ". $this->_name ." WHERE email = '". $email ."'";
		$row = $db->fetchRow($sql);
		return $row['user_id'];
	}

    /**
     * To validate the user name
     * and password is valids or not
     * @param <string> $username
     * @param <string> $password
     */
    public function userAuthenticate($email,$password)
	{

		$db_adapter = Application_Model_DbTable_DbUsers::getDefaultAdapter();
        $auth_adapter = new Zend_Auth_Adapter_DbTable($db_adapter);

        $auth_adapter->setTableName($this->_name) // table where users are stored
                     ->setIdentityColumn('email') // field name of user in the table
                     ->setCredentialColumn('password') // field name of password in the table
                     ->setCredentialTreatment('MD5(?) AND status=1'); // optional if password has been hashed

        $auth_adapter->setIdentity($email); // set value of username field
        $auth_adapter->setCredential($password);// set value of password field

        //instantiate Zend_Auth class
        $auth = Zend_Auth::getInstance();

        $result = $auth->authenticate($auth_adapter);

        if($result->isValid()){
           	return true;
        }else{
		   return false;
        }
	}

	function changePassword($newpwd, $id){
		$_user_data=array(
			'password'=> MD5($newpwd),
			'modified_date'=> date('Y-m-d H:i:s')
	    );

		$where=$this->getAdapter()->quoteInto('user_id=?', $id);

		return  $this->update($_user_data,$where);
	}

	function comfirmEmail($email, $psw){
		$_user_data=array(
				'status'=> 1,
				'modified_date'=> date('Y-m-d H:i:s')
		);

		$where='email = "'. $email . '" AND password = "'. $psw .'" AND status = 0';

		return  $this->update($_user_data,$where);
	}

	public function getUserLists($exp='', $sqlonly = false)
	{
		$sql="SELECT
				id
				,`name`
				,email
				,age
				,title
			 FROM ". $this->_name ." WHERE `status`=1 ".$exp;
		if($sqlonly) return $sql;
		$db=$this->getAdapter();
		return $db->fetchAll($sql);
	}

	//check email
	public function isExistEmail($email){
		$sql="SELECT email FROM ". $this->_name ." WHERE email='".$email."'";
		$rs=$this->getAdapter()->fetchAll($sql);
		if($rs) return true;
		return false;
	}

	/**
	 * To check email have or not
	 * have before allow to user register
	 * @param string $email
	 */
	public function checkStatusByEmail($email){
		$db = $this->getAdapter();
		$sql = "SELECT status FROM ". $this->_name ." WHERE email = '". $email ."'";
		$row = $db->fetchRow($sql);
		return $row['status'];
	}

	/**
	 * To get all acl of a user type
	 * @param string $user_type_id
	 */
	public function getArrAcl($user_type_id){
		$db = $this->getAdapter();
		$sql = "SELECT aa.module, aa.controller, aa.action FROM rsv_acl_user_access AS ua
		INNER JOIN rsv_acl_acl AS aa ON (ua.acl_id=aa.acl_id) WHERE ua.user_type_id='".$user_type_id."'";
		$rows = $db->fetchAll($sql);
		return $rows;
	}

	public function getArrConMod( $user_type_id, $module){
		$db = $this->getAdapter();
		$sql = "SELECT DISTINCT aa.controller
				FROM rsv_acl_user_access AS ua
					 INNER JOIN rsv_acl_acl AS aa ON (ua.acl_id=aa.acl_id)
				WHERE ua.user_type_id='".$user_type_id."' AND aa.module = '" . $module ."' AND aa.status = 1 ORDER BY aa.rank ASC";
		//echo $sql;exit;
		$cols = $db->fetchCol($sql);
		return $cols;
	}
}


text:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;

namespace CatalogApi.Models
{
    public class ProductCategory
    {
        public string Name { get; set; }
        public IEnumerable<Product> Products { get; set; }
    }
}


text:
class RecipesController < ApplicationController
  layout 'recipe'

  before_filter do
    @page_title = "RailsWizard Recipes"
    @back = '/'
    if signed_in?
      @user_pending_recipes = Recipe.where(:user_id => current_user.id).pending
      @user_recipes = Recipe.where(:user_id => current_user.id).approved
    end
  end

  before_filter :login_required, :only => [:create, :new, :edit, :update]
  before_filter :access_required, :only => [:edit, :update]
  before_filter :admin_required, :only => [:moderate, :toggle]

  def index
    render :text => 'Not Ready'
    @heading = "All Recipes"
    @recipes = Recipe.all(:order => [['category', 1]])
  end

  def new
    @heading = "Create a New Recipe"
  end

  def create
    @recipe = Recipe.new(params[:recipe])
    @recipe.user = current_user
    if @recipe.save
      redirect_to recipe
    else
      flash.now[:alert] = 'Error creating recipe.'
      render :action => 'new'
    end
  end

  def show
    @heading = "Recipe: <em>#{recipe.name}</em>".html_safe
  end

  def moderate
    @pending_recipes = Recipe.pending
    @recipes = Recipe.approved
  end

  def toggle
    @recipe = Recipe.from_param(params[:id])

    @recipe.approved = !@recipe.approved?
    if @recipe.save
      flash[:notice] = "Toggled successfully."
    else
      flash[:alert] = "Something went wrong."
    end
    redirect_to :back
  end

  def update
    if recipe.update_attributes(params[:recipe])
      redirect_to recipe_path(recipe)
    else
      flash[:alert] = 'Error saving recipe.'
      redirect_to :back
    end
  end

  protected

  def recipe
    @recipe ||= Recipe.from_param(params[:id]) || Recipe.new
  end
  helper_method :recipe

  def access_required
    unless current_user.admin? || @recipe.user == current_user
      flash[:alert] = "You don't have permission to edit that."
      redirect_to :back
    end
  end
end


text:
module Rdkafka
  class Producer
    # Delivery report for a successfully produced message.
    class DeliveryReport
      # The partition this message was produced to.
      # @return [Integer]
      attr_reader :partition

      # The offset of the produced message.
      # @return [Integer]
      attr_reader :offset

      # Error in case happen during produce.
      # @return [String]
      attr_reader :error

      private

      def initialize(partition, offset, error = nil)
        @partition = partition
        @offset = offset
        @error = error
      end
    end
  end
end


text:
<!DOCTYPE html>

    <title>Chapter 109: Ahab and Starbuck in the Cabin | Moby Dick | Herman Melville | Lit2Go ETC</title>
    <link rel="stylesheet" href="http://etc.usf.edu/lit2go/css/screenless.css" type="text/css" media="screen" title="no title" charset="utf-8">
    <link rel="stylesheet" href="http://etc.usf.edu/lit2go/css/printless.css" type="text/css" media="print" title="no title" charset="utf-8">

          Lit2Go

<form action="http://etc.usf.edu/lit2go/search/"><input type="text" name="q" placeholder="Search" value=""></form>

Authors

Books

Genres

Collections

Readability

      Moby Dick

      by Herman Melville

      Chapter 109: Ahab and Starbuck in the Cabin

        Additional Information

            Year Published:
            1851

            Language:
            English

            Country of Origin:
            United States of America

            Source:
            Melville H. (1851). Moby Dick.London, England: Richard Bently.

            Readability:

                Flesch–Kincaid Level:
                9.8

            Word Count:
            972

            Genre:
            Adventure

            Keywords:
            19th century literature, american literature, herman melville, moby dick

            ✎ Cite This

  Share
  |

Downloads

          Audio

          Passage PDF

            APA

            MLA

            Chicago

            Melville, H. (1851). Chapter 109: Ahab and Starbuck in the Cabin. Moby Dick (Lit2Go Edition). Retrieved February 15, 2016, from http://etc.usf.edu/lit2go/42/moby-dick/790/chapter-109-ahab-and-starbuck-in-the-cabin/

            Melville, Herman. "Chapter 109: Ahab and Starbuck in the Cabin." Moby Dick. Lit2Go Edition. 1851. Web. <http://etc.usf.edu/lit2go/42/moby-dick/790/chapter-109-ahab-and-starbuck-in-the-cabin/>. February 15, 2016.

            Herman Melville, "Chapter 109: Ahab and Starbuck in the Cabin," Moby Dick, Lit2Go Edition, (1851), accessed February 15, 2016, http://etc.usf.edu/lit2go/42/moby-dick/790/chapter-109-ahab-and-starbuck-in-the-cabin/.

Back

Next

                  <audio controls style="width:99%;">
            <source src="http://etc.usf.edu/lit2go/audio/mp3/moby-dick-110-chapter-109-ahab-and-starbuck-in-the-cabin.790.mp3" type="audio/mpeg" />
                          <source src="http://etc.usf.edu/lit2go/audio/ogg/moby-dick-110-chapter-109-ahab-and-starbuck-in-the-cabin.790.ogg" type="audio/ogg" />
                        The embedded audio player requires a modern internet browser. You should visit Browse Happy and update your internet browser today!
          </audio>

	According to usage they were pumping the ship next morning; and lo! no inconsiderable oil came up with the water; the casks below must have sprung a bad leak. Much concern was shown; and Starbuck went down into the cabin to report this unfavorable affair.

	In Sperm-whalemen with any considerable quantity of oil on board, it is a regular semiweekly duty to conduct a hose into the hold, and drench the casks with sea-water; which afterwards, at varying intervals, is removed by the ship’s pumps. Hereby the casks are sought to be kept damply tight; while by the changed character of the withdrawn water, the mariners readily detect any serious leakage in the precious cargo.

	Now, from the South and West the Pequod was drawing nigh to Formosa and the Bashee Isles, between which lies one of the tropical outlets from the China waters into the Pacific. And so Starbuck found Ahab with a general chart of the oriental archipelagoes spread before him; and another separate one representing the long eastern coasts of the Japanese islands- Niphon, Matsmai, and Sikoke. With his snow-white new ivory leg braced against the screwed leg of his table, and with a long pruning-hook of a jack-knife in his hand, the wondrous old man, with his back to the gangway door, was wrinkling his brow, and tracing his old courses again.

	“Who’s there?” hearing the footstep at the door, but not turning round to it. “On deck! Begone!”

	“Captain Ahab mistakes; it is I. The oil in the hold is leaking, sir. We must up Burtons and break out.”

	“Up Burtons and break out? Now that we are nearing Japan; heave-to here for a week to tinker a parcel of old hoops?”

	“Either do that, sir, or waste in one day more oil than we may make good in a year. What we come twenty thousand miles to get is worth saving, sir.”

	“So it is, so it is; if we get it.”

	“I was speaking of the oil in the hold, sir.”

	“And I was not speaking or thinking of that at all. Begone! Let it leak! I’m all aleak myself. Aye! leaks in leaks! not only full of leaky casks, but those leaky casks are in a leaky ship; and that’s a far worse plight than the Pequod’s, man. Yet I don’t stop to plug my leak; for who can find it in the deep-loaded hull; or how hope to plug it, even if found, in this life’s howling ale? Starbuck! I’ll not have the Burtons hoisted.”

	“What will the owners say, sir?”

	“Let the owners stand on Nantucket beach and outyell the Typhoons. What cares Ahab? Owners, owners? Thou art always prating to me, Starbuck, about those miserly owners, as if the owners were my conscience. But look ye, the only real owner of anything is its commander; and hark ye, my conscience is in this ship’s keel.- On deck!”

	“Captain Ahab,” said the reddening mate, moving further into the cabin, with a daring so strangely respectful and cautious that it almost seemed not only every way seeking to avoid the slightest outward manifestation of itself, but within also seemed more than half distrustful of itself; “A better man than I might well pass over in thee what he would quickly enough resent in a younger man; aye, and in a happier, Captain Ahab.”

	“Devils! Dost thou then so much as dare to critically think of me?- On deck!”

	“Nay, sir, not yet; I do entreat. And I do dare, sir- to be forbearing! Shall we not understand each other better than hitherto, Captain Ahab?”

	Ahab seized a loaded musket from the rack (forming part of most South-Sea-men’s cabin furniture), and pointing it towards Starbuck, exclaimed: “There is one God that is Lord over the earth, and one Captain that is lord over the Pequod.- On deck!”

	For an instant in the flashing eyes of the mate, and his fiery cheeks, you would have almost thought that he had really received the blaze of the levelled tube. But, mastering his emotion, he half calmly rose, and as he quitted the cabin, paused for an instant and said: “Thou hast outraged, not insulted me, sir; but for that I ask thee not to beware of Starbuck; thou wouldst but laugh; but let Ahab beware of Ahab; beware of thyself, old man.”

	“He waxes brave, but nevertheless obeys; most careful bravery that!” murmured Ahab, as Starbuck disappeared. “What’s that he said- Ahab beware of Ahab- there’s something there!” Then unconsciously using the musket for a staff, with an iron brow he paced to and fro in the little cabin; but presently the thick plaits of his forehead relaxed, and returning the gun to the rack, he went to the deck.

	“Thou art but too good a fellow, Starbuck,” he said lowly to the mate; then raising his voice to the crew: “Furl the t’gallant-sails, and close-reef the top-sails, fore and aft; back the main-yard; up Burtons, and break out in the main-hold.”

	It were perhaps vain to surmise exactly why it was, that as respecting Starbuck, Ahab thus acted. It may have been a flash of honesty in him; or mere prudential policy which, under the circumstance, imperiously forbade the slightest symptom of open disaffection, however transient, in the important chief officer of his ship. However it was, his orders were executed; and the Burtons were hoisted.

Back

Next

            This collection of children's literature is a part of the Educational Technology Clearinghouse and is funded by various grants.

            Copyright © 2006—2016 by the Florida Center for Instructional Technology, College of Education, University of South Florida.

License

Credits

FAQ

Giving

This document was downloaded from Lit2Go, a free online collection of stories and poems in Mp3 (audiobook) format published by the Florida Center for Instructional Technology. For more information, including classroom activities, readability data, and original sources, please visit http://etc.usf.edu/lit2go/42/moby-dick/790/chapter-109-ahab-and-starbuck-in-the-cabin/.

Lit2Go: Moby Dick

Chapter 109: Ahab and Starbuck in the Cabin


text:
<?php

namespace SphinxSearch\Tool\Source\Writer;

use SphinxSearch\Tool\Source\Exception\NotValidDocumentException;

/**
 * Class TSV
 *
 */
class TSV implements SourceInterface
{
    /**
     * @var resource
     */
    protected $handle;

    /**
     * Constructor
     */
    public function __construct()
    {
        $this->openURI('php://output');
    }

    /**
     * {@inheritdoc}
     */
    public function openURI($uri)
    {
        $this->handle = fopen($uri, 'w');
        if (!$this->handle) {
            return false;
        } else {
            return true;
        }
    }

    /**
     * {@inheritdoc}
     */
    public function beginOutput()
    {
        return '';
    }

    /**
     * {@inheritdoc}
     */
    public function addDocument(array $doc)
    {
        if (!isset($doc['id'])) {
            throw new NotValidDocumentException('Document array must have an element with "id" key');
        }
        ob_start();
        $len = fputcsv($this->handle, $doc, "\t");
        if ($len === false) {
            throw new \RuntimeException('Error writing document');
        }
        return ob_get_clean();
    }

    /**
     * {@inheritdoc}
     */
    public function endOutput()
    {
        fclose($this->handle);
        return '';
    }
}


text:
package com.mokalab.butler.adapter.viewtype;

import android.content.Context;
import android.view.View;

import com.mokalab.butler.util.ViewUtils;

/**
 * A View Holder wrapper class.
 * Mainly used for Adapters to implement View Holder pattern.
 *

 * Created by Pirdad S. on 12/15/2013.
 */
public abstract class AdapterViewHolder<T> {

    /**
     * Get the associated layout resource id for the passed row object.
     * @return int resource id of the layout. ie. R.layout.example_layout
     */
    public abstract int getLayoutResource(T data);

    /**
     * Called as a cycle flow method, generally after {@link #getLayoutResource(Object)}.
     * The responsibility here would be to find the child views from the rootView and
     * hold their reference so that when {@link #onSetData(android.content.Context, Object, int)} gets called, all it
     * has to do is set the associate data to the views.
     * ie. mTxtTitleView = rootView.findViewById(R.id.txt_title);
     */
    public abstract void onFindViews(Context ctx, View rootView);

    /**
     * Called as a cycle flow method after {@link #onFindViews(android.content.Context, android.view.View)}.
     * Responsibility of this method is to simply map and set data from the passed object
     * to the child views that this view holder holds.
     * ie. mTxtTitleView.setText(data.getTitle());
     */
    public abstract void onSetData(Context ctx, T data, int position);

    /**
     * Use this method to Find a View by it's Id. The from View is required. The is the
     * parent View of the id that was passed. You won't have
     * to cast the return of this method.

     * May throw ClassCastException if the passed id's type is not the same as T.
     */
    protected <T extends View> T findView(View from, int id) {

        return ViewUtils.findView(from, id);
    }
}


text:
Spectrometer Package
====================

.. autoclass:: pychron.spectrometer.field_table.FieldTable
   :members:

.. autoclass:: pychron.spectrometer.fieldmixin.FieldMixin
   :members:

.. autoclass:: pychron.spectrometer.base_magnet.BaseMagnet
   :members:

.. autoclass:: pychron.spectrometer.base_detector.BaseDetector
   :members:

Thermo
------
The thermo package (pychron.spectrometer.thermo) contains abstractions for interfacing a Thermo Scientific mass spectrometer
via RemoteControlService.cs

Spectrometers
~~~~~~~~~~~~~
.. autoclass:: pychron.spectrometer.thermo.spectrometer.base.ThermoSpectrometer
   :members:

.. autoclass:: pychron.spectrometer.thermo.spectrometer.argus.ArgusSpectrometer
   :members:

.. autoclass:: pychron.spectrometer.thermo.spectrometer.helix.HelixSpectrometer
   :members:

.. autoclass:: pychron.spectrometer.thermo.magnet.base.ThermoMagnet
   :members:

.. autoclass:: pychron.spectrometer.thermo.magnet.argus.ArgusMagnet
   :members:

.. autoclass:: pychron.spectrometer.thermo.magnet.helix.HelixMagnet
   :members:

Isotopx
----------
The Isotopx package (pychron.spectrometer.isotopx) contains abstractions for interfacing a Isotopx mass
spectrometer via IsotopxRCS

Spectrometers
~~~~~~~~~~~~~
.. autoclass:: pychron.spectrometer.isotopx.spectrometer.base.IsotopxSpectrometer
   :members:

.. autoclass:: pychron.spectrometer.isotopx.spectrometer.ngx.NGXSpectrometer
   :members:

.. autoclass:: pychron.spectrometer.isotopx.magnet.base.IsotopxMagnet
   :members:

.. autoclass:: pychron.spectrometer.isotopx.magnet.ngx.NGXMagnet
   :members:

MAP
--------------
The map package (pychron.spectrometer.map) contains abstractions for interfacing with a Mass Analyzer Products (MAP)
mass spectromter. Developed for New Mexico Geochronology Research Laboratory's MAP215-50

.. autoclass:: pychron.spectrometer.map.magnet.MapMagnet
   :members:


text:
using System.Text.Json;
using Azure.Core;

namespace Azure.ResourceManager.EventGrid.Models
{
    public partial class EventGridDomainPatch : IUtf8JsonSerializable
    {
        void IUtf8JsonSerializable.Write(Utf8JsonWriter writer)
        {
            writer.WriteStartObject();
            if (Optional.IsCollectionDefined(Tags))
            {
                writer.WritePropertyName("tags");
                writer.WriteStartObject();
                foreach (var item in Tags)
                {
                    writer.WritePropertyName(item.Key);
                    writer.WriteStringValue(item.Value);
                }
                writer.WriteEndObject();
            }
            if (Optional.IsDefined(Identity))
            {
                writer.WritePropertyName("identity");
                JsonSerializer.Serialize(writer, Identity);
            }
            writer.WritePropertyName("properties");
            writer.WriteStartObject();
            if (Optional.IsDefined(PublicNetworkAccess))
            {
                writer.WritePropertyName("publicNetworkAccess");
                writer.WriteStringValue(PublicNetworkAccess.Value.ToString());
            }
            if (Optional.IsCollectionDefined(InboundIPRules))
            {
                writer.WritePropertyName("inboundIpRules");
                writer.WriteStartArray();
                foreach (var item in InboundIPRules)
                {
                    writer.WriteObjectValue(item);
                }
                writer.WriteEndArray();
            }
            if (Optional.IsDefined(IsLocalAuthDisabled))
            {
                writer.WritePropertyName("disableLocalAuth");
                writer.WriteBooleanValue(IsLocalAuthDisabled.Value);
            }
            if (Optional.IsDefined(AutoCreateTopicWithFirstSubscription))
            {
                writer.WritePropertyName("autoCreateTopicWithFirstSubscription");
                writer.WriteBooleanValue(AutoCreateTopicWithFirstSubscription.Value);
            }
            if (Optional.IsDefined(AutoDeleteTopicWithLastSubscription))
            {
                writer.WritePropertyName("autoDeleteTopicWithLastSubscription");
                writer.WriteBooleanValue(AutoDeleteTopicWithLastSubscription.Value);
            }
            if (Optional.IsDefined(DataResidencyBoundary))
            {
                writer.WritePropertyName("dataResidencyBoundary");
                writer.WriteStringValue(DataResidencyBoundary.Value.ToString());
            }
            writer.WriteEndObject();
            writer.WriteEndObject();
        }
    }
}


text:
.. Resumen Estadística documentation master file, created by
   sphinx-quickstart on Sun Nov 29 13:59:38 2015.
   You can adapt this file completely to your liking, but it should at least
   contain the root `toctree` directive.

Welcome to Resumen Estadística's documentation!
===============================================

Contents:

.. toctree::
   :maxdepth: 2

   Introduccion
   Estadistica
   Estadistica_Descriptiva
   Estadistica_Inferencial
   Glosario

Indices and tables
==================

* :ref:`genindex`
* :ref:`modindex`
* :ref:`search`


text:
<?php
namespace Hgtan\Bundle\HelloDoctrineMongoDBBundle\Document;

class Orders
{

    /**
     * @var MongoId $id
     */
    protected $id;

    /**
     * @var int $orderNumber
     */
    protected $orderNumber;

    /**
     * @var date $orderDate
     */
    protected $orderDate;

    /**
     * @var date $requiredDate
     */
    protected $requiredDate;

    /**
     * @var date $shippedDate
     */
    protected $shippedDate;

    /**
     * @var string $status
     */
    protected $status;

    /**
     * @var string $comments
     */
    protected $comments;

    /**
     * @var int $customerNumber
     */
    protected $customerNumber;

    /**
     * Get id
     *
     * @return id $id
     */
    public function getId()
    {
        return $this->id;
    }

    /**
     * Set orderNumber
     *
     * @param int $orderNumber
     * @return self
     */
    public function setOrderNumber($orderNumber)
    {
        $this->orderNumber = $orderNumber;
        return $this;
    }

    /**
     * Get orderNumber
     *
     * @return int $orderNumber
     */
    public function getOrderNumber()
    {
        return $this->orderNumber;
    }

    /**
     * Set orderDate
     *
     * @param date $orderDate
     * @return self
     */
    public function setOrderDate($orderDate)
    {
        $this->orderDate = $orderDate;
        return $this;
    }

    /**
     * Get orderDate
     *
     * @return date $orderDate
     */
    public function getOrderDate()
    {
        return $this->orderDate;
    }

    /**
     * Set requiredDate
     *
     * @param date $requiredDate
     * @return self
     */
    public function setRequiredDate($requiredDate)
    {
        $this->requiredDate = $requiredDate;
        return $this;
    }

    /**
     * Get requiredDate
     *
     * @return date $requiredDate
     */
    public function getRequiredDate()
    {
        return $this->requiredDate;
    }

    /**
     * Set shippedDate
     *
     * @param date $shippedDate
     * @return self
     */
    public function setShippedDate($shippedDate)
    {
        $this->shippedDate = $shippedDate;
        return $this;
    }

    /**
     * Get shippedDate
     *
     * @return date $shippedDate
     */
    public function getShippedDate()
    {
        return $this->shippedDate;
    }

    /**
     * Set status
     *
     * @param string $status
     * @return self
     */
    public function setStatus($status)
    {
        $this->status = $status;
        return $this;
    }

    /**
     * Get status
     *
     * @return string $status
     */
    public function getStatus()
    {
        return $this->status;
    }

    /**
     * Set comments
     *
     * @param string $comments
     * @return self
     */
    public function setComments($comments)
    {
        $this->comments = $comments;
        return $this;
    }

    /**
     * Get comments
     *
     * @return string $comments
     */
    public function getComments()
    {
        return $this->comments;
    }

    /**
     * Set customerNumber
     *
     * @param int $customerNumber
     * @return self
     */
    public function setCustomerNumber($customerNumber)
    {
        $this->customerNumber = $customerNumber;
        return $this;
    }

    /**
     * Get customerNumber
     *
     * @return int $customerNumber
     */
    public function getCustomerNumber()
    {
        return $this->customerNumber;
    }
}


text:
module.exports = {
	//The patches to woodcut
	woodcuttingPatches: [ 1, 2, 3, 4],

	//Delay after each woodcutting action, in MS
	delay: 1500,

	//Delay after closing a dialog
	delayDialog: 250,
};


text:
package com.asakusafw.testdriver.bulkloader;

import static org.hamcrest.Matchers.*;
import static org.junit.Assert.*;

import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.ResultSet;
import java.sql.Statement;
import java.util.List;

import org.junit.Rule;
import org.junit.Test;

/**
 * Test for {@link H2Resource}.
 */
public class H2ResourceTest {

    /**
     * target.
     */
    @Rule
    public H2Resource h2 = new H2Resource("test") {
        @Override
        protected void before() throws Exception {
            execute("CREATE TABLE TESTING(" +
                    "  SID IDENTITY PRIMARY KEY," +
                    "  NUMBER INT," +
                    "  TEXT VARCHAR(250)" +
                    ")");
        }
    };

    /**
     * execute via resource.
     * @throws Exception if failed
     */
    @Test
    public void execute_resource() throws Exception {
        h2.execute("INSERT INTO TESTING (NUMBER, TEXT) VALUES(100, 'Hello, world!')");
        List<List<Object>> results = h2.query("SELECT NUMBER, TEXT FROM TESTING");
        assertThat(results.size(), is(1));

        List<Object> columns = results.get(0);
        assertThat(columns.size(), is(2));
        assertThat(columns.get(0), is((Object) 100));
        assertThat(columns.get(1), is((Object) "Hello, world!"));
    }

    /**
     * execute outer resource.
     * @throws Exception if failed
     */
    @Test
    public void execute_direct() throws Exception {
        h2.execute("INSERT INTO TESTING (NUMBER, TEXT) VALUES(100, 'Hello, world!')");

        try (Connection conn = DriverManager.getConnection("jdbc:h2:mem:test");
                Statement stmt = conn.createStatement();
                ResultSet rs = stmt.executeQuery("SELECT NUMBER, TEXT FROM TESTING")) {
            assertThat(rs.next(), is(true));
            assertThat(rs.getObject(1), is((Object) 100));
            assertThat(rs.getObject(2), is((Object) "Hello, world!"));
            assertThat(rs.next(), is(false));
        }
    }
}


text:
//=================================================================================================

//=================================================================================================

#ifndef _BLAZE_UTIL_CONSTRAINTS_SIZE_H_
#define _BLAZE_UTIL_CONSTRAINTS_SIZE_H_

//*************************************************************************************************
// Includes
//*************************************************************************************************

#include <blaze/util/typetraits/HasSize.h>

namespace blaze {

//=================================================================================================
//
//  MUST_HAVE_SIZE CONSTRAINT
//
//=================================================================================================

//*************************************************************************************************
/*!\brief Constraint on the size of a data type.
// \ingroup constraints
//
// In case the type \a T doesn't have a size of \a S bytes, a compilation error is created.
*/
#define BLAZE_CONSTRAINT_MUST_HAVE_SIZE(T,S) \
   static_assert( ::blaze::HasSize<T,S>::value, "Invalid size detected" )
//*************************************************************************************************

//=================================================================================================
//
//  MUST_NOT_HAVE_SIZE CONSTRAINT
//
//=================================================================================================

//*************************************************************************************************
/*!\brief Constraint on the size of a data type.
// \ingroup constraints
//
// In case the type \a T has a size of \a S bytes, a compilation error is created.
*/
#define BLAZE_CONSTRAINT_MUST_NOT_HAVE_SIZE(T,S) \
   static_assert( !::blaze::HasSize<T,S>::value, "Invalid size detected" )
//*************************************************************************************************

//=================================================================================================
//
//  MUST_HAVE_1_BYTE CONSTRAINT
//
//=================================================================================================

//*************************************************************************************************
/*!\brief Constraint on the size of a data type.
// \ingroup constraints
//
// In case the type \a T doesn't have a size of exactly 1 byte, a compilation error is created.
*/
#define BLAZE_CONSTRAINT_MUST_HAVE_1_BYTE(T) \
   static_assert( ::blaze::Has1Byte<T>::value, "Invalid size detected" )
//*************************************************************************************************

//=================================================================================================
//
//  MUST_NOT_HAVE_1_BYTE CONSTRAINT
//
//=================================================================================================

//*************************************************************************************************
/*!\brief Constraint on the size of a data type.
// \ingroup constraints
//
// In case the type \a T has a size of exactly 1 byte, a compilation error is created.
*/
#define BLAZE_CONSTRAINT_MUST_NOT_HAVE_1_BYTE(T) \
   static_assert( !::blaze::Has1Byte<T>::value, "Invalid size detected" )
//*************************************************************************************************

//=================================================================================================
//
//  MUST_HAVE_2_BYTES CONSTRAINT
//
//=================================================================================================

//*************************************************************************************************
/*!\brief Constraint on the size of a data type.
// \ingroup constraints
//
// In case the type \a T doesn't have a size of exactly 2 bytes, a compilation error is created.
*/
#define BLAZE_CONSTRAINT_MUST_HAVE_2_BYTES(T) \
   static_assert( ::blaze::Has2Byte<T>::value, "Invalid size detected" )
//*************************************************************************************************

//=================================================================================================
//
//  MUST_NOT_HAVE_2_BYTES CONSTRAINT
//
//=================================================================================================

//*************************************************************************************************
/*!\brief Constraint on the size of a data type.
// \ingroup constraints
//
// In case the type \a T has a size of exactly 2 bytes, a compilation error is created.
*/
#define BLAZE_CONSTRAINT_MUST_NOT_HAVE_2_BYTES(T) \
   static_assert( !::blaze::Has2Byte<T>::value, "Invalid size detected" )
//*************************************************************************************************

//=================================================================================================
//
//  MUST_HAVE_4_BYTES CONSTRAINT
//
//=================================================================================================

//*************************************************************************************************
/*!\brief Constraint on the size of a data type.
// \ingroup constraints
//
// In case the type \a T doesn't have a size of exactly 4 bytes, a compilation error is created.
*/
#define BLAZE_CONSTRAINT_MUST_HAVE_4_BYTES(T) \
   static_assert( ::blaze::Has4Byte<T>::value, "Invalid size detected" )
//*************************************************************************************************

//=================================================================================================
//
//  MUST_NOT_HAVE_4_BYTES CONSTRAINT
//
//=================================================================================================

//*************************************************************************************************
/*!\brief Constraint on the size of a data type.
// \ingroup constraints
//
// In case the type \a T has a size of exactly 4 bytes, a compilation error is created.
*/
#define BLAZE_CONSTRAINT_MUST_NOT_HAVE_4_BYTES(T) \
   static_assert( !::blaze::Has4Byte<T>::value, "Invalid size detected" )
//*************************************************************************************************

//=================================================================================================
//
//  MUST_HAVE_8_BYTES CONSTRAINT
//
//=================================================================================================

//*************************************************************************************************
/*!\brief Constraint on the size of a data type.
// \ingroup constraints
//
// In case the type \a T doesn't have a size of exactly 8 bytes, a compilation error is created.
*/
#define BLAZE_CONSTRAINT_MUST_HAVE_8_BYTES(T) \
   static_assert( ::blaze::Has8Byte<T>::value, "Invalid size detected" )
//*************************************************************************************************

//=================================================================================================
//
//  MUST_NOT_HAVE_8_BYTES CONSTRAINT
//
//=================================================================================================

//*************************************************************************************************
/*!\brief Constraint on the size of a data type.
// \ingroup constraints
//
// In case the type \a T has a size of exactly 8 bytes, a compilation error is created.
*/
#define BLAZE_CONSTRAINT_MUST_NOT_HAVE_8_BYTES(T) \
   static_assert( !::blaze::Has8Byte<T>::value, "Invalid size detected" )
//*************************************************************************************************

} // namespace blaze

#endif


text:
package main

import (
	"fmt"
	"github.com/funnylookinhat/easyjson"
	"io/ioutil"
	"log"
	"net/http"
)

// Demo application where the root of the returned JSON is an array.
func main() {
	url := "https://api.github.com/users/funnylookinhat"

	fmt.Printf("Fetching URL %s \n", url)

	res, err := http.Get(url)

	if err != nil {
		log.Fatal(err)
	}

	defer res.Body.Close()
	body, err := ioutil.ReadAll(res.Body)

	if err != nil {
		log.Fatal(err)
	}

	data, err := easyjson.DecodeJson([]byte(body))

	if err != nil {
		log.Fatal(err)
	}

	name, _ := easyjson.GetString(data, "name")
	blog, _ := easyjson.GetString(data, "blog")
	location, _ := easyjson.GetString(data, "location")

	fmt.Printf("Name: %s\nBlog: %s\nLocation: %s\n", name, blog, location)
}


text:
<title>Soft float library routines - GNU Compiler Collection (GCC) Internals</title>
<meta http-equiv="Content-Type" content="text/html">
<meta name="description" content="GNU Compiler Collection (GCC) Internals">
<meta name="generator" content="makeinfo 4.7">
<link title="Top" rel="start" href="index.html#Top">
<link rel="up" href="Libgcc.html#Libgcc" title="Libgcc">
<link rel="prev" href="Integer-library-routines.html#Integer-library-routines" title="Integer library routines">
<link rel="next" href="Decimal-float-library-routines.html#Decimal-float-library-routines" title="Decimal float library routines">
<link href="http://www.gnu.org/software/texinfo/" rel="generator-home" title="Texinfo Homepage">

<meta http-equiv="Content-Style-Type" content="text/css">

Next: Decimal float library routines,
Previous: Integer library routines,
Up: Libgcc

4.2 Routines for floating point emulation

The software floating point library is used on machines which do not
have hardware support for floating point.  It is also used whenever
-msoft-float is used to disable generation of floating point
instructions.  (Not all targets support this switch.)

For compatibility with other compilers, the floating point emulation
routines can be renamed with the DECLARE_LIBRARY_RENAMES macro
(see Library Calls).  In this section, the default names are used.

Presently the library does not support XFmode, which is used
for long double on some architectures.

4.2.1 Arithmetic functions

— Runtime Function: float __addsf3 (<var>float a, float b</var>)<var></var>

— Runtime Function: double __adddf3 (<var>double a, double b</var>)<var></var>

— Runtime Function: long double __addtf3 (<var>long double a, long double b</var>)<var></var>

— Runtime Function: long double __addxf3 (<var>long double a, long double b</var>)<var></var>

These functions return the sum of <var>a</var> and <var>b</var>.

— Runtime Function: float __subsf3 (<var>float a, float b</var>)<var></var>

— Runtime Function: double __subdf3 (<var>double a, double b</var>)<var></var>

— Runtime Function: long double __subtf3 (<var>long double a, long double b</var>)<var></var>

— Runtime Function: long double __subxf3 (<var>long double a, long double b</var>)<var></var>

These functions return the difference between <var>b</var> and <var>a</var>;
that is, <var>a</var> - <var>b</var>.

— Runtime Function: float __mulsf3 (<var>float a, float b</var>)<var></var>

— Runtime Function: double __muldf3 (<var>double a, double b</var>)<var></var>

— Runtime Function: long double __multf3 (<var>long double a, long double b</var>)<var></var>

— Runtime Function: long double __mulxf3 (<var>long double a, long double b</var>)<var></var>

These functions return the product of <var>a</var> and <var>b</var>.

— Runtime Function: float __divsf3 (<var>float a, float b</var>)<var></var>

— Runtime Function: double __divdf3 (<var>double a, double b</var>)<var></var>

— Runtime Function: long double __divtf3 (<var>long double a, long double b</var>)<var></var>

— Runtime Function: long double __divxf3 (<var>long double a, long double b</var>)<var></var>

These functions return the quotient of <var>a</var> and <var>b</var>; that is,
<var>a</var> / <var>b</var>.

— Runtime Function: float __negsf2 (<var>float a</var>)<var></var>

— Runtime Function: double __negdf2 (<var>double a</var>)<var></var>

— Runtime Function: long double __negtf2 (<var>long double a</var>)<var></var>

— Runtime Function: long double __negxf2 (<var>long double a</var>)<var></var>

These functions return the negation of <var>a</var>.  They simply flip the
sign bit, so they can produce negative zero and negative NaN.

4.2.2 Conversion functions

— Runtime Function: double __extendsfdf2 (<var>float a</var>)<var></var>

— Runtime Function: long double __extendsftf2 (<var>float a</var>)<var></var>

— Runtime Function: long double __extendsfxf2 (<var>float a</var>)<var></var>

— Runtime Function: long double __extenddftf2 (<var>double a</var>)<var></var>

— Runtime Function: long double __extenddfxf2 (<var>double a</var>)<var></var>

These functions extend <var>a</var> to the wider mode of their return
type.

— Runtime Function: double __truncxfdf2 (<var>long double a</var>)<var></var>

— Runtime Function: double __trunctfdf2 (<var>long double a</var>)<var></var>

— Runtime Function: float __truncxfsf2 (<var>long double a</var>)<var></var>

— Runtime Function: float __trunctfsf2 (<var>long double a</var>)<var></var>

— Runtime Function: float __truncdfsf2 (<var>double a</var>)<var></var>

These functions truncate <var>a</var> to the narrower mode of their return
type, rounding toward zero.

— Runtime Function: int __fixsfsi (<var>float a</var>)<var></var>

— Runtime Function: int __fixdfsi (<var>double a</var>)<var></var>

— Runtime Function: int __fixtfsi (<var>long double a</var>)<var></var>

— Runtime Function: int __fixxfsi (<var>long double a</var>)<var></var>

These functions convert <var>a</var> to a signed integer, rounding toward zero.

— Runtime Function: long __fixsfdi (<var>float a</var>)<var></var>

— Runtime Function: long __fixdfdi (<var>double a</var>)<var></var>

— Runtime Function: long __fixtfdi (<var>long double a</var>)<var></var>

— Runtime Function: long __fixxfdi (<var>long double a</var>)<var></var>

These functions convert <var>a</var> to a signed long, rounding toward zero.

— Runtime Function: long long __fixsfti (<var>float a</var>)<var></var>

— Runtime Function: long long __fixdfti (<var>double a</var>)<var></var>

— Runtime Function: long long __fixtfti (<var>long double a</var>)<var></var>

— Runtime Function: long long __fixxfti (<var>long double a</var>)<var></var>

These functions convert <var>a</var> to a signed long long, rounding toward zero.

— Runtime Function: unsigned int __fixunssfsi (<var>float a</var>)<var></var>

— Runtime Function: unsigned int __fixunsdfsi (<var>double a</var>)<var></var>

— Runtime Function: unsigned int __fixunstfsi (<var>long double a</var>)<var></var>

— Runtime Function: unsigned int __fixunsxfsi (<var>long double a</var>)<var></var>

These functions convert <var>a</var> to an unsigned integer, rounding
toward zero.  Negative values all become zero.

— Runtime Function: unsigned long __fixunssfdi (<var>float a</var>)<var></var>

— Runtime Function: unsigned long __fixunsdfdi (<var>double a</var>)<var></var>

— Runtime Function: unsigned long __fixunstfdi (<var>long double a</var>)<var></var>

— Runtime Function: unsigned long __fixunsxfdi (<var>long double a</var>)<var></var>

These functions convert <var>a</var> to an unsigned long, rounding
toward zero.  Negative values all become zero.

— Runtime Function: unsigned long long __fixunssfti (<var>float a</var>)<var></var>

— Runtime Function: unsigned long long __fixunsdfti (<var>double a</var>)<var></var>

— Runtime Function: unsigned long long __fixunstfti (<var>long double a</var>)<var></var>

— Runtime Function: unsigned long long __fixunsxfti (<var>long double a</var>)<var></var>

These functions convert <var>a</var> to an unsigned long long, rounding
toward zero.  Negative values all become zero.

— Runtime Function: float __floatsisf (<var>int i</var>)<var></var>

— Runtime Function: double __floatsidf (<var>int i</var>)<var></var>

— Runtime Function: long double __floatsitf (<var>int i</var>)<var></var>

— Runtime Function: long double __floatsixf (<var>int i</var>)<var></var>

These functions convert <var>i</var>, a signed integer, to floating point.

— Runtime Function: float __floatdisf (<var>long i</var>)<var></var>

— Runtime Function: double __floatdidf (<var>long i</var>)<var></var>

— Runtime Function: long double __floatditf (<var>long i</var>)<var></var>

— Runtime Function: long double __floatdixf (<var>long i</var>)<var></var>

These functions convert <var>i</var>, a signed long, to floating point.

— Runtime Function: float __floattisf (<var>long long i</var>)<var></var>

— Runtime Function: double __floattidf (<var>long long i</var>)<var></var>

— Runtime Function: long double __floattitf (<var>long long i</var>)<var></var>

— Runtime Function: long double __floattixf (<var>long long i</var>)<var></var>

These functions convert <var>i</var>, a signed long long, to floating point.

— Runtime Function: float __floatunsisf (<var>unsigned int i</var>)<var></var>

— Runtime Function: double __floatunsidf (<var>unsigned int i</var>)<var></var>

— Runtime Function: long double __floatunsitf (<var>unsigned int i</var>)<var></var>

— Runtime Function: long double __floatunsixf (<var>unsigned int i</var>)<var></var>

These functions convert <var>i</var>, an unsigned integer, to floating point.

— Runtime Function: float __floatundisf (<var>unsigned long i</var>)<var></var>

— Runtime Function: double __floatundidf (<var>unsigned long i</var>)<var></var>

— Runtime Function: long double __floatunditf (<var>unsigned long i</var>)<var></var>

— Runtime Function: long double __floatundixf (<var>unsigned long i</var>)<var></var>

These functions convert <var>i</var>, an unsigned long, to floating point.

— Runtime Function: float __floatuntisf (<var>unsigned long long i</var>)<var></var>

— Runtime Function: double __floatuntidf (<var>unsigned long long i</var>)<var></var>

— Runtime Function: long double __floatuntitf (<var>unsigned long long i</var>)<var></var>

— Runtime Function: long double __floatuntixf (<var>unsigned long long i</var>)<var></var>

These functions convert <var>i</var>, an unsigned long long, to floating point.

4.2.3 Comparison functions

There are two sets of basic comparison functions.

— Runtime Function: int __cmpsf2 (<var>float a, float b</var>)<var></var>

— Runtime Function: int __cmpdf2 (<var>double a, double b</var>)<var></var>

— Runtime Function: int __cmptf2 (<var>long double a, long double b</var>)<var></var>

These functions calculate a <=> b.  That is, if <var>a</var> is less
than <var>b</var>, they return −1; if <var>a</var> is greater than <var>b</var>, they
return 1; and if <var>a</var> and <var>b</var> are equal they return 0.  If
either argument is NaN they return 1, but you should not rely on this;
if NaN is a possibility, use one of the higher-level comparison
functions.

— Runtime Function: int __unordsf2 (<var>float a, float b</var>)<var></var>

— Runtime Function: int __unorddf2 (<var>double a, double b</var>)<var></var>

— Runtime Function: int __unordtf2 (<var>long double a, long double b</var>)<var></var>

These functions return a nonzero value if either argument is NaN, otherwise 0.

There is also a complete group of higher level functions which
correspond directly to comparison operators.  They implement the ISO C
semantics for floating-point comparisons, taking NaN into account.
Pay careful attention to the return values defined for each set.
Under the hood, all of these routines are implemented as

       if (__unord<var>X</var>f2 (a, b))
         return <var>E</var>;
       return __cmp<var>X</var>f2 (a, b);

where <var>E</var> is a constant chosen to give the proper behavior for
NaN.  Thus, the meaning of the return value is different for each set.
Do not rely on this implementation; only the semantics documented
below are guaranteed.

— Runtime Function: int __eqsf2 (<var>float a, float b</var>)<var></var>

— Runtime Function: int __eqdf2 (<var>double a, double b</var>)<var></var>

— Runtime Function: int __eqtf2 (<var>long double a, long double b</var>)<var></var>

These functions return zero if neither argument is NaN, and <var>a</var> and
<var>b</var> are equal.

— Runtime Function: int __nesf2 (<var>float a, float b</var>)<var></var>

— Runtime Function: int __nedf2 (<var>double a, double b</var>)<var></var>

— Runtime Function: int __netf2 (<var>long double a, long double b</var>)<var></var>

These functions return a nonzero value if either argument is NaN, or
if <var>a</var> and <var>b</var> are unequal.

— Runtime Function: int __gesf2 (<var>float a, float b</var>)<var></var>

— Runtime Function: int __gedf2 (<var>double a, double b</var>)<var></var>

— Runtime Function: int __getf2 (<var>long double a, long double b</var>)<var></var>

These functions return a value greater than or equal to zero if
neither argument is NaN, and <var>a</var> is greater than or equal to
<var>b</var>.

— Runtime Function: int __ltsf2 (<var>float a, float b</var>)<var></var>

— Runtime Function: int __ltdf2 (<var>double a, double b</var>)<var></var>

— Runtime Function: int __lttf2 (<var>long double a, long double b</var>)<var></var>

These functions return a value less than zero if neither argument is
NaN, and <var>a</var> is strictly less than <var>b</var>.

— Runtime Function: int __lesf2 (<var>float a, float b</var>)<var></var>

— Runtime Function: int __ledf2 (<var>double a, double b</var>)<var></var>

— Runtime Function: int __letf2 (<var>long double a, long double b</var>)<var></var>

These functions return a value less than or equal to zero if neither
argument is NaN, and <var>a</var> is less than or equal to <var>b</var>.

— Runtime Function: int __gtsf2 (<var>float a, float b</var>)<var></var>

— Runtime Function: int __gtdf2 (<var>double a, double b</var>)<var></var>

— Runtime Function: int __gttf2 (<var>long double a, long double b</var>)<var></var>

These functions return a value greater than zero if neither argument
is NaN, and <var>a</var> is strictly greater than <var>b</var>.

4.2.4 Other floating-point functions

— Runtime Function: float __powisf2 (<var>float a, int b</var>)<var></var>

— Runtime Function: double __powidf2 (<var>double a, int b</var>)<var></var>

— Runtime Function: long double __powitf2 (<var>long double a, int b</var>)<var></var>

— Runtime Function: long double __powixf2 (<var>long double a, int b</var>)<var></var>

These functions convert raise <var>a</var> to the power <var>b</var>.

— Runtime Function: complex float __mulsc3 (<var>float a, float b, float c, float d</var>)<var></var>

— Runtime Function: complex double __muldc3 (<var>double a, double b, double c, double d</var>)<var></var>

— Runtime Function: complex long double __multc3 (<var>long double a, long double b, long double c, long double d</var>)<var></var>

— Runtime Function: complex long double __mulxc3 (<var>long double a, long double b, long double c, long double d</var>)<var></var>

These functions return the product of <var>a</var> + i<var>b</var> and
<var>c</var> + i<var>d</var>, following the rules of C99 Annex G.

— Runtime Function: complex float __divsc3 (<var>float a, float b, float c, float d</var>)<var></var>

— Runtime Function: complex double __divdc3 (<var>double a, double b, double c, double d</var>)<var></var>

— Runtime Function: complex long double __divtc3 (<var>long double a, long double b, long double c, long double d</var>)<var></var>

— Runtime Function: complex long double __divxc3 (<var>long double a, long double b, long double c, long double d</var>)<var></var>

These functions return the quotient of <var>a</var> + i<var>b</var> and
<var>c</var> + i<var>d</var> (i.e., (<var>a</var> + i<var>b</var>) / (<var>c</var>
+ i<var>d</var>)), following the rules of C99 Annex G.


text:
package com.geeksaga.light.profiler.selector;

import com.geeksaga.light.logger.CommonLogger;
import com.geeksaga.light.logger.LightLogger;

import java.util.List;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;

/**
 * @author geeksaga
 */
public class ClassSelector
{
    LightLogger logger;

    Map<String, MethodSelector> selectors = new ConcurrentHashMap<String, MethodSelector>();

    public ClassSelector()
    {
        this.logger = CommonLogger.getLogger(getClass().getName());
    }

    public void add(String fullDescription)
    {
        if (isNotNone(fullDescription))
        {
            String[] classMethod = divideClassMethod(fullDescription.trim());
            if (!"java.lang.Object".equals(classMethod[0]) && isNotNone(classMethod[0]))
            {
                add(classMethod[0], classMethod[1]);
            }
        }
    }

    public void add(String clazz, String fullDescription)
    {
        MethodSelector methodSelector = selectors.get(clazz);
        if (methodSelector == null)
        {
            methodSelector = new MethodSelector();

            selectors.put(clazz, methodSelector);
        }

        if (isNotNone(fullDescription))
        {
            methodSelector.add(fullDescription);
        }
    }

    private String[] divideClassMethod(String fullDescriptor)
    {
        String[] classMethod = new String[2];

        int indexOf = fullDescriptor.indexOf(" ");
        if (indexOf <= 0)
        {
            classMethod[0] = fullDescriptor.trim();
            classMethod[1] = null;
        }
        else
        {
            classMethod[0] = fullDescriptor.substring(0, indexOf).trim();
            classMethod[1] = fullDescriptor.substring(indexOf + 1).trim();
        }

        return classMethod;
    }

    private boolean isNotNone(String value)
    {
        return value != null && value.length() > 0;
    }

    private MethodSelector selectBySuperOrInterface(String[] superOrInterfaces)
    {
        if (superOrInterfaces == null)
        {
            return null;
        }

        for (String superOrInterface : superOrInterfaces)
        {
            Object o = selectors.get(superOrInterface);
            if (o != null)
            {
                return (MethodSelector) o;
            }
        }

        return null;
    }

    public MethodSelector selectByClass(String name)
    {
        return selectors.get(name);
    }

    public MethodSelector selectByInterface(String[] interfaces)
    {
        return selectBySuperOrInterface(interfaces);
    }

    public MethodSelector selectBySuper(String name)
    {
        return selectors.get(name);
    }

    public MethodSelector selectBySuper(String[] superClasses)
    {
        return selectBySuperOrInterface(superClasses);
    }

    public MethodSelector selectByPattern(String name)
    {
        return selectors.get(name);
    }

    public boolean isEmpty()
    {
        return selectors.isEmpty();
    }

    public boolean containsKey(Object key)
    {
        return selectors.containsKey(key);
    }

    public static ClassSelector create(String[] list)
    {
        ClassSelector classSelector = new ClassSelector();

        if (list == null)
        {
            return classSelector;
        }

        for (String value : list)
        {
            classSelector.add(value);
        }

        return classSelector;
    }

    public static ClassSelector create(List<String> list)
    {
        ClassSelector classSelector = new ClassSelector();

        for (String value : list)
        {
            //            classSelector.add(value.replace(".", "/"));
            classSelector.add(value);

            System.out.println(value);
        }

        return classSelector;
    }
}


text:
DateTimeWidget
==============

Show a formatted date time.

+-------------+--------------------------------------------------------------------+
| type        | datetime                                                           |
+-------------+--------------------------------------------------------------------+
| require     | - property_                                                        |
+-------------+--------------------------------------------------------------------+
| option      | - format_                                                          |
|             | - width_                                                           |
|             | - label_                                                           |
|             | - translationDomain_                                               |
+-------------+--------------------------------------------------------------------+
| class       | :class:`Enhavo\\Bundle\\AppBundle\\Table\\Widget\\DateTimeWidget`  |
+-------------+--------------------------------------------------------------------+

Require
-------

.. include:: /reference/table-widget/option/property.rst

Option
------

.. include:: /reference/table-widget/option/format.rst

.. include:: /reference/table-widget/option/width.rst

.. include:: /reference/table-widget/option/label.rst

.. include:: /reference/table-widget/option/translationDomain.rst