text:
<!DOCTYPE html>

    <meta charset="UTF-8" />
    <meta name="robots" content="index, follow, all" />
    <title>Thelia\Model\AreaQuery | Thelia 2 API</title>

            <link rel="stylesheet" type="text/css" href="../../css/bootstrap.min.css">
        <link rel="stylesheet" type="text/css" href="../../css/bootstrap-theme.min.css">
        <link rel="stylesheet" type="text/css" href="../../css/sami.css">

        <meta name="MobileOptimized" content="width">
        <meta name="HandheldFriendly" content="true">
        <meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=1">

                <form id="search-form" action="../../search.html" method="GET">

            <input name="search"
                   class="typeahead form-control"
                   type="search"
                   placeholder="Search">
        </form>

                <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar-elements">
                    Toggle navigation

                </button>
                Thelia 2 API

Classes

Namespaces

Interfaces

Traits

Index

Search

class

Thelia

Model

AreaQuery

AreaQuery

    class
    AreaQuery        extends AreaQuery

Skeleton subclass for performing query and update operations on the 'area' table.

You should add additional methods to this class to meet the
application requirements.  This class will only be generated as
long as it does not already exist in the output directory.

Methods

                    __construct(
    string $dbName = 'thelia',
    string $modelName = '\\Thelia\\Model\\Area',
    string $modelAlias = null)

Initializes internal state of \Thelia\Model\Base\AreaQuery object.

from
    AreaQuery

                    static
    AreaQuery

                    create(
    string $modelAlias = null,
    Criteria $criteria = null)

Returns a new ChildAreaQuery object.

from
    AreaQuery

    Area|array|mixed

                    findPk(
    mixed $key,
    ConnectionInterface $con = null)

Find object by primary key.

from
    AreaQuery

    ObjectCollection|array|mixed

                    findPks(
    array $keys,
    ConnectionInterface $con = null)

Find objects by primary key

$objs = $c->findPks(array(12, 56, 832), $con);

from
    AreaQuery

    AreaQuery

                    filterByPrimaryKey(
    mixed $key)

Filter the query by primary key

from
    AreaQuery

    AreaQuery

                    filterByPrimaryKeys(
    array $keys)

Filter the query by a list of primary keys

from
    AreaQuery

    AreaQuery

                    filterById(
    mixed $id = null,
    string $comparison = null)

Filter the query on the id column

from
    AreaQuery

    AreaQuery

                    filterByName(
    string $name = null,
    string $comparison = null)

Filter the query on the name column

from
    AreaQuery

    AreaQuery

                    filterByPostage(
    mixed $postage = null,
    string $comparison = null)

Filter the query on the postage column

from
    AreaQuery

    AreaQuery

                    filterByCreatedAt(
    mixed $createdAt = null,
    string $comparison = null)

Filter the query on the created_at column

from
    AreaQuery

    AreaQuery

                    filterByUpdatedAt(
    mixed $updatedAt = null,
    string $comparison = null)

Filter the query on the updated_at column

from
    AreaQuery

    AreaQuery

                    filterByAreaDeliveryModule(
    AreaDeliveryModule|ObjectCollection $areaDeliveryModule,
    string $comparison = null)

Filter the query by a related \Thelia\Model\AreaDeliveryModule object

from
    AreaQuery

    AreaQuery

                    joinAreaDeliveryModule(
    string $relationAlias = null,
    string $joinType = Criteria::INNER_JOIN)

Adds a JOIN clause to the query using the AreaDeliveryModule relation

from
    AreaQuery

    AreaDeliveryModuleQuery

                    useAreaDeliveryModuleQuery(
    string $relationAlias = null,
    string $joinType = Criteria::INNER_JOIN)

Use the AreaDeliveryModule relation AreaDeliveryModule object

from
    AreaQuery

    AreaQuery

                    filterByCountryArea(
    CountryArea|ObjectCollection $countryArea,
    string $comparison = null)

Filter the query by a related \Thelia\Model\CountryArea object

from
    AreaQuery

    AreaQuery

                    joinCountryArea(
    string $relationAlias = null,
    string $joinType = Criteria::INNER_JOIN)

Adds a JOIN clause to the query using the CountryArea relation

from
    AreaQuery

    CountryAreaQuery

                    useCountryAreaQuery(
    string $relationAlias = null,
    string $joinType = Criteria::INNER_JOIN)

Use the CountryArea relation CountryArea object

from
    AreaQuery

    AreaQuery

                    filterByCountry(
    Country $country,
    string $comparison = Criteria::EQUAL)

Filter the query by a related Country object
using the country_area table as cross reference

from
    AreaQuery

    AreaQuery

                    prune(
    Area $area = null)

Exclude object from result

from
    AreaQuery

    int

                    doDeleteAll(
    ConnectionInterface $con = null)

Deletes all rows from the area table.

from
    AreaQuery

    int

                    delete(
    ConnectionInterface $con = null)

Performs a DELETE on the database, given a ChildArea or Criteria object OR a primary key value.

from
    AreaQuery

    AreaQuery

                    recentlyUpdated(
    int $nbDays = 7)

Filter by the latest updated

from
    AreaQuery

    AreaQuery

                    recentlyCreated(
    int $nbDays = 7)

Filter by the latest created

from
    AreaQuery

    AreaQuery

                    lastUpdatedFirst()

Order by update date desc

from
    AreaQuery

    AreaQuery

                    firstUpdatedFirst()

Order by update date asc

from
    AreaQuery

    AreaQuery

                    lastCreatedFirst()

Order by create date desc

from
    AreaQuery

    AreaQuery

                    firstCreatedFirst()

Order by create date asc

from
    AreaQuery

    ChildAreaQuery

                    orderById($order = Criteria::ASC)

Order by the id column

from
    AreaQuery

    ChildAreaQuery

                    orderByName($order = Criteria::ASC)

Order by the name column

from
    AreaQuery

    ChildAreaQuery

                    orderByPostage($order = Criteria::ASC)

Order by the postage column

from
    AreaQuery

    ChildAreaQuery

                    orderByCreatedAt($order = Criteria::ASC)

Order by the created_at column

from
    AreaQuery

    ChildAreaQuery

                    orderByUpdatedAt($order = Criteria::ASC)

Order by the updated_at column

from
    AreaQuery

    ChildAreaQuery

                    groupById()

Group by the id column

from
    AreaQuery

    ChildAreaQuery

                    groupByName()

Group by the name column

from
    AreaQuery

    ChildAreaQuery

                    groupByPostage()

Group by the postage column

from
    AreaQuery

    ChildAreaQuery

                    groupByCreatedAt()

Group by the created_at column

from
    AreaQuery

    ChildAreaQuery

                    groupByUpdatedAt()

Group by the updated_at column

from
    AreaQuery

    ChildAreaQuery

                    leftJoin($relation)

Adds a LEFT JOIN clause to the query

from
    AreaQuery

    ChildAreaQuery

                    rightJoin($relation)

Adds a RIGHT JOIN clause to the query

from
    AreaQuery

    ChildAreaQuery

                    innerJoin($relation)

Adds a INNER JOIN clause to the query

from
    AreaQuery

    ChildAreaQuery

                    leftJoinAreaDeliveryModule($relationAlias = null)

Adds a LEFT JOIN clause to the query using the AreaDeliveryModule relation

