text:
/* //////////////////////////// SECTION 4 ///////////////////////////////////*/

.section4--mainContent--place {
  display: flex;
  flex-wrap:wrap;
  align-items:flex-end;
}

.section4--mainContent--place {
  font-weight: bold;
}

.section4--mainContent--email {
  display: flex;
  flex-wrap:wrap;
  align-items:center;
  width:100%;
  height:20vh;
}

.section4--mainContent--social {
  width:100%;
  height:20vh;
}

.section4--mainContent--social li {
  width: 25%;
  font-weight: bold;
  padding: 0.5em 0;
}

.section4--footer--mentions {
  font-size:0.6em;
}

.section4--footer--mentions span:hover {
  cursor: pointer;
  color: red;
}

@media screen and (min-width: 800px) {
  .section4--mainContent--place  {width:100%;height:20vh;}
  .section4--mainContent--email {height:40vh;}
  .section4--mainContent--social { display: flex;}
  .section4--mainContent--social li {padding: 0 0;}
  .section4--footer--mentions {font-size:0.8em;}
}


text:
import re
import argparse

if __name__ == '__main__':
    parser = argparse.ArgumentParser()
    parser.add_argument('--input', required=True, type=str)
    args = parser.parse_args()
    print("Loading image '{}' as binary".format(args.input))
    img = open(args.input, 'rb').read()
    print('Duplicating image into one huge BLOB')
    images = img+img
    # jpeg_start: ffd8, jpeg_end: ffd9
    jpeg_regex = re.compile(rb"\xff\xd8(.*?)\xff\xd9", re.DOTALL)
    counter = 0
    for match_obj in jpeg_regex.finditer(images):
        offset = match_obj.start()
        offset2 = match_obj.end()
        print("Image {} offsets: {} - {}".format(counter, offset, offset2))
        counter = counter + 1

redpajama_set_name: RedPajamaGithub


text:
// ========================================================================
//  XML.ObjTree -- XML source code from/to JavaScript object like E4X
// ========================================================================

if ( typeof(XML) == 'undefined' ) XML = function() {};

//  constructor

XML.ObjTree = function () {
    return this;
};

//  class variables

XML.ObjTree.VERSION = "0.24";

//  object prototype

XML.ObjTree.prototype.xmlDecl = '<?xml version="1.0" encoding="UTF-8" ?>\n';
XML.ObjTree.prototype.attr_prefix = '-';
XML.ObjTree.prototype.overrideMimeType = 'text/xml';

//  method: parseXML( xmlsource )

XML.ObjTree.prototype.parseXML = function ( xml ) {
    var root;
    if ( window.DOMParser ) {
        var xmldom = new DOMParser();
//      xmldom.async = false;           // DOMParser is always sync-mode
        var dom = xmldom.parseFromString( xml, "application/xml" );
        if ( ! dom ) return;
        root = dom.documentElement;
    } else if ( window.ActiveXObject ) {
        xmldom = new ActiveXObject('Microsoft.XMLDOM');
        xmldom.async = false;
        xmldom.loadXML( xml );
        root = xmldom.documentElement;
    }
    if ( ! root ) return;
    return this.parseDOM( root );
};

//  method: parseHTTP( url, options, callback )

XML.ObjTree.prototype.parseHTTP = function ( url, options, callback ) {
    var myopt = {};
    for( var key in options ) {
        myopt[key] = options[key];                  // copy object
    }
    if ( ! myopt.method ) {
        if ( typeof(myopt.postBody) == "undefined" &&
             typeof(myopt.postbody) == "undefined" &&
             typeof(myopt.parameters) == "undefined" ) {
            myopt.method = "get";
        } else {
            myopt.method = "post";
        }
    }
    if ( callback ) {
        myopt.asynchronous = true;                  // async-mode
        var __this = this;
        var __func = callback;
        var __save = myopt.onComplete;
        myopt.onComplete = function ( trans ) {
            var tree;
            if ( trans && trans.responseXML && trans.responseXML.documentElement ) {
                tree = __this.parseDOM( trans.responseXML.documentElement );
            } else if ( trans && trans.responseText ) {
                tree = __this.parseXML( trans.responseText );
            }
            __func( tree, trans );
            if ( __save ) __save( trans );
        };
    } else {
        myopt.asynchronous = false;                 // sync-mode
    }
    var trans;
    if ( typeof(HTTP) != "undefined" && HTTP.Request ) {
        myopt.uri = url;
        var req = new HTTP.Request( myopt );        // JSAN
        if ( req ) trans = req.transport;
    } else if ( typeof(Ajax) != "undefined" && Ajax.Request ) {
        var req = new Ajax.Request( url, myopt );   // ptorotype.js
        if ( req ) trans = req.transport;
    }
//  if ( trans && typeof(trans.overrideMimeType) != "undefined" ) {
//      trans.overrideMimeType( this.overrideMimeType );
//  }
    if ( callback ) return trans;
    if ( trans && trans.responseXML && trans.responseXML.documentElement ) {
        return this.parseDOM( trans.responseXML.documentElement );
    } else if ( trans && trans.responseText ) {
        return this.parseXML( trans.responseText );
    }
}

//  method: parseDOM( documentroot )

