text:
The PackageManagementProviderResource (used to be called OneGetProviderResource) module contains the following Windows PowerShell Desired State Configuration (DSC) resources to allow you to manage packages and Windows PowerShell modules.

* **NugetPackage** – lets you download packages from the NuGet source location (e.g., http://nuget.org/api/v2/), and install or uninstall the package.

* **PSModule** – lets you download Windows PowerShell modules from the PowerShell Gallery, "PSGallery" (e.g., https://www.powershellgallery.com/api/v2/ ), and install them on your computer.

* **PackageManagementSource** – lets you register or unregister a package source on your computer

**NugetPackage** DSC resource has the following properties:

         Property
        Description

        Name
        Specifies the name of the package to be installed or uninstalled.

    DestinationPath
    Specifies a file location where you want the package to be installed.

    Ensure
    Determines whether the package is to be installed or uninstalled.

    InstallationPolicy
    Determines whether you trust the package's source.

    RequiredVersion
    Specifies the exact version of the package you want to install or uninstall.

    MinimumVersion
    Specifies the minimum version of the package you want to install or uninstall.

    MaximumVersion
    Specifies the maximum version of the package you want to install or uninstall.

    Source
    Specifies the URI or name of the registered package source.

    SourceCredential
    Provides access to the package on a remote source. This property is not used to install the package. The package is always installed on the local system account.

**PSModule** DSC resource has the following properties:

        Property
        Description

        Name
        Specifies the name of the PowerShell module to be installed or uninstalled.

    Ensure
    Determines whether the module to be installed or uninstalled.

    InstallationPolicy
    Determines whether you trust the source repository where the module resides.

    RequiredVersion
    Specifies the exact version of the module you want to install or uninstall.

    MinimumVersion
    Specifies the minimum version of the module you want to install or uninstall.

    Repository
    Specifies the name of the module source repository where the module can found.

**PackageManagementSource** has the following properties:

        Property
        Description

        Name
        Specifies the name of the package source to be registered or unregistered on your system.

      ProviderName
      Specifies the name of the OneGet provider through which you can interop with the package source.

    Ensure
    Determines whether the package source is to be registered or unregistered.

    InstallationPolicy
    Determines whether you trust the package source.

    SourceUri
    Specifies the URI of the package source.

    SourceCredential
    Provides access to the package on a remote source.

###**Requirements**###

Before you install OneGetProviderResource, you must be running  [Windows Management Framework 5.0 Preview April 2015](http://blogs.msdn.com/b/powershell/archive/2015/04/29/windows-management-framework-5-0-preview-april-2015-is-now-available.aspx).

###**Installation**###

To use the **PackageManagementProviderResource** module,
* Copy the content of the download to the $env:ProgramFiles\WindowsPowerShell\Modules folder.

To confirm installation,
* Run **Get-DSCResource** to verify that NugetPackage, OneGetSource, PSModule are among the DSC Resources are listed in your DSC resources.

###**Building the Code**###

The code is a Windows PowerShell script and interpreted by the Windows PowerShell engine at runtime.

###**Running Test**###

To test the modules, run the following commands. The NuGetPackage resource is used here as an example.
* cd $env:ProgramFiles\WindowsPowerShell\Modules\PackageManagementProviderResource\Test
* .\NugetPackage\NugetPackage.Get.Tests.ps1
* .\NugetPackage\NugetPackage.Set.Tests.ps1
* .\NugetPackage\NugetPackage.Test.Tests.ps1

You can repeat these commands similarly for testing PSModule and OneGetSource DSC resources.

###**Contributing to the Code**###

You are welcome to contribute to this project. There are many ways to contribute:

1.	Submit a bug report via [Issues]( https://github.com/PowerShell/PackageManagementProviderResource/issues). For a guide to submitting good bug reports, please read [Painless Bug Tracking](http://www.joelonsoftware.com/articles/fog0000000029.html).

2.	Verify fixes for bugs.

3.	Submit your fixes for a bug. Before submitting, please make sure you have:
 - Performed code reviews of your own
 - Updated the test cases if needed
 - Run the test cases to ensure no feature breaks or test breaks
 - Added the test cases for new code
4.	Submit a feature request.
5.	Help answer questions in the discussions list.
6.	Submit test cases.
7.	Tell others about the project.
8.	Tell the developers how much you appreciate the product!

You might also read these two blog posts about contributing code: [Open Source Contribution Etiquette](http://tirania.org/blog/archive/2010/Dec-31.html) by Miguel de Icaza, and [Don't "Push" Your Pull Requests](http://www.igvita.com/2011/12/19/dont-push-your-pull-requests/) by Ilya Grigorik.

Before submitting a feature or substantial code contribution, please discuss it with the Windows PowerShell team via [Issues]( https://github.com/WindowsPowerShell/OneGetResource/issues), and ensure it follows the product roadmap. Note that all code submissions will be rigorously reviewed by the Windows PowerShell Team. Only those that meet a high bar for both quality and roadmap fit will be merged into the source.


text:
package io.mycat.statistic.stat;

import java.util.concurrent.atomic.AtomicLongArray;

public class Histogram {

    private final long[] ranges;
    private final AtomicLongArray rangeCounters;

    public Histogram(long... ranges){
        this.ranges = ranges;
        this.rangeCounters = new AtomicLongArray(ranges.length);
    }

    public void reset() {
        for (int i = 0; i < rangeCounters.length(); i++) {
            rangeCounters.set(i, 0);
        }
    }

    public void record(long range) {
        int index = rangeCounters.length();
        for (int i = 0; i < ranges.length; i++) {
            if (range == ranges[i]) {
                index = i;
                break;
            }
        }

        rangeCounters.incrementAndGet(index);
    }

    public long get(int index) {
        return rangeCounters.get(index);
    }

    public long[] toArray() {
        long[] array = new long[rangeCounters.length()];
        for (int i = 0; i < rangeCounters.length(); i++) {
            array[i] = rangeCounters.get(i);
        }
        return array;
    }

    public long[] toArrayAndReset() {
        long[] array = new long[rangeCounters.length()];
        for (int i = 0; i < rangeCounters.length(); i++) {
            array[i] = rangeCounters.getAndSet(i, 0);
        }

        return array;
    }

    public long[] getRanges() {
        return ranges;
    }

    public long getValue(int index) {
        return rangeCounters.get(index);
    }

    public long getSum() {
        long sum = 0;
        for (int i = 0; i < rangeCounters.length(); ++i) {
            sum += rangeCounters.get(i);
        }
        return sum;
    }

    public String toString() {
        StringBuilder buf = new StringBuilder();
        buf.append('[');
        for (int i = 0; i < rangeCounters.length(); i++) {
            if (i != 0) {
                buf.append(", ");
            }
            buf.append(rangeCounters.get(i));
        }
        buf.append(']');
        return buf.toString();
    }
}

redpajama_set_name: RedPajamaGithub


text:
package org.apache.jena.sdb.test.update;

import junit.framework.JUnit4TestAdapter;
import org.apache.jena.sdb.Store ;
import org.apache.jena.sdb.test.StoreCreator ;

public class TestStoreUpdateOracleHash extends TestStoreUpdateBase {

	public static junit.framework.Test suite() {
	    return new JUnit4TestAdapter(TestStoreUpdateOracleHash.class);
	}

	@Override
	Store getStore() {
		return StoreCreator.getHashOracle();
	}

}


text:
namespace juce
{

//==============================================================================
/**
    A type of ImagePixelData that stores its image data in an OpenGL
    framebuffer, allowing a JUCE Image object to wrap a framebuffer.

    By creating an Image from an instance of an OpenGLFrameBufferImage,
    you can then use a Graphics object to draw into the framebuffer using normal
    JUCE 2D operations.

    @see Image, ImageType, ImagePixelData, OpenGLFrameBuffer

    @tags{OpenGL}
*/
class JUCE_API  OpenGLImageType     : public ImageType
{
public:
    OpenGLImageType();
    ~OpenGLImageType() override;

    ImagePixelData::Ptr create (Image::PixelFormat, int width, int height, bool shouldClearImage) const override;
    int getTypeID() const override;

    static OpenGLFrameBuffer* getFrameBufferFrom (const Image&);
};

} // namespace juce


text:
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html
     PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

  <title>encode (OpenID::Server::SigningEncoder)</title>
  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  <link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />

# File lib/openid/server.rb, line 1172
      def encode(response)
        # the is_a? is a bit of a kludge... it means there isn't
        # really an adapter to make the interfaces quite match.
        if !response.is_a?(Exception) and response.needs_signing()
          if !@signatory
            raise ArgumentError.new(
              sprintf("Must have a store to sign this request: %s",
                      response), response)
          end

          if response.fields.has_key?(OPENID_NS, 'sig')
            raise AlreadySigned.new(response)
          end

          response = @signatory.sign(response)
        end

        return super(response)
      end


text:
function installCommon() {
	## DEACTIVATE SCREEN SAVER
	gsettings set org.gnome.desktop.screensaver lock-enabled false
	gsettings set org.gnome.desktop.screensaver ubuntu-lock-on-suspend false
	gsettings set org.gnome.desktop.session idle-delay 0

	## UPDATE SYSTEM
	sudo apt-get -y update && sudo apt-get -y upgrade && sudo apt autoremove -y

	## REMOVE SOFTWARES
	sudo apt-get -y autoremove software-center landscape-client-ui-install example-content rhythmbox* \
	thunderbird* totem totem-common

	## DEACTIVATE LENSES
	gsettings set com.canonical.Unity.Lenses disabled-scopes "['more_suggestions-amazon.scope', 'more_suggestions-u1ms.scope', 'more_suggestions-populartracks.scope', 'music-musicstore.scope', 'more_suggestions-ebay.scope', 'more_suggestions-ubuntushop.scope', 'more_suggestions-skimlinks.scope']"
	gsettings set com.canonical.Unity.Lenses remote-content-search 'none'

	## ADD SOME REPOS
	sudo sh -c 'echo "deb [arch=amd64] https://dl.google.com/linux/chrome/deb/ stable main" > /etc/apt/sources.list.d/google-chrome.list'
	wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
	sudo sh -c 'echo "deb [arch=amd64] https://packagecloud.io/AtomEditor/atom/any/ any main" > /etc/apt/sources.list.d/atom.list'
	wget -qO - https://packagecloud.io/AtomEditor/atom/gpgkey | sudo apt-key add -
	echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
	curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
	sudo apt-get -y update

	## INSTALL SOFTWARES
	softs=(
		aptitude synaptic dconf-editor bleachbit gparted gnome-tweak-tool
		software-properties-common python gcc g++ make # Nodejs deps
		gimp gimp-data gimp-plugin-registry gimp-data-extras # Image editor
		terminator git atom vim curl google-chrome-stable # Dev tools
		unace unrar zip unzip p7zip-full p7zip-rar sharutils rar # Archive tools
		uudeview mpack arj cabextract file-roller
		)
	for s in "${softs[@]}"
	do
		sudo apt-get -y install $s
	done

	## Node and npm install without sudo
	curl -sL https://deb.nodesource.com/setup_11.x | sudo -E bash -
        sudo apt-get -y install nodejs yarn
        mkdir ~/npm
        npm config set prefix ~/npm

	## Python packages
	sudo apt autoremove python-pip
	sudo apt-get -y install python3-pip

	## ATOM THEMES AND PACKAGES
	atoms=(
		project-plus
		highlight-line
		sort-lines
		toggle-quotes
		color-picker
		todo-show
		atom-beautify
		git-plus
		git-blame
		file-icons
		)
	for p in "${atoms[@]}"
	do
		apm install $p
	done

	## SETTINGS
	# Privacy
	gsettings set org.gnome.desktop.privacy remember-recent-files false
	# Launcher
	gsettings set org.gnome.shell.extensions.dash-to-dock favorites "['application://nautilus.desktop', 'application://firefox.desktop', 'application://atom.desktop', 'unity://expo-icon']"
	# Datetime
	gsettings set com.canonical.indicator.datetime show-date true
	gsettings set com.canonical.indicator.datetime show-day true
	gsettings set com.canonical.indicator.datetime show-seconds true
	# Sound
	gsettings set com.ubuntu.sound allow-amplified-volume true
	# Workspace
	gsettings set org.compiz.core:/org/compiz/profiles/unity/plugins/core/ hsize 2
	gsettings set org.compiz.core:/org/compiz/profiles/unity/plugins/core/ vsize 2
}

function installPerso() {
	## ADD SOME REPOS
	sudo add-apt-repository -y ppa:atareao/telegram # Telegram

	## INSTALL SOFTWARES
	sudo apt-get -y install vlc exaile # Media tools
	sudo apt-get -y install wine # Windows tool runner
	sudo apt-get -y install gstreamer0.10-plugins-ugly gxine libdvdread4 totem-mozilla \
		                icedax tagtool easytag id3tool lame nautilus-script-audio-convert \
		                libmad0 mpg321 gstreamer1.0-libav # Multimedia codecs
	sudo apt-get -y install telegram # Instant messaging
	cd ~/
	git clone git://github.com/joeyh/github-backup
	cd github-backup
	make

	## Owncloud client
	sudo sh -c "echo 'deb http://download.opensuse.org/repositories/isv:/ownCloud:/desktop/Ubuntu_16.04/ /' > /etc/apt/sources.list.d/owncloud-client.list"
	sudo apt-get -y update
	sudo apt-get -y install owncloud-client
}

## INSTALL
if [ "$1" == "--perso" -o "$1" == "-p" ]; then
	installCommon;
	installPerso;
else
	read -p "Would you like to install softwares usually dedicated to spare time ? (y/N) " -n 1;
	echo "";
	if [[ $REPLY =~ ^[Yy]$ ]]; then
		installCommon;
		installPerso;
	else
		installCommon;
	fi;
fi;

## DOTFILES
source bootstrap.sh --force

## UNSET
unset installCommon;
unset installPerso;


text:
package P05;

public class HumanImpl implements Identifiable,Human {
    private String name;
    private int age;
    private String id;

    HumanImpl(String name, int age, String id) {
        this.setName(name);
        this.setAge(age);
        this.setId(id);
    }

    @Override
    public String getId() {
        return id;
    }

    @Override
    public String getName() {
        return name;
    }

    @Override
    public int getAge() {
        return age;
    }

    private void setName(String name) {
        this.name = name;
    }

    private void setAge(int age) {
        this.age = age;
    }

    private void setId(String id) {
        this.id = id;
    }
}


text:
import React from 'react';
import {connect} from 'react-redux';

import DynamicForm from '../../src/components/DynamicForm';

@connect()
export default class CreateDynamicFormPage extends React.Component{
    beforeSubmit(){
        console.log('回调函数beforeSubmit');
    }
    onSuccess(response){
        console.log('回调函数onSuccess');
    }
    onError(error){
        console.log('回调函数onError')
    }
    onSubmit(){
        console.log('自定义onSubmit')
    }
    render(){
        return(
            <DynamicForm
                isUpdate={false}
                formDefinitionSrc={`http://localhost:3000/api/getdefinition/${this.props.match && this.props.match.params.name}`}
                submitDataSrc={`http://localhost:3000/api/createformdata`}
                dataPaht='data'
                beforeSubmit={this.beforeSubmit}
                onSuccess={this.onSuccess}
                onError={this.onError}
                />
        );
    }
}


text:
namespace System.Web.Services.Description {

    using System.Web.Services;
    using System.Web.Services.Protocols;
    using System.Xml.Serialization;
    using System.Xml.Schema;
    using System.Collections;
    using System;
    using System.Reflection;
    using System.CodeDom;

    internal abstract class MimeImporter {
        HttpProtocolImporter protocol;

        internal abstract MimeParameterCollection ImportParameters();
        internal abstract MimeReturn ImportReturn();

        internal virtual void GenerateCode(MimeReturn[] importedReturns, MimeParameterCollection[] importedParameters) {
        }

        internal virtual void AddClassMetadata(CodeTypeDeclaration codeClass) {
        }

        internal HttpProtocolImporter ImportContext {
            get { return protocol; }
            set { protocol = value; }
        }
    }
}


text:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

    <meta name="Date-Creation-yyyymmdd" content="20010731">
    <meta name="Date-Revision-yyyymmdd" content="20010731">
    <meta name="description" content="the interactive plasma physics education experience -- topics about physics ranging from electricity, magnetism, energy, and especially fusion & plasma physics. the first fully interactive www site for students on fusion energy and plasma physics. operate your own virtual fusion reactor. analyze real data from fusion experiments. ask a scientist about plasma physics, fusion energy, and more! the most definitive source for students on plasma physics. ippex online.">
    <meta name="Identifier-URL" content="http://ippex.pppl.gov/">
    <meta name="keywords" content="ippex, fusion, government, department of energy, princeton university, plasma, physics, electricity, magnets, magnetism, tokamak, virtual, ask, scientist, science, education, data, analysis, crew, mission, energy, security, internet, experience">
    <meta name="Publisher" content="IPPEX Online">
    <meta name="Publisher-Email" content="ippexwebmaster@pppl.gov">
    <meta name="revisit-after" content="7 Days">
    <meta name="ROBOTS" content="ALL">
    <title>ippex online - main</title>

    <link rel="ToC" href="http://ippex.pppl.gov">
    <link rel="Home" href="http://ippex.pppl.gov">
    <link rel="STYLESHEET" href="../../default.css" type="text/css">
    <base target="_top">

        THE
        INTERNET PLASMA PHYSICS EDUCATION EXPERIENCE

home | contact | search | privacy
          & security notice

                          Information

                              Home

                              Mission

                              Science Education
                                At PPPL

                          Education

                              About
                              Fusion

                              Interactive
                              Physics

                              Virtual
                              Tokamak

                              Ask a Physicist

                              Fusion Data
                              Analysis

                          Support

                              Privacy &
                              Security

                              The
                              Crew

                              Site Map

                              Search

Kinetic Energy, Mass and Velocity!

In this experiment, you can study the relationship between kinetic
 energy, mass, and velocity.  The four buttons in the experiment are
 "rewind", "stop", "play", and "step".  Time and the position of the
 mass is recorded automatically.  Here are 3 questions to think about
 as you perform this experiment.

What happens when you increase the kinetic energy and keep
	the mass constant?

What happens when you increase the mass and keep the kinetic
	energy constant?

The relationship between kinetic energy, mass, and velocity is
	Kinetic energy = 1/2 x mass x velocity x velocity
(K.E.=1/2 x m x v
                  2).

	  Velocity is equal to
	distance/time.  For a kinetic energy of 8 joules and a mass of 4 kilograms,
	at what time will the mass move 2 meters?  Can you calculate it on paper
before	trying it in the experiment?

                <EMBED SRC="ke_vs_mass.dcr"

WIDTH=464 Height=190  PALETTE=foreground>

                (If you don't have shockwave,
                here's what you would see
if you did.)

Does it help to plot this data
on graph paper, or in a spreadsheet program?

                    home - about fusion - interactive physics - ask a physicist - virtual tokamak

                    fusion data analysis - the crew - site
          map

    Copyright © 2001 IPPEX
    ONLINE

                all rights reserved.


text: require File.expand_path('../minitest/implicit/subject', __FILE__)


text:
using System;
using System.ComponentModel;

namespace Azure.AI.MetricsAdvisor.Models
{
    /// <summary> snooze scope. </summary>
    public readonly partial struct SnoozeScope : IEquatable<SnoozeScope>
    {
        private readonly string _value;

        /// <summary> Determines if two <see cref="SnoozeScope"/> values are the same. </summary>
        /// <exception cref="ArgumentNullException"> <paramref name="value"/> is null. </exception>
        public SnoozeScope(string value)
        {
            _value = value ?? throw new ArgumentNullException(nameof(value));
        }

        private const string MetricValue = "Metric";
        private const string SeriesValue = "Series";
        /// <summary> Determines if two <see cref="SnoozeScope"/> values are the same. </summary>
        public static bool operator ==(SnoozeScope left, SnoozeScope right) => left.Equals(right);
        /// <summary> Determines if two <see cref="SnoozeScope"/> values are not the same. </summary>
        public static bool operator !=(SnoozeScope left, SnoozeScope right) => !left.Equals(right);
        /// <summary> Converts a string to a <see cref="SnoozeScope"/>. </summary>
        public static implicit operator SnoozeScope(string value) => new SnoozeScope(value);

        /// <inheritdoc />
        [EditorBrowsable(EditorBrowsableState.Never)]
        public override bool Equals(object obj) => obj is SnoozeScope other && Equals(other);
        /// <inheritdoc />
        public bool Equals(SnoozeScope other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase);

        /// <inheritdoc />
        [EditorBrowsable(EditorBrowsableState.Never)]
        public override int GetHashCode() => _value?.GetHashCode() ?? 0;
        /// <inheritdoc />
        public override string ToString() => _value;
    }
}


text:
package it.unibz.inf.ontop.iq.node.normalization.impl;

import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableSet;
import com.google.inject.Inject;
import com.google.inject.Singleton;
import it.unibz.inf.ontop.exception.MinorOntopInternalBugException;
import it.unibz.inf.ontop.injection.IntermediateQueryFactory;
import it.unibz.inf.ontop.iq.IQTree;
import it.unibz.inf.ontop.iq.IQTreeCache;
import it.unibz.inf.ontop.iq.UnaryIQTree;
import it.unibz.inf.ontop.iq.node.*;
import it.unibz.inf.ontop.iq.node.normalization.ConditionSimplifier;
import it.unibz.inf.ontop.iq.node.impl.UnsatisfiableConditionException;
import it.unibz.inf.ontop.iq.node.normalization.ConditionSimplifier.ExpressionAndSubstitution;
import it.unibz.inf.ontop.iq.node.normalization.FilterNormalizer;
import it.unibz.inf.ontop.model.term.ImmutableExpression;
import it.unibz.inf.ontop.model.term.ImmutableTerm;
import it.unibz.inf.ontop.model.term.TermFactory;
import it.unibz.inf.ontop.model.term.Variable;
import it.unibz.inf.ontop.substitution.ImmutableSubstitution;
import it.unibz.inf.ontop.utils.VariableGenerator;

import java.util.Optional;

@Singleton
public class FilterNormalizerImpl implements FilterNormalizer {

    private static final int MAX_NORMALIZATION_ITERATIONS = 10000;
    private final IntermediateQueryFactory iqFactory;
    private final TermFactory termFactory;
    private final ConditionSimplifier conditionSimplifier;

    @Inject
    private FilterNormalizerImpl(IntermediateQueryFactory iqFactory, TermFactory termFactory,
                                 ConditionSimplifier conditionSimplifier) {
        this.iqFactory = iqFactory;
        this.termFactory = termFactory;
        this.conditionSimplifier = conditionSimplifier;
    }

    /**
     * TODO: Optimization: lift direct construction and filter nodes before normalizing them
     *  (so as to reduce the recursive pressure)
     */
    @Override
    public IQTree normalizeForOptimization(FilterNode initialFilterNode, IQTree initialChild, VariableGenerator variableGenerator, IQTreeCache treeCache) {
        //Non-final
        State state = new State(initialFilterNode, initialChild)
                .normalizeChild(variableGenerator);

        for(int i=0; i < MAX_NORMALIZATION_ITERATIONS; i++) {
            State stateBeforeSimplification = state.liftBindingsAndDistinct()
                    .mergeWithChild();

            State newState = stateBeforeSimplification.simplifyAndPropagateDownConstraint(variableGenerator)
                    .normalizeChild(variableGenerator);

            // Convergence
            if (newState.child.equals(state.child))
                return newState.createNormalizedTree(variableGenerator, treeCache);

            state = newState;
        }

        throw new MinorOntopInternalBugException("Bug: FilterNode.normalizeForOptimization() did not converge after "
                + MAX_NORMALIZATION_ITERATIONS + " iterations");
    }

    /**
     * Immutable
     *
     * Normalization operations are directly done on this structure.
     *
     */
    @SuppressWarnings("OptionalUsedAsFieldOrParameterType")
    protected class State {
        private final ImmutableSet<Variable> projectedVariables;
        // Parent first (should be composed of construction and distinct nodes only)
        private final ImmutableList<UnaryOperatorNode> ancestors;
        private final Optional<ImmutableExpression> condition;
        private final IQTree child;
        /**
         * Initial constructor
         */
        protected State(FilterNode initialFilterNode, IQTree initialChild) {
            projectedVariables = initialChild.getVariables();
            ancestors = ImmutableList.of();
            condition = Optional.of(initialFilterNode.getFilterCondition());
            child = initialChild;
        }

        protected State(ImmutableSet<Variable> projectedVariables, ImmutableList<UnaryOperatorNode> ancestors,
                        Optional<ImmutableExpression> condition, IQTree child) {
            this.projectedVariables = projectedVariables;
            this.ancestors = ancestors;
            this.condition = condition;
            this.child = child;
        }

        private State updateChild(IQTree newChild) {
            return new State(projectedVariables, ancestors, condition, newChild);
        }

        private State updateParentChildAndCondition(UnaryOperatorNode newParent,
                                                                       ImmutableExpression newCondition, IQTree newChild) {
            ImmutableList<UnaryOperatorNode> newAncestors = ImmutableList.<UnaryOperatorNode>builder()
                    .add(newParent)
                    .addAll(ancestors)
                    .build();

            return new State(projectedVariables, newAncestors, Optional.of(newCondition), newChild);
        }

        private State addParentRemoveConditionAndUpdateChild(UnaryOperatorNode newParent, IQTree newChild) {
            ImmutableList<UnaryOperatorNode> newAncestors = ImmutableList.<UnaryOperatorNode>builder()
                    .add(newParent)
                    .addAll(ancestors)
                    .build();

            return new State(projectedVariables, newAncestors, Optional.empty(), newChild);
        }

        private State liftChildAsParent(UnaryIQTree formerChildTree) {
            ImmutableList<UnaryOperatorNode> newAncestors = ImmutableList.<UnaryOperatorNode>builder()
                    .add(formerChildTree.getRootNode())
                    .addAll(ancestors)
                    .build();

            IQTree newChild = formerChildTree.getChild();
            return new State(projectedVariables, newAncestors, condition, newChild);
        }

        private State updateConditionAndChild(ImmutableExpression newCondition, IQTree newChild) {
            return new State(projectedVariables, ancestors, Optional.of(newCondition), newChild);
        }

        private State removeConditionAndUpdateChild(IQTree newChild) {
            return new State(projectedVariables, ancestors, Optional.empty(), newChild);
        }

        private State createEmptyState() {
            return new State(projectedVariables, ImmutableList.of(), Optional.empty(),
                    iqFactory.createEmptyNode(projectedVariables));
        }

        public State normalizeChild(VariableGenerator variableGenerator) {
            return updateChild(child.normalizeForOptimization(variableGenerator));
        }

        /**
         * Returns a tree in which the "filter-level" sub-tree is declared as normalized.
         */
        public IQTree createNormalizedTree(VariableGenerator variableGenerator, IQTreeCache treeCache) {

            if (child.isDeclaredAsEmpty())
                return iqFactory.createEmptyNode(projectedVariables);

            IQTree filterLevelTree = condition
                    .map(c -> (IQTree) iqFactory.createUnaryIQTree(iqFactory.createFilterNode(c), child,
                            treeCache.declareAsNormalizedForOptimizationWithEffect()))
                    .orElse(child);

            if (ancestors.isEmpty())
                return filterLevelTree;

            return ancestors.stream()
                    .reduce(filterLevelTree, (t, n) -> iqFactory.createUnaryIQTree(n, t),
                            // Should not be called
                            (t1, t2) -> { throw new MinorOntopInternalBugException("The order must be respected"); })
                    // Normalizes the ancestors (recursive)
                    .normalizeForOptimization(variableGenerator);
        }

        public State liftBindingsAndDistinct() {
            QueryNode childRoot = child.getRootNode();

            if (childRoot instanceof ConstructionNode)
                return liftBindings((ConstructionNode) childRoot, (UnaryIQTree) child)
                        // Recursive (maybe followed by a distinct)
                        .liftBindingsAndDistinct();

            else if (childRoot instanceof DistinctNode)
                return liftDistinct((DistinctNode) childRoot, (UnaryIQTree) child)
                        // Recursive (may be followed by another construction node)
                        .liftBindingsAndDistinct();
            else
                return this;
        }

        private State liftBindings(ConstructionNode childConstructionNode, UnaryIQTree child) {
            return condition
                    .map(e -> childConstructionNode.getSubstitution().applyToBooleanExpression(e))
                    .map(e -> updateParentChildAndCondition(childConstructionNode, e, child.getChild()))
                    .orElseGet(() -> liftChildAsParent(child));
        }

        private State liftDistinct(DistinctNode childDistinct, UnaryIQTree child) {
            return condition
                    .map(e -> updateParentChildAndCondition(childDistinct, e, child.getChild()))
                    .orElseGet(() -> liftChildAsParent(child));
        }

        /**
         * Tries to merge with the child
         */
        public State mergeWithChild() {
            if (condition.isPresent()) {

                QueryNode childRoot = child.getRootNode();

                if (childRoot instanceof FilterNode) {
                    FilterNode filterChild = (FilterNode) childRoot;

                    ImmutableExpression newCondition = termFactory.getConjunction(condition.get(),
                            filterChild.getFilterCondition());

                    return updateConditionAndChild(newCondition, ((UnaryIQTree)child).getChild());
                }

                else if (childRoot instanceof InnerJoinNode) {
                    ImmutableExpression newJoiningCondition = ((InnerJoinNode) childRoot).getOptionalFilterCondition()
                            .map(c -> termFactory.getConjunction(condition.get(), c))
                            .orElse(condition.get());

                    InnerJoinNode newJoinNode = iqFactory.createInnerJoinNode(newJoiningCondition);

                    IQTree newChild = iqFactory.createNaryIQTree(newJoinNode, child.getChildren());
                    return removeConditionAndUpdateChild(newChild);
                }
            }
            return this;
        }

        public State simplifyAndPropagateDownConstraint(VariableGenerator variableGenerator) {
            if (!condition.isPresent()) {
                return this;
            }

            try {
                VariableNullability childVariableNullability = child.getVariableNullability();

                // TODO: also consider the constraint for simplifying the condition
                ExpressionAndSubstitution conditionSimplificationResults = conditionSimplifier.simplifyCondition(
                        condition.get(), ImmutableList.of(child), childVariableNullability);

                Optional<ImmutableExpression> downConstraint = conditionSimplifier.computeDownConstraint(Optional.empty(),
                        conditionSimplificationResults, childVariableNullability);

                IQTree newChild = Optional.of(conditionSimplificationResults.getSubstitution())
                        .filter(s -> !s.isEmpty())
                        .map(s -> child.applyDescendingSubstitution(s, downConstraint, variableGenerator))
                        .orElseGet(() -> downConstraint
                                .map(c -> child.propagateDownConstraint(c, variableGenerator))
                                .orElse(child));

                Optional<ConstructionNode> parentConstructionNode = Optional.of(conditionSimplificationResults.getSubstitution())
                        .filter(s -> !s.isEmpty())
                        .map(s -> (ImmutableSubstitution<ImmutableTerm>) (ImmutableSubstitution<?>) s)
                        .map(s -> iqFactory.createConstructionNode(child.getVariables(), s));

                return conditionSimplificationResults.getOptionalExpression()
                        .map(e -> parentConstructionNode
                                .map(p -> updateParentChildAndCondition(p, e, newChild))
                                .orElseGet(() -> updateConditionAndChild(e, newChild)))
                        .orElseGet(() -> parentConstructionNode
                                .map(p -> addParentRemoveConditionAndUpdateChild(p, newChild))
                                .orElseGet(() -> removeConditionAndUpdateChild(newChild)));
            } catch (UnsatisfiableConditionException e) {
                return createEmptyState();
            }
        }
    }
}


text:
using pcl::PointCloud;
using pcl::PointIndices;
using pcl::PointXYZRGB;
using std::vector;

namespace rapid {
namespace perception {
ParseParams Pr2Params() {
  ParseParams p;
  p.scene.min_x = 0.2;
  p.scene.max_x = 1.2;
  p.scene.min_y = -1;
  p.scene.max_y = 1;
  p.scene.min_z = 0.3;
  p.scene.max_z = 1.7;
  p.hsurface.distance_threshold = 0.015;
  p.hsurface.eps_angle = rapid::utils::DegreesToRadians(5);
  p.objects.distance_threshold = 0.05;
  p.objects.point_color_threshold = 35;
  p.objects.region_color_threshold = 20;
  p.objects.min_cluster_size = 38;
  return p;
}

bool ParseScene(const PointCloud<PointXYZRGB>::ConstPtr& cloud,
                const ParseParams& params, Scene* scene) {
  // This function just crops the scene to a box given by the params.
  scene->set_cloud(cloud);
  Eigen::Vector4f min;
  min << params.scene.min_x, params.scene.min_y, params.scene.min_z, 1;
  Eigen::Vector4f max;
  max << params.scene.max_x, params.scene.max_y, params.scene.max_z, 1;
  pcl::CropBox<PointXYZRGB> cb;
  cb.setInputCloud(cloud);
  cb.setMin(min);
  cb.setMax(max);

  vector<int> box_indices;
  cb.filter(box_indices);

  PointIndices::Ptr pcl_indices(new PointIndices);
  pcl_indices->indices = box_indices;
  HSurface primary_surface;
  bool success = ParseHSurface(cloud, pcl_indices, params, &primary_surface);
  if (!success) {
    return false;
  }
  scene->set_primary_surface(primary_surface);
  geometry_msgs::PoseStamped ps;
  ps.header.frame_id = cloud->header.frame_id;
  ps.pose.position.x = (params.scene.max_x + params.scene.min_x) / 2;
  ps.pose.position.y = (params.scene.max_y + params.scene.min_y) / 2;
  ps.pose.position.z = (params.scene.max_z + params.scene.min_z) / 2;
  ps.pose.orientation.w = 1;
  scene->set_pose(ps);
  geometry_msgs::Vector3 scale;
  scale.x = params.scene.max_x - params.scene.min_x;
  scale.y = params.scene.max_y - params.scene.min_y;
  scale.z = params.scene.max_z - params.scene.min_z;
  scene->set_scale(scale);
  return true;
}

bool ParseHSurface(const pcl::PointCloud<pcl::PointXYZRGB>::ConstPtr& cloud,
                   const PointIndices::ConstPtr& indices,
                   const ParseParams& params, HSurface* surface) {
  // Find the dominant plane, which should be mostly horizontal. This becomes
  // the HSurface.
  PointIndices::Ptr plane_inliers(new PointIndices);
  bool found =
      FindHorizontalPlane(cloud, indices, params.hsurface.distance_threshold,
                          params.hsurface.eps_angle, plane_inliers);
  if (!found) {
    return false;
  }

  geometry_msgs::PoseStamped ps;
  geometry_msgs::Vector3 scale;
  GetBoundingBox(cloud, plane_inliers, &ps, &scale);

  surface->SetCloud(cloud, plane_inliers);
  surface->set_name("primary_surface");
  surface->set_pose(ps);
  surface->set_scale(scale);

  // Find points above the HSurface
  PointIndices::Ptr object_indices(new PointIndices);
  tf::Vector3 surface_translation(ps.pose.position.x, ps.pose.position.y,
                                  ps.pose.position.z);
  tf::Quaternion surface_orientation;
  tf::quaternionMsgToTF(ps.pose.orientation, surface_orientation);
  tf::Transform base_to_surface(surface_orientation, surface_translation);
  for (size_t i = 0; i < indices->indices.size(); ++i) {
    int index = indices->indices[i];
    const PointXYZRGB& point = cloud->points[index];
    tf::Vector3 point_v(point.x, point.y, point.z);
    // Project point into table space
    tf::Vector3 table_p = base_to_surface.inverse() * point_v;
    if (table_p.x() >= -scale.x / 2 && table_p.x() <= scale.x / 2 &&
        table_p.y() >= -scale.y / 2 && table_p.y() <= scale.y / 2 &&
        table_p.z() > scale.z / 2) {
      object_indices->indices.push_back(index);
    }
  }

  // We must reify the object cloud now because the outlier filters search for
  // neighbors in the entire input cloud, not just in the indices subset.
  PointCloud<PointXYZRGB>::Ptr object_cloud =
      IndicesToCloud(cloud, object_indices);

  pcl::RadiusOutlierRemoval<PointXYZRGB> radius;
  radius.setInputCloud(object_cloud);
  radius.setRadiusSearch(0.05);
  radius.setMinNeighborsInRadius(10);
  radius.filter(*object_cloud);

  vector<Object> objects;
  PointIndices::Ptr all_indices(new PointIndices);
  ParseObjects(object_cloud, all_indices, params, &objects);
  for (size_t i = 0; i < objects.size(); ++i) {
    surface->AddObject(objects[i]);
  }
  return true;
}

bool ParseObjects(const pcl::PointCloud<pcl::PointXYZRGB>::ConstPtr& cloud,
                  const pcl::PointIndices::ConstPtr& indices,
                  const ParseParams& params, std::vector<Object>* objects) {
  pcl::search::KdTree<PointXYZRGB>::Ptr tree(
      new pcl::search::KdTree<PointXYZRGB>);
  tree->setInputCloud(cloud);

  vector<PointIndices> cluster_indices;
  pcl::RegionGrowingRGB<PointXYZRGB> ec;
  ec.setInputCloud(cloud);
  if (indices->indices.size() != 0) {
    ec.setIndices(indices);
  }
  ec.setSearchMethod(tree);
  ec.setDistanceThreshold(params.objects.distance_threshold);
  ec.setPointColorThreshold(params.objects.point_color_threshold);
  ec.setRegionColorThreshold(params.objects.region_color_threshold);
  ec.setMinClusterSize(params.objects.min_cluster_size);
  ec.extract(cluster_indices);

  int obj_num = 0;
  for (vector<PointIndices>::const_iterator it = cluster_indices.begin();
       it != cluster_indices.end(); ++it) {
    PointIndices::Ptr cluster_indices_p(new PointIndices);
    *cluster_indices_p = *it;
    geometry_msgs::PoseStamped ps;
    ps.header.frame_id = cloud->header.frame_id;
    geometry_msgs::Vector3 scale;
    GetPlanarBoundingBox(cloud, cluster_indices_p, &ps.pose, &scale);
    std::stringstream ss;
    ss << "object_" << obj_num++;

    Object obj;
    obj.SetCloud(cloud, cluster_indices_p);
    obj.set_name(ss.str());
    obj.set_pose(ps);
    obj.set_scale(scale);
    objects->push_back(obj);
  }
  return true;
}
}  // namespace perception
}  // namespace rapid


text:
package org.jusecase.properties.usecases;

import org.jusecase.Usecase;
import org.jusecase.properties.gateways.PropertiesGateway;
import org.jusecase.properties.gateways.SettingsGateway;
import org.jusecase.properties.gateways.UndoableRequestGateway;

public class Initialize implements Usecase<Initialize.Request, Initialize.Response> {

    private final ReloadBundle reloadBundle;

    public Initialize(PropertiesGateway propertiesGateway, SettingsGateway settingsGateway, UndoableRequestGateway undoableRequestGateway) {
        this.reloadBundle = new ReloadBundle(propertiesGateway, settingsGateway, undoableRequestGateway);
    }

    @Override
    public Response execute(Request request) {
        Response response = new Response();

        ReloadBundle.Response reloadBundleResponse = reloadBundle.execute(new ReloadBundle.Request());
        response.fileNames = reloadBundleResponse.fileNames;
        response.keys = reloadBundleResponse.keys;

        return response;
    }

    public static class Request {
    }

    public static class Response extends LoadBundle.Response {
    }
}


text:
title: Introduction
type: index
weight: 1
---

A full PHP development environment for Docker.

Includes pre-packaged Docker Images, all pre-configured to provide a wonderful PHP development environment.

Laradock is well known in the Laravel community, as the project started with single focus on running Laravel projects on Docker. Later and due to the large adoption from the PHP community, it started supporting other PHP projects like Symfony, CodeIgniter, WordPress, Drupal...

![](https://s19.postimg.org/jblfytw9f/laradock-logo.jpg)

## Quick Overview

Let's see how easy it is to install `NGINX`, `PHP`, `Composer`, `MySQL`, `Redis` and `Beanstalkd`:

1 - Clone Laradock inside your PHP project:

```shell
git clone https://github.com/Laradock/laradock.git
```

2 - Enter the laradock folder and rename `env-example` to `.env`.

```shell
cp env-example .env
```

3 - Run your containers:

```shell
docker-compose up -d nginx mysql phpmyadmin redis workspace
```

4 - Open your project's `.env` file and set the following:

```shell
DB_HOST=mysql
REDIS_HOST=redis
QUEUE_HOST=beanstalkd
```

5 - Open your browser and visit localhost: `http://localhost`.

```shell
That's it! enjoy :)
```

## Features

- Easy switch between PHP versions: 7.2, 7.1, 5.6...
- Choose your favorite database engine: MySQL, Postgres, MariaDB...
- Run your own combination of software: Memcached, HHVM, Beanstalkd...
- Every software runs on a separate container: PHP-FPM, NGINX, PHP-CLI...
- Easy to customize any container, with simple edit to the `Dockerfile`.
- All Images extends from an official base Image. (Trusted base Images).
- Pre-configured NGINX to host any code at your root directory.
- Can use Laradock per project, or single Laradock for all projects.
- Easy to install/remove software's in Containers using environment variables.
- Clean and well structured Dockerfiles (`Dockerfile`).
- Latest version of the Docker Compose file (`docker-compose`).
- Everything is visible and editable.
- Fast Images Builds.
- More to come every week..

## Supported Software (Images)

In adhering to the separation of concerns principle as promoted by Docker, Laradock runs each software on its own Container.
You can turn On/Off as many instances of as any container without worrying about the configurations, everything works like a charm.

- **Database Engines:**
MySQL - MariaDB - Percona - MongoDB - Neo4j - RethinkDB - MSSQL - PostgreSQL - Postgres-PostGIS.
- **Database Management:**
PhpMyAdmin - Adminer - PgAdmin
- **Cache Engines:**
Redis - Memcached - Aerospike
- **PHP Servers:**
NGINX - Apache2 - Caddy
- **PHP Compilers:**
PHP FPM - HHVM
- **Message Queueing:**
Beanstalkd - RabbitMQ - PHP Worker
- **Queueing Management:**
Beanstalkd Console - RabbitMQ Console
- **Random Tools:**
Mailu - HAProxy - Certbot - Blackfire - Selenium - Jenkins - ElasticSearch - Kibana - Grafana - Gitlab - Mailhog - MailDev - Minio - Varnish - Swoole - NetData - Portainer - Laravel Echo - Phalcon...

Laradock introduces the **Workspace** Image, as a development environment.
It contains a rich set of helpful tools, all pre-configured to work and integrate with almost any combination of Containers and tools you may choose.

**Workspace Image Tools**
PHP CLI - Composer - Git - Linuxbrew - Node - V8JS - Gulp - SQLite - xDebug - Envoy - Deployer - Vim - Yarn - SOAP - Drush...

You can choose, which tools to install in your workspace container and other containers, from the `.env` file.

> If you modify `docker-compose.yml`, `.env` or any `dockerfile` file, you must re-build your containers, to see those effects in the running instance.

If you can't find your Software in the list, build it yourself and submit it. Contributions are welcomed :)

## Sponsors

Support this project by becoming a sponsor.

Your logo will show up on the [github repository](https://github.com/laradock/laradock/) index page and the [documentation](http://laradock.io/) main page, with a link to your website. [[Become a sponsor](https://opencollective.com/laradock#sponsor)]

## What is Docker?

[Docker](https://www.docker.com) is an open platform for developing, shipping, and running applications.
Docker enables you to separate your applications from your infrastructure so you can deliver software quickly.
With Docker, you can manage your infrastructure in the same ways you manage your applications.
By taking advantage of Docker's methodologies for shipping, testing, and deploying code quickly, you can significantly reduce the delay between writing code and running it in production.

## Why Docker not Vagrant!?

[Vagrant](https://www.vagrantup.com) creates Virtual Machines in minutes while Docker creates Virtual Containers in seconds.

Instead of providing a full Virtual Machines, like you get with Vagrant, Docker provides you **lightweight** Virtual Containers, that share the same kernel and allow to safely execute independent processes.

In addition to the speed, Docker gives tons of features that cannot be achieved with Vagrant.

Most importantly Docker can run on Development and on Production (same environment everywhere). While Vagrant is designed for Development only, (so you have to re-provision your server on Production every time).

## Demo Video

What's better than a **Demo Video**:

- Laradock v5.* (should be next!)
- Laradock [v4.*](https://www.youtube.com/watch?v=TQii1jDa96Y)
- Laradock [v2.*](https://www.youtube.com/watch?v=-DamFMczwDA)
- Laradock [v0.3](https://www.youtube.com/watch?v=jGkyO6Is_aI)
- Laradock [v0.1](https://www.youtube.com/watch?v=3YQsHe6oF80)

## Chat with us

You are welcome to join our chat room on Gitter.

[![Gitter](https://badges.gitter.im/Laradock/laradock.svg)](https://gitter.im/Laradock/laradock?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)

## Donations

> Help keeping the project development going, by [contributing](http://laradock.io/contributing) or donating a little.
> Thanks in advance.

Donate directly via [Paypal](https://www.paypal.me/mzalt)

[![Donate](https://img.shields.io/badge/Donate-PayPal-green.svg)](https://www.paypal.me/mzalt)

or become a backer on [Open Collective](https://opencollective.com/laradock#backer)

or show your support via [Beerpay](https://beerpay.io/laradock/laradock)

[![Beerpay](https://beerpay.io/laradock/laradock/badge.svg?style=flat)](https://beerpay.io/laradock/laradock)


text:
/*
 * Open Source Software published under the Apache Licence, Version 2.0.
 */

package io.github.vocabhunter.gui.dialogues;

import io.github.vocabhunter.gui.i18n.I18nKey;
import io.github.vocabhunter.gui.i18n.I18nManager;
import javafx.scene.Parent;
import javafx.scene.Scene;
import javafx.scene.control.Alert;
import javafx.stage.Modality;
import javafx.stage.Stage;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import java.nio.file.Path;
import javax.inject.Inject;
import javax.inject.Singleton;

import static io.github.vocabhunter.gui.i18n.I18nKey.*;

@Singleton
public class DialogueTool {
    private static final Logger LOG = LoggerFactory.getLogger(DialogueTool.class);

    private final I18nManager i18nManager;

    @Inject
    public DialogueTool(final I18nManager i18nManager) {
        this.i18nManager = i18nManager;
    }

    public void setupModal(final Stage stage, final Parent root, final I18nKey titleKey) {
        stage.initModality(Modality.APPLICATION_MODAL);
        stage.setTitle(i18nManager.text(titleKey));
        stage.setScene(new Scene(root));
        stage.show();
    }

    public void errorOnOpen(final Path file, final RuntimeException e) {
        handleFileError(file, e, ERROR_SESSION_OPEN_TITLE, ERROR_SESSION_OPEN_DETAILS, "Unable to open file '{}'");
    }

    public void errorOnSave(final Path file, final RuntimeException e) {
        handleFileError(file, e, ERROR_SESSION_SAVE_TITLE, ERROR_SESSION_SAVE_DETAILS, "Unable to save session file '{}'");
    }

    public void errorOnExport(final Path file, final RuntimeException e) {
        handleFileError(file, e, ERROR_SESSION_EXPORT_TITLE, ERROR_SESSION_EXPORT_DETAILS, "Unable export to file '{}'");
    }

    private void handleFileError(final Path file, final RuntimeException e, final I18nKey titleKey, final I18nKey detailKey, final String log) {
        LOG.info(log, file, e);

        String message = i18nManager.text(detailKey, file.getFileName());
        ErrorDialogue dialogue = new ErrorDialogue(i18nManager, titleKey, e, message);

        dialogue.showError();
    }

    public void filterErrorAlert(final Exception e) {
        ErrorDialogue dialogue = new ErrorDialogue(i18nManager, FILTER_ERROR_TITLE, e, e.getMessage(), i18nManager.text(FILTER_ERROR_DISABLED));

        dialogue.showError();
    }

    public void filterErrorAlert() {
        Alert alert = new Alert(Alert.AlertType.ERROR);

        alert.setTitle(i18nManager.text(FILTER_ERROR_TITLE));
        alert.setHeaderText(i18nManager.text(FILTER_ERROR_ALL));
        alert.setContentText(i18nManager.text(FILTER_ERROR_DISABLED));
        alert.getDialogPane().setId("filterErrorDialogue");

        alert.showAndWait();
    }

    public UnsavedChangesDialogue unsavedChangesDialogue(final Path file) {
        return new UnsavedChangesDialogue(file, i18nManager);
    }
}


text:
namespace IPC {
class Message;
class Sender;
}

namespace ui {
class WindowAndroid;
struct DidOverscrollParams;
}

namespace content {

class RenderWidgetHostViewAndroid;
class SynchronousCompositorClient;
class SynchronousCompositorBrowserFilter;
struct SyncCompositorCommonRendererParams;

class SynchronousCompositorHost : public SynchronousCompositor {
 public:
  static std::unique_ptr<SynchronousCompositorHost> Create(
      RenderWidgetHostViewAndroid* rwhva);

  ~SynchronousCompositorHost() override;

  // SynchronousCompositor overrides.
  SynchronousCompositor::Frame DemandDrawHw(
      const gfx::Size& viewport_size,
      const gfx::Rect& viewport_rect_for_tile_priority,
      const gfx::Transform& transform_for_tile_priority) override;
  scoped_refptr<FrameFuture> DemandDrawHwAsync(
      const gfx::Size& viewport_size,
      const gfx::Rect& viewport_rect_for_tile_priority,
      const gfx::Transform& transform_for_tile_priority) override;
  bool DemandDrawSw(SkCanvas* canvas) override;
  void ReturnResources(uint32_t compositor_frame_sink_id,
                       const cc::ReturnedResourceArray& resources) override;
  void SetMemoryPolicy(size_t bytes_limit) override;
  void DidChangeRootLayerScrollOffset(
      const gfx::ScrollOffset& root_offset) override;
  void SynchronouslyZoomBy(float zoom_delta, const gfx::Point& anchor) override;
  void OnComputeScroll(base::TimeTicks animation_time) override;

  void DidOverscroll(const ui::DidOverscrollParams& over_scroll_params);
  void DidSendBeginFrame(ui::WindowAndroid* window_android);
  bool OnMessageReceived(const IPC::Message& message);

  // Called by SynchronousCompositorBrowserFilter.
  int routing_id() const { return routing_id_; }
  void UpdateFrameMetaData(cc::CompositorFrameMetadata frame_metadata);
  void ProcessCommonParams(const SyncCompositorCommonRendererParams& params);

  SynchronousCompositorClient* client() { return client_; }

 private:
  class ScopedSendZeroMemory;
  struct SharedMemoryWithSize;
  friend class ScopedSetZeroMemory;
  friend class SynchronousCompositorBase;

  SynchronousCompositorHost(RenderWidgetHostViewAndroid* rwhva,
                            bool use_in_proc_software_draw);
  void CompositorFrameSinkCreated();
  bool DemandDrawSwInProc(SkCanvas* canvas);
  void SetSoftwareDrawSharedMemoryIfNeeded(size_t stride, size_t buffer_size);
  void SendZeroMemory();
  SynchronousCompositorBrowserFilter* GetFilter();

  RenderWidgetHostViewAndroid* const rwhva_;
  SynchronousCompositorClient* const client_;
  const scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner_;
  const int process_id_;
  const int routing_id_;
  IPC::Sender* const sender_;
  const bool use_in_process_zero_copy_software_draw_;

  bool registered_with_filter_ = false;

  size_t bytes_limit_;
  std::unique_ptr<SharedMemoryWithSize> software_draw_shm_;

  // Indicates the next draw needs to be synchronous
  bool compute_scroll_needs_synchronous_draw_ = false;

  // Updated by both renderer and browser.
  gfx::ScrollOffset root_scroll_offset_;

  // From renderer.
  uint32_t renderer_param_version_;
  bool need_animate_scroll_;
  uint32_t need_invalidate_count_;
  uint32_t did_activate_pending_tree_count_;

  DISALLOW_COPY_AND_ASSIGN(SynchronousCompositorHost);
};

}  // namespace content

#endif  // CONTENT_BROWSER_ANDROID_SYNCHRONOUS_COMPOSITOR_HOST_H_


text:
const R = require("ramda");
const {stripIndent} = require("common-tags");

const FILENAME = "quotes.json";

module.exports = (s3Store, {style, match, help}) => {
  const normalize = (s) => style.clear(s).toLowerCase().trim();
  const quotesEqual = R.curry((q1, q2) => normalize(q1) == normalize(q2));
  const quoteFuzzyMatch = R.curry((query, quote) => normalize(quote).includes(normalize(query)));

  const getQuotes = (state) =>
    R.pathOr([], ["quotes"], state);

  const setQuotes = (quotes, state) =>
    R.assocPath(["quotes"], quotes, state);

  const updateQuotes = (upd, cb) => {
    getState((err, state) => {
      if (err) return cb(err);
      const oldQuotes = getQuotes(state);
      const newQuotes = upd(oldQuotes);
      saveState(setQuotes(newQuotes, state), (err) => {
        cb(err, err ? null : newQuotes, oldQuotes);
      });
    });
  };

  const findQuote = (quotes, query, lastQuote) => {
    if (query) quotes = R.filter(quoteFuzzyMatch(query), quotes);
    if (!query && lastQuote) quotes = R.reject(quotesEqual(lastQuote), quotes);
    if (quotes.length == 0) return null;
    return quotes[Math.floor(Math.random() * quotes.length)];
  };

  const getState = (...args) => s3Store.getState(FILENAME, ...args);
  const saveState = (...args) => s3Store.saveState(FILENAME, ...args);
  let lastQuote = null;

  const retrieveQuotes = (cb) => {
    getState((err, state) => {
      if (err) return cb(err);
      cb(null, getQuotes(state));
    });
  };

  help("quotes", stripIndent`
    Save your shitposts for future generations.
    ${style.em(`!q [query]`)}: Posts a random saved quote, optionally within search results
    ${style.em(`!aq <text>`)}: Adds the given quote
    ${style.em(`!dq <text>`)}: Deletes the given quote
  `);

  match(/^!q(?:\s+(.+))?$/i, ({reply}, [query]) => {
    retrieveQuotes((err, quotes) => {
      if (err) return console.error(err);
      const quote = findQuote(quotes, query ? style.clear(query) : null, lastQuote);
      reply(quote ? style.em(quote) : "No results");
      lastQuote = quote;
    });
  });

  match(/^!aq\s+(.+)$/i, ({reply}, [quote]) => {
    updateQuotes(R.append(quote), (err, newQuotes) => {
      reply(err ? "(╯°□°)╯︵ ┻━┻" : `Quote added (${newQuotes.length} total)`);
    });
  });

  match(/^!dq\s+(.+)$/i, ({reply}, [quote]) => {
    updateQuotes(R.reject(quotesEqual(quote)), (err, newQuotes, oldQuotes) => {
      if (err) {
        console.error(err);
        reply("(╯°□°)╯︵ ┻━┻");
      } else if (oldQuotes && oldQuotes.length == newQuotes.length) {
        reply(`No matching messages found`);
      } else {
        reply(`Quote deleted (${newQuotes.length} total)`);
      }
    });
  });
};


text:
require 'google/protobuf'

require 'google/api/field_behavior_pb'
require 'google/cloud/recommendationengine/v1beta1/common_pb'

Google::Protobuf::DescriptorPool.generated_pool.build do
  add_file("google/cloud/recommendationengine/v1beta1/catalog.proto", :syntax => :proto3) do
    add_message "google.cloud.recommendationengine.v1beta1.CatalogItem" do
      optional :id, :string, 1
      repeated :category_hierarchies, :message, 2, "google.cloud.recommendationengine.v1beta1.CatalogItem.CategoryHierarchy"
      optional :title, :string, 3
      optional :description, :string, 4
      optional :item_attributes, :message, 5, "google.cloud.recommendationengine.v1beta1.FeatureMap"
      optional :language_code, :string, 6
      repeated :tags, :string, 8
      optional :item_group_id, :string, 9
      oneof :recommendation_type do
        optional :product_metadata, :message, 10, "google.cloud.recommendationengine.v1beta1.ProductCatalogItem"
      end
    end
    add_message "google.cloud.recommendationengine.v1beta1.CatalogItem.CategoryHierarchy" do
      repeated :categories, :string, 1
    end
    add_message "google.cloud.recommendationengine.v1beta1.ProductCatalogItem" do
      map :costs, :string, :float, 3
      optional :currency_code, :string, 4
      optional :stock_state, :enum, 5, "google.cloud.recommendationengine.v1beta1.ProductCatalogItem.StockState"
      optional :available_quantity, :int64, 6
      optional :canonical_product_uri, :string, 7
      repeated :images, :message, 8, "google.cloud.recommendationengine.v1beta1.Image"
      oneof :price do
        optional :exact_price, :message, 1, "google.cloud.recommendationengine.v1beta1.ProductCatalogItem.ExactPrice"
        optional :price_range, :message, 2, "google.cloud.recommendationengine.v1beta1.ProductCatalogItem.PriceRange"
      end
    end
    add_message "google.cloud.recommendationengine.v1beta1.ProductCatalogItem.ExactPrice" do
      optional :display_price, :float, 1
      optional :original_price, :float, 2
    end
    add_message "google.cloud.recommendationengine.v1beta1.ProductCatalogItem.PriceRange" do
      optional :min, :float, 1
      optional :max, :float, 2
    end
    add_enum "google.cloud.recommendationengine.v1beta1.ProductCatalogItem.StockState" do
      value :STOCK_STATE_UNSPECIFIED, 0
      value :IN_STOCK, 0
      value :OUT_OF_STOCK, 1
      value :PREORDER, 2
      value :BACKORDER, 3
    end
    add_message "google.cloud.recommendationengine.v1beta1.Image" do
      optional :uri, :string, 1
      optional :height, :int32, 2
      optional :width, :int32, 3
    end
  end
end

module Google
  module Cloud
    module RecommendationEngine
      module V1beta1
        CatalogItem = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.recommendationengine.v1beta1.CatalogItem").msgclass
        CatalogItem::CategoryHierarchy = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.recommendationengine.v1beta1.CatalogItem.CategoryHierarchy").msgclass
        ProductCatalogItem = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.recommendationengine.v1beta1.ProductCatalogItem").msgclass
        ProductCatalogItem::ExactPrice = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.recommendationengine.v1beta1.ProductCatalogItem.ExactPrice").msgclass
        ProductCatalogItem::PriceRange = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.recommendationengine.v1beta1.ProductCatalogItem.PriceRange").msgclass
        ProductCatalogItem::StockState = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.recommendationengine.v1beta1.ProductCatalogItem.StockState").enummodule
        Image = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.recommendationengine.v1beta1.Image").msgclass
      end
    end
  end
end


text:
package com.jetdrone.vertx.yoke.annotations;

import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
import java.util.regex.Pattern;

/**
 * # RegExParam
 *
 * Annotate a field with the param to be mounted in the middleware chain.
 */
@Retention(RetentionPolicy.RUNTIME)
@Target({ElementType.FIELD})
public @interface RegExParam {
    String value();
}


text:
« CSS « CSS Reference   « CSS Reference:Mozilla Extensions

Summary

In Mozilla applications, -moz-user-input determines if an element will accept user input.

Initial value
:
none

Applies to: all elements

Inherited
: yes

Percentages: n/a

Media:
visual

Computed value
: as specified

-moz-user-input was one of the proposals leading to the proposed CSS 3
user-input property, which has not yet reached Candidate Recommendation (call for implementations).

For elements that normally take user input, such as a textarea, the initial value of -moz-user-input is enabled.

Syntax

-moz-user-input: none | enabled | disabled | inherit

Values

none

The element does not respond to user input, and it does not become
:active.

enabled

The element accepts user input. For textboxes, this is the default behavior.

disabled

The element does not accept user input. However, this is not the same as setting
disabled to true, in that the element is drawn normally.

Related properties

-moz-user-focus controls what happens when an element is given focus.

-moz-user-modify controls if a user can read or write in an element.

-moz-user-select controls how an element is selected.

Examples

input.example {
  /* the user will be able to select the text, but not change it. */
  -moz-user-input: disabled;
}


text:
@NonNullByDefault
package org.atlasapi.source;

import com.metabroadcast.common.annotation.NonNullByDefault;


text:
package com.helpplusapp.amit.helpplus.datahelpler;

import ckm.simple.sql_provider.annotation.SimpleSQLColumn;
import ckm.simple.sql_provider.annotation.SimpleSQLTable;

/**
 * Created by amit on 8/30/2016.
 */
@SimpleSQLTable(table = "helpPlusDBTable", provider = App.HELPPLUS_PROVIDER)
public class HelpPlusDBTable {

    @SimpleSQLColumn(value = "_id",primary = true)
    public long id;

    @SimpleSQLColumn("tagname")
    public String tagName;

    @SimpleSQLColumn("timecreated")
    public String timeCreated;

    public HelpPlusDBTable() {
    }

    public HelpPlusDBTable(String tagName, String timeCreated) {
        this.tagName = tagName;
        this.timeCreated = timeCreated;
    }
}


text:
<?php
/**
 * ALIPAY API: alipay.acquire.cancel request
 *
 * @author auto create
 * @since 1.0, 2014-06-12 17:17:06
 */
class AlipayAcquireCancelRequest
{
	/**
	 * 操作员ID。
	 **/
	private $operatorId;

	/**
	 * 操作员的类型:
0:支付宝操作员
1:商户的操作员
如果传入其它值或者为空,则默认设置为1
	 **/
	private $operatorType;

	/**
	 * 支付宝合作商户网站唯一订单号。
	 **/
	private $outTradeNo;

	/**
	 * 该交易在支付宝系统中的交易流水号。
最短16位,最长64位。
如果同时传了out_trade_no和trade_no,则以trade_no为准。
	 **/
	private $tradeNo;

	private $apiParas = array();
	private $terminalType;
	private $terminalInfo;
	private $prodCode;
	private $apiVersion="1.0";
	private $notifyUrl;
	private $returnUrl;
    private $needEncrypt=false;

	public function setOperatorId($operatorId)
	{
		$this->operatorId = $operatorId;
		$this->apiParas["operator_id"] = $operatorId;
	}

	public function getOperatorId()
	{
		return $this->operatorId;
	}

	public function setOperatorType($operatorType)
	{
		$this->operatorType = $operatorType;
		$this->apiParas["operator_type"] = $operatorType;
	}

	public function getOperatorType()
	{
		return $this->operatorType;
	}

	public function setOutTradeNo($outTradeNo)
	{
		$this->outTradeNo = $outTradeNo;
		$this->apiParas["out_trade_no"] = $outTradeNo;
	}

	public function getOutTradeNo()
	{
		return $this->outTradeNo;
	}

	public function setTradeNo($tradeNo)
	{
		$this->tradeNo = $tradeNo;
		$this->apiParas["trade_no"] = $tradeNo;
	}

	public function getTradeNo()
	{
		return $this->tradeNo;
	}

	public function getApiMethodName()
	{
		return "alipay.acquire.cancel";
	}

	public function setNotifyUrl($notifyUrl)
	{
		$this->notifyUrl=$notifyUrl;
	}

	public function getNotifyUrl()
	{
		return $this->notifyUrl;
	}

	public function setReturnUrl($returnUrl)
	{
		$this->returnUrl=$returnUrl;
	}

	public function getReturnUrl()
	{
		return $this->returnUrl;
	}

	public function getApiParas()
	{
		return $this->apiParas;
	}

	public function getTerminalType()
	{
		return $this->terminalType;
	}

	public function setTerminalType($terminalType)
	{
		$this->terminalType = $terminalType;
	}

	public function getTerminalInfo()
	{
		return $this->terminalInfo;
	}

	public function setTerminalInfo($terminalInfo)
	{
		$this->terminalInfo = $terminalInfo;
	}

	public function getProdCode()
	{
		return $this->prodCode;
	}

	public function setProdCode($prodCode)
	{
		$this->prodCode = $prodCode;
	}

	public function setApiVersion($apiVersion)
	{
		$this->apiVersion=$apiVersion;
	}

	public function getApiVersion()
	{
		return $this->apiVersion;
	}

  public function setNeedEncrypt($needEncrypt)
  {

     $this->needEncrypt=$needEncrypt;

  }

  public function getNeedEncrypt()
  {
    return $this->needEncrypt;
  }

}


text:
package models

// It is very important that NewValueSetMap gets called to get a populated ValueSetMap
type ValueSetMap map[string][]CodeSet

func NewValueSetMap(vs []ValueSet) ValueSetMap {
	vsMap := make(ValueSetMap)
	for _, valueSet := range vs {
		vsMap[valueSet.Oid] = valueSet.CodeSetMap()
	}
	return vsMap
}

// ValueSet is a set of concepts relating to a particular topic
type ValueSet struct {
	Oid         string    `json:"oid"`
	DisplayName string    `json:"display_name"`
	Version     string    `json:"version"`
	Concepts    []Concept `json:"concepts"`
}

// CodeSetMap returns a slice of CodeSets, each containing Concepts for a different code system
func (vs *ValueSet) CodeSetMap() []CodeSet {
	var cs = make(map[string][]Concept)
	for _, concept := range vs.Concepts {
		cs[concept.CodeSystemName] = append(cs[concept.CodeSystemName], concept)
	}
	var retVal = []CodeSet{}
	for key, val := range cs {
		retVal = append(retVal, CodeSet{Set: key, Values: val})
	}
	return retVal
}

// Concept is a mapping between code/system/version and a display name
type Concept struct {
	Code              string `json:"code"`
	CodeSystem        string `json:"code_system"`
	CodeSystemName    string `json:"code_system_name"`
	CodeSystemVersion string `json:"code_system_version"`
	DisplayName       string `json:"display_name"`
}

// CodeSet is a struct grouping Concepts by CodeSystem
type CodeSet struct {
	Set    string
	Values []Concept
}

func (v ValueSetMap) GenerateCodeDisplay(entry *Entry, coded *Coded, MapDataCriteria Mdc, codeType string) CodeDisplay {
	codeDisplay, err := entry.GetCodeDisplay(codeType)
	if err != nil {
		panic(err.Error())
	}
	codeDisplay.MapDataCriteria = MapDataCriteria
	switch codeType {
	case "resultValue":
		for i, oid := range MapDataCriteria.ResultOids {
			preferredCodes := coded.PreferredCodes(codeDisplay.PreferredCodeSets, codeDisplay.CodeSetRequired, codeDisplay.ValueSetPreferred, v, oid)
			codeDisplay.setCodesFromPreferred(preferredCodes)
			if codeDisplay.PreferredCode.Code != "" {
				oldOid := MapDataCriteria.ResultOids[0]
				MapDataCriteria.ResultOids[0] = oid
				MapDataCriteria.ResultOids[i] = oldOid
				return codeDisplay
			}
		}
		for codeSystem, codes := range coded.Codes {
			codeDisplay.PreferredCode = Concept{CodeSystem: codeSystem, Code: codes[0]}
			break
		}
	case "diagnosis", "principalDiagnosis": // Preferred Code For Field
		field := codeTypeToField(codeType)
		for i, oid := range MapDataCriteria.FieldOids[field] {
			preferredCodes := coded.PreferredCodes(codeDisplay.PreferredCodeSets, codeDisplay.CodeSetRequired, codeDisplay.ValueSetPreferred, v, MapDataCriteria.FieldOids[field][i])
			codeDisplay.setCodesFromPreferred(preferredCodes)
			if codeDisplay.PreferredCode.Code != "" {
				//Put the relevant oid in the 0 index for export
				oldoid := MapDataCriteria.FieldOids[field][0]
				MapDataCriteria.FieldOids[field][0] = oid
				MapDataCriteria.FieldOids[field][i] = oldoid
				break
			}
		}
	default: // In most scenarios, with "entryCode" codeType
		preferredCodes := coded.PreferredCodes(codeDisplay.PreferredCodeSets, codeDisplay.CodeSetRequired, codeDisplay.ValueSetPreferred, v, MapDataCriteria.ValueSetOid)
		codeDisplay.setCodesFromPreferred(preferredCodes)
	}
	return codeDisplay
}

func codeTypeToField(codeType string) string {
	switch codeType {
	case "diagnosis":
		return "DIAGNOSIS"
	case "principalDiagnosis":
		return "PRINCIPAL_DIAGNOSIS"
	}
	return codeType
}

// For R3 Compatibility with a single template. If R3 is phased out in the future, this may be deleted.
func (v ValueSetMap) GenerateCodeDisplayWithLaterality(entry *Entry, coded *Coded, MapDataCriteria Mdc, codeType string, laterality Laterality) CodeDisplay {
	codeDisplay, err := entry.GetCodeDisplay(codeType)
	if err != nil {
		panic(err.Error())
	}
	preferredCodes := coded.PreferredCodes(codeDisplay.PreferredCodeSets, codeDisplay.CodeSetRequired, codeDisplay.ValueSetPreferred, v, MapDataCriteria.ValueSetOid)
	codeDisplay.setCodesFromPreferred(preferredCodes)
	codeDisplay.Laterality = laterality
	codeDisplay.MapDataCriteria = MapDataCriteria
	return codeDisplay
}

func (v ValueSetMap) OidForCode(codedValue CodedConcept, valuesetOids []string) string {
	for _, vsoid := range valuesetOids {
		oidlist := v[vsoid]
		if codeSetContainsCode(oidlist, codedValue) {
			return vsoid
		}
	}
	return ""
}

func (c *CodeDisplay) setCodesFromPreferred(preferredCodes []Concept) {
	if len(preferredCodes) > 0 {
		c.PreferredCode = preferredCodes[0]
		if len(preferredCodes) > 1 {
			c.Translations = preferredCodes[1:]
		}
	}
}

func codeSetContainsCode(sets []CodeSet, codedValue CodedConcept) bool {
	for _, cs := range sets {
		for _, val := range cs.Values {
			if ((val.CodeSystem == codedValue.CodeSystem ||
				val.CodeSystemName == codedValue.CodeSystemName ||
				val.CodeSystemName == codedValue.CodeSystem) ||
				(val.CodeSystem == codeSystemAliases[codedValue.CodeSystem] ||
					val.CodeSystemName == codeSystemAliases[codedValue.CodeSystemName] ||
					val.CodeSystemName == codeSystemAliases[codedValue.CodeSystem])) &&
				val.Code == codedValue.Code {
				return true
			}
		}
	}
	return false
}


text:
<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">

<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="false">

 <!-- Log levels:DEBUG,INFO,WARN,ERROR,FATAL -->
   <appender name="FILE" class="org.jboss.logging.appender.RollingFileAppender">
     <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
     <param name="File" value="${jboss.server.log.dir}/server.log"/>
     <param name="Append" value="true"/>
     <param name="MaxFileSize" value="10000KB"/>
     <param name="MaxBackupIndex" value="5"/>

     <layout class="org.apache.log4j.PatternLayout">
       <param name="ConversionPattern" value="%d %-5p [%c] %m%n"/>
     </layout>
   </appender>

   <!-- ============================== -->
   <!-- Append messages to the console -->
   <!-- ============================== -->

   <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
      <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
      <param name="Target" value="System.out"/>
      <param name="Threshold" value="INFO"/>

      <layout class="org.apache.log4j.PatternLayout">
         <!-- The default pattern: Date Priority [Category] Message\n -->
         <param name="ConversionPattern" value="%d{ABSOLUTE} %-5p [%c{1}] %m%n"/>
      </layout>
   </appender>

   <!-- ============================== -->
   <!-- REVM Appender                  -->
   <!-- ============================== -->

   <appender name="ENGINE_LOG" class="org.jboss.logging.appender.RollingFileAppender">
      <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
      <param name="File" value="${jboss.server.log.dir}/engine.log"/>
      <param name="Append" value="true"/>
      <param name="MaxFileSize" value="10000KB"/>
      <param name="MaxBackupIndex" value="9"/>
      <param name="Threshold" value="DEBUG"/>
      <layout class="org.apache.log4j.PatternLayout">
         <param name="ConversionPattern" value="%d %-5p [%c] (%t) %m%n"/>
      </layout>
   </appender>

<!-- ============================== -->
   <!-- PublicAPI Appender                  -->
   <!-- ============================== -->

   <appender name="PUBLICAPI_LOG" class="org.jboss.logging.appender.RollingFileAppender">
      <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
      <param name="File" value="${jboss.server.log.dir}/soap-api.log"/>
      <param name="Append" value="true"/>
      <param name="MaxFileSize" value="10000KB"/>
      <param name="MaxBackupIndex" value="9"/>
      <param name="Threshold" value="DEBUG"/>
      <layout class="org.apache.log4j.PatternLayout">
         <param name="ConversionPattern" value="%d %-5p [%c] (%t) %m%n"/>
      </layout>
   </appender>

   <!-- ================ -->
   <!-- Limit categories -->
   <!-- ================ -->

   <!-- Limit the org.apache category to INFO as its DEBUG is verbose -->
   <category name="org.apache">
      <priority value="INFO"/>
   </category>

   <!-- Limit the jacorb category to WARN as its INFO is verbose -->
   <category name="jacorb">
      <priority value="WARN"/>
   </category>

   <!-- Set the logging level of the JSF implementation that uses
      | java.util.logging. The jdk logging levels can be controlled
      | through the org.jboss.logging.log4j.JDKLevel class that
      | in addition to the standard log4j levels it adds support for
      | SEVERE, WARNING, CONFIG, FINE, FINER, FINEST
   -->
   <category name="javax.enterprise.resource.webcontainer.jsf">
     <priority value="INFO" class="org.jboss.logging.log4j.JDKLevel"/>
   </category>

   <!-- Limit the org.jgroups category to WARN as its INFO is verbose -->
   <category name="org.jgroups">
      <priority value="WARN"/>
   </category>

   <!-- Limit the org.quartz category to INFO as its DEBUG is verbose -->
   <category name="org.quartz">
      <priority value="INFO"/>
   </category>

   <!-- Limit the com.sun category to INFO as its FINE is verbose -->
   <category name="com.sun">
      <priority value="INFO"/>
   </category>

   <!-- Limit the sun category to INFO as its FINE is verbose -->
   <category name="sun">
      <priority value="INFO"/>
   </category>

   <!-- Limit the javax.xml.bind category to INFO as its FINE is verbose -->
   <category name="javax.xml.bind">
      <priority value="INFO"/>
   </category>

   <!-- Limit JBoss categories
   <category name="org.jboss">
      <priority value="INFO"/>
   </category>
   -->

   <!-- Limit the JSR77 categories -->
   <category name="org.jboss.management">
      <priority value="INFO"/>
   </category>

   <!-- Limit the verbose facelets compiler -->
   <category name="facelets.compiler">
      <priority value="WARN"/>
   </category>

   <!-- Limit the verbose ajax4jsf cache initialization -->
   <category name="org.ajax4jsf.cache">
      <priority value="WARN"/>
   </category>

   <!-- Limit the verbose embedded jopr categories -->
   <category name="org.rhq">
      <priority value="WARN"/>
   </category>

   <!-- Limit the verbose seam categories -->
   <category name="org.jboss.seam">
      <priority value="WARN"/>
   </category>

   <!-- Limit the verbose MC4J EMS (lib used by admin-console) categories -->
   <category name="org.mc4j.ems">
      <priority value="WARN"/>
   </category>

   <!-- Limit the org.apache.cxf categories -->
   <category name="org.apache.cxf">
      <priority value="WARN"/>
   </category>

   <!-- Limit the org.apache.cxf categories -->
   <category name="org.springframework">
      <priority value="WARN"/>
   </category>

   <!-- Show the evolution of the DataSource pool in the logs [inUse/Available/Max]
   <category name="org.jboss.resource.connectionmanager.JBossManagedConnectionPool">
     <priority value="TRACE"/>
   </category>
   -->

   <!-- Category specifically for Security Audit Provider
   <category name="org.jboss.security.audit.providers.LogAuditProvider" additivity="false">
     <priority value="TRACE"/>
     <appender-ref ref="AUDIT"/>
   </category>
   -->

   <!-- Limit the org.jboss.serial (jboss-serialization) to INFO as its DEBUG is verbose -->
   <category name="org.jboss.serial">
      <priority value="INFO"/>
   </category>

   <!-- Decrease the priority threshold for the org.jboss.varia category
   <category name="org.jboss.varia">
     <priority value="DEBUG"/>
   </category>
   -->

   <!-- Enable JBossWS message tracing
   <category name="org.jboss.ws.core.MessageTrace">
     <priority value="TRACE"/>
   </category>
   -->

   <!--
      | An example of enabling the custom TRACE level priority that is used
      | by the JBoss internals to diagnose low level details. This example
      | turns on TRACE level msgs for the org.jboss.ejb.plugins package and its
      | subpackages. This will produce A LOT of logging output.
      |
      | Note: since jboss AS 4.2.x, the trace level is supported natively by
      | log4j, so although the custom org.jboss.logging.XLevel priority will
      | still work, there is no need to use it. The two examples that follow
      | will both enable trace logging.
   <category name="org.jboss.system">
     <priority value="TRACE" class="org.jboss.logging.XLevel"/>
   </category>
   <category name="org.jboss.ejb.plugins">
     <priority value="TRACE"/>
   </category>
   -->

   <!--
       | Logs these events to SNMP:
           - server starts/stops
           - cluster evolution (node death/startup)
           - When an EJB archive is deployed (and associated verified messages)
           - When an EAR archive is deployed

   <category name="org.jboss.system.server.Server">
     <priority value="INFO" />
     <appender-ref ref="TRAP_LOG"/>
   </category>

   <category name="org.jboss.ha.framework.interfaces.HAPartition.lifecycle">
     <priority value="INFO" />
     <appender-ref ref="TRAP_LOG"/>
   </category>

   <category name="org.jboss.deployment.MainDeployer">
     <priority value="ERROR" />
     <appender-ref ref="TRAP_LOG"/>
   </category>

   <category name="org.jboss.ejb.EJBDeployer">
     <priority value="INFO" />
     <appender-ref ref="TRAP_LOG"/>

   </category>

   <category name="org.jboss.deployment.EARDeployer">
     <priority value="INFO" />
     <appender-ref ref="TRAP_LOG"/>
   </category>
   -->

   <!-- Clustering logging -->
   <!-- Uncomment the following to redirect the org.jgroups and
      org.jboss.ha categories to a cluster.log file.

   <appender name="CLUSTER" class="org.jboss.logging.appender.RollingFileAppender">
     <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
     <param name="File" value="${jboss.server.log.dir}/cluster.log"/>
     <param name="Append" value="false"/>
     <param name="MaxFileSize" value="500KB"/>
     <param name="MaxBackupIndex" value="1"/>

     <layout class="org.apache.log4j.PatternLayout">
       <param name="ConversionPattern" value="%d %-5p [%c] %m%n"/>
     </layout>
   </appender>
   <category name="org.jgroups">
     <priority value="DEBUG" />
     <appender-ref ref="CLUSTER"/>
   </category>
   <category name="org.jboss.ha">
     <priority value="DEBUG" />
     <appender-ref ref="CLUSTER"/>
   </category>
   -->

   <!-- ======================= -->
   <!-- REVM categories 	-->
   <!-- ======================= -->

   <!--TOP configuration for all REVM categories -->
   <category name="com.redhat.engine" additivity="false">
	<priority value="INFO"/>
	<appender-ref ref="ENGINE_LOG"/>
   </category>

   <!--Buisness Logic -->
   <category name="com.redhat.engine.bll">
     <priority value="INFO"/>
   </category>

   <!--Vdsbroker -->
   <category name="com.redhat.engine.vdsbroker">
     <priority value="INFO"/>
   </category>

   <!--utils -->
   <category name="com.redhat.engine.utils">
     <priority value="INFO"/>
   </category>

   <!--Search backend -->
   <category name="com.redhat.engine.searchbackend">
     <priority value="INFO"/>
   </category>

   <!--Common -->
   <category name="com.redhat.engine.common">
     <priority value="INFO"/>
   </category>

   <!--Compact -->
   <category name="com.redhat.engine.compact">
     <priority value="INFO"/>
   </category>

   <!--Encrypt utils-->
   <category name="com.redhat.engine.engineencryptutils">
     <priority value="INFO"/>
   </category>

   <!--REST API-->
   <category name="com.redhat.engine.restapi">
     <priority value="INFO"/>
   </category>

   <!--Postgres causes lots of verboe messages in INFO level:
        "Added default SqlReturnResultSet parameter named #result-set-1"-->
   <category name="com.redhat.engine.dal.dbbroker.PostgresDbEngineDialect$PostgresJdbcTemplate">
        <priority value="WARN"/>
   </category>

   <!-- ======================= -->
   <!-- Third party categories 	-->
   <!-- ======================= -->

   <category name="org.apache.xmlrpc" additivity="false">
	<priority value="WARN"/>
	<appender-ref ref="ENGINE_LOG"/>
   </category>

   <category name="org.apache.sshd" additivity="false">
	<priority value="WARN"/>
	<appender-ref ref="ENGINE_LOG"/>
   </category>

   <category name="org.apache.commons.httpclient" additivity="false">
        <priority value="WARN" />
        <appender-ref ref="ENGINE_LOG" />
   </category>

   <category name="org.springframework.ldap" additivity="false">
        <priority value="WARN" />
        <appender-ref ref="ENGINE_LOG" />
   </category>

   <!-- ======================= -->
   <!-- Setup the Root category -->
   <!-- ======================= -->

   <root>
      <!--
         Set the root logger priority via a system property. Note this is parsed by log4j,
         so the full JBoss system property format is not supported; e.g.
         setting a default via ${jboss.server.log.threshold:WARN} will not work.
       -->
      <priority value="${jboss.server.log.threshold}"/>
      <appender-ref ref="CONSOLE"/>
      <appender-ref ref="FILE"/>
   </root>

</log4j:configuration>


text:
<?xml version="1.0" encoding="UTF-8"?>
<application xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://www.m-files.com/schemas/appdef-client-v4.xsd">
	<guid>1B9762B3-C2D5-44b9-905F-D4ABAC5E8AE2</guid>
	<name>Show web page in iframe</name>
	<version>0.2</version>
	<description></description>
	<publisher>M-Files Corporation</publisher>
	<copyright>(c) M-Files Corporation 2021</copyright>
	<!-- This application has been upgraded to support fast-browsing: https://developer.m-files.com/Frameworks/User-Interface-Extensibility-Framework/Fast-Browsing/ -->
	<required-mfiles-version>20.12.0.0</required-mfiles-version>
	<platforms>
		<platform>Desktop</platform>
	</platforms>
	<modules>
		<module environment="shellui" fast-browsing-compatible="true">
			<file>main.js</file>
		</module>
	</modules>
	<dashboards>
		<dashboard id="MyDashboard">
			<content>dashboard.html</content>
			<trusted-content>http://</trusted-content>
			<trusted-content>https://</trusted-content>
		</dashboard>
	</dashboards>
</application>


text:
	stream->writeLine(_indent + "<" + hstr(string) + "/>");
#define OPEN_NODE(string) \
	stream->writeLine(_indent + "<" + hstr(string) + ">"); \
	_indent += "\t";
#define CLOSE_NODE(string) \
	_indent = _indent(0, _indent.size() - 1); \
	stream->writeLine(_indent + "</" + hstr(string) + ">");
#define START_LINE(string) \
	stream->write(_indent + "<" + hstr(string));
#define FINISH_LINE(string) \
	stream->writeLine(hstr(string) + "/>");

namespace liteser
{
	namespace xml
	{
		inline bool __dumpVariableStart(Variable* variable)
		{
			bool result = true;
			if (variable->type->identifier == Type::Identifier::Harray || variable->type->identifier == Type::Identifier::Hmap)
			{
				harray<hstr> types;
				foreach (Type*, it, variable->type->subTypes)
				{
					types += hsprintf("%02X", (*it)->identifier.value);
				}
				if (variable->containerSize > 0)
				{
					OPEN_NODE(hsprintf("Variable name=\"%s\" type=\"%02X\" sub_types=\"%s\"", variable->name.cStr(), variable->type->identifier.value, types.joined(',').cStr()));
				}
				else
				{
					WRITE_NODE(hsprintf("Variable name=\"%s\" type=\"%02X\" sub_types=\"%s\"", variable->name.cStr(), variable->type->identifier.value, types.joined(',').cStr()));
				}
			}
			else if (variable->type->identifier == Type::Identifier::ValueObject)
			{
				OPEN_NODE(hsprintf("Variable name=\"%s\" type=\"%02X\"", variable->name.cStr(), variable->type->identifier.value));
			}
			else if (variable->type->identifier == Type::Identifier::Object)
			{
				if (*variable->value<Serializable*>() != NULL)
				{
					OPEN_NODE(hsprintf("Variable name=\"%s\" type=\"%02X\"", variable->name.cStr(), variable->type->identifier.value));
				}
				else
				{
					WRITE_NODE(hsprintf("Variable name=\"%s\" type=\"%02X\"", variable->name.cStr(), variable->type->identifier.value));
					result = false;
				}
			}
			else
			{
				START_LINE(hsprintf("Variable name=\"%s\" type=\"%02X\" value=\"", variable->name.cStr(), variable->type->identifier.value));
			}
			return result;
		}

		inline void __dumpVariableFinish(Variable* variable)
		{
			if (variable->type->identifier == Type::Identifier::Harray || variable->type->identifier == Type::Identifier::Hmap)
			{
				if (variable->containerSize > 0)
				{
					CLOSE_NODE("Variable");
				}
			}
			else if (variable->type->identifier == Type::Identifier::ValueObject)
			{
				CLOSE_NODE("Variable");
			}
			else if (variable->type->identifier == Type::Identifier::Object)
			{
				if (*variable->value<Serializable*>() != NULL)
				{
					CLOSE_NODE("Variable");
				}
			}
			else
			{
				FINISH_LINE("\"");
			}
		}

		inline void __dumpVariable(Variable* variable)
		{
			if (variable->type->identifier == Type::Identifier::Int8)				stream->write((int)*variable->value<char>());
			else if (variable->type->identifier == Type::Identifier::UInt8)			stream->write(*variable->value<unsigned char>());
			else if (variable->type->identifier == Type::Identifier::Int16)			stream->write(*variable->value<short>());
			else if (variable->type->identifier == Type::Identifier::UInt16)		stream->write(*variable->value<unsigned short>());
			else if (variable->type->identifier == Type::Identifier::Int32)			stream->write(*variable->value<int>());
			else if (variable->type->identifier == Type::Identifier::UInt32)		stream->write(*variable->value<unsigned int>());
			else if (variable->type->identifier == Type::Identifier::Int64)			stream->write(*variable->value<int64_t>());
			else if (variable->type->identifier == Type::Identifier::UInt64)		stream->write(*variable->value<uint64_t>());
			else if (variable->type->identifier == Type::Identifier::Float)			stream->write(hsprintf("%g", *variable->value<float>()));
			else if (variable->type->identifier == Type::Identifier::Double)		stream->write(hsprintf("%g", *variable->value<double>()));
			else if (variable->type->identifier == Type::Identifier::Bool)			stream->write(*variable->value<bool>());
			else if (variable->type->identifier == Type::Identifier::Hstr)			_dump(variable->value<hstr>());
			else if (variable->type->identifier == Type::Identifier::Hversion)		_dump(variable->value<hversion>());
			else if (variable->type->identifier == Type::Identifier::Henum)			_dump(variable->value<henum>());
			else if (variable->type->identifier == Type::Identifier::Grectf)		_dump(variable->value<grectf>());
			else if (variable->type->identifier == Type::Identifier::Gvec2f)		_dump(variable->value<gvec2f>());
			else if (variable->type->identifier == Type::Identifier::Gvec3f)		_dump(variable->value<gvec3f>());
			else if (variable->type->identifier == Type::Identifier::Grecti)		_dump(variable->value<grecti>());
			else if (variable->type->identifier == Type::Identifier::Gvec2i)		_dump(variable->value<gvec2i>());
			else if (variable->type->identifier == Type::Identifier::Gvec3i)		_dump(variable->value<gvec3i>());
			else if (variable->type->identifier == Type::Identifier::Grectd)		_dump(variable->value<grectd>());
			else if (variable->type->identifier == Type::Identifier::Gvec2d)		_dump(variable->value<gvec2d>());
			else if (variable->type->identifier == Type::Identifier::Gvec3d)		_dump(variable->value<gvec3d>());
			else if (variable->type->identifier == Type::Identifier::ValueObject)	_dump(variable->value<Serializable>());
			else if (variable->type->identifier == Type::Identifier::Object)		_dump(variable->value<Serializable*>());
			else if (variable->type->identifier == Type::Identifier::Harray)		__dumpContainer(variable);
			else if (variable->type->identifier == Type::Identifier::Hmap)			__dumpContainer(variable);
		}

		inline void __dumpContainerVariableStart(Variable* variable)
		{
			if (variable->type->identifier == Type::Identifier::Harray || variable->type->identifier == Type::Identifier::Hmap)
			{
				harray<hstr> types;
				foreach (Type*, it, variable->type->subTypes)
				{
					types += hsprintf("%02X", (*it)->identifier.value);
				}
				if (variable->containerSize > 0)
				{
					OPEN_NODE(hsprintf("Container sub_types=\"%s\"", types.joined(',').cStr()));
				}
				else
				{
					WRITE_NODE(hsprintf("Container sub_types=\"%s\"", types.joined(',').cStr()));
				}
			}
			else if (variable->type->identifier != Type::Identifier::ValueObject && variable->type->identifier != Type::Identifier::Object)
			{
				START_LINE("Element value=\"");
			}
		}

		inline void __dumpContainerVariableFinish(Variable* variable)
		{
			if (variable->type->identifier == Type::Identifier::Harray || variable->type->identifier == Type::Identifier::Hmap)
			{
				if (variable->containerSize > 0)
				{
					CLOSE_NODE("Container");
				}
			}
			else if (variable->type->identifier != Type::Identifier::ValueObject && variable->type->identifier != Type::Identifier::Object)
			{
				FINISH_LINE("\"");
			}
		}

		inline void __dumpContainer(Variable* variable)
		{
			if (variable->containerSize > 0)
			{
				foreach (Variable*, it, variable->subVariables)
				{
					__dumpContainerVariableStart(*it);
					__dumpVariable(*it);
					__dumpContainerVariableFinish(*it);
				}
			}
		}

		void _dump(hstr* value)
		{
			stream->write(*value);
		}

		void _dump(hversion* value)
		{
			stream->write(value->toString(4));
		}

		void _dump(henum* value)
		{
			stream->write(value->value);
		}

		void _dump(grectf* value)
		{
			stream->write(hsprintf("%g,%g,%g,%g", value->x, value->y, value->w, value->h));
		}

		void _dump(gvec2f* value)
		{
			stream->write(hsprintf("%g,%g", value->x, value->y));
		}

		void _dump(gvec3f* value)
		{
			stream->write(hsprintf("%g,%g,%g", value->x, value->y, value->z));
		}

		void _dump(grecti* value)
		{
			stream->write(hsprintf("%d,%d,%d,%d", value->x, value->y, value->w, value->h));
		}

		void _dump(gvec2i* value)
		{
			stream->write(hsprintf("%d,%d", value->x, value->y));
		}

		void _dump(gvec3i* value)
		{
			stream->write(hsprintf("%d,%d,%d", value->x, value->y, value->z));
		}

		void _dump(grectd* value)
		{
			stream->write(hsprintf("%g,%g,%g,%g", value->x, value->y, value->w, value->h));
		}

		void _dump(gvec2d* value)
		{
			stream->write(hsprintf("%g,%g", value->x, value->y));
		}

		void _dump(gvec3d* value)
		{
			stream->write(hsprintf("%g,%g,%g", value->x, value->y, value->z));
		}

		void _dump(Serializable* value)
		{
			unsigned int id = 0;
			if (value == NULL)
			{
				WRITE_NODE("Null");
				return;
			}
			if (!_currentHeader.allowMultiReferencing || __tryMapObject(&id, value))
			{
				value->_lsOnSerializing();
				hstr name = value->_lsName();
				harray<Variable*> variables = value->_lsVars();
				int variablesSize = variables.size();
				if (variablesSize > 0)
				{
					if (_currentHeader.allowMultiReferencing)
					{
						OPEN_NODE(hsprintf("Object name=\"%s\" id=\"%d\"", name.cStr(), id));
					}
					else
					{
						OPEN_NODE(hsprintf("Object name=\"%s\"", name.cStr()));
					}
					foreach (Variable*, it, variables)
					{
						if (__dumpVariableStart(*it))
						{
							__dumpVariable(*it);
							__dumpVariableFinish(*it);
						}
						delete (*it);
					}
					CLOSE_NODE("Object");
				}
				else if (_currentHeader.allowMultiReferencing)
				{
					WRITE_NODE(hsprintf("Object name=\"%s\" id=\"%d\"", name.cStr(), id));
				}
				else
				{
					WRITE_NODE(hsprintf("Object name=\"%s\"", name.cStr()));
				}
				value->_lsOnSerialized();
			}
			else
			{
				WRITE_NODE(hsprintf("Object id=\"%d\"", id));
			}
		}

		void _dump(Serializable** value)
		{
			_dump(*value);
		}

		void _dumpHarray(harray<Serializable*>* value)
		{
			foreach (Serializable*, it, *value)
			{
				_dump(*it);
			}
		}

		void _dumpHarray(harray<char>* value)
		{
			foreach (char, it, *value)
			{
				START_LINE("Element value=\"");
				stream->write((int)(*it));
				FINISH_LINE("\"");
			}
		}

#define DEFINE_DUMP_HARRAY(type) \
		void _dumpHarray(harray<type>* value) \
		{ \
			foreach (type, it, *value) \
			{ \
				START_LINE("Element value=\""); \
				stream->write(*it); \
				FINISH_LINE("\""); \
			} \
		}

#define DEFINE_DUMP_HARRAY_C(type) \
		void _dumpHarray(harray<type>* value) \
		{ \
			foreach (type, it, *value) \
			{ \
				START_LINE("Element value=\""); \
				_dump(&(*it)); \
				FINISH_LINE("\""); \
			} \
		}

		DEFINE_DUMP_HARRAY(unsigned char);
		DEFINE_DUMP_HARRAY(short);
		DEFINE_DUMP_HARRAY(unsigned short);
		DEFINE_DUMP_HARRAY(int);
		DEFINE_DUMP_HARRAY(unsigned int);
		DEFINE_DUMP_HARRAY(int64_t);
		DEFINE_DUMP_HARRAY(uint64_t);
		DEFINE_DUMP_HARRAY(float);
		DEFINE_DUMP_HARRAY(double);
		DEFINE_DUMP_HARRAY_C(hstr);
		DEFINE_DUMP_HARRAY_C(hversion);
		DEFINE_DUMP_HARRAY_C(henum);
		DEFINE_DUMP_HARRAY_C(grectf);
		DEFINE_DUMP_HARRAY_C(gvec2f);
		DEFINE_DUMP_HARRAY_C(gvec3f);
		DEFINE_DUMP_HARRAY_C(grecti);
		DEFINE_DUMP_HARRAY_C(gvec2i);
		DEFINE_DUMP_HARRAY_C(gvec3i);
		DEFINE_DUMP_HARRAY_C(grectd);
		DEFINE_DUMP_HARRAY_C(gvec2d);
		DEFINE_DUMP_HARRAY_C(gvec3d);
	}

}


text:
SYNONYM

#### According to
Index Fungorum

#### Published in
null

#### Original name
Calicium sessile Pers.

### Remarks
null