from
    AreaQuery

    ChildAreaQuery

                    rightJoinAreaDeliveryModule($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the AreaDeliveryModule relation

from
    AreaQuery

    ChildAreaQuery

                    innerJoinAreaDeliveryModule($relationAlias = null)

Adds a INNER JOIN clause to the query using the AreaDeliveryModule relation

from
    AreaQuery

    ChildAreaQuery

                    leftJoinCountryArea($relationAlias = null)

Adds a LEFT JOIN clause to the query using the CountryArea relation

from
    AreaQuery

    ChildAreaQuery

                    rightJoinCountryArea($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the CountryArea relation

from
    AreaQuery

    ChildAreaQuery

                    innerJoinCountryArea($relationAlias = null)

Adds a INNER JOIN clause to the query using the CountryArea relation

from
    AreaQuery

    ChildArea

                    findOne(
    ConnectionInterface  $con = null)

Return the first ChildArea matching the query

from
    AreaQuery

    ChildArea

                    findOneOrCreate(
    ConnectionInterface  $con = null)

Return the first ChildArea matching the query, or a new ChildArea object populated from the query conditions when no match is found

from
    AreaQuery

    ChildArea

                    findOneById(
    int  $id)

Return the first ChildArea filtered by the id column

from
    AreaQuery

    ChildArea

                    findOneByName(
    string  $name)

Return the first ChildArea filtered by the name column

from
    AreaQuery

    ChildArea

                    findOneByPostage(
    double  $postage)

Return the first ChildArea filtered by the postage column

from
    AreaQuery

    ChildArea

                    findOneByCreatedAt(
    string  $created_at)

Return the first ChildArea filtered by the created_at column

from
    AreaQuery

    ChildArea

                    findOneByUpdatedAt(
    string  $updated_at)

Return the first ChildArea filtered by the updated_at column

from
    AreaQuery

    array

                    findById(
    int  $id)

Return ChildArea objects filtered by the id column

from
    AreaQuery

    array

                    findByName(
    string  $name)

Return ChildArea objects filtered by the name column

from
    AreaQuery

    array

                    findByPostage(
    double  $postage)

Return ChildArea objects filtered by the postage column

from
    AreaQuery

    array

                    findByCreatedAt(
    string  $created_at)

Return ChildArea objects filtered by the created_at column

from
    AreaQuery

    array

                    findByUpdatedAt(
    string  $updated_at)

Return ChildArea objects filtered by the updated_at column

from
    AreaQuery

Details

in
    AreaQuery at line 74

    __construct(
    string $dbName = 'thelia',
    string $modelName = '\\Thelia\\Model\\Area',
    string $modelAlias = null)

Initializes internal state of \Thelia\Model\Base\AreaQuery object.

Parameters

    string
                $dbName
                The database name

    string
                $modelName
                The phpName of a model, e.g. 'Book'

    string
                $modelAlias
                The alias for the model in this query, e.g. 'b'

in
    AreaQuery at line 87

                static
    AreaQuery
    create(
    string $modelAlias = null,
    Criteria $criteria = null)

Returns a new ChildAreaQuery object.

Parameters

    string
                $modelAlias
                The alias of a model in the query

    Criteria
                $criteria
                Optional Criteria to build the query from

Return Value

    AreaQuery

in
    AreaQuery at line 117

    Area|array|mixed
    findPk(
    mixed $key,
    ConnectionInterface $con = null)

Find object by primary key.

Propel uses the instance pool to skip the database if the object exists.
Go fast if the query is untouched.

$obj  = $c->findPk(12, $con);

Parameters

    mixed
                $key
                Primary key to use for the query

    ConnectionInterface
                $con
                an optional connection object

Return Value

    Area|array|mixed
            the result, formatted by the current formatter

in
    AreaQuery at line 199

    ObjectCollection|array|mixed
    findPks(
    array $keys,
    ConnectionInterface $con = null)

Find objects by primary key

$objs = $c->findPks(array(12, 56, 832), $con);

Parameters

    array
                $keys
                Primary keys to use for the query

    ConnectionInterface
                $con
                an optional connection object

Return Value

    ObjectCollection|array|mixed
            the list of results, formatted by the current formatter

in
    AreaQuery at line 220

    AreaQuery
    filterByPrimaryKey(
    mixed $key)

Filter the query by primary key

Parameters

    mixed
                $key
                Primary key to use for the query

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 233

    AreaQuery
    filterByPrimaryKeys(
    array $keys)

Filter the query by a list of primary keys

Parameters

    array
                $keys
                The list of primary key to use for the query

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 257

    AreaQuery
    filterById(
    mixed $id = null,
    string $comparison = null)

Filter the query on the id column

Example usage:

$query->filterById(1234); // WHERE id = 1234
$query->filterById(array(12, 34)); // WHERE id IN (12, 34)
$query->filterById(array('min' => 12)); // WHERE id > 12

Parameters

    mixed
                $id
                The value to use as filter.
             Use scalar values for equality.
             Use array values for in_array() equivalent.
             Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.

    string
                $comparison
                Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 295

    AreaQuery
    filterByName(
    string $name = null,
    string $comparison = null)

Filter the query on the name column

Example usage:

$query->filterByName('fooValue');   // WHERE name = 'fooValue'
$query->filterByName('%fooValue%'); // WHERE name LIKE '%fooValue%'

Parameters

    string
                $name
                The value to use as filter.
             Accepts wildcards (* and % trigger a LIKE)

    string
                $comparison
                Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 327

    AreaQuery
    filterByPostage(
    mixed $postage = null,
    string $comparison = null)

Filter the query on the postage column

Example usage:

$query->filterByPostage(1234); // WHERE postage = 1234
$query->filterByPostage(array(12, 34)); // WHERE postage IN (12, 34)
$query->filterByPostage(array('min' => 12)); // WHERE postage > 12

Parameters

    mixed
                $postage
                The value to use as filter.
             Use scalar values for equality.
             Use array values for in_array() equivalent.
             Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.

    string
                $comparison
                Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 370

    AreaQuery
    filterByCreatedAt(
    mixed $createdAt = null,
    string $comparison = null)

Filter the query on the created_at column

Example usage:

$query->filterByCreatedAt('2011-03-14'); // WHERE createdat = '2011-03-14'
$query->filterByCreatedAt('now'); // WHERE createdat = '2011-03-14'
$query->filterByCreatedAt(array('max' => 'yesterday')); // WHERE created_at > '2011-03-13'

Parameters

    mixed
                $createdAt
                The value to use as filter.
             Values can be integers (unix timestamps), DateTime objects, or strings.
             Empty strings are treated as NULL.
             Use scalar values for equality.
             Use array values for in_array() equivalent.
             Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.

    string
                $comparison
                Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 413

    AreaQuery
    filterByUpdatedAt(
    mixed $updatedAt = null,
    string $comparison = null)

Filter the query on the updated_at column

Example usage:

$query->filterByUpdatedAt('2011-03-14'); // WHERE updatedat = '2011-03-14'
$query->filterByUpdatedAt('now'); // WHERE updatedat = '2011-03-14'
$query->filterByUpdatedAt(array('max' => 'yesterday')); // WHERE updated_at > '2011-03-13'

Parameters

    mixed
                $updatedAt
                The value to use as filter.
             Values can be integers (unix timestamps), DateTime objects, or strings.
             Empty strings are treated as NULL.
             Use scalar values for equality.
             Use array values for in_array() equivalent.
             Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.

    string
                $comparison
                Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 444

    AreaQuery
    filterByAreaDeliveryModule(
    AreaDeliveryModule|ObjectCollection $areaDeliveryModule,
    string $comparison = null)

Filter the query by a related \Thelia\Model\AreaDeliveryModule object

Parameters

    AreaDeliveryModule|ObjectCollection
                $areaDeliveryModule
                the related object to use as filter

    string
                $comparison
                Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 467

    AreaQuery
    joinAreaDeliveryModule(
    string $relationAlias = null,
    string $joinType = Criteria::INNER_JOIN)

Adds a JOIN clause to the query using the AreaDeliveryModule relation

Parameters

    string
                $relationAlias
                optional alias for the relation

    string
                $joinType
                Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 502

    AreaDeliveryModuleQuery
    useAreaDeliveryModuleQuery(
    string $relationAlias = null,
    string $joinType = Criteria::INNER_JOIN)

Use the AreaDeliveryModule relation AreaDeliveryModule object

Parameters

    string
                $relationAlias
                optional alias for the relation,
                                  to be used as main alias in the secondary query

    string
                $joinType
                Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

    AreaDeliveryModuleQuery
            A secondary query class using the current class as primary query

See also

                useQuery()

in
    AreaQuery at line 517

    AreaQuery
    filterByCountryArea(
    CountryArea|ObjectCollection $countryArea,
    string $comparison = null)

Filter the query by a related \Thelia\Model\CountryArea object

Parameters

    CountryArea|ObjectCollection
                $countryArea
                the related object to use as filter

    string
                $comparison
                Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 540

    AreaQuery
    joinCountryArea(
    string $relationAlias = null,
    string $joinType = Criteria::INNER_JOIN)

Adds a JOIN clause to the query using the CountryArea relation

Parameters

    string
                $relationAlias
                optional alias for the relation

    string
                $joinType
                Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 575

    CountryAreaQuery
    useCountryAreaQuery(
    string $relationAlias = null,
    string $joinType = Criteria::INNER_JOIN)

Use the CountryArea relation CountryArea object

Parameters

    string
                $relationAlias
                optional alias for the relation,
                                  to be used as main alias in the secondary query

    string
                $joinType
                Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

    CountryAreaQuery
            A secondary query class using the current class as primary query

See also

                useQuery()

in
    AreaQuery at line 591

    AreaQuery
    filterByCountry(
    Country $country,
    string $comparison = Criteria::EQUAL)

Filter the query by a related Country object
using the country_area table as cross reference

Parameters

    Country
                $country
                the related object to use as filter

    string
                $comparison
                Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 606

    AreaQuery
    prune(
    Area $area = null)

Exclude object from result

Parameters

    Area
                $area
                Object to remove from the list of results

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 621

    int
    doDeleteAll(
    ConnectionInterface $con = null)

Deletes all rows from the area table.

Parameters

    ConnectionInterface
                $con
                the connection to use

Return Value

    int
            The number of affected rows (if supported by underlying database driver).

in
    AreaQuery at line 658

    int
    delete(
    ConnectionInterface $con = null)

Performs a DELETE on the database, given a ChildArea or Criteria object OR a primary key value.

Parameters

    ConnectionInterface
                $con

Return Value

    int
            The number of affected rows (if supported by underlying database driver).  This includes CASCADE-related rows
               if supported by native driver or if emulated using Propel.

Exceptions

                PropelException
                Any exceptions caught during processing will be
        rethrown wrapped into a PropelException.

in
    AreaQuery at line 699

    AreaQuery
    recentlyUpdated(
    int $nbDays = 7)

Filter by the latest updated

Parameters

    int
                $nbDays
                Maximum age of the latest update in days

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 711

    AreaQuery
    recentlyCreated(
    int $nbDays = 7)

Filter by the latest created

Parameters

    int
                $nbDays
                Maximum age of in days

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 721

    AreaQuery
    lastUpdatedFirst()

Order by update date desc

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 731

    AreaQuery
    firstUpdatedFirst()

Order by update date asc

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 741

    AreaQuery
    lastCreatedFirst()

Order by create date desc

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 751

    AreaQuery
    firstCreatedFirst()

Order by create date asc

Return Value

    AreaQuery
            The current query, for fluid interface

in
    AreaQuery at line 64

    ChildAreaQuery
    orderById($order = Criteria::ASC)

Order by the id column

Parameters

                $order

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    orderByName($order = Criteria::ASC)

Order by the name column

Parameters

                $order

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    orderByPostage($order = Criteria::ASC)

Order by the postage column

Parameters

                $order

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    orderByCreatedAt($order = Criteria::ASC)

Order by the created_at column

Parameters

                $order

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    orderByUpdatedAt($order = Criteria::ASC)

Order by the updated_at column

Parameters

                $order

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    groupById()

Group by the id column

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    groupByName()

Group by the name column

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    groupByPostage()

Group by the postage column

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    groupByCreatedAt()

Group by the created_at column

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    groupByUpdatedAt()

Group by the updated_at column

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    leftJoin($relation)

Adds a LEFT JOIN clause to the query

Parameters

                $relation

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    rightJoin($relation)

Adds a RIGHT JOIN clause to the query

Parameters

                $relation

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    innerJoin($relation)

Adds a INNER JOIN clause to the query

Parameters

                $relation

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    leftJoinAreaDeliveryModule($relationAlias = null)

Adds a LEFT JOIN clause to the query using the AreaDeliveryModule relation

Parameters

                $relationAlias

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    rightJoinAreaDeliveryModule($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the AreaDeliveryModule relation

Parameters

                $relationAlias

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    innerJoinAreaDeliveryModule($relationAlias = null)

Adds a INNER JOIN clause to the query using the AreaDeliveryModule relation

Parameters

                $relationAlias

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    leftJoinCountryArea($relationAlias = null)

Adds a LEFT JOIN clause to the query using the CountryArea relation

Parameters

                $relationAlias

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    rightJoinCountryArea($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the CountryArea relation

Parameters

                $relationAlias

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildAreaQuery
    innerJoinCountryArea($relationAlias = null)

Adds a INNER JOIN clause to the query using the CountryArea relation

Parameters

                $relationAlias

Return Value

    ChildAreaQuery

in
    AreaQuery at line 64

    ChildArea
    findOne(
    ConnectionInterface  $con = null)

Return the first ChildArea matching the query

Parameters

    ConnectionInterface
                $con

Return Value

    ChildArea

in
    AreaQuery at line 64

    ChildArea
    findOneOrCreate(
    ConnectionInterface  $con = null)

Return the first ChildArea matching the query, or a new ChildArea object populated from the query conditions when no match is found

Parameters

    ConnectionInterface
                $con

Return Value

    ChildArea

in
    AreaQuery at line 64

    ChildArea
    findOneById(
    int  $id)

Return the first ChildArea filtered by the id column

Parameters

    int
                $id

Return Value

    ChildArea

in
    AreaQuery at line 64

    ChildArea
    findOneByName(
    string  $name)

Return the first ChildArea filtered by the name column

Parameters

    string
                $name

Return Value

    ChildArea

in
    AreaQuery at line 64

    ChildArea
    findOneByPostage(
    double  $postage)

Return the first ChildArea filtered by the postage column

Parameters

    double
                $postage

Return Value

    ChildArea

in
    AreaQuery at line 64

    ChildArea
    findOneByCreatedAt(
    string  $created_at)

Return the first ChildArea filtered by the created_at column

Parameters

    string
                $created_at

Return Value

    ChildArea

in
    AreaQuery at line 64

    ChildArea
    findOneByUpdatedAt(
    string  $updated_at)

Return the first ChildArea filtered by the updated_at column

Parameters

    string
                $updated_at

Return Value

    ChildArea

in
    AreaQuery at line 64

    array
    findById(
    int  $id)

Return ChildArea objects filtered by the id column

Parameters

    int
                $id

Return Value

    array

in
    AreaQuery at line 64

    array
    findByName(
    string  $name)

Return ChildArea objects filtered by the name column

Parameters

    string
                $name

Return Value

    array

in
    AreaQuery at line 64

    array
    findByPostage(
    double  $postage)

Return ChildArea objects filtered by the postage column

Parameters

    double
                $postage

Return Value

    array

in
    AreaQuery at line 64

    array
    findByCreatedAt(
    string  $created_at)

Return ChildArea objects filtered by the created_at column

Parameters

    string
                $created_at

Return Value

    array

in
    AreaQuery at line 64

    array
    findByUpdatedAt(
    string  $updated_at)

Return ChildArea objects filtered by the updated_at column

Parameters

    string
                $updated_at

Return Value

    array

        Generated by Sami, the API Documentation Generator.


text:
package org.onosproject.pcepio.types;

import org.jboss.netty.buffer.ChannelBuffer;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import com.google.common.base.MoreObjects;

/**
 * Provides PcepRsvpObjectHeader.
 */
public class PcepRsvpSpecObjHeader {

    /*
    0             1              2             3
    +-------------+-------------+-------------+-------------+
    |       Length (bytes)      |  Class-Num  |   C-Type    |
    +-------------+-------------+-------------+-------------+
    |                                                       |
    //                  (Object contents)                   //
    |                                                       |
    +-------------+-------------+-------------+-------------+

              ERROR_SPEC object Header
     */

    protected static final Logger log = LoggerFactory.getLogger(PcepRsvpSpecObjHeader.class);

    private short objLen;
    private byte objClassNum;
    private byte objClassType;

    /**
     * Constructor to initialize length, class num and type.
     *
     * @param objLen object length
     * @param objClassNum pcep rsvp error spec object class num
     * @param objClassType pcep rsvp error spec object class type
     */
    public PcepRsvpSpecObjHeader(short objLen, byte objClassNum, byte objClassType) {
        this.objLen = objLen;
        this.objClassNum = objClassNum;
        this.objClassType = objClassType;
    }

    /**
     * Sets the Class num.
     *
     * @param value pcep rsvp error spec object class num
     */
    public void setObjClassNum(byte value) {
        this.objClassNum = value;
    }

    /**
     * Sets the Class type.
     *
     * @param value pcep rsvp error spec object class type
     */
    public void setObjClassType(byte value) {
        this.objClassType = value;
    }

    /**
     * Sets the Class Length.
     *
     * @param value pcep rsvp error spec object length
     */
    public void setObjLen(short value) {
        this.objLen = value;
    }

    /**
     * Returns Object Length.
     *
     * @return objLen pcep rsvp error spec object length
     */
    public short getObjLen() {
        return this.objLen;
    }

    /**
     * Returns Object num.
     *
     * @return objClassNum pcep rsvp error spec object class num
     */
    public byte getObjClassNum() {
        return this.objClassNum;
    }

    /**
     * Returns Object type.
     *
     * @return objClassType pcep rsvp error spec object class type
     */
    public byte getObjClassType() {
        return this.objClassType;
    }

    /**
     * Writes the byte stream of PcepRsvpObjectHeader to channel buffer.
     *
     * @param bb of type channel buffer
     * @return object length index
     */
    public int write(ChannelBuffer bb) {
        int objLenIndex = bb.writerIndex();
        bb.writeShort(objLen);
        bb.writeByte(objClassNum);
        bb.writeByte(objClassType);
        return bb.writerIndex() - objLenIndex;
    }

    /**
     * Reads the PcepRsvpObjectHeader.
     *
     * @param bb of type channel buffer
     * @return PcepRsvpObjectHeader
     */
    public static PcepRsvpSpecObjHeader read(ChannelBuffer bb) {
        byte objClassNum;
        byte objClassType;
        short objLen;
        objLen = bb.readShort();
        objClassNum = bb.readByte();
        objClassType = bb.readByte();

        return new PcepRsvpSpecObjHeader(objLen, objClassNum, objClassType);
    }

    @Override
    public String toString() {
        return MoreObjects.toStringHelper(getClass())
                .add("ObjectClassNum: " , objClassNum)
                .add("ObjectCType: " , objClassType)
                .add("ObjectLength: " , objLen)
                .toString();
    }
}

redpajama_set_name: RedPajamaGithub


text:
<?xml version="1.0" encoding="UTF-8"?>
<mappings xmlns="http://dozer.sourceforge.net"
          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
          xsi:schemaLocation="http://dozer.sourceforge.net
          http://dozer.sourceforge.net/schema/beanmapping.xsd">

    <mapping map-null="false">
        <class-a>com.comsysto.shop.service.order.model.OrderInfo</class-a>
        <class-b>com.comsysto.shop.repository.order.model.Order</class-b>
        <field>
            orderId
            orderId
        </field>
        <field type="one-way">
            user.id
            userId
        </field>
        <field relationship-type="cumulative">
            orderItems
            orderItems
            com.comsysto.shop.service.order.model.OrderItemInfo
            com.comsysto.shop.repository.order.model.OrderItem
        </field>
        <field>
            deliveryAddress
            deliveryAddress
        </field>
        <field>
            sessionId
            sessionId
        </field>
        <field>
            orderDate
            orderDate
        </field>
        <field>
            deliveryAddress
            deliveryAddress
            com.comsysto.shop.service.order.model.DeliveryAddressInfo
            com.comsysto.shop.repository.order.model.DeliveryAddress
        </field>
    </mapping>

    <mapping>
        <class-a>com.comsysto.shop.service.order.model.DeliveryAddressInfo</class-a>
        <class-b>com.comsysto.shop.repository.order.model.DeliveryAddress</class-b>
        <field>
            firstname
            firstname
        </field>
        <field>
            lastname
            lastname
        </field>
        <field>
            street
            street
        </field>
        <field>
            city
            city
        </field>
        <field>
            zip
            zip
        </field>
        <field>
            county
            county
        </field>
        <field>
            houseNumber
            houseNumber
        </field>
        <field>
            state
            state
        </field>
        <field>
            countryCode
            countryCode
        </field>
        <field>
            country
            country
        </field>
        <field>
            longitude
            longitude
        </field>
        <field>
            latitude
            latitude
        </field>
    </mapping>

    <mapping>
        <class-a>com.comsysto.shop.service.order.model.OrderItemInfo</class-a>
        <class-b>com.comsysto.shop.repository.order.model.OrderItem</class-b>
        <field>
            product
            product
            com.comsysto.shop.service.product.model.ProductInfo
            com.comsysto.shop.repository.product.model.Product
        </field>
        <field>
            uuid
            uuid
        </field>
    </mapping>

</mappings>


text:
@interface ShopViewController : UIViewController

@end


text:
<?xml version="1.0"?>
<!DOCTYPE OpenGLAPI SYSTEM "gl_API.dtd">

<!-- Note: no GLX protocol info yet. -->

<OpenGLAPI>

<category name="GL_ARB_robustness" number="105">

    <enum name="GUILTY_CONTEXT_RESET_ARB"                 value="0x8253"/>
    <enum name="INNOCENT_CONTEXT_RESET_ARB"               value="0x8254"/>
    <enum name="UNKNOWN_CONTEXT_RESET_ARB"                value="0x8255"/>

    <enum name="RESET_NOTIFICATION_STRATEGY_ARB" count="1" value="0x8256">
        <size name="Get" mode="get"/>
    </enum>
    <enum name="LOSE_CONTEXT_ON_RESET_ARB"                value="0x8252"/>
    <enum name="NO_RESET_NOTIFICATION_ARB"                value="0x8261"/>

    <enum name="CONTEXT_FLAG_ROBUST_ACCESS_BIT_ARB"       value="0x00000004"/>

    <function name="GetGraphicsResetStatusARB" offset="assign">
        <return type="GLenum"/>
    </function>

<!-- OpenGL 1.0 sized buffer queries -->
    <function name="GetnMapdvARB" offset="assign" deprecated="3.1">
        <param name="target" type="GLenum"/>
        <param name="query" type="GLenum"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="v" type="GLdouble *" output="true"/>
    </function>

    <function name="GetnMapfvARB" offset="assign" deprecated="3.1">
        <param name="target" type="GLenum"/>
        <param name="query" type="GLenum"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="v" type="GLfloat *" output="true"/>
    </function>

    <function name="GetnMapivARB" offset="assign" deprecated="3.1">
        <param name="target" type="GLenum"/>
        <param name="query" type="GLenum"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="v" type="GLint *" output="true"/>
    </function>

    <function name="GetnPixelMapfvARB" offset="assign" deprecated="3.1">
        <param name="map" type="GLenum"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="values" type="GLfloat *" output="true"/>
    </function>

    <function name="GetnPixelMapuivARB" offset="assign" deprecated="3.1">
        <param name="map" type="GLenum"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="values" type="GLuint *" output="true"/>
    </function>

    <function name="GetnPixelMapusvARB" offset="assign" deprecated="3.1">
        <param name="map" type="GLenum"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="values" type="GLushort *" output="true"/>
    </function>

    <function name="GetnPolygonStippleARB" offset="assign">
        <param name="bufSize" type="GLsizei"/>
        <param name="pattern" type="GLubyte *" output="true"/>
    </function>

    <function name="GetnTexImageARB" offset="assign">
        <param name="target" type="GLenum"/>
        <param name="level" type="GLint"/>
        <param name="format" type="GLenum"/>
        <param name="type" type="GLenum"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="img" type="GLvoid *" output="true"/>
    </function>

    <function name="ReadnPixelsARB" offset="assign">
        <param name="x" type="GLint"/>
        <param name="y" type="GLint"/>
        <param name="width" type="GLsizei"/>
        <param name="height" type="GLsizei"/>
        <param name="format" type="GLenum"/>
        <param name="type" type="GLenum"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="data" type="GLvoid *" output="true"/>
    </function>

<!-- ARB_imaging sized buffer queries -->
    <function name="GetnColorTableARB" offset="assign" deprecated="3.1">
        <param name="target" type="GLenum"/>
        <param name="format" type="GLenum"/>
        <param name="type" type="GLenum"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="table" type="GLvoid *" output="true"/>
    </function>

    <function name="GetnConvolutionFilterARB" offset="assign" deprecated="3.1">
        <param name="target" type="GLenum"/>
        <param name="format" type="GLenum"/>
        <param name="type" type="GLenum"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="image" type="GLvoid *" output="true"/>
    </function>

    <function name="GetnSeparableFilterARB" offset="assign" deprecated="3.1">
        <param name="target" type="GLenum"/>
        <param name="format" type="GLenum"/>
        <param name="type" type="GLenum"/>
        <param name="rowBufSize" type="GLsizei"/>
        <param name="row" type="GLvoid *" output="true"/>
        <param name="columnBufSize" type="GLsizei"/>
        <param name="column" type="GLvoid *" output="true"/>
        <param name="span" type="GLvoid *" output="true"/>
    </function>

    <function name="GetnHistogramARB" offset="assign" deprecated="3.1">
        <param name="target" type="GLenum"/>
        <param name="reset" type="GLboolean"/>
        <param name="format" type="GLenum"/>
        <param name="type" type="GLenum"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="values" type="GLvoid *" output="true"/>
    </function>

    <function name="GetnMinmaxARB" offset="assign" deprecated="3.1">
        <param name="target" type="GLenum"/>
        <param name="reset" type="GLboolean"/>
        <param name="format" type="GLenum"/>
        <param name="type" type="GLenum"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="values" type="GLvoid *" output="true"/>
    </function>

<!-- OpenGL 1.3 sized buffer queries -->
    <function name="GetnCompressedTexImageARB" offset="assign">
        <param name="target" type="GLenum"/>
        <param name="lod" type="GLint"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="img" type="GLvoid *" output="true"/>
    </function>

<!-- OpenGL 2.0 sized buffer queries -->
    <function name="GetnUniformfvARB" offset="assign">
        <param name="program" type="GLhandleARB"/>
        <param name="location" type="GLint"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="params" type="GLfloat *" output="true"/>
    </function>

    <function name="GetnUniformivARB" offset="assign">
        <param name="program" type="GLhandleARB"/>
        <param name="location" type="GLint"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="params" type="GLint *" output="true"/>
    </function>

    <function name="GetnUniformuivARB" offset="assign">
        <param name="program" type="GLhandleARB"/>
        <param name="location" type="GLint"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="params" type="GLuint *" output="true"/>
    </function>

    <function name="GetnUniformdvARB" offset="assign">
        <param name="program" type="GLhandleARB"/>
        <param name="location" type="GLint"/>
        <param name="bufSize" type="GLsizei"/>
        <param name="params" type="GLdouble *" output="true"/>
    </function>

</category>

</OpenGLAPI>


text:
<!DOCTYPE html>

  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  <title>비디오들 | React</title>
  <meta name="viewport" content="width=device-width">
  <meta property="og:title" content="비디오들 | React">
  <meta property="og:type" content="website">
  <meta property="og:url" content="https://facebook.github.io/react/docs/videos-ko-KR.html">
  <meta property="og:image" content="https://facebook.github.io/react/img/logo_og.png">
  <meta property="og:description" content="A JavaScript library for building user interfaces">
  <meta property="fb:app_id" content="623268441017527">

  <link rel="shortcut icon" href="/react/favicon.ico">
  <link rel="alternate" type="application/rss+xml" title="React" href="https://facebook.github.io/react/feed.xml">

  <link rel="stylesheet" href="https://cdn.jsdelivr.net/docsearch.js/1/docsearch.min.css" />
  <link rel="stylesheet" href="/react/css/syntax.css">
  <link rel="stylesheet" href="/react/css/codemirror.css">
  <link rel="stylesheet" href="/react/css/react.css">

          React

Docs

Support

Download

Blog

            <input id="algolia-doc-search" type="text" placeholder="Search docs..." />

GitHub

React Native

Quick Start

            Getting Started

            Tutorial

            Thinking in React

Community Resources

            Conferences

            Videos

            Complementary Tools

            Examples

Guides

            Why React?

            Displaying Data

                    JSX in Depth

                    JSX Spread Attributes

                    JSX Gotchas

            Interactivity and Dynamic UIs

            Multiple Components

            Reusable Components

            Transferring Props

            Forms

            Working With the Browser

                    Refs to Components

            Tooling Integration

                    Language Tooling

                    Package Management

                    Server-side Environments

            Add-Ons

                    Animation

                    Two-Way Binding Helpers

                    Test Utilities

                    Cloning Elements

                    Keyed Fragments

                    Immutability Helpers

                    PureRenderMixin

                    Performance Tools

                    Shallow Compare

            Advanced Performance

            Context

Reference

            Top-Level API

            Component API

            Component Specs and Lifecycle

            Supported Tags and Attributes

            Event System

            DOM Differences

            Special Non-DOM Attributes

            Reconciliation

            Web Components

            React (Virtual) DOM Terminology

Tips

            Introduction

            Inline Styles

            If-Else in JSX

            Self-Closing Tag

            Maximum Number of JSX Root Nodes

            Shorthand for Specifying Pixel Values in style props

            Type of the Children props

            Value of null for Controlled Input

            componentWillReceiveProps Not Triggered After Mounting

            Props in getInitialState Is an Anti-Pattern

            DOM Event Listeners in a Component

            Load Initial Data via AJAX

            False in JSX

            Communicate Between Components

            Expose Component Functions

            this.props.children undefined

            Use React with Other Libraries

            Dangerously Set innerHTML

Contributing

            Design Principles

    Edit on GitHub

      비디오들

Rethinking best practices - JSConf.eu #

"페이스북과 인스타그램에서, 우리는 React 를 이용해 웹에서 벌어질 수 있는 한계를 뛰어넘으려 노력하고 있습니다. 저는 프레임워크에 대한 짤막한 소개로 시작해서, 논쟁이 벌어질 수 있는 다음의 세가지 주제로 넘어갈겁니다. 템플릿의 개념을 버리고 JavaScript 를 이용해 View 를 구축하기, 자료가 변할때 전체 어플리케이션을 다시 그리기("re-rendering"), 그리고 DOM과 events의 경량화된 구현 입니다." -- Pete Hunt

Thinking in react - tagtree.tv #

tagtree.tv의 비디오는 간단한 어플리케이션을 구성하면서 Thinking in React의 원리들을 전달합니다.

Secrets of the Virtual DOM - MtnWest JS #

"이번에는 왜 우리가 virtual DOM을 만들었는지, 이것이 다른 시스템들과는 어떻게 다른지, 그리고 브라우져 기술들의 미래와 어떻게 관련이 있는지에 대해서 이야기 해 볼 겁니다." -- Pete Hunt

Going big with React #

"이 발표에서, 이 모든 JS 프레임워크가 다음을 약속하는것처럼 보입니다: 깨끗한 구현들, 빠른 코드 디자인, 완전한 수행. 그런데 당신이 JavaScript 스트레스 테스트를 할때, 어떤 일이 발생합니까? 혹은 6MB의 코드를 던지면 무슨일이 발생합니까? 이번에는 높은 스트레스 환경에서 React가 어떻게 작동하는지, 그리고 이것이 우리 팀이 방대한 크기의 코드를 안전하게 구성하는데 어떻게 도움이 되어줄지를 조사해 볼겁니다."

CodeWinds #

CodeWinds Episode 4 에서 Pete Hunt와 Jeff Barczewski가 React에 대해서 이야기 합니다.

[![](/react/img/docs/codewinds-004.png)](http://codewinds.com/4)

02:08 - What is React and why use it?

03:08 - The symbiotic relationship of ClojureScript and React

04:54 - The history of React and why it was created

09:43 - Updating web page with React without using data binding

13:11 - Using the virtual DOM to change the browser DOM

13:57 - Programming with React, render targets HTML, canvas, other

16:45 - Working with designers. Contrasted with Ember and AngularJS

21:45 - JSX Compiler bridging HTML and React javascript

23:50 - Autobuilding JSX and in browser tools for React

24:50 - Tips and tricks to working with React, getting started

27:17 - Rendering HTML on the server with Node.js. Rendering backends

29:20 - React evolved through survival of the fittest at Facebook

30:15 - Ideas for having state on server and client, using web sockets.

32:05 - React-multiuser - distributed shared mutable state using Firebase

33:03 - Better debugging with React using the state transitions, replaying events

34:08 - Differences from Web Components

34:25 - Notable companies using React

35:16 - Could a React backend plugin be created to target PDF?

36:30 - Future of React, what's next?

39:38 - Contributing and getting help

방송 자료 읽어보기

JavaScript Jabber #

JavaScript Jabber 73에서 Pete Hunt와 Jordan Walke가 React에 대해서 이야기했습니다.

[![](/react/img/docs/javascript-jabber.png)](http://javascriptjabber.com/073-jsj-react-with-pete-hunt-and-jordan-walke/#content)

01:34 – Pete Hunt Introduction

02:45 – Jordan Walke Introduction

04:15 – React

06:38 – 60 Frames Per Second

09:34 – Data Binding

12:31 – Performance

17:39 – Diffing Algorithm

19:36 – DOM Manipulation

23:06 – Supporting node.js

24:03 – rendr

26:02 – JSX

30:31 – requestAnimationFrame

34:15 – React and Applications

38:12 – React Users Khan Academy

39:53 – Making it work

전체 기록 읽어보기

Introduction to React.js - Facebook Seattle #

By Tom Occhino, Jordan Walke

Backbone + React + Middleman Screencast #

Backbone은 React로 REST API를 제공하기 위한 아주 좋은 방법입니다. 이 화면중개는 Backbone-React-Component을 이용해서 어떻게 이 두가지를 연동하는지 보여줍니다. Middleman은 이 예제에서 사용되는 프레임워크이지만, 쉽게 다른 프레임워크로 대체하실 수 있습니다. 지원되는 템플릿은 이곳에서 찾으실 수 있습니다. -- 열린 마음의 혁명들

Developing User Interfaces With React - Super VanJS #

By Steven Luscher

Introduction to React - LAWebSpeed meetup #

by Stoyan Stefanov

React, or how to make life simpler - FrontEnd Dev Conf '14 #

러시아어 by Alexander Solovyov

"Functional DOM programming" - Meteor DevShop 11 #

"Rethinking Web App Development at Facebook" - Facebook F8 Conference 2014 #

React and Flux: Building Applications with a Unidirectional Data Flow - Forward JS 2014 #

Facebook 개발자 Bill Fisher와 Jing Chen가 Flux 와 React 에 대해서 이야기합니다. 그리고 어떻게 단일 방향의 자료흐름을 사용하는 어플리케이션 구조가 방대한 코드를 정리하는지에 대해서 이야기합니다."

Server-Side Rendering of Isomorphic Apps at SoundCloud #

Server-side rendering을 위해 SoundCloud가 React 와 Flux를 사용하는지 by Andres Suarez
발표 자료와 예제 코드

Introducing React Native (+Playlist) - React.js Conf 2015 #

2015년에 Tom Occhino님이 React의 과거와 현재를 리뷰하고 나아갈 방향을 제시했습니다.

        ← Prev

        Next →

        A Facebook & Instagram collaboration.

        Acknowledgements

        © 2013–2016 Facebook Inc.

        Documentation licensed under CC BY 4.0.


text:
namespace Net
{
	Node::Node(const Address& address, const std::string& name)
	{
		m_address = address;
		m_name = name;
	}

	void Node::AddSendPacket(const std::shared_ptr<NetPacket> & data)
	{
		std::lock_guard<std::mutex> lock(m_lock);
		m_sending.push(data);
	}

	void Node::AddRecievedPacket(const std::shared_ptr<NetPacket> & data)
	{
		std::lock_guard<std::mutex> lock(m_lock);
		m_recieved.push(data);
	}

	bool Node::GetNextSendingPacket(std::shared_ptr<NetPacket>& data)
	{
		std::lock_guard<std::mutex> lock(m_lock);
		if (!m_sending.empty())
		{
			data = m_sending.front();
			m_sending.pop();
			return true;
		}

		return false;
	}

	const std::string & Node::GetName() const
	{
		return m_name;
	}

	const Address & Node::GetAddress() const
	{
		return m_address;
	}

	bool Node::GetNextPacket(ByteBuffer& data)
	{
		std::lock_guard<std::mutex> lock(m_lock);
		if (!m_recieved.empty())
		{
			auto packet = m_recieved.front();
			m_recieved.pop();
			if(packet)
			{
				data = packet->data();
			}
			return !data.empty();
		}

		return false;
	}

	bool Node::SetNextPacket(const ByteBuffer & data)
	{
		if (!data.empty())
		{
			auto packet = std::make_shared<NetPacket>(m_address, m_LocalCSP, m_RemoteCSP);
			packet->AddData(data);
			std::lock_guard<std::mutex> lock(m_lock);
			m_sending.push(packet);
			return true;
		}

		return false;
	}
}


text:
namespace IECore
{

/// A base class for warp operations on ImagePrimitive objects.
/// This Op modifies an image by remapping pixels values to other locations.
/// The display window does not change in this process, but the data window may change.
/// The mapping is determined by the derived classes. The base class is responsible for resizing the
/// data window and applying filter on the colors based on the floating point positions returned by warp method.
/// \ingroup imageProcessingGroup
class IECORE_API WarpOp : public ImagePrimitiveOp
{
	public:

		enum FilterType { None = 0, Bilinear = 1 };
		enum BoundMode { Clamp = 0, SetToBlack = 1 };

		WarpOp( const std::string &description );
		virtual ~WarpOp();

		IntParameter * filterParameter();
		const IntParameter * filterParameter() const;

		IE_CORE_DECLARERUNTIMETYPED( WarpOp, ImagePrimitiveOp );

	protected :

		/// Implemented to call begin(), warpedDataWindow(), warp() and end(). Derived classes should implement those functions rather than
		/// this function.
		virtual void modifyTypedPrimitive( ImagePrimitive * image, const CompoundObject * operands );

		/// Called once per operation before anything else. This is an opportunity to perform any preprocessing
		/// necessary before warpedDataWindow() and many calls to warp() are made.
		virtual void begin( const CompoundObject * operands );
		/// Defines the resulting dataWindow.
		/// This function is called after begin() method. The input Box2i corresponds to the input image data window.
		/// The default implementation returns the same data window as the original image.
		virtual Imath::Box2i warpedDataWindow( const Imath::Box2i &dataWindow ) const;
		/// Called once per element (pixel for ImagePrimitives).
		/// Must be implemented by subclasses to determine where the color will come from.
		/// The returned coordinate is on pixel space of the input image and the given V2f coordinates are on the
		/// output image pixel space.
		virtual Imath::V2f warp( const Imath::V2f &p ) const = 0;
		/// Called once per operation, after all calls to transform() have been made. This is
		/// an opportunity to perform any cleanup necessary.
		virtual void end();

	private :

		IntParameterPtr m_filterParameter;
		IntParameterPtr m_boundModeParameter;
		struct Warp;
		friend struct Warp;
};

IE_CORE_DECLAREPTR( WarpOp );

} // namespace IECore

#endif // IECORE_WARPOP_H


text:
<?php
defined('BASEPATH') OR exit('No direct script access allowed');

class InicioAdministrador extends CI_Controller {
    public function __construct() {
        parent::__construct();
        $sessionActual = $this->session->userdata('logged_in');
        if(!$sessionActual) {
            redirect(base_url().'Welcome/errorLogueo');
        } elseif (!($sessionActual['tipo'] == 3)) {
            redirect(base_url().'Welcome/errorPermiso');
        }
    }
    public function index() {
        $this->load->model('Administrador_model');
        $data = array();
        $data['administrador'] = $this->Administrador_model->obtenerAdministrador($this->session->userdata('logged_in')['id']);
        $this->load->view('layout/default/header.php');
        $this->load->view('layout/default/menuAdministrador.php');
        $this->load->view('welcome_message', $data);
        $this->load->view('layout/default/footer.php');
    }
    function logout() {
        $this->session->unset_userdata('logged_in');
        session_destroy();
        redirect('Welcome', 'refresh');
    }
}


text:
<?php

namespace RemoteServerBundle;

use Symfony\Component\HttpKernel\Bundle\Bundle;

/**
 * Class RemoteServerBundle
 * @package RemoteServerBundle
 */
Class RemoteServerBundle extends Bundle
{

}


text:
define( [
	"../core"
], function( jQuery ) {

jQuery.readyException = function( error ) {
	window.setTimeout( function() {
		throw error;
	} );
};

} );


text:
#ifndef SMGR_H
#define SMGR_H

#include "access/xlog.h"
#include "fmgr.h"
#include "storage/block.h"
#include "storage/relfilenode.h"
#include "storage/dbdirnode.h"
#include "access/persistentendxactrec.h"
#include "access/filerepdefs.h"

/*
 * smgr.c maintains a table of SMgrRelation objects, which are essentially
 * cached file handles.  An SMgrRelation is created (if not already present)
 * by smgropen(), and destroyed by smgrclose().  Note that neither of these
 * operations imply I/O, they just create or destroy a hashtable entry.
 * (But smgrclose() may release associated resources, such as OS-level file
 * descriptors.)
 *
 * An SMgrRelation may have an "owner", which is just a pointer to it from
 * somewhere else; smgr.c will clear this pointer if the SMgrRelation is
 * closed.	We use this to avoid dangling pointers from relcache to smgr
 * without having to make the smgr explicitly aware of relcache.  There
 * can't be more than one "owner" pointer per SMgrRelation, but that's
 * all we need.
 */
typedef struct SMgrRelationData
{
	/* rnode is the hashtable lookup key, so it must be first! */
	RelFileNode smgr_rnode;		/* relation physical identifier */

	/* pointer to owning pointer, or NULL if none */
	struct SMgrRelationData **smgr_owner;

	/* additional public fields may someday exist here */

	/*
	 * Fields below here are intended to be private to smgr.c and its
	 * submodules.	Do not touch them from elsewhere.
	 */
	int			smgr_which;		/* storage manager selector */

	struct _MdMirVec *md_mirvec;		/* for md.c; NULL if not open */
} SMgrRelationData;

typedef SMgrRelationData *SMgrRelation;

/*
 * Whether the object is being dropped in the original transaction, crash recovery, or
 * as part of (re)create / (re)drop during resynchronize.
 */
typedef enum StorageManagerMirrorMode
{
	StorageManagerMirrorMode_None = 0,
	StorageManagerMirrorMode_PrimaryOnly = 1,
	StorageManagerMirrorMode_Both = 2,
	StorageManagerMirrorMode_MirrorOnly = 3,
	MaxStorageManagerMirrorMode /* must always be last */
} StorageManagerMirrorMode;

inline static bool StorageManagerMirrorMode_DoPrimaryWork(
	StorageManagerMirrorMode		mirrorMode)
{
	return (mirrorMode == StorageManagerMirrorMode_Both|| mirrorMode == StorageManagerMirrorMode_PrimaryOnly);
}

inline static bool StorageManagerMirrorMode_SendToMirror(
	StorageManagerMirrorMode		mirrorMode)
{
	return (mirrorMode == StorageManagerMirrorMode_Both|| mirrorMode == StorageManagerMirrorMode_MirrorOnly);
}

extern char *StorageManagerMirrorMode_Name(
	StorageManagerMirrorMode		mirrorMode);

extern void smgrinit(void);
extern SMgrRelation smgropen(RelFileNode rnode);
extern void smgrsetowner(SMgrRelation *owner, SMgrRelation reln);
extern void smgrclose(SMgrRelation reln);
extern void smgrcloseall(void);
extern void smgrclosenode(RelFileNode rnode);
extern void smgrcreatefilespacedirpending(
	Oid 							filespaceOid,

	int16							primaryDbId,

	char							*primaryFilespaceLocation,

	int16							mirrorDbId,

	char							*mirrorFilespaceLocation,

	MirroredObjectExistenceState 	mirrorExistenceState,

	ItemPointer 					persistentTid,

	int64							*persistentSerialNum,

	bool							flushToXLog);
extern void smgrcreatefilespacedir(
	Oid 						filespaceOid,

	char						*primaryFilespaceLocation,
								/*
								 * The primary filespace directory path.  NOT Blank padded.
								 * Just a NULL terminated string.
								 */

	char						*mirrorFilespaceLocation,

	StorageManagerMirrorMode	mirrorMode,

	bool						ignoreAlreadyExists,

	int 						*primaryError,

	bool						*mirrorDataLossOccurred);
extern void smgrcreatetablespacedirpending(
	TablespaceDirNode				*tablespaceDirNode,

	MirroredObjectExistenceState	mirrorExistenceState,

	ItemPointer 					persistentTid,

	int64							*persistentSerialNum,

	bool							flushToXLog);
extern void smgrcreatetablespacedir(
	Oid 						tablespaceOid,

	StorageManagerMirrorMode	mirrorMode,

	bool						ignoreAlreadyExists,

	int 						*primaryError,

	bool						*mirrorDataLossOccurred);
extern void smgrcreatedbdirjustintime(
	DbDirNode					*justInTimeDbDirNode,

	MirroredObjectExistenceState 	mirrorExistenceState,

	StorageManagerMirrorMode	mirrorMode,

	ItemPointer 				persistentTid,

	int64						*persistentSerialNum,

	int 						*primaryError,

	bool						*mirrorDataLossOccurred);
extern void smgrcreatedbdirpending(
	DbDirNode						*dbDirNode,

	MirroredObjectExistenceState	mirrorExistenceState,

	ItemPointer 					persistentTid,

	int64							*persistentSerialNum,

	bool							flushToXLog);
extern void smgrcreatedbdir(

	DbDirNode					*dbDirNode,

	StorageManagerMirrorMode	mirrorMode,

	bool						ignoreAlreadyExists,

	int 						*primaryError,

	bool						*mirrorDataLossOccurred);
extern void smgrcreatepending(
	RelFileNode 					*relFileNode,

	int32							segmentFileNum,

	PersistentFileSysRelStorageMgr relStorageMgr,

	PersistentFileSysRelBufpoolKind relBufpoolKind,

	MirroredObjectExistenceState 	mirrorExistenceState,

	MirroredRelDataSynchronizationState relDataSynchronizationState,

	char							*relationName,

	ItemPointer 					persistentTid,

	int64							*persistentSerialNum,

	bool							isLocalBuf,

	bool							bufferPoolBulkLoad,

	bool							flushToXLog);
extern void smgrcreate(
	SMgrRelation 				reln,

	bool						isLocalBuf,

	char						*relationName,
					/* For tracing only.  Can be NULL in some execution paths. */

	MirrorDataLossTrackingState mirrorDataLossTrackingState,

	int64						mirrorDataLossTrackingSessionNum,

	bool						ignoreAlreadyExists,

	bool						*mirrorDataLossOccurred);
extern void smgrrecreate(
	RelFileNode 				*relFileNode,

	bool						isLocalBuf,

	char						*relationName,
					/* For tracing only.  Can be NULL in some execution paths. */

	MirrorDataLossTrackingState mirrorDataLossTrackingState,

	int64						mirrorDataLossTrackingSessionNum,

	int 						*primaryError,

	bool						*mirrorDataLossOccurred);
extern void smgrscheduleunlink(
	RelFileNode 	*relFileNode,

	int32			segmentFileNum,

	PersistentFileSysRelStorageMgr relStorageMgr,

	bool			isLocalBuf,

	char			*relationName,

	ItemPointer 	persistentTid,

	int64			persistentSerialNum);
extern void smgrdounlink(
	RelFileNode 				*relFileNode,

	bool 						isLocalBuf,

	char						*relationName,
					/* For tracing only.  Can be NULL in some execution paths. */

	bool  						primaryOnly,

	bool						isRedo,

	bool 						ignoreNonExistence,

	bool						*mirrorDataLossOccurred);
extern void smgrschedulermfilespacedir(
	Oid 				filespaceOid,

	ItemPointer 		persistentTid,

	int64				persistentSerialNum);
extern void smgrschedulermtablespacedir(
	Oid 				tablespaceOid,

	ItemPointer 		persistentTid,

	int64				persistentSerialNum);
extern void smgrschedulermdbdir(
	DbDirNode			*dbDirNode,

	ItemPointer		 	persistentTid,

	int64				persistentSerialNum);
extern void smgrdormfilespacedir(
	Oid 						filespaceOid,

	char						*primaryFilespaceLocation,
								/*
								 * The primary filespace directory path.  NOT Blank padded.
								 * Just a NULL terminated string.
								 */

	char						*mirrorFilespaceLocation,

	bool  						primaryOnly,

	bool						mirrorOnly,

	bool 						ignoreNonExistence,

	bool						*mirrorDataLossOccurred);
extern void smgrdormtablespacedir(
	Oid 						tablespaceOid,

	bool  						primaryOnly,

	bool						mirrorOnly,

	bool 						ignoreNonExistence,

	bool						*mirrorDataLossOccurred);
extern void smgrdormdbdir(
	DbDirNode 					*dropDbDirNode,

	bool  						primaryOnly,

	bool						mirrorOnly,

	bool 						ignoreNonExistence,

	bool						*mirrorDataLossOccurred);
extern void smgrextend(SMgrRelation reln, BlockNumber blocknum, char *buffer,
		   bool isTemp);
extern void smgrread(SMgrRelation reln, BlockNumber blocknum, char *buffer);
extern void smgrwrite(SMgrRelation reln, BlockNumber blocknum, char *buffer,
		  bool isTemp);
extern BlockNumber smgrnblocks(SMgrRelation reln);
extern void smgrtruncate(SMgrRelation reln, BlockNumber nblocks,
			 bool isTemp, bool isLocalBuf, ItemPointer persistentTid, int64 persistentSerialNum);
extern bool smgrgetpersistentinfo(
	XLogRecord		*record,

	RelFileNode	*relFileNode,

	ItemPointer	persistentTid,

	int64		*persistentSerialNum);
extern void smgrimmedsync(SMgrRelation reln);
extern void smgrappendonlymirrorresynceofs(
	RelFileNode						*relFileNode,

	int32							segmentFileNum,

	char							*relationName,

	ItemPointer						persistentTid,

	int64							persistentSerialNum,

	bool							mirrorCatchupRequired,

	MirrorDataLossTrackingState 	mirrorDataLossTrackingState,

	int64							mirrorDataLossTrackingSessionNum,

	int64							mirrorNewEof);
extern bool smgrgetappendonlyinfo(
	RelFileNode 					*relFileNode,

	int32							segmentFileNum,

	char							*relationName,

	bool							*mirrorCatchupRequired,

	MirrorDataLossTrackingState 	*mirrorDataLossTrackingState,

	int64							*mirrorDataLossTrackingSessionNum);
extern int	smgrGetPendingFileSysWork(
	EndXactRecKind						endXactRecKind,

	PersistentEndXactFileSysActionInfo	**ptr);
extern int	smgrGetAppendOnlyMirrorResyncEofs(
	EndXactRecKind									endXactRecKind,

	PersistentEndXactAppendOnlyMirrorResyncEofs 	**ptr);
extern bool	smgrIsPendingFileSysWork(
	EndXactRecKind						endXactRecKind);
extern bool smgrIsAppendOnlyMirrorResyncEofs(
	EndXactRecKind						endXactRecKind);
extern void AtSubCommit_smgr(void);
extern void AtSubAbort_smgr(void);
extern void AtEOXact_smgr(bool forCommit);
extern void PostPrepare_smgr(void);
extern void smgrcommit(void);
extern void smgrabort(void);
extern void smgrsync(void);

extern void smgr_redo(XLogRecPtr beginLoc, XLogRecPtr lsn, XLogRecord *record);
extern void smgr_desc(StringInfo buf, XLogRecPtr beginLoc, XLogRecord *record);

/* internals: move me elsewhere -- ay 7/94 */

/* in md.c */
extern void mdinit(void);
extern void mdclose(SMgrRelation reln);
extern void mdcreatefilespacedir(
	Oid 						filespaceOid,

	char						*primaryFilespaceLocation,
								/*
								 * The primary filespace directory path.  NOT Blank padded.
								 * Just a NULL terminated string.
								 */

	char						*mirrorFilespaceLocation,

	StorageManagerMirrorMode	mirrorMode,

	bool						ignoreAlreadyExists,

	int 						*primaryError,

	bool						*mirrorDataLossOccurred);
extern void mdcreatetablespacedir(
	Oid 						tablespaceOid,

	StorageManagerMirrorMode	mirrorMode,

	bool						ignoreAlreadyExists,

	int 						*primaryError,

	bool						*mirrorDataLossOccurred);
extern void mdcreatedbdir(
	DbDirNode					*dbDirNode,

	StorageManagerMirrorMode	mirrorMode,

	bool						ignoreAlreadyExists,

	int 						*primaryError,

	bool						*mirrorDataLossOccurred);
extern void mdcreate(
	SMgrRelation 				reln,

	bool 						isLocalBuf,

	char						*relationName,
					/* For tracing only.  Can be NULL in some execution paths. */

	MirrorDataLossTrackingState mirrorDataLossTrackingState,

	int64						mirrorDataLossTrackingSessionNum,

	bool						ignoreAlreadyExists,

	bool						*mirrorDataLossOccurred);
extern void mdunlink(
	RelFileNode 				rnode,

	char						*relationName,
					/* For tracing only.  Can be NULL in some execution paths. */

	bool  						primaryOnly,

	bool						isRedo,

	bool 						ignoreNonExistence,

	bool						*mirrorDataLossOccurred);
extern bool mdrmfilespacedir(
	Oid 						filespaceOid,

	char						*primaryFilespaceLocation,
								/*
								 * The primary filespace directory path.  NOT Blank padded.
								 * Just a NULL terminated string.
								 */

	char						*mirrorFilespaceLocation,

	bool						primaryOnly,

	bool						mirrorOnly,

	bool 						ignoreNonExistence,

	bool						*mirrorDataLossOccurred);
extern bool mdrmtablespacedir(
	Oid 						tablespaceOid,

	bool						primaryOnly,

	bool						mirrorOnly,

	bool 						ignoreNonExistence,

	bool						*mirrorDataLossOccurred);
extern bool mdrmdbdir(
	DbDirNode					*dbDirNode,

	bool						primaryOnly,

	bool						mirrorOnly,

	bool 						ignoreNonExistence,

	bool						*mirrorDataLossOccurred);
extern void mdextend(SMgrRelation reln, BlockNumber blocknum, char *buffer,
		 bool isTemp);
extern void mdread(SMgrRelation reln, BlockNumber blocknum, char *buffer);
extern void mdwrite(SMgrRelation reln, BlockNumber blocknum, char *buffer,
		bool isTemp);
extern BlockNumber mdnblocks(SMgrRelation reln);
extern void mdtruncate(SMgrRelation reln, BlockNumber nblocks,
		   bool isTemp, bool allowedNotFound);
extern void mdimmedsync(SMgrRelation reln);
extern void mdsync(void);

/*
 * MPP-18228 - to make addition to pending delete list atomic with adding
 * a 'Create Pending' entry in persistent tables.
 * Wrapper around the static PendingDelete_AddCreatePendingEntry() for relations
 */
extern void PendingDelete_AddCreatePendingRelationEntry(
		PersistentFileSysObjName *fsObjName,

		ItemPointer 			persistentTid,

		int64					*persistentSerialNum,

		PersistentFileSysRelStorageMgr relStorageMgr,

		char				*relationName,

		bool				isLocalBuf,

		bool				bufferPoolBulkLoad);

/*
 * MPP-18228 - Wrapper around PendingDelete_AddCreatePendingEntry() for
 * database, tablespace and filespace
 */
extern void PendingDelete_AddCreatePendingEntryWrapper(
	PersistentFileSysObjName *fsObjName,

	ItemPointer 			persistentTid,

	int64					persistentSerialNum);

extern void RememberFsyncRequest(RelFileNode rnode, BlockNumber segno);
extern void ForgetRelationFsyncRequests(RelFileNode rnode);
extern void ForgetDatabaseFsyncRequests(Oid tblspc, Oid dbid);

/* smgrtype.c */
extern Datum smgrout(PG_FUNCTION_ARGS);
extern Datum smgrin(PG_FUNCTION_ARGS);
extern Datum smgreq(PG_FUNCTION_ARGS);
extern Datum smgrne(PG_FUNCTION_ARGS);

#endif   /* SMGR_H */


text:
auto rainbow::get_small_buffer(size_t size) -> void*
{
    constexpr size_t kSmallBufferSize = 8192;

    if (size > kSmallBufferSize)
        return nullptr;

    thread_local std::array<uint8_t, kSmallBufferSize> buffer;
    return buffer.data();
}


text:
Si ets membre de Telecogresca, pots iniciar sessió a través de la intranet.

<?php $this->widget('bootstrap.widgets.TbButton', array(
    'label'=> Yii::t('engrescat', "Inicia sessió amb la Intranet"),
	'type'=>'primary',
	'size'=>'large',
	'url' => 'http://omega.telecogresca.com/intranet/user/engrescat'
)); ?>


text:
""" Collect all python test in worktree """
from __future__ import absolute_import
from __future__ import unicode_literals
from __future__ import print_function

import qibuild.parsers
import qipy.parsers
from qisys import ui
from qitest.collector import PythonTestCollector

def configure_parser(parser):
    """ Configure Parser """
    qibuild.parsers.cmake_build_parser(parser)

def do(args):
    """ Main Entry Point """
    python_worktree = qipy.parsers.get_python_worktree(args)
    ui.info(ui.green, "python projects in:", ui.blue, python_worktree.root)
    collector = PythonTestCollector(python_worktree)
    collector.collect()


text:
Simple Web Server in GO for Galera Cluster HealthCheck

### Prerequisite

You need to have:

* Go 1.8
* Go Environment properly set
* Galera Cluster

### Compilation

```sh
git clone https://github.com/jsenon/GalAirCheck.git
go build -o galaircheck
```

### Galera Node File Configuration

Edit and rename config-node.json.example to config-node.json
Replace value by your own

```sh
"Host": "MyNode",
"Port": "MyPort",
"User": "MyUser",
"Password": "MyPassword"
```

### Access

Access through favorite web browser on http://YOURIP:YOURPORT ie http://127.0.0.1:9030

### API

Auto Health Check API status available at /healthy/am-i-up

### ToDo

- [ ] API
- [x] Web part to view details
- [ ] API Doc
- [ ] Build Docker App
- [x] Add API monitoring
- [x] Add Cluster ID
- [x] Add Cluster Size
- [ ] Thread connected SHOW FULL PROCESSLIST; show status like 'Threads_connected';
- [ ] Queries show status like 'Quer%';


text:
/*
 * Copyright (c) 2014, FHNW (Simon Schubiger)
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 *  Redistributions of source code must retain the above copyright notice,
 *   this list of conditions and the following disclaimer.
 *  Redistributions in binary form must reproduce the above copyright notice,
 *   this list of conditions and the following disclaimer in the documentation
 *   and/or other materials provided with the distribution.
 *  Neither the name of FHNW nor the names of its contributors may be
 *   used to endorse or promote products derived from this software without
 *   specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER BE LIABLE FOR ANY
 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 */
package ch.fhnw.ether.formats;

import java.net.URL;
import java.util.EnumSet;
import java.util.List;

import ch.fhnw.ether.scene.mesh.IMesh;
import ch.fhnw.ether.scene.mesh.material.IMaterial;

public abstract class AbstractModelReader implements IModelReader {
	private final ModelObject object;
	private final EnumSet<Options> options;

	public AbstractModelReader(URL resource, EnumSet<Options> options) {
		this.object = new ModelObject(resource);
		this.options = options;
	}

	@Override
	public final ModelObject getObject() {
		return object;
	}

	@Override
	public final List<IMesh> getMeshes() {
		return object.getMeshes();
	}

	@Override
	public final List<IMesh> getMeshes(IMaterial material) {
		return object.getMeshes(material);
	}

	protected EnumSet<Options> getOptions() {
		return options;
	}
}


text:
package org.slc.sli.client;

import com.google.gson.JsonObject;
import com.google.gson.JsonParser;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import org.springframework.http.HttpEntity;
import org.springframework.http.HttpHeaders;
import org.springframework.http.HttpMethod;
import org.springframework.stereotype.Component;
import org.springframework.web.client.HttpClientErrorException;
import org.springframework.web.client.RestTemplate;

import org.slc.sli.util.Constants;
import org.slc.sli.util.URLBuilder;

/**
 * REST client to make requests to API
 *
 */
@Component("RESTClient")
public class RESTClient {

	private String securityUrl;

	private static Logger logger = LoggerFactory.getLogger(RESTClient.class);

	/**
	 * Call the session/check API
	 *
	 * @param token
	 *            the sessionId or null
	 * @return JsonOject as described by API documentation
	 * @throws NoSessionException
	 */
	public JsonObject sessionCheck(String token) {
		logger.info("Session check URL = " + Constants.SESSION_CHECK_PREFIX);
		String jsonText = makeJsonRequestWHeaders(
				Constants.SESSION_CHECK_PREFIX, token, true);
		logger.info("jsonText = " + jsonText);
		JsonParser parser = new JsonParser();
		return parser.parse(jsonText).getAsJsonObject();
	}

	/**
	 * Make a request to a REST service and convert the result to JSON
	 *
	 * @param path
	 *            the unique portion of the requested REST service URL
	 * @param token
	 *            not used yet
	 * @return a {@link JsonElement} if the request is successful and returns
	 *         valid JSON, otherwise null.
	 * @throws NoSessionException
	 */
	public String makeJsonRequest(String path, String token) {
		RestTemplate template = new RestTemplate();
		URLBuilder url = new URLBuilder(getSecurityUrl());
		url.addPath(path);
		HttpEntity entity = null;
		if (token != null) {
			HttpHeaders headers = new HttpHeaders();
			headers.add("Authorization", "Bearer " + token);
			entity = new HttpEntity(headers);
		}
		logger.info("Accessing API at: " + url.toString());

		HttpEntity<String> response = template.exchange(url.toString(),
				HttpMethod.GET, entity, String.class);
		logger.info("JSON response for roles: " + response.getBody());
		return response.getBody();

	}

	public String makeJsonRequestWHeaders(String path, String token,
			boolean fullEntities) {
		RestTemplate template = new RestTemplate();

		if (token != null) {
			URLBuilder url = null;
			if (!path.startsWith("http")) {
				url = new URLBuilder(getSecurityUrl());
				url.addPath(path);
			} else {
				url = new URLBuilder(path);
			}
			if (fullEntities)
				url.addQueryParam("full-entities", "true");

			HttpHeaders headers = new HttpHeaders();
			headers.add("Authorization", "Bearer " + token);
			HttpEntity entity = new HttpEntity(headers);
			logger.debug("Accessing API at: " + url);
			HttpEntity<String> response = null;
			try {
				response = template.exchange(url.toString(), HttpMethod.GET,
						entity, String.class);
			} catch (HttpClientErrorException e) {
				logger.debug("Catch HttpClientException: "
						+ e.getStatusCode().toString());
			}
			if (response == null) {
				return null;
			}
			return response.getBody();
		}
		logger.debug("Token is null in call to RESTClient for path" + path);

		return null;
	}

	public String getSecurityUrl() {
		return securityUrl;
	}

	public void setSecurityUrl(String securityUrl) {
		this.securityUrl = securityUrl;
	}
}


text:
/**
Potentiometer.h
Larry LeBron

A simple library for a potentiometer connected between 5V, ground and an an analog input
*/

#include "Arduino.h"

#ifndef POTENTIOMETER_H
#define POTENTIOMETER_H

const int MAX_POT_VALUE = 1023;

// only considered a value change if the jump is at least of this delta
// prevents noise from random fluctuation
const int MIN_CHANGE_DELTA = 11;

class Potentiometer {
public:
	Potentiometer(uint8_t potPin);

	//update the pot, must be called every loop for best accuracy
	void update();

	//returns true if the pot changed this update
	bool valChangedThisUpdate();

	// returns the percent of the pot, from 0 to 1 (0, MAX_POT_VALUE)
	float getPercentVal();

private:
	uint8_t potPin; //the pot pin
	int lastAcknowledgedReading; // the last pot reading acknowledged as actual input
	bool changedThisUpdate = false; // did the pot change this update?
};

#endif


text:
# 1. Create a [Azure Storage Account](https://azure.microsoft.com/en-us/documentation/articles/storage-introduction/)

An Azure storage account gives you access to the Azure Blob, Queue, Table, and File services in Azure Storage.
Your storage account provides the unique namespace for your Azure Storage data objects.
By default, the data in your account is available only to you, the account owner.

Sign in into [Azure Portal](https://portal.azure.com/).

To create Storage Account, select **New**, **Data + Storage**, and **Storage account**.

![create new storage account](./images/01-storageaccount-01.png)

Set a unique name for your storage. For [Deployment model](https://azure.microsoft.com/en-us/documentation/articles/resource-manager-deployment-model/), [Performance](https://azure.microsoft.com/en-us/documentation/articles/storage-introduction/#introducing-the-azure-storage-services)
and [Replication](https://azure.microsoft.com/en-us/documentation/articles/storage-redundancy/) take the default values as shown in the screenshot.

Be sure you have selected your [Resource Group](https://azure.microsoft.com/en-us/documentation/articles/resource-group-overview/#resource-groups) and the Location is set to **West Europe**.
Finally, click 'Create' to create your new storage account.

![create new storage account](./images/01-storageaccount-02.png)

As soon the Storage Account is created, you should be able to configure it through **Resource groups** -> **Your Resource group** -> **Click in the summary panel**

![edit storage account](./images/01-storageaccount-03.png)

The access keys are available through the Key-Icon and click on **...**
We need the connectionstring later in the demo.

![storage account connectionstrings](./images/01-storageaccount-04.png)

# 2. Integrate Storage Account

To store images sent by the application, we need to configure the Storage Account.
Take the copied connection string from above and insert into Web.config in the **Trivadis.AzureBootcamp.WebApi** Project.

```xml
  <appSettings>
    <add key="AzureStorageAccount" value="<YOUR CONNECTION STRING>" />
  </appSettings>
```

Add the code to upload an image file into blob storage to the class
**Trivadis.AzureBootcamp.CrossCutting.CloudStorage.AzureStorageAccount**

Use this snippet as a reference:

```csharp
public async Task<CloudStorageFileUploadResult> UploadAsync(CloudStorageFileUpload file)
{
    if (file == null)
        throw new ArgumentNullException(nameof(file));

    CloudBlockBlob cloudblob = CreateCloudBlockBlob(file);
    string uri = CreateSharedAccessBlobPolicy(cloudblob);

    await cloudblob.UploadFromFileAsync(file.FilePath);

    CloudStorageFileUploadResult result = new CloudStorageFileUploadResult();
    result.Uri = uri;
    result.ContentType = file.ContentType;
    result.Filename = file.RealFileName;

    return result;
}
```

Restart the application by pressing F5 and login into chat

![storage account](./images/02-integration-01.png)

Select an image, write a message and press send

![storage account](./images/02-integration-02.png)

After the message is sent and the image appears in the chat application, open your storage account with a tool of your choice,
for instance the [Microsoft Azure Storage Explorer](http://storageexplorer.com/) or the
[Visual Studio Cloud Explorer](https://visualstudiogallery.msdn.microsoft.com/84e83a7c-9606-4f9f-83dd-0f6182f13add/)
(see below), and browse the blob container (chatimages).

![storage account](./images/02-integration-03.png)

![storage account](./images/02-integration-04.png)

Note : All images (blobs) are stored using a [Shared Access Signature](https://azure.microsoft.com/en-us/documentation/articles/storage-dotnet-shared-access-signature-part-1/). The SAS ist created in the **CreateSharedAccessBlobPolicy**-Method in the **Trivadis.AzureBootcamp.CrossCutting.CloudStorage.AzureStorageAccount** class

A shared access signature provides delegated access to resources in your storage account.
This means that you can grant a client limited permissions to objects in your storage account
for a **specified period of time** and with a specified set of permissions, without having to share your account access keys. The SAS is a URI that encompasses in its query parameters all of the information necessary for authenticated access to a storage resource.
To access storage resources with the SAS, the client only needs to pass in the SAS to the appropriate constructor or method.


text:
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

	<modelVersion>4.0.0</modelVersion>

	<parent>
		<groupId>com.coreoz</groupId>
		<artifactId>plume-file-parent</artifactId>
		<version>1.0.0-SNAPSHOT</version>
	</parent>

	<artifactId>plume-file-gallery</artifactId>
	<packaging>jar</packaging>
	<name>Plume File Gallery</name>
	<description>Manage files galleries</description>

	<build>
		<resources>
			<resource>
				<directory>src/main/java</directory>
				<includes>
					<include>**/*.conf</include>
				</includes>
			</resource>
		</resources>
	</build>

	<dependencies>
		<dependency>
			<groupId>com.coreoz</groupId>
			<artifactId>plume-file-core</artifactId>
		</dependency>

		<dependency>
			<groupId>com.coreoz</groupId>
			<artifactId>plume-db-hibernate</artifactId>
			<optional>true</optional>
		</dependency>
		<dependency>
			<groupId>com.coreoz</groupId>
			<artifactId>plume-db-querydsl</artifactId>
			<optional>true</optional>
		</dependency>

		<dependency>
			<groupId>com.coreoz</groupId>
			<artifactId>plume-admin-security</artifactId>
			<version>1.0.0</version>
			<optional>true</optional>
		</dependency>

		<dependency>
			<groupId>org.projectlombok</groupId>
			<artifactId>lombok</artifactId>
			<scope>provided</scope>
		</dependency>

		<dependency>
			<groupId>com.google.inject</groupId>
			<artifactId>guice</artifactId>
			<optional>true</optional>
		</dependency>

		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.assertj</groupId>
			<artifactId>assertj-core</artifactId>
			<scope>test</scope>
		</dependency>
	</dependencies>

	<dependencyManagement>
		<dependencies>
			<dependency>
				<groupId>com.coreoz</groupId>
				<artifactId>plume-framework-dependencies</artifactId>
				<version>${plume-framework-dependencies.version}</version>
				<scope>import</scope>
				<type>pom</type>
			</dependency>
		</dependencies>
	</dependencyManagement>

</project>


text:
namespace Sitecore.FakeDb.Tests.Globalization.Translate
{
    using FluentAssertions;
    using Sitecore.Globalization;
    using Xunit;

    [Trait("Translate", "Auto-translate is enabled with default suffix")]
    public class AutoTranslateEnabledWithDefaultSuffix : AutoTranslateTestBase
    {
        public AutoTranslateEnabledWithDefaultSuffix()
        {
            this.Db.Configuration.Settings.AutoTranslate = true;
        }

        [Fact(DisplayName = @"Setting ""FakeDb.AutoTranslate"" is ""True""")]
        public void SettingAutoTranslateIsTrue()
        {
            this.Db.Configuration.Settings.AutoTranslate.Should().BeTrue();
        }

        [Fact(DisplayName = @"Setting ""FakeDb.AutoTranslateSuffix"" is empty")]
        public void SettingAutoTranslateSuffixIsAsterisk()
        {
            this.Db.Configuration.Settings.AutoTranslateSuffix.Should().BeEmpty();
        }

        [Fact(DisplayName = @"Translate.Text() adds ""*"" to the end of the phrase")]
        public void TranslateTextAddAsteriskToEnd()
        {
            Translate.Text("Hello!").Should().Be("Hello!*");
        }

        [Fact(DisplayName = @"Translate.Text() does not translate phrases twice")]
        public void TranslateTextNotTranslatePhraseTwice()
        {
            Translate.Text(Translate.Text("Hello!")).Should().Be("Hello!*");
        }

        [Fact(DisplayName = @"Translate.TextByLanguage() adds ""*"" to the end of the phrase")]
        public void TranslateTextByLanguageAddAsteriskToEnd()
        {
            Translate.TextByLanguage("Hello!", this.Language).Should().Be("Hello!*");
        }
    }
}


text:
namespace ktt
{

VulkanTransferAction::VulkanTransferAction(const TransferActionId id, const QueueId queueId, const VulkanDevice* device,
    const VulkanCommandPool* commandPool, VulkanQueryPool* queryPool, std::unique_ptr<VulkanBuffer> stagingBuffer) :
    m_Id(id),
    m_QueueId(queueId),
    m_StagingBuffer(std::move(stagingBuffer)),
    m_QueryPool(queryPool),
    m_Duration(InvalidDuration),
    m_Overhead(0),
    m_FirstQueryId(0),
    m_SecondQueryId(0)
{
    Logger::LogDebug("Initializing Vulkan transfer action with id " + std::to_string(id));

    if (commandPool != nullptr)
    {
        KttAssert(device != nullptr, "Async actions require valid device");
        KttAssert(m_QueryPool != nullptr, "Async actions require valid query pool");
        m_CommandBuffers = commandPool->AllocateBuffers(1);
        m_Fence = std::make_unique<VulkanFence>(*device);

        const auto ids = m_QueryPool->AssignQueryIds();
        m_FirstQueryId = ids.first;
        m_SecondQueryId = ids.second;
    }
}

void VulkanTransferAction::SetDuration(const Nanoseconds duration)
{
    KttAssert(!IsAsync(), "Duration for async actions is handled by query pool");
    m_Duration = duration;
}

void VulkanTransferAction::IncreaseOverhead(const Nanoseconds overhead)
{
    m_Overhead += overhead;
}

void VulkanTransferAction::WaitForFinish()
{
    Logger::LogDebug("Waiting for Vulkan transfer action with id " + std::to_string(m_Id));

    if (IsAsync())
    {
        m_Fence->Wait();
    }
}

TransferActionId VulkanTransferAction::GetId() const
{
    return m_Id;
}

QueueId VulkanTransferAction::GetQueueId() const
{
    return m_QueueId;
}

VkFence VulkanTransferAction::GetFence() const
{
    KttAssert(IsAsync(), "Only async actions contain valid fence");
    return m_Fence->GetFence();
}

VkCommandBuffer VulkanTransferAction::GetCommandBuffer() const
{
    KttAssert(IsAsync(), "Only async actions contain valid command buffer");
    return m_CommandBuffers->GetBuffer();
}

uint32_t VulkanTransferAction::GetFirstQueryId() const
{
    KttAssert(IsAsync(), "Only async actions contain valid query ids");
    return m_FirstQueryId;
}

uint32_t VulkanTransferAction::GetSecondQueryId() const
{
    KttAssert(IsAsync(), "Only async actions contain valid query ids");
    return m_SecondQueryId;
}

Nanoseconds VulkanTransferAction::GetDuration() const
{
    if (IsAsync())
    {
        return m_QueryPool->GetOperationDuration(m_FirstQueryId);
    }

    return m_Duration;
}

Nanoseconds VulkanTransferAction::GetOverhead() const
{
    return m_Overhead;
}

bool VulkanTransferAction::IsAsync() const
{
    return m_CommandBuffers != nullptr;
}

TransferResult VulkanTransferAction::GenerateResult() const
{
    const Nanoseconds duration = GetDuration();
    const Nanoseconds overhead = GetOverhead();
    return TransferResult(duration, overhead);
}

} // namespace ktt

#endif // KTT_API_VULKAN


text:
package de.chefkoch.raclette.rx.android.support;

import android.databinding.ViewDataBinding;
import android.os.Bundle;
import android.support.annotation.CallSuper;
import android.support.annotation.CheckResult;
import android.support.annotation.NonNull;
import de.chefkoch.raclette.ViewModel;
import de.chefkoch.raclette.android.RacletteActivity;
import de.chefkoch.raclette.android.support.RacletteAppCompatActivity;
import de.chefkoch.raclette.rx.lifecycle.HasBindToLifecycle;
import rx.Observable;
import rx.subjects.BehaviorSubject;
import com.trello.rxlifecycle.ActivityEvent;
import com.trello.rxlifecycle.RxLifecycle;
import com.trello.rxlifecycle.ActivityLifecycleProvider;

/**
 * Created by christophwidulle on 28.09.15.
 */
public class RacletteRxAppCompatActivity<V extends ViewModel, B extends ViewDataBinding> extends RacletteAppCompatActivity<V,B> implements ActivityLifecycleProvider, HasBindToLifecycle {

    protected final BehaviorSubject<ActivityEvent> lifecycleSubject = BehaviorSubject.create();

    @Override
    @NonNull
    @CheckResult
    public final Observable<ActivityEvent> lifecycle() {
        return lifecycleSubject.asObservable();
    }

    @Override
    @NonNull
    @CheckResult
    public final <T> Observable.Transformer<T, T> bindUntilEvent(@NonNull ActivityEvent event) {
        return RxLifecycle.bindUntilEvent(lifecycleSubject, event);
    }

    @Override
    @NonNull
    @CheckResult
    public final <T> Observable.Transformer<T, T> bindToLifecycle() {
        return RxLifecycle.bindActivity(lifecycleSubject);
    }

    @Override
    public <T> Observable.Transformer<T, T> bindUntilDestroy() {
        return bindUntilEvent(ActivityEvent.DESTROY);
    }

    @Override
    @CallSuper
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        lifecycleSubject.onNext(ActivityEvent.CREATE);
    }

    @Override
    @CallSuper
    protected void onStart() {
        super.onStart();
        lifecycleSubject.onNext(ActivityEvent.START);
    }

    @Override
    @CallSuper
    protected void onResume() {
        super.onResume();
        lifecycleSubject.onNext(ActivityEvent.RESUME);
    }

    @Override
    @CallSuper
    protected void onPause() {
        lifecycleSubject.onNext(ActivityEvent.PAUSE);
        super.onPause();
    }

    @Override
    @CallSuper
    protected void onStop() {
        lifecycleSubject.onNext(ActivityEvent.STOP);
        super.onStop();
    }

    @Override
    @CallSuper
    protected void onDestroy() {
        lifecycleSubject.onNext(ActivityEvent.DESTROY);
        super.onDestroy();
    }
}


text:
set -e

# utilities
source "${DATA_DIR}/utils.sh"

# script variables
LOG_TITLE="build"

log "nothing to build" 2
exit 1


text:
        <link rel="stylesheet" type="text/css" href="../css/webglbook.css" media="screen" />
        <link rel="stylesheet" type="text/css" href="game-sounds.css" media="screen" />

Game - Sound Lab

		Driving

				<audio controls="controls" id="driving_controls">
				  <source src="../sounds/50910__rutgermuller__in-car-driving.wav" type="audio/wav" />
				  Your browser does not support WAV files in the audio element.
				</audio>

		<button type="button" onclick="document.getElementById('driving_controls').play();">play</button>
		<button type="button" onclick="document.getElementById('driving_controls').pause();">pause</button>
		<button type="button" onclick="document.getElementById('driving_controls').currentTime = 0;">start</button>
		<button type="button" onclick="document.getElementById('driving_controls').currentTime = document.getElementById('driving_controls').duration;">end</button>
		<input type="range" class="slider" min="0" max="100" value="100"
			onchange="document.getElementById('driving_controls').volume=this.value/100;"></input>

		Rev - Short

				<audio controls="controls" id="rev_short_controls">
				  <source src="../sounds/rev-short.wav" type="audio/wav" />
				  Your browser does not support WAV files in the audio element.
				</audio>

		<button type="button" onclick="document.getElementById('rev_short_controls').play();">play</button>
		<button type="button" onclick="document.getElementById('rev_short_controls').pause();">pause</button>
		<button type="button" onclick="document.getElementById('rev_short_controls').currentTime = 0;">start</button>
		<button type="button" onclick="document.getElementById('rev_short_controls').currentTime = document.getElementById('rev_short_controls').duration;">end</button>
		<input type="range" class="slider" min="0" max="100" value="100"
			onchange="document.getElementById('rev_short_controls').volume=this.value/100;"></input>

		Rev - Long

				<audio controls="controls" id="rev_long_controls">
				  <source src="../sounds/rev-trimmed.wav" type="audio/wav" />
				  Your browser does not support WAV files in the audio element.
				</audio>

		<button type="button" onclick="document.getElementById('rev_long_controls').play();">play</button>
		<button type="button" onclick="document.getElementById('rev_long_controls').pause();">pause</button>
		<button type="button" onclick="document.getElementById('rev_long_controls').currentTime = 0;">start</button>
		<button type="button" onclick="document.getElementById('rev_long_controls').currentTime = document.getElementById('rev_long_controls').duration;">end</button>
		<input type="range" class="slider" min="0" max="100" value="100"
			onchange="document.getElementById('rev_long_controls').volume=this.value/100;"></input>

		Burnout

				<audio controls="controls" id="burnout_controls">
				  <source src="../sounds/burnout-trimmed.wav" type="audio/wav" />
				  Your browser does not support WAV files in the audio element.
				</audio>

		<button type="button" onclick="document.getElementById('burnout_controls').play();">play</button>
		<button type="button" onclick="document.getElementById('burnout_controls').pause();">pause</button>
		<button type="button" onclick="document.getElementById('burnout_controls').currentTime = 0;">start</button>
		<button type="button" onclick="document.getElementById('burnout_controls').currentTime = document.getElementById('burnout_controls').duration;">end</button>
		<input type="range" class="slider" min="0" max="100" value="100"
			onchange="document.getElementById('burnout_controls').volume=this.value/100;"></input>

		Crash

				<audio controls="controls" id="crash_controls">
				  <source src="../sounds/crash-trimmed.wav" type="audio/wav" />
				  Your browser does not support WAV files in the audio element.
				</audio>

		<button type="button" onclick="document.getElementById('crash_controls').play();">play</button>
		<button type="button" onclick="document.getElementById('crash_controls').pause();">pause</button>
		<button type="button" onclick="document.getElementById('crash_controls').currentTime = 0;">start</button>
		<button type="button" onclick="document.getElementById('crash_controls').currentTime = document.getElementById('crash_controls').duration;">end</button>
		<input type="range" class="slider" min="0" max="100" value="100"
			onchange="document.getElementById('crash_controls').volume=this.value/100;"></input>


text:
set -e

sudo rm -rf /entropyshift/codedeploy/overseer/*


text:
XebraCommunicator
=============

XebraCommunicator is the underlying communication package for [xebra.js](../xebra.js) and is not intended to be used solely by itself. Please refer to the [xebra.js package](../xebra.js) if you are interested in using the Web enabled communication with Max MSP.

## Contribute

Please use the GitHub issue tracker in case you experience any bugs or get in touch for your feature requests. Please make sure to read our Contributing Guide before submitting any changes.
[Contributing Guide](../../CONTRIBUTING.md)

## How to build

XebraCommunicator is written in ES6. In order to generate the ES5 lib version please run

```
$> yarn run build
```

## License

[MIT](LICENSE)