XML.ObjTree.prototype.parseDOM = function ( root ) {
    if ( ! root ) return;

    this.__force_array = {};
    if ( this.force_array ) {
        for( var i=0; i<this.force_array.length; i++ ) {
            this.__force_array[this.force_array[i]] = 1;
        }
    }

    var json = this.parseElement( root );   // parse root node
    if ( this.__force_array[root.nodeName] ) {
        json = [ json ];
    }
    if ( root.nodeType != 11 ) {            // DOCUMENT_FRAGMENT_NODE
        var tmp = {};
        tmp[root.nodeName] = json;          // root nodeName
        json = tmp;
    }
    return json;
};

//  method: parseElement( element )

XML.ObjTree.prototype.parseElement = function ( elem ) {
    //  COMMENT_NODE
    if ( elem.nodeType == 7 ) {
        return;
    }

    //  TEXT_NODE CDATA_SECTION_NODE
    if ( elem.nodeType == 3 || elem.nodeType == 4 ) {
        var bool = elem.nodeValue.match( /[^\x00-\x20]/ );
        if ( bool == null ) return;     // ignore white spaces
        return elem.nodeValue;
    }

    var retval;
    var cnt = {};

    //  parse attributes
    if ( elem.attributes && elem.attributes.length ) {
        retval = {};
        for ( var i=0; i<elem.attributes.length; i++ ) {
            var key = elem.attributes[i].nodeName;
            if ( typeof(key) != "string" ) continue;
            var val = elem.attributes[i].nodeValue;
            if ( ! val ) continue;
            key = this.attr_prefix + key;
            if ( typeof(cnt[key]) == "undefined" ) cnt[key] = 0;
            cnt[key] ++;
            this.addNode( retval, key, cnt[key], val );
        }
    }

    //  parse child nodes (recursive)
    if ( elem.childNodes && elem.childNodes.length ) {
        var textonly = true;
        if ( retval ) textonly = false;        // some attributes exists
        for ( var i=0; i<elem.childNodes.length && textonly; i++ ) {
            var ntype = elem.childNodes[i].nodeType;
            if ( ntype == 3 || ntype == 4 ) continue;
            textonly = false;
        }
        if ( textonly ) {
            if ( ! retval ) retval = "";
            for ( var i=0; i<elem.childNodes.length; i++ ) {
                retval += elem.childNodes[i].nodeValue;
            }
        } else {
            if ( ! retval ) retval = {};
            for ( var i=0; i<elem.childNodes.length; i++ ) {
                var key = elem.childNodes[i].nodeName;
                if ( typeof(key) != "string" ) continue;
                var val = this.parseElement( elem.childNodes[i] );
                if ( ! val ) continue;
                if ( typeof(cnt[key]) == "undefined" ) cnt[key] = 0;
                cnt[key] ++;
                this.addNode( retval, key, cnt[key], val );
            }
        }
    }
    return retval;
};

//  method: addNode( hash, key, count, value )

XML.ObjTree.prototype.addNode = function ( hash, key, cnts, val ) {
    if ( this.__force_array[key] ) {
        if ( cnts == 1 ) hash[key] = [];
        hash[key][hash[key].length] = val;      // push
    } else if ( cnts == 1 ) {                   // 1st sibling
        hash[key] = val;
    } else if ( cnts == 2 ) {                   // 2nd sibling
        hash[key] = [ hash[key], val ];
    } else {                                    // 3rd sibling and more
        hash[key][hash[key].length] = val;
    }
};

//  method: writeXML( tree )

XML.ObjTree.prototype.writeXML = function ( tree ) {
    var xml = this.hash_to_xml( null, tree );
    return this.xmlDecl + xml;
};

//  method: hash_to_xml( tagName, tree )

XML.ObjTree.prototype.hash_to_xml = function ( name, tree ) {
    var elem = [];
    var attr = [];
    for( var key in tree ) {
        if ( ! tree.hasOwnProperty(key) ) continue;
        var val = tree[key];
        if ( key.charAt(0) != this.attr_prefix ) {
            if ( typeof(val) == "undefined" || val == null ) {
                elem[elem.length] = "<"+key+" />";
            } else if ( typeof(val) == "object" && val.constructor == Array ) {
                elem[elem.length] = this.array_to_xml( key, val );
            } else if ( typeof(val) == "object" ) {
                elem[elem.length] = this.hash_to_xml( key, val );
            } else {
                elem[elem.length] = this.scalar_to_xml( key, val );
            }
        } else {
            attr[attr.length] = " "+(key.substring(1))+'="'+(this.xml_escape( val ))+'"';
        }
    }
    var jattr = attr.join("");
    var jelem = elem.join("");
    if ( typeof(name) == "undefined" || name == null ) {
        // no tag
    } else if ( elem.length > 0 ) {
        if ( jelem.match( /\n/ )) {
            jelem = "<"+name+jattr+">\n"+jelem+"</"+name+">\n";
        } else {
            jelem = "<"+name+jattr+">"  +jelem+"</"+name+">\n";
        }
    } else {
        jelem = "<"+name+jattr+" />\n";
    }
    return jelem;
};

//  method: array_to_xml( tagName, array )

XML.ObjTree.prototype.array_to_xml = function ( name, array ) {
    var out = [];
    for( var i=0; i<array.length; i++ ) {
        var val = array[i];
        if ( typeof(val) == "undefined" || val == null ) {
            out[out.length] = "<"+name+" />";
        } else if ( typeof(val) == "object" && val.constructor == Array ) {
            out[out.length] = this.array_to_xml( name, val );
        } else if ( typeof(val) == "object" ) {
            out[out.length] = this.hash_to_xml( name, val );
        } else {
            out[out.length] = this.scalar_to_xml( name, val );
        }
    }
    return out.join("");
};

//  method: scalar_to_xml( tagName, text )

XML.ObjTree.prototype.scalar_to_xml = function ( name, text ) {
    if ( name == "#text" ) {
        return this.xml_escape(text);
    } else {
        return "<"+name+">"+this.xml_escape(text)+"</"+name+">\n";
    }
};

//  method: xml_escape( text )

XML.ObjTree.prototype.xml_escape = function ( text ) {
    return String(text).replace(/&/g,'&').replace(/</g,'<').replace(/>/g,'>').replace(/"/g,'"');
};


text:
package net.adrianlehmann.swt_revision.patterns.variation_patterns.abstractfactory;

/**
 * Created by adrianlehmann on 09.07.17.
 */
public class WindowsGUIFactory implements GUIFactory {
    @Override
    public NavBar makeNavBar() {
        return () -> System.out.println("Sorry I crashed");
    }
}


text: <!DOCTYPE html>


text:
package aQute.openapi.v2.api;

import java.net.URI;

/**
 * Contact information for the exposed API.
 *
 * <pre>
 * {
 * 	"name": "API Support",
 * 	"url": "http://www.swagger.io/support",
 * 	"email": "support@swagger.io"
 * }
 * </pre>
 *
 * @see "https://github.com/OAI/OpenAPI-Specification/blob/master/versions/2.0.md#contact-object"
 */

public class ContactObject extends BaseOpenAPIObject {
	/**
	 * The identifying name of the contact person/organization.
	 */
	public String	name;

	/**
	 * The URL pointing to the contact information. MUST be in the format of a
	 * URL.
	 */
	public URI		url;

	/**
	 * The email address of the contact person/organization. MUST be in the
	 * format of an email address.
	 */
	public String	email;

}


text:
"""picha URL Configuration

The `urlpatterns` list routes URLs to views. For more information please see:
    https://docs.djangoproject.com/en/1.8/topics/http/urls/
Examples:
Function views
    1. Add an import:  from my_app import views
    2. Add a URL to urlpatterns:  url(r'^$', views.home, name='home')
Class-based views
    1. Add an import:  from other_app.views import Home
    2. Add a URL to urlpatterns:  url(r'^$', Home.as_view(), name='home')
Including another URLconf
    1. Add an import:  from blog import urls as blog_urls
    2. Add a URL to urlpatterns:  url(r'^blog/', include(blog_urls))
"""
from django.conf.urls import include, url
from django.conf.urls.static import static
from django.conf import settings
from django.contrib import admin
from django.views.generic import TemplateView

from api import views

urlpatterns = [
    url(r'^admin/', include(admin.site.urls)),
    url('', include('social.apps.django_app.urls', namespace='social')),
    url(r'^api/', include('api.urls')),
    # url(r'^register/', views.social_register),
    url(r'^.*$', TemplateView.as_view(template_name='picha/index.html'), name='index'),
]

urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)


text:
package org.raboss.dev.atlassian.jira.proman.api.rest.hal.custom;

import org.raboss.dev.atlassian.jira.proman.api.rest.hal.LinkObject;

import javax.xml.bind.annotation.XmlElement;
import java.util.ArrayList;

/**
 * Applications that don't wish to register a link relation type can use an
 * extension relation type, which is a URI {@link http://tools.ietf.org/html/rfc3986}
 * that uniquely identifies the relation type. Although the URI can point to a
 * resource that contains a definition of the semantics of the relation
 * type, clients SHOULD NOT automatically access that resource to avoid
 * overburdening its server.
 * @doc {@link http://tools.ietf.org/html/rfc5988#section-4.2}
 */
public class LinkRelation extends org.raboss.dev.atlassian.jira.proman.api.rest.hal.LinkRelation {
    @XmlElement
    private ArrayList<LinkObject> curies;

    /**
     * Custom link relation types (Extension Relation Types in {@link http://tools.ietf.org/html/rfc5988#section-4.2})
     * SHOULD be URIs that when dereferenced in a web browser provide
     * relevant documentation, in the form of an HTML page, about the
     * meaning and/or behaviour of the target Resource.  This will improve
     * the discoverability of the API.
     * @param curies Custom Link Relations
     * @doc {@link http://tools.ietf.org/html/draft-kelly-json-hal-08#section-8.2}
     */
    public LinkRelation setCurieLinkRelations(final ArrayList<LinkObject> curies) {
        this.curies = curies;
        return this;
    }

    public ArrayList<LinkObject> getCurieLinkRelations() {
        return curies;
    }
}


text:
namespace mojo {

template <>
struct EnumTraits<display::mojom::DisplayConnectionType,
                  display::DisplayConnectionType> {
  static display::mojom::DisplayConnectionType ToMojom(
      display::DisplayConnectionType type);
  static bool FromMojom(display::mojom::DisplayConnectionType type,
                        display::DisplayConnectionType* out);
};

template <>
struct EnumTraits<display::mojom::HDCPState, display::HDCPState> {
  static display::mojom::HDCPState ToMojom(display::HDCPState type);
  static bool FromMojom(display::mojom::HDCPState type,
                        display::HDCPState* out);
};

template <>
struct EnumTraits<display::mojom::ContentProtectionMethod,
                  display::ContentProtectionMethod> {
  static display::mojom::ContentProtectionMethod ToMojom(
      display::ContentProtectionMethod type);
  static bool FromMojom(display::mojom::ContentProtectionMethod type,
                        display::ContentProtectionMethod* out);
};

template <>
struct EnumTraits<display::mojom::PanelOrientation, display::PanelOrientation> {
  static display::mojom::PanelOrientation ToMojom(
      display::PanelOrientation type);
  static bool FromMojom(display::mojom::PanelOrientation type,
                        display::PanelOrientation* out);
};

template <>
struct EnumTraits<display::mojom::PrivacyScreenState,
                  display::PrivacyScreenState> {
  static display::mojom::PrivacyScreenState ToMojom(
      display::PrivacyScreenState type);
  static bool FromMojom(display::mojom::PrivacyScreenState type,
                        display::PrivacyScreenState* out);
};

}  // namespace mojo

#endif  // UI_DISPLAY_MOJOM_DISPLAY_CONSTANTS_MOJOM_TRAITS_H_


text:
use strict;
use warnings;
use utf8;

use FindBin qw($Bin);
use lib "$Bin/../../lib";
use Google::Ads::GoogleAds::Client;
use Google::Ads::GoogleAds::Utils::GoogleAdsHelper;
use Google::Ads::GoogleAds::V12::Resources::AdGroupBidModifier;
use Google::Ads::GoogleAds::V12::Common::HotelCheckInDayInfo;
use Google::Ads::GoogleAds::V12::Common::HotelLengthOfStayInfo;
use Google::Ads::GoogleAds::V12::Enums::DayOfWeekEnum qw(MONDAY);
use
  Google::Ads::GoogleAds::V12::Services::AdGroupBidModifierService::AdGroupBidModifierOperation;
use Google::Ads::GoogleAds::V12::Utils::ResourceNames;

use Getopt::Long qw(:config auto_help);
use Pod::Usage;
use Cwd qw(abs_path);

# The following parameter(s) should be provided to run the example. You can
# either specify these by changing the INSERT_XXX_ID_HERE values below, or on
# the command line.
#
# Parameters passed on the command line will override any parameters set in
# code.
#
# Running the example with -h will print the command line usage.
my $customer_id = "INSERT_CUSTOMER_ID_HERE";
my $ad_group_id = "INSERT_AD_GROUP_ID_HERE";

# [START add_hotel_ad_group_bid_modifiers]
sub add_hotel_ad_group_bid_modifiers {
  my ($api_client, $customer_id, $ad_group_id) = @_;

  # 1) Create an ad group bid modifier based on the hotel check-in day.
  my $check_in_day_ad_group_bid_modifier =
    Google::Ads::GoogleAds::V12::Resources::AdGroupBidModifier->new({
      # Set the ad group.
      adGroup => Google::Ads::GoogleAds::V12::Utils::ResourceNames::ad_group(
        $customer_id, $ad_group_id
      ),
      hotelCheckInDay =>
        Google::Ads::GoogleAds::V12::Common::HotelCheckInDayInfo->new({
          dayOfWeek => MONDAY
        }
        ),
      # Set the bid modifier value to 150%.
      bidModifier => 1.5
    });

  # Create an ad group bid modifier operation.
  my $check_in_day_ad_group_bid_modifier_operation =
    Google::Ads::GoogleAds::V12::Services::AdGroupBidModifierService::AdGroupBidModifierOperation
    ->new({
      create => $check_in_day_ad_group_bid_modifier
    });

  # 2) Create an ad group bid modifier based on the hotel length of stay.
  my $length_of_stay_ad_group_bid_modifier =
    Google::Ads::GoogleAds::V12::Resources::AdGroupBidModifier->new({
      # Set the ad group.
      adGroup => Google::Ads::GoogleAds::V12::Utils::ResourceNames::ad_group(
        $customer_id, $ad_group_id
      ),
      # Create the hotel length of stay info.
      hotelLengthOfStay =>
        Google::Ads::GoogleAds::V12::Common::HotelLengthOfStayInfo->new({
          minNights => 3,
          maxNights => 7
        }
        ),
      # Set the bid modifier value to 170%.
      bidModifier => 1.7
    });

  # Create an ad group bid modifier operation.
  my $length_of_stay_ad_group_bid_modifier_operation =
    Google::Ads::GoogleAds::V12::Services::AdGroupBidModifierService::AdGroupBidModifierOperation
    ->new({
      create => $length_of_stay_ad_group_bid_modifier
    });

  # 3) Add the ad group bid modifiers.
  my $ad_group_bid_modifiers_response =
    $api_client->AdGroupBidModifierService()->mutate({
      customerId => $customer_id,
      operations => [
        $check_in_day_ad_group_bid_modifier_operation,
        $length_of_stay_ad_group_bid_modifier_operation
      ]});

  # Print out resource names of the added ad group bid modifiers.
  my $ad_group_bid_modifier_results =
    $ad_group_bid_modifiers_response->{results};
  printf "Added %d hotel ad group bid modifiers:\n",
    scalar @$ad_group_bid_modifier_results;

  foreach my $ad_group_bid_modifier_result (@$ad_group_bid_modifier_results) {
    printf "\t%s\n", $ad_group_bid_modifier_result->{resourceName};
  }

  return 1;
}
# [END add_hotel_ad_group_bid_modifiers]

# Don't run the example if the file is being included.
if (abs_path($0) ne abs_path(__FILE__)) {
  return 1;
}

# Get Google Ads Client, credentials will be read from ~/googleads.properties.
my $api_client = Google::Ads::GoogleAds::Client->new();

# By default examples are set to die on any server returned fault.
$api_client->set_die_on_faults(1);

# Parameters passed on the command line will override any parameters set in code.
GetOptions(
  "customer_id=s" => \$customer_id,
  "ad_group_id=i" => \$ad_group_id
);

# Print the help message if the parameters are not initialized in the code nor
# in the command line.
pod2usage(2) if not check_params($customer_id, $ad_group_id);

# Call the example.
add_hotel_ad_group_bid_modifiers($api_client, $customer_id =~ s/-//gr,
  $ad_group_id);

=pod

=head1 NAME

add_hotel_ad_group_bid_modifiers

=head1 DESCRIPTION

This example shows how to add ad group bid modifiers to a hotel ad group based on
hotel check-in day and hotel length of stay.

=head1 SYNOPSIS

add_hotel_ad_group_bid_modifiers.pl [options]

    -help                       Show the help message.
    -customer_id                The Google Ads customer ID.
    -ad_group_id                The hotel ad group ID.

=cut


text:
		<link rel="stylesheet" type="text/css" href="/styles/bootstrap.css">
		<link rel="stylesheet" type="text/css" href="/styles/site.css">

 File sharing with webRTC

© Karaxuna 2014


text: export { ChartNetwork32 as default } from "../../";


text:
require 'spec_helper'

describe Moose do
  it 'has a version number' do
    expect(Moose::VERSION).not_to be nil
  end

  it 'does something useful' do
    expect(false).to eq(true)
  end
end


text:
package net.ichigotake.android.yancha.app.ui;

import android.app.Fragment;
import android.app.FragmentManager;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;

import net.ichigotake.android.yancha.app.R;

public final class ProgressBarFragment extends Fragment {

    private static final String FRAGMENT_TAG = "ProgressBarFragment";

    public static void show(FragmentManager fragmentManager) {
        if (fragmentManager.findFragmentByTag(FRAGMENT_TAG) != null) {
            return;
        }
        fragmentManager.beginTransaction()
                .add(android.R.id.content, new ProgressBarFragment(), FRAGMENT_TAG)
                .commit();
    }

    public static void hide(FragmentManager fragmentManager) {
        Fragment fragment = fragmentManager.findFragmentByTag(FRAGMENT_TAG);
        if (fragment != null) {
            fragmentManager.beginTransaction()
                    .remove(fragment)
                    .commit();
        }
    }

    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle savedInstanceState) {
        return inflater.inflate(R.layout.fragment_progress_bar, parent, false);
    }

}


text: ALTER TABLE task ADD COLUMN IF NOT EXISTS spark_extension JSONB;


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">
    <!-- <parent>
        <groupId>org.neo4j.build</groupId>
        <artifactId>parent-pom</artifactId>
        <version>35</version>
        <relativePath/>
    </parent>
    -->

    <modelVersion>4.0.0</modelVersion>
    <groupId>org.neo4j.server.plugin</groupId>
    <artifactId>neo4j-entitygraph</artifactId>
    <version>1.0</version>
    <name>Neo4j Entity Graphs</name>
    <description>Neo4j Entity Graphs and Batch Insert Using Rest Component</description>
    <!--<url>http://github.com/neo4j-contrib/neo4j-jdbc</url>-->

    <properties>
        <neo4j.version>2.2.1</neo4j.version>
        <short-name>neo4j-entitygraph</short-name>
    </properties>

    <!--<packaging>jar</packaging>-->

    <!--<scm>
        <connection>scm:git:git://github.com/neo4j-contrib/neo4j-jdbc.git</connection>
        <developerConnection>scm:git:git@github.com:neo4j-contrib/neo4j-jdbc.git</developerConnection>
        <url>https://github.com/neo4j-contrib/neo4j-jdbc</url>
        <tag>HEAD</tag>
    </scm>
    -->

    <!-- <licenses>
      <license>
        <name>The Apache Software License, Version 2.0</name>
        <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
        <comments>
          Note that this license is for the project itself,
          and not for its dependencies.
          </comments>
          <distribution>repo</distribution>
      </license>
    </licenses>
    -->

    <dependencies>
        <dependency>
            <groupId>org.codehaus.jackson</groupId>
            <artifactId>jackson-core-asl</artifactId>
            <version>1.9.12</version>
        </dependency>
        <dependency>
            <groupId>org.codehaus.jackson</groupId>
            <artifactId>jackson-mapper-asl</artifactId>
            <version>1.9.12</version>
        </dependency>
        <dependency>
            <groupId>org.neo4j</groupId>
            <artifactId>neo4j</artifactId>
            <version>${neo4j.version}</version>
            <optional>true</optional>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.neo4j</groupId>
            <artifactId>server-api</artifactId>
            <version>${neo4j.version}</version>
            <optional>true</optional>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.neo4j</groupId>
            <artifactId>neo4j-kernel</artifactId>
            <version>${neo4j.version}</version>
            <type>test-jar</type>
            <optional>true</optional>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.neo4j</groupId>
            <artifactId>neo4j-io</artifactId>
            <version>${neo4j.version}</version>
            <type>test-jar</type>
            <optional>true</optional>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.neo4j.app</groupId>
            <artifactId>neo4j-server</artifactId>
            <version>${neo4j.version}</version>
            <type>test-jar</type>
            <scope>test</scope>
            <optional>true</optional>
        </dependency>
        <dependency>
            <groupId>com.googlecode.json-simple</groupId>
            <artifactId>json-simple</artifactId>
            <version>1.1.1</version>
        </dependency>
        <dependency>
            <groupId>com.google.code.externalsortinginjava</groupId>
            <artifactId>externalsortinginjava</artifactId>
            <version>0.1.9</version>
        </dependency>
        <dependency>
            <groupId>com.google.guava</groupId>
            <artifactId>guava</artifactId>
            <version>18.0</version>
        </dependency>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-log4j12</artifactId>
            <version>1.7.5</version>
        </dependency>

        <!-- Testing -->
        <dependency>
            <groupId>commons-codec</groupId>
            <artifactId>commons-codec</artifactId>
            <version>1.6</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.11</version>
            <scope>test</scope>
        </dependency>
        <dependency>
 	      <groupId>org.neo4j.app</groupId>
 	      <artifactId>neo4j-server</artifactId>
 	      <version>${neo4j.version}</version>
 	      <exclusions>
 	          <exclusion>
 	              <groupId>org.neo4j</groupId>
 	              <artifactId>neo4j</artifactId>
 	          </exclusion>
 	          <exclusion>
 	              <groupId>ch.qos.logback</groupId>
 	              <artifactId>logback-access</artifactId>
 	          </exclusion>
 	          <exclusion>
 	              <groupId>ch.qos.logback</groupId>
 	              <artifactId>logback-classic</artifactId>
 	          </exclusion>
 	          <exclusion>
 	              <groupId>janino</groupId>
 	              <artifactId>janino</artifactId>
 	          </exclusion>
 	          <exclusion>
 	              <groupId>com.sun.jersey.contribs</groupId>
 	              <artifactId>jersey-multipart</artifactId>
 	          </exclusion>
 	          <exclusion>
 	              <groupId>bouncycastle</groupId>
 	              <artifactId>bcprov-jdk16</artifactId>
 	          </exclusion>
 	      </exclusions>
 	      <scope>test</scope>
 	    </dependency>
    </dependencies>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>2.1</version>
                <configuration>
                    <source>1.7</source>
                    <target>1.7</target>
                </configuration>
            </plugin>
            <plugin>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>2.15</version>
                <configuration>
                    <argLine>-Xmx300m</argLine>
                </configuration>
            </plugin>
            <plugin>
                <artifactId>maven-assembly-plugin</artifactId>

                <configuration>
                    <descriptorRefs>
                        <descriptorRef>jar-with-dependencies</descriptorRef>
                    </descriptorRefs>
                    <appendAssemblyId>true</appendAssemblyId>
                    <archive>
                        <manifest>
                            <addClasspath>true</addClasspath>
                        </manifest>
                    </archive>
                </configuration>

                <executions>
                    <execution>
                        <id>make-assembly</id>
                        <phase>package</phase>
                        <goals>
                            <goal>single</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <version>2.4</version>
                <configuration>
                    <archive>
                        <manifest>
                            <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
                            <addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
                        </manifest>
                    </archive>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <version>2.2.1</version>
                <executions>
                    <execution>
                        <id>attach-sources</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <!-- <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>2.9.1</version>
                <executions>
                    <execution>
                        <id>attach-javadocs</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin> -->
            <plugin>
                <artifactId>exec-maven-plugin</artifactId>
                <groupId>org.codehaus.mojo</groupId>
                <executions>
                    <execution><!-- Run our version calculation script -->
                        <id>Make Plugin</id>
                        <phase>package</phase>
                        <goals>
                            <goal>exec</goal>
                        </goals>
                        <configuration>
                            <executable>${basedir}/copyManifestFiles.bash</executable>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

  <!--<distributionManagement>
    <repository>
      <id>releases@repo.neo4j.org</id>
      <name>releases@repo.neo4j.org</name>
      <uniqueVersion>false</uniqueVersion>
      <url>http://m2.neo4j.org/content/repositories/releases</url>
    </repository>
  </distributionManagement>
  -->

</project>


text:
(async function() {
  TestRunner.addResult(`Tests that modifying stylesheet text with multiple @import at-rules does not crash.\n`);
  await TestRunner.loadLegacyModule('elements'); await TestRunner.loadTestModule('elements_test_runner');
  await TestRunner.showPanel('elements');
  await TestRunner.loadHTML(`

Text

  `);
  var initialAddsExpected = 3;
  var initialAdded = [];
  await new Promise(f => TestRunner.cssModel.addEventListener(SDK.CSSModel.Events.StyleSheetAdded, function styleSheetAdded(event) {
    if (event.data.sourceURL === "") {
      // Don't include the


text:
* Proposal: [SDL-0108](0108-AutoCompleteList.md)
* Author: [Derrick Portis](https://github.com/dportis)
* Status: **Accepted**
* Impacted Platforms: [Core / iOS / Android / RPC]

## Introduction

The AutoCompleteList will give apps the ability to have multiple listing options while searching for things like destination and information; instead of giving a single suggestion.

## Motivation

Our goal is to make things as simple as possible for our users, and the current implementation for auto-complete suggestions while searching is limited to a single suggestion. The single suggestion is inefficient in cases where a user has to type the entire address due to having one suggestion. The autoCompleteList is a technique used by many domains that are used for searching, e.g, Google, Apple Maps, or any search engine.

## Proposed solution

The functionality that autoCompleteList provides is the ability to receive a list of suggestions from the app to use while the user types in a destination or any other search. As the user types in location, for example Walmart, when the user types "Wal" there will be a list of results based on factors like proximity and popularity. The user should get a list of suggestion which include several Walmarts or Walgreens with the address attached. The user should also see the list update as characters are typed, meaning once the user types "Walm", other suggestions like Walgreens and others should remove themselves from the list.

The autoCompleteList is a new parameter to the KeyboardProperties struct. This param will be referenced by SDL when an app sends a request that requires the use of a keyboard. The app will provide a list of matching entries as a key phrase is being typed into the search bar. This list should be deleted and replaced if the app sends a new list to the system.

### Current Implementation:
The system currently only allows for a single suggestion while using the keyboard to type.

```xml
<param name="autoCompleteText" type="String" maxlength="1000" mandatory="false">
    <description>Allows an app to prepopulate the text field with a suggested or completed entry as the user types</description>
</param>
```

### Proposed Implementation:

There is a new parameter for KeyboardProperties which uses an array to allow multiple listing instead of one.

```xml
<param name="autoCompleteList" type="String" maxlength="1000" minsize="0" maxsize="100" array="true" mandatory="false">
    <description>Allows an app to prepopulate the text field with a list of suggested or completed entry as the user types. Set to 0 to remove the auto-complete list from the screen</description>
</param>
```

If an app send both an autoCompleteText and an autoCompleteList parameter in a request to a HU that supports autoCompleteList, the response is successful, and the autoCompleteText is ignored all together.

## Potential downsides

N/A

## Impact on existing code

Mobile API's, HMI API's, and SDL Core all need to be updated to accommodate the new parameters proposed. Older HUs that do not support autoCompleteList will ignore the 'autoCompleteList' parameter and the SetGlobalProperties request itself would be successful.

## Alternatives considered

It was briefly considered to use the existing AutoCompleteText parameter and use a text delimiter key that would allow the system to separate different entries.


text:
<!DOCTYPE frameset SYSTEM "frameset.dtd">
<frameset>
    <predicate lemma="cramp">
        <note>
            Frames file for 'cramp' based on sentences in ectb2.
            No verbnet entry.  Comparison with 'hamper.'
        </note>

        <roleset id="cramp.01" name="obstruct, hinder with painful constriction">
            <roles>
                <role descr="causer of cramping" n="0"/>
                <role descr="entity being cramped, experiencer" n="1"/>
                <role descr="cramped with what, instrument if separate from arg 0" n="2"/>
            </roles>

            <example name="All Arguments, Idiomatic">
                <text>
                    In public, he cramped my style with his incessant impersonations of
                    Simpson's characters.
                </text>
                <arg n="M" f="LOC">In public</arg>
                <arg n="0">he</arg>
                <rel>cramped</rel>
                <arg n="1">my style</arg>
                <arg n="2">with his incessant impersonations of Simpson's
                    characters
                </arg>
            </example>

            <example name="Pain">
                <text>
                    The runner's calf muscle cramped painfully after the race.
                </text>
                <arg n="1">The runner's calf muscle</arg>
                <rel>cramped</rel>
                <arg n="M" f="MNR">painfully</arg>
                <arg n="M" f="TMP">after the race</arg>

            </example>

        </roleset>
    </predicate>
</frameset>


text:
/*
 * StructuredLightSensorProcessor.cpp
 *
 *  Created on: Feb 5, 2014
 *      Author: Péter Fankhauser
 *   Institute: ETH Zurich, ANYbotics
 */

#include <elevation_mapping/sensor_processors/StructuredLightSensorProcessor.hpp>

// PCL
#include <pcl/filters/passthrough.h>
#include <pcl/filters/voxel_grid.h>

// STD
#include <vector>
#include <limits>
#include <string>

namespace elevation_mapping {

/*! StructuredLight-type (structured light) sensor model:
 * standardDeviationInNormalDirection = sensorModelNormalFactorA_ + sensorModelNormalFactorB_ * (measurementDistance - sensorModelNormalFactorC_)^2;
 * standardDeviationInLateralDirection = sensorModelLateralFactor_ * measurementDistance
 * Taken from: Nguyen, C. V., Izadi, S., & Lovell, D., Modeling Kinect Sensor Noise for Improved 3D Reconstruction and Tracking, 2012.
 */

StructuredLightSensorProcessor::StructuredLightSensorProcessor(ros::NodeHandle& nodeHandle, tf::TransformListener& transformListener)
    : SensorProcessorBase(nodeHandle, transformListener)
{

}

StructuredLightSensorProcessor::~StructuredLightSensorProcessor()
{

}

bool StructuredLightSensorProcessor::readParameters()
{
  SensorProcessorBase::readParameters();
  nodeHandle_.param("sensor_processor/normal_factor_a", sensorParameters_["normal_factor_a"], 0.0);
  nodeHandle_.param("sensor_processor/normal_factor_b", sensorParameters_["normal_factor_b"], 0.0);
  nodeHandle_.param("sensor_processor/normal_factor_c", sensorParameters_["normal_factor_c"], 0.0);
  nodeHandle_.param("sensor_processor/normal_factor_d", sensorParameters_["normal_factor_d"], 0.0);
  nodeHandle_.param("sensor_processor/normal_factor_e", sensorParameters_["normal_factor_e"], 0.0);
  nodeHandle_.param("sensor_processor/lateral_factor", sensorParameters_["lateral_factor"], 0.0);
  nodeHandle_.param("sensor_processor/cutoff_min_depth", sensorParameters_["cutoff_min_depth"], std::numeric_limits<double>::min());
  nodeHandle_.param("sensor_processor/cutoff_max_depth", sensorParameters_["cutoff_max_depth"], std::numeric_limits<double>::max());
  return true;
}

bool StructuredLightSensorProcessor::computeVariances(
		const pcl::PointCloud<pcl::PointXYZRGB>::ConstPtr pointCloud,
		const Eigen::Matrix<double, 6, 6>& robotPoseCovariance,
		Eigen::VectorXf& variances)
{
	variances.resize(pointCloud->size());

	// Projection vector (P).
	const Eigen::RowVector3f projectionVector = Eigen::RowVector3f::UnitZ();

	// Sensor Jacobian (J_s).
	const Eigen::RowVector3f sensorJacobian = projectionVector * (rotationMapToBase_.transposed() * rotationBaseToSensor_.transposed()).toImplementation().cast<float>();

	// Robot rotation covariance matrix (Sigma_q).
	Eigen::Matrix3f rotationVariance = robotPoseCovariance.bottomRightCorner(3, 3).cast<float>();

	// Preparations for robot rotation Jacobian (J_q) to minimize computation for every point in point cloud.
	const Eigen::Matrix3f C_BM_transpose = rotationMapToBase_.transposed().toImplementation().cast<float>();
	const Eigen::RowVector3f P_mul_C_BM_transpose = projectionVector * C_BM_transpose;
	const Eigen::Matrix3f C_SB_transpose = rotationBaseToSensor_.transposed().toImplementation().cast<float>();
	const Eigen::Matrix3f B_r_BS_skew = kindr::getSkewMatrixFromVector(Eigen::Vector3f(translationBaseToSensorInBaseFrame_.toImplementation().cast<float>()));

  for (unsigned int i = 0; i < pointCloud->size(); ++i) {
		// For every point in point cloud.

		// Preparation.
		auto& point = pointCloud->points[i];
		Eigen::Vector3f pointVector(point.x, point.y, point.z); // S_r_SP
		float heightVariance = 0.0; // sigma_p

		// Measurement distance.
		float measurementDistance = pointVector.z();

		// Compute sensor covariance matrix (Sigma_S) with sensor model.
                float deviationNormal = sensorParameters_.at("normal_factor_a")
                    + sensorParameters_.at("normal_factor_b")
                        * (measurementDistance - sensorParameters_.at("normal_factor_c")) * (measurementDistance - sensorParameters_.at("normal_factor_c"))
                    + sensorParameters_.at("normal_factor_d") * pow(measurementDistance, sensorParameters_.at("normal_factor_e"));
		float varianceNormal = deviationNormal * deviationNormal;
		float deviationLateral = sensorParameters_.at("lateral_factor") * measurementDistance;
		float varianceLateral = deviationLateral * deviationLateral;
		Eigen::Matrix3f sensorVariance = Eigen::Matrix3f::Zero();
		sensorVariance.diagonal() << varianceLateral, varianceLateral, varianceNormal;

		// Robot rotation Jacobian (J_q).
		const Eigen::Matrix3f C_SB_transpose_times_S_r_SP_skew = kindr::getSkewMatrixFromVector(Eigen::Vector3f(C_SB_transpose * pointVector));
		Eigen::RowVector3f rotationJacobian = P_mul_C_BM_transpose * (C_SB_transpose_times_S_r_SP_skew + B_r_BS_skew);

		// Measurement variance for map (error propagation law).
		heightVariance = rotationJacobian * rotationVariance * rotationJacobian.transpose();
		heightVariance += sensorJacobian * sensorVariance * sensorJacobian.transpose();

		// Copy to list.
		variances(i) = heightVariance;
	}

	return true;
}

bool StructuredLightSensorProcessor::filterPointCloudSensorType(
        const pcl::PointCloud<pcl::PointXYZRGB>::Ptr pointCloud) {
    pcl::PassThrough<pcl::PointXYZRGB> passThroughFilter;
    pcl::PointCloud<pcl::PointXYZRGB> tempPointCloud;

    // cutoff points with z values
    passThroughFilter.setInputCloud(pointCloud);
    passThroughFilter.setFilterFieldName("z");
    passThroughFilter.setFilterLimits(sensorParameters_.at("cutoff_min_depth"),
                                      sensorParameters_.at("cutoff_max_depth"));
    passThroughFilter.filter(tempPointCloud);
    pointCloud->swap(tempPointCloud);

    return true;
}

} /* namespace */