text:
import React from 'react';
import TextField from 'material-ui/TextField';
import { List, ListItem } from 'material-ui/List';

import ActionGrade from 'material-ui/svg-icons/action/grade';
import { pinkA200 } from 'material-ui/styles/colors';
import { ClassComponent } from '../module/container/Application';
import enter from '../module/functions/onEnter';
import handler from '../module/functions/handler';
const map = Function.prototype.call.bind(Array.prototype.map);

class TodoApp extends React.Component {
  constructor() {
    super();
    this.state = {
      input: {
        name: ''
      },
      tasks: [{
        name: 'init'
      }]
    };
  }

  addTask() {
    const newState = {
      input: {
        name: ''
      },
      tasks: this.state.tasks.concat({
        name: this.state.input.name
      })
    };
    this.setState(newState);
  }

  render() {
    const TaskList = map(this.state.tasks, (task, i) => {
      return (<ListItem
                        key={ i }
                        leftIcon={ <ActionGrade color={ pinkA200 } /> }>
                { task.name }
              </ListItem>);
    });
    const trans = (v) => {
      return {
        name: v
      };
    };
    return (
      <div>
        <TextField
                   hintText="input task name"
                   value={ this.state.input.name }
                   onKeyDown={ enter(::this.addTask) }
                   onChange={ this::handler('input', trans) } />
        <List>
          { TaskList }
        </List>
      </div>
      );
  }
}

export default ClassComponent(TodoApp);


text:
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet href="latest_ob.xsl" type="text/xsl"?>
<current_observation version="1.0"
	 xmlns:xsd="http://www.w3.org/2001/XMLSchema"
	 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	 xsi:noNamespaceSchemaLocation="http://www.weather.gov/view/current_observation.xsd">
	<credit>NOAA's National Weather Service</credit>
	<credit_URL>http://weather.gov/</credit_URL>
	<image>
		<url>http://weather.gov/images/xml_logo.gif</url>
		<title>NOAA's National Weather Service</title>
		<link>http://weather.gov</link>
	</image>
	<suggested_pickup>15 minutes after the hour</suggested_pickup>
	<suggested_pickup_period>60</suggested_pickup_period>
	<location>Fallbrook Community Airpark, CA</location>
	<station_id>KL18</station_id>
	<latitude>33.3542</latitude>
	<longitude>-117.2509</longitude>
	<observation_time>Last Updated on Jan 4 2016, 6:55 pm PST</observation_time>
        <observation_time_rfc822>Mon, 04 Jan 2016 18:55:00 -0800</observation_time_rfc822>
	<weather>Overcast</weather>
	<temperature_string>55.0 F (13.0 C)</temperature_string>
	<temp_f>55.0</temp_f>
	<temp_c>13.0</temp_c>
	<relative_humidity>88</relative_humidity>
	<wind_string>West at 4.6 MPH (4 KT)</wind_string>
	<wind_dir>West</wind_dir>
	<wind_degrees>260</wind_degrees>
	<wind_mph>4.6</wind_mph>
	<wind_kt>4</wind_kt>
	<pressure_in>29.85</pressure_in>
	<dewpoint_string>51.8 F (11.0 C)</dewpoint_string>
	<dewpoint_f>51.8</dewpoint_f>
	<dewpoint_c>11.0</dewpoint_c>
	<windchill_string>54 F (12 C)</windchill_string>
      	<windchill_f>54</windchill_f>
      	<windchill_c>12</windchill_c>
	<visibility_mi>10.00</visibility_mi>
 	<icon_url_base>http://forecast.weather.gov/images/wtf/small/</icon_url_base>
	<two_day_history_url>http://www.weather.gov/data/obhistory/KL18.html</two_day_history_url>
	<icon_url_name>ovc.png</icon_url_name>
	<ob_url>http://www.weather.gov/data/METAR/KL18.1.txt</ob_url>
	<disclaimer_url>http://weather.gov/disclaimer.html</disclaimer_url>
	<copyright_url>http://weather.gov/disclaimer.html</copyright_url>
	<privacy_policy_url>http://weather.gov/notice.html</privacy_policy_url>
</current_observation>

redpajama_set_name: RedPajamaGithub


text:
set(Plugin-ActivationPolicy "eager")
set(Plugin-Name "pluginSL4")
set(Plugin-Version "1.0.0")
set(Plugin-Description "Test plugin for framework, pluginSL4_test")
set(Plugin-Vendor "CommonTK")
set(Plugin-ContactAddress "http://commontk.org")
set(Plugin-Category "test")
set(Require-Plugin pluginSL1.test)


text:
require 'spec_helper'
module Finitio
  describe RelationType, "default_name" do

    let(:heading){
      Heading.new([Attribute.new(:a, byte)])
    }

    subject{ type.default_name }

    let(:type){ RelationType.new(heading) }

    it{ should eq("{{a: Byte}}") }

  end
end


text:
Low-level API
=============

.. currentmodule:: paka.cmark.lowlevel

.. automodule:: paka.cmark.lowlevel
  :no-members:
  :no-undoc-members:

.. autofunction:: version_string

.. autofunction:: parse_document
.. autofunction:: node_new
.. autofunction:: node_free
.. autofunction:: node_get_type
.. autofunction:: node_get_type_string
.. autofunction:: node_get_fence_info
.. autofunction:: node_get_literal
.. autofunction:: node_set_literal
.. autofunction:: node_get_heading_level
.. autofunction:: node_set_heading_level
.. autofunction:: node_get_list_type
.. autofunction:: node_set_list_type
.. autofunction:: node_get_list_delim
.. autofunction:: node_set_list_delim
.. autofunction:: node_get_list_start
.. autofunction:: node_set_list_start
.. autofunction:: node_get_list_tight
.. autofunction:: node_set_list_tight
.. autofunction:: node_get_url
.. autofunction:: node_set_url
.. autofunction:: node_get_title
.. autofunction:: node_set_title
.. autofunction:: node_get_start_line
.. autofunction:: node_get_start_column
.. autofunction:: node_get_end_line
.. autofunction:: node_get_end_column

Parsing (streaming API)
-----------------------
.. autofunction:: parser_new
.. autofunction:: parser_free
.. autofunction:: parser_feed
.. autofunction:: parser_finish

Tree traversal
--------------
.. autofunction:: node_next
.. autofunction:: node_previous
.. autofunction:: node_parent
.. autofunction:: node_first_child
.. autofunction:: node_last_child

Tree manipulation
-----------------
.. autofunction:: node_unlink
.. autofunction:: node_insert_before
.. autofunction:: node_insert_after
.. autofunction:: node_replace
.. autofunction:: node_prepend_child
.. autofunction:: node_append_child
.. autofunction:: consolidate_text_nodes

Iteration
---------
.. autofunction:: iter_new
.. autofunction:: iter_free
.. autofunction:: iter_next
.. autofunction:: iter_get_node
.. autofunction:: iter_get_event_type
.. autofunction:: iter_get_root
.. autofunction:: iter_reset

.. _iteration_event_types:

Iteration event types
---------------------
.. autodata:: EVENT_ENTER
.. autodata:: EVENT_EXIT
.. autodata:: EVENT_DONE

Rendering
---------
.. autofunction:: markdown_to_html
.. autofunction:: render_html
.. autofunction:: render_xml
.. autofunction:: render_man
.. autofunction:: render_commonmark
.. autofunction:: render_latex

.. _options:

Options
-------
.. autodata:: OPT_DEFAULT
.. autodata:: OPT_HARDBREAKS
.. autodata:: OPT_NOBREAKS
.. autodata:: OPT_SOURCEPOS
.. autodata:: OPT_UNSAFE
.. autodata:: OPT_SMART

.. _node_types:

Node types
----------
.. autodata:: NODE_NONE
.. autodata:: NODE_CODE_BLOCK
.. autodata:: NODE_HTML_BLOCK
.. autodata:: NODE_DOCUMENT
.. autodata:: NODE_BLOCK_QUOTE
.. autodata:: NODE_LIST
.. autodata:: NODE_ITEM
.. autodata:: NODE_CUSTOM_BLOCK
.. autodata:: NODE_PARAGRAPH
.. autodata:: NODE_HEADING
.. autodata:: NODE_THEMATIC_BREAK
.. autodata:: NODE_FIRST_BLOCK
.. autodata:: NODE_LAST_BLOCK
.. autodata:: NODE_TEXT
.. autodata:: NODE_SOFTBREAK
.. autodata:: NODE_LINEBREAK
.. autodata:: NODE_CODE
.. autodata:: NODE_HTML_INLINE
.. autodata:: NODE_CUSTOM_INLINE
.. autodata:: NODE_EMPH
.. autodata:: NODE_STRONG
.. autodata:: NODE_LINK
.. autodata:: NODE_IMAGE
.. autodata:: NODE_FIRST_INLINE
.. autodata:: NODE_LAST_INLINE

.. _list_types:

List types
----------
.. autodata:: BULLET_LIST
.. autodata:: ORDERED_LIST
.. autodata:: NO_LIST

.. _list_delimiters:

List delimiters
---------------
.. autodata:: PERIOD_DELIM
.. autodata:: PAREN_DELIM
.. autodata:: NO_DELIM

Python Helpers
--------------
.. autofunction:: text_to_c
.. autofunction:: text_from_c


text:
doc_ids_path=data/tmp/2015-08-18/filtered_trainable_doc_ids.txt
ok_path=/cs/taatto/home/hxiao/capitalization-recovery/corpus/puls-format/
mal_path=/cs/taatto/home/hxiao/capitalization-recovery/corpus/puls-format-rule-based

time python rule_based.py ${doc_ids_path}  ${ok_path} ${mal_path}


text:
var path = require('path');
var fs = require('fs');
var autoprefixer = require('autoprefixer');

var webpack = require('webpack');
var HtmlWebpackPlugin = require('html-webpack-plugin');

var root_path = fs.realpathSync(process.cwd());

module.exports = {

  entry: [
    path.resolve(__dirname, '../dev-tools/webpack-hot-client.js'),
    path.resolve(root_path, 'src/client/index.js')
  ],

  output: {

    path: path.resolve(root_path, 'build'),
    pathinfo: true,

    filename: 'assets/application.js',
    publicPath: '/'
  },

  resolveLoader: {
    root: path.resolve(__dirname, '../node_modules')
  },

  module: {
    loaders: [
      {
        test: /\.js$/,
        include: [
          path.resolve(__dirname, '../dev-tools'),
          path.resolve(root_path, 'src/client')
        ],
        loader: `ng-annotate!babel?babelrc=false&presets[]=${require.resolve('babel-preset-es2015')}`
      },
      {
        test: /\.css$/,
        loader: 'style!css!postcss'
      },
      {
        test: /\.json$/,
        loader: 'json'
      },
      {
        test: /\.html$/,
        loader: 'raw'
      },
      {
        test: /\.(ico|jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2)(\?.*)?$/,
        loader: 'file',
        query: {
          name: 'assets/media/[name].[hash:8].[ext]'
        }
      }
    ]
  },

  postcss: [
    autoprefixer({
      browsers: ['last 2 versions']
    })
  ],

  plugins: [
    new HtmlWebpackPlugin({
      inject: true,
      template: path.resolve(root_path, 'public/index.html')
    }),
    new webpack.HotModuleReplacementPlugin()
  ]
}


text:
/*
 * $Id: SubContextList.java 468655 2006-10-28 07:12:06Z minchau $
 */
package org.apache.xpath.axes;

import org.apache.xpath.XPathContext;

/**
 * A class that implements this interface is a sub context node list, meaning it
 * is a node list for a location path step for a predicate.
 * @xsl.usage advanced
 */
public interface SubContextList
{

  /**
   * Get the number of nodes in the node list, which, in the XSLT 1 based
   * counting system, is the last index position.
   *
   *
   * @param xctxt The XPath runtime context.
   *
   * @return the number of nodes in the node list.
   */
  public int getLastPos(XPathContext xctxt);

  /**
   * Get the current sub-context position.
   *
   * @param xctxt The XPath runtime context.
   *
   * @return The position of the current node in the list.
   */
  public int getProximityPosition(XPathContext xctxt);
}


text:
<?php
/**********************************************************************************************************************************
*
* Custom Post Types
*
* Author: Webbu Design
*
***********************************************************************************************************************************/

function create_post_type_pointfinder()
{

    /**
    *Start: Get Admin Values
    **/
        $setup3_pointposttype_pt1 = PFSAIssetControl('setup3_pointposttype_pt1','','pfitemfinder');
        $setup3_pointposttype_pt2 = PFSAIssetControl('setup3_pointposttype_pt2','','PF Item');
        $setup3_pointposttype_pt3 = PFSAIssetControl('setup3_pointposttype_pt3','','PF Items');
        $setup3_pointposttype_pt4 = PFSAIssetControl('setup3_pointposttype_pt4','','Item Types');
        $setup3_pointposttype_pt4s = PFSAIssetControl('setup3_pointposttype_pt4s','','Item Type');
        $setup3_pointposttype_pt4p = PFSAIssetControl('setup3_pointposttype_pt4p','','types');
        $setup3_pointposttype_pt5 = PFSAIssetControl('setup3_pointposttype_pt5','','Locations');
        $setup3_pointposttype_pt5s = PFSAIssetControl('setup3_pointposttype_pt5s','','Location');
        $setup3_pointposttype_pt5p = PFSAIssetControl('setup3_pointposttype_pt5p','','area');
        $setup3_pointposttype_pt6 = PFSAIssetControl('setup3_pointposttype_pt6','','Features');
        $setup3_pointposttype_pt6s = PFSAIssetControl('setup3_pointposttype_pt6s','','Feature');
        $setup3_pointposttype_pt6p = PFSAIssetControl('setup3_pointposttype_pt6p','','feature');
        $setup3_pointposttype_pt7 = PFSAIssetControl('setup3_pointposttype_pt7','','Listing Types');
        $setup3_pointposttype_pt7s = PFSAIssetControl('setup3_pointposttype_pt7s','','Listing Type');
        $setup3_pointposttype_pt7p = PFSAIssetControl('setup3_pointposttype_pt7p','','listing');
        $setup3_pointposttype_pt8 = PFSAIssetControl('setup3_pointposttype_pt8','','agents');
        $setup3_pointposttype_pt9 = PFSAIssetControl('setup3_pointposttype_pt9','','PF Agent');
        $setup3_pointposttype_pt10 = PFSAIssetControl('setup3_pointposttype_pt10','','PF Agents');
        $setup3_pointposttype_pt11 = PFSAIssetControl('setup3_pointposttype_pt11','','testimonials');
        $setup3_pointposttype_pt12 = PFSAIssetControl('setup3_pointposttype_pt12','','PF Testimonials');
        $setup3_pointposttype_pt13 = PFSAIssetControl('setup3_pointposttype_pt13','','Testimonial');

        $setup3_pt14 = PFSAIssetControl('setup3_pt14','','Conditions');
        $setup3_pt14s = PFSAIssetControl('setup3_pt14s','','Condition');
        $setup3_pt14p = PFSAIssetControl('setup3_pt14p','','condition');
        $setup3_pt14_check = PFSAIssetControl('setup3_pt14_check','','0');

        $setup3_pointposttype_pt4_check = PFSAIssetControl('setup3_pointposttype_pt4_check','','1');
        $setup3_pointposttype_pt5_check = PFSAIssetControl('setup3_pointposttype_pt5_check','','1');
        $setup3_pointposttype_pt6_check = PFSAIssetControl('setup3_pointposttype_pt6_check','','1');

        $setup3_pointposttype_pt6_status = PFSAIssetControl('setup3_pointposttype_pt6_status','','1');

        $setup4_membersettings_loginregister = PFSAIssetControl('setup4_membersettings_loginregister','','1');
        $setup4_membersettings_frontend = PFSAIssetControl('setup4_membersettings_frontend','','1');

        $setup11_reviewsystem_check = PFREVSIssetControl('setup11_reviewsystem_check','','0');
        $setup4_membersettings_paymentsystem = PFSAIssetControl('setup4_membersettings_paymentsystem','','1');
    /**
    *End: Get Admin Values
    **/

    /**
    *Start: Reviews Post Type
    **/
        if($setup11_reviewsystem_check == 1){

            register_post_type('pointfinderreviews',
                array(
                'labels' => array(
                    'name' => esc_html__( 'PF Reviews', 'pointfindert2d' ),
                    'singular_name' => esc_html__( 'PF Review', 'pointfindert2d' ),
                    'add_new' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),esc_html__( 'Review', 'pointfindert2d' )),
                    'add_new_item' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),esc_html__( 'Review', 'pointfindert2d' )),
                    'edit' => esc_html__('Edit', 'pointfindert2d'),
                    'edit_item' => sprintf(esc_html__( 'Edit %s', 'pointfindert2d' ),esc_html__( 'Review', 'pointfindert2d' )),
                    'new_item' => sprintf(esc_html__( 'New %s', 'pointfindert2d' ),esc_html__( 'Review', 'pointfindert2d' )),
                    'view' => sprintf(esc_html__( 'View %s', 'pointfindert2d' ),esc_html__( 'Review', 'pointfindert2d' )),
                    'view_item' => sprintf(esc_html__( 'View %s', 'pointfindert2d' ),esc_html__( 'Review', 'pointfindert2d' )),
                    'search_items' =>  sprintf(esc_html__( 'Search %s', 'pointfindert2d' ),esc_html__( 'Review', 'pointfindert2d' )),
                    'not_found' => sprintf(esc_html__( 'No %s found', 'pointfindert2d' ),esc_html__( 'Review', 'pointfindert2d' )),
                    'not_found_in_trash' => sprintf(esc_html__( 'No %s found in Trash', 'pointfindert2d' ),esc_html__( 'Review', 'pointfindert2d' )),
                ),
                'public' => true,
        		'menu_position' => 209,
        		'menu_icon' => 'dashicons-format-status',
                'hierarchical' => true,
        		'show_tagcloud' => false,
                'show_in_nav_menus' => false,
                'has_archive' => true,
                'supports' => array('title','editor'),
                'can_export' => true,
        		'taxonomies' => array(),
        		'register_meta_box_cb' => 'pointfinder_reviews_add_meta_box',
            ));

        }
    /**
    *End: Reviews Post Type
    **/

    /**
    *Start: Orders Post Type
    **/
        if($setup4_membersettings_frontend == 1 && $setup4_membersettings_loginregister == 1 && $setup4_membersettings_paymentsystem == 1){

            register_post_type('pointfinderorders',
                array(
                'labels' => array(
                    'name' => esc_html__( 'PF Orders', 'pointfindert2d' ),
                    'singular_name' => esc_html__( 'PF Order', 'pointfindert2d' ),
                    'add_new' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                    'add_new_item' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                    'edit' => esc_html__('Edit', 'pointfindert2d'),
                    'edit_item' => sprintf(esc_html__( 'Edit %s', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                    'new_item' => sprintf(esc_html__( 'New %s', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                    'view' => sprintf(esc_html__( 'View %s', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                    'view_item' => sprintf(esc_html__( 'View %s', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                    'search_items' =>  sprintf(esc_html__( 'Search %s', 'pointfindert2d' ),esc_html__( 'Orders', 'pointfindert2d' )),
                    'not_found' => sprintf(esc_html__( 'No %s found', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                    'not_found_in_trash' => sprintf(esc_html__( 'No %s found in Trash', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                ),
                'public' => true,
        		'menu_position' => 208,
        		'menu_icon' => 'dashicons-feedback',
                'hierarchical' => true,
        		'show_tagcloud' => false,
                'show_in_nav_menus' => false,
                'has_archive' => true,
                'supports' => false,
                'can_export' => true,
        		'taxonomies' => array(),
        		'register_meta_box_cb' => 'pointfinder_orders_add_meta_box',

            ));

        }
    /**
    *End: Orders Post Type
    **/

    /**
    *Start: Orders for membership Post Type
    **/
        if($setup4_membersettings_frontend == 1 && $setup4_membersettings_loginregister == 1 && $setup4_membersettings_paymentsystem == 2){

            register_post_type('pointfindermorders',
                array(
                'labels' => array(
                    'name' => esc_html__( 'PF Orders', 'pointfindert2d' ),
                    'singular_name' => esc_html__( 'PF Order', 'pointfindert2d' ),
                    'add_new' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                    'add_new_item' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                    'edit' => esc_html__('Edit', 'pointfindert2d'),
                    'edit_item' => sprintf(esc_html__( 'Edit %s', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                    'new_item' => sprintf(esc_html__( 'New %s', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                    'view' => sprintf(esc_html__( 'View %s', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                    'view_item' => sprintf(esc_html__( 'View %s', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                    'search_items' =>  sprintf(esc_html__( 'Search %s', 'pointfindert2d' ),esc_html__( 'Orders', 'pointfindert2d' )),
                    'not_found' => sprintf(esc_html__( 'No %s found', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                    'not_found_in_trash' => sprintf(esc_html__( 'No %s found in Trash', 'pointfindert2d' ),esc_html__( 'Order', 'pointfindert2d' )),
                ),
                'public' => true,
                'menu_position' => 208,
                'menu_icon' => 'dashicons-feedback',
                'hierarchical' => true,
                'show_tagcloud' => false,
                'show_in_nav_menus' => false,
                'has_archive' => true,
                'supports' => false,
                'can_export' => true,
                'taxonomies' => array(),
                'register_meta_box_cb' => 'pointfinder_morders_add_meta_box',

            ));

        }
    /**
    *End: Orders for membership Post Type
    **/

    /**
    *Start: Invoices Post Type
    **/
        if($setup4_membersettings_frontend == 1 && $setup4_membersettings_loginregister == 1){

            register_post_type('pointfinderinvoices',
                array(
                'labels' => array(
                    'name' => esc_html__( 'PF Invoices', 'pointfindert2d' ),
                    'singular_name' => esc_html__( 'PF Invoice', 'pointfindert2d' ),
                    'add_new' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),esc_html__( 'Invoice', 'pointfindert2d' )),
                    'add_new_item' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),esc_html__( 'Invoice', 'pointfindert2d' )),
                    'edit' => esc_html__('Edit', 'pointfindert2d'),
                    'edit_item' => sprintf(esc_html__( 'Edit %s', 'pointfindert2d' ),esc_html__( 'Invoice', 'pointfindert2d' )),
                    'new_item' => sprintf(esc_html__( 'New %s', 'pointfindert2d' ),esc_html__( 'Invoice', 'pointfindert2d' )),
                    'view' => sprintf(esc_html__( 'View %s', 'pointfindert2d' ),esc_html__( 'Invoice', 'pointfindert2d' )),
                    'view_item' => sprintf(esc_html__( 'View %s', 'pointfindert2d' ),esc_html__( 'Invoice', 'pointfindert2d' )),
                    'search_items' =>  sprintf(esc_html__( 'Search %s', 'pointfindert2d' ),esc_html__( 'Invoices', 'pointfindert2d' )),
                    'not_found' => sprintf(esc_html__( 'No %s found', 'pointfindert2d' ),esc_html__( 'Invoice', 'pointfindert2d' )),
                    'not_found_in_trash' => sprintf(esc_html__( 'No %s found in Trash', 'pointfindert2d' ),esc_html__( 'Invoice', 'pointfindert2d' )),
                ),
                'public' => true,
                'menu_position' => 210,
                'menu_icon' => 'dashicons-list-view',
                'hierarchical' => true,
                'show_tagcloud' => false,
                'show_in_nav_menus' => false,
                'has_archive' => true,
                'supports' => false,
                'can_export' => true,
                'taxonomies' => array(),
                'register_meta_box_cb' => 'pointfinder_minvoices_add_meta_box',

            ));

        }
    /**
    *End: Invoices Post Type
    **/

    /**
    *Start: Testimonials Post Type
    **/
        register_post_type(''.$setup3_pointposttype_pt11.'',
            array(
            'labels' => array(
                'name' => ''.$setup3_pointposttype_pt12.'',
                'singular_name' => ''.$setup3_pointposttype_pt13.'',
                'add_new' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),$setup3_pointposttype_pt13),
                'add_new_item' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),$setup3_pointposttype_pt13),
                'edit' => esc_html__('Edit', 'pointfindert2d'),
                'edit_item' => sprintf(esc_html__( 'Edit %s', 'pointfindert2d' ),$setup3_pointposttype_pt13),
                'new_item' => sprintf(esc_html__( 'New %s', 'pointfindert2d' ),$setup3_pointposttype_pt13),
                'view' => sprintf(esc_html__( 'View %s', 'pointfindert2d' ),$setup3_pointposttype_pt13),
                'view_item' => sprintf(esc_html__( 'View %s', 'pointfindert2d' ),$setup3_pointposttype_pt13),
                'search_items' =>  sprintf(esc_html__( 'Search %s', 'pointfindert2d' ),$setup3_pointposttype_pt12),
                'not_found' => sprintf(esc_html__( 'No %s found', 'pointfindert2d' ),$setup3_pointposttype_pt13),
                'not_found_in_trash' => sprintf(esc_html__( 'No %s found in Trash', 'pointfindert2d' ),$setup3_pointposttype_pt13),
            ),
            'public' => true,
    		'menu_position' => 207,
    		'menu_icon' => 'dashicons-format-chat',
            'hierarchical' => true,
    		'show_tagcloud' => false,
            'show_in_nav_menus' => false,
            'has_archive' => true,
            'supports' => array(
                'title',
                'editor',
            ),
            'can_export' => true,
    		'taxonomies' => array(),

        ));
    /**
    *End: Testimonials Post Type
    **/

    /**
    *Start: Agents Post Type
    **/
        if($setup3_pointposttype_pt6_status == 1){
            register_post_type(''.$setup3_pointposttype_pt8.'',
                array(
                'labels' => array(
                    'name' => ''.$setup3_pointposttype_pt10.'',
                    'singular_name' => ''.$setup3_pointposttype_pt9.'',
                    'add_new' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),$setup3_pointposttype_pt9),
                    'add_new_item' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),$setup3_pointposttype_pt9),
                    'edit' => esc_html__('Edit', 'pointfindert2d'),
                    'edit_item' => sprintf(esc_html__( 'Edit %s', 'pointfindert2d' ),$setup3_pointposttype_pt9),
                    'new_item' => sprintf(esc_html__( 'New %s', 'pointfindert2d' ),$setup3_pointposttype_pt9),
                    'view' => sprintf(esc_html__( 'View %s', 'pointfindert2d' ),$setup3_pointposttype_pt9),
                    'view_item' => sprintf(esc_html__( 'View %s', 'pointfindert2d' ),$setup3_pointposttype_pt9),
                    'search_items' =>  sprintf(esc_html__( 'Search %s', 'pointfindert2d' ),$setup3_pointposttype_pt10),
                    'not_found' => sprintf(esc_html__( 'No %s found', 'pointfindert2d' ),$setup3_pointposttype_pt9),
                    'not_found_in_trash' => sprintf(esc_html__( 'No %s found in Trash', 'pointfindert2d' ),$setup3_pointposttype_pt9),
                ),
                'public' => true,
        		'menu_position' => 206,
        		'menu_icon' => 'dashicons-businessman',
                'hierarchical' => true,
        		'show_tagcloud' => false,
                'has_archive' => true,
                'supports' => array(
                    'title',
                    'editor',
                    'thumbnail',
                ),
                'can_export' => true,
        		'taxonomies' => array(),
                'rewrite' => true

            ));
        }
    /**
    *End: Agents Post Type
    **/

    /**
    *Start: PF Items Post Type
    **/
        register_post_type(''.$setup3_pointposttype_pt1.'',
            array(
            'labels' => array(
                'name' => ''.$setup3_pointposttype_pt3.'',
                'singular_name' => ''.$setup3_pointposttype_pt2.'',
                'add_new' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),$setup3_pointposttype_pt2),
                'add_new_item' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),$setup3_pointposttype_pt2),
                'edit' => esc_html__('Edit', 'pointfindert2d'),
                'edit_item' => sprintf(esc_html__( 'Edit %s', 'pointfindert2d' ),$setup3_pointposttype_pt2),
                'new_item' => sprintf(esc_html__( 'New %s', 'pointfindert2d' ),$setup3_pointposttype_pt2),
                'view' => sprintf(esc_html__( 'View %s', 'pointfindert2d' ),$setup3_pointposttype_pt2),
                'view_item' => sprintf(esc_html__( 'View %s', 'pointfindert2d' ),$setup3_pointposttype_pt2),
                'search_items' =>  sprintf(esc_html__( 'Search %s', 'pointfindert2d' ),$setup3_pointposttype_pt3),
                'not_found' => sprintf(esc_html__( 'No %s found', 'pointfindert2d' ),$setup3_pointposttype_pt2),
                'not_found_in_trash' => sprintf(esc_html__( 'No %s found in Trash', 'pointfindert2d' ),$setup3_pointposttype_pt2),
            ),
            'public' => true,
    		'menu_position' => 202,
    		'menu_icon' => 'dashicons-location-alt',
            'hierarchical' => true,
    		'show_tagcloud' => false,
            'has_archive' => true,
            'supports' => array(
                'title',
                'editor',
                'thumbnail',
    			'excerpt',
                'page-attributes',
                'tags'
            ),
            'can_export' => true,
    		'taxonomies' => array('post_tag')

        ));
    /**
    *End: PF Items Post Type
    **/

    /**
    *Start: Listing Types Taxonomy
    **/
    	  $labels = array(
    		'name' => ''.$setup3_pointposttype_pt7.'',
    		'singular_name' => ''.$setup3_pointposttype_pt7s.'',
    		'search_items' =>  sprintf(esc_html__( 'Search %s', 'pointfindert2d' ),$setup3_pointposttype_pt7),
    		'popular_items' => sprintf(esc_html__( 'Popular %s', 'pointfindert2d' ),$setup3_pointposttype_pt7),
    		'all_items' => sprintf(esc_html__( 'All %s', 'pointfindert2d' ),$setup3_pointposttype_pt7),
    		'parent_item' => null,
    		'parent_item_colon' => null,
    		'edit_item' => sprintf(esc_html__( 'Edit %s', 'pointfindert2d' ),$setup3_pointposttype_pt7s),
    		'update_item' => sprintf(esc_html__( 'Update %s', 'pointfindert2d' ),$setup3_pointposttype_pt7s),
    		'add_new_item' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),$setup3_pointposttype_pt7s),
    		'new_item_name' => sprintf(esc_html__( 'New %s', 'pointfindert2d' ),$setup3_pointposttype_pt7s),
    		'separate_items_with_commas' => sprintf(esc_html__( 'Separate %s with commas', 'pointfindert2d' ),$setup3_pointposttype_pt7),
    		'add_or_remove_items' => sprintf(esc_html__( 'Add or remove %s', 'pointfindert2d' ),$setup3_pointposttype_pt7s),
    		'choose_from_most_used' => sprintf(esc_html__( 'Choose from the most used %s', 'pointfindert2d' ),$setup3_pointposttype_pt7s),
    		'menu_name' => ''.$setup3_pointposttype_pt7.'',
    	  );

    	  register_taxonomy('pointfinderltypes',''.$setup3_pointposttype_pt1.'',array(
    		'hierarchical' => true,
    		'labels' => $labels,
    		'show_ui' => true,
    		'show_admin_column' => true,
            'show_in_nav_menus' => true,
    		'update_count_callback' => '_update_post_term_count',
    		'query_var' => true,
    		'rewrite' => array( 'slug' => $setup3_pointposttype_pt7p,'hierarchical'=>true ),
    		'sort' => true,
    	  ));
    /**
    *End: Listing Types Taxonomy
    **/

    /**
    *Start: Item Types Taxonomy
    **/
        if($setup3_pointposttype_pt4_check == 1){
        	  $labels = array(
        		'name' => ''.$setup3_pointposttype_pt4.'',
        		'singular_name' => ''.$setup3_pointposttype_pt4.'',
        		'search_items' =>  sprintf(esc_html__( 'Search %s', 'pointfindert2d' ),$setup3_pointposttype_pt4),
        		'popular_items' => sprintf(esc_html__( 'Popular %s', 'pointfindert2d' ),$setup3_pointposttype_pt4),
        		'all_items' => sprintf(esc_html__( 'All %s', 'pointfindert2d' ),$setup3_pointposttype_pt4),
        		'parent_item' => null,
        		'parent_item_colon' => null,
        		'edit_item' => sprintf(esc_html__( 'Edit %s', 'pointfindert2d' ),$setup3_pointposttype_pt4s),
        		'update_item' => sprintf(esc_html__( 'Update %s', 'pointfindert2d' ),$setup3_pointposttype_pt4s),
        		'add_new_item' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),$setup3_pointposttype_pt4s),
        		'new_item_name' => sprintf(esc_html__( 'New %s', 'pointfindert2d' ),$setup3_pointposttype_pt4s),
        		'separate_items_with_commas' => sprintf(esc_html__( 'Separate %s with commas', 'pointfindert2d' ),$setup3_pointposttype_pt4),
        		'add_or_remove_items' => sprintf(esc_html__( 'Add or remove %s', 'pointfindert2d' ),$setup3_pointposttype_pt4s),
        		'choose_from_most_used' => sprintf(esc_html__( 'Choose from the most used %s', 'pointfindert2d' ),$setup3_pointposttype_pt4s),
        		'menu_name' => ''.$setup3_pointposttype_pt4.'',
        	  );

        	  register_taxonomy('pointfinderitypes',''.$setup3_pointposttype_pt1.'',array(
                'show_in_nav_menus' => true,
        		'hierarchical' => true,
        		'labels' => $labels,
        		'show_ui' => true,
        		'show_admin_column' => true,
        		'update_count_callback' => '_update_post_term_count',
        		'query_var' => true,
        		'rewrite' => array( 'slug' => $setup3_pointposttype_pt4p,'hierarchical'=>true),
        		'sort' => true,
        	  ));
        }
    /**
    *End: Item Types Taxonomy
    **/

    /**
    *Start: Locations Taxonomy
    **/
        if($setup3_pointposttype_pt5_check == 1){
        	  $labels = array(
        		'name' => ''.$setup3_pointposttype_pt5.'',
        		'singular_name' => ''.$setup3_pointposttype_pt5.'',
        		'search_items' =>  sprintf(esc_html__( 'Search %s', 'pointfindert2d' ),$setup3_pointposttype_pt5),
        		'popular_items' => sprintf(esc_html__( 'Popular %s', 'pointfindert2d' ),$setup3_pointposttype_pt5),
        		'all_items' => sprintf(esc_html__( 'All %s', 'pointfindert2d' ),$setup3_pointposttype_pt5),
        		'parent_item' => null,
        		'parent_item_colon' => null,
        		'edit_item' => sprintf(esc_html__( 'Edit %s', 'pointfindert2d' ),$setup3_pointposttype_pt5s),
        		'update_item' => sprintf(esc_html__( 'Update %s', 'pointfindert2d' ),$setup3_pointposttype_pt5s),
        		'add_new_item' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),$setup3_pointposttype_pt5s),
        		'new_item_name' => sprintf(esc_html__( 'New %s', 'pointfindert2d' ),$setup3_pointposttype_pt5s),
        		'separate_items_with_commas' => sprintf(esc_html__( 'Separate %s with commas', 'pointfindert2d' ),$setup3_pointposttype_pt5),
        		'add_or_remove_items' => sprintf(esc_html__( 'Add or remove %s', 'pointfindert2d' ),$setup3_pointposttype_pt5s),
        		'choose_from_most_used' => sprintf(esc_html__( 'Choose from the most used %s', 'pointfindert2d' ),$setup3_pointposttype_pt5s),
        		'menu_name' => ''.$setup3_pointposttype_pt5.'',
        	  );

        	  register_taxonomy('pointfinderlocations',''.$setup3_pointposttype_pt1.'',array(
        		'hierarchical' => true,
        		'labels' => $labels,
        		'show_ui' => true,
        		'show_admin_column' => false,
                'show_in_nav_menus' => true,
        		'update_count_callback' => '_update_post_term_count',
        		'query_var' => true,
        		'rewrite' => array( 'slug' => $setup3_pointposttype_pt5p,'hierarchical'=>true ),
        	  ));

        }
    /**
    *End: Locations Taxonomy
    **/

    /**
    *Start: Features Taxonomy
    **/

        if($setup3_pointposttype_pt6_check == 1){
        	  $labels = array(
        		'name' => ''.$setup3_pointposttype_pt6.'',
        		'singular_name' => ''.$setup3_pointposttype_pt6.'',
        		'search_items' =>  sprintf(esc_html__( 'Search %s', 'pointfindert2d' ),$setup3_pointposttype_pt6),
        		'popular_items' => sprintf(esc_html__( 'Popular %s', 'pointfindert2d' ),$setup3_pointposttype_pt6),
        		'all_items' => sprintf(esc_html__( 'All %s', 'pointfindert2d' ),$setup3_pointposttype_pt6),
        		'parent_item' => null,
        		'parent_item_colon' => null,
        		'edit_item' => sprintf(esc_html__( 'Edit %s', 'pointfindert2d' ),$setup3_pointposttype_pt6s),
        		'update_item' => sprintf(esc_html__( 'Update %s', 'pointfindert2d' ),$setup3_pointposttype_pt6s),
        		'add_new_item' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),$setup3_pointposttype_pt6s),
        		'new_item_name' => sprintf(esc_html__( 'New %s', 'pointfindert2d' ),$setup3_pointposttype_pt6s),
        		'separate_items_with_commas' => sprintf(esc_html__( 'Separate %s with commas', 'pointfindert2d' ),$setup3_pointposttype_pt6),
        		'add_or_remove_items' => sprintf(esc_html__( 'Add or remove %s', 'pointfindert2d' ),$setup3_pointposttype_pt6s),
        		'choose_from_most_used' => sprintf(esc_html__( 'Choose from the most used %s', 'pointfindert2d' ),$setup3_pointposttype_pt6s),
        		'menu_name' => ''.$setup3_pointposttype_pt6.'',
        	  );

        	  register_taxonomy('pointfinderfeatures',''.$setup3_pointposttype_pt1.'',array(
        		'hierarchical' => true,
        		'labels' => $labels,
        		'show_ui' => true,
        		'show_admin_column' => false,
                'show_in_nav_menus' => true,
        		'update_count_callback' => '_update_post_term_count',
        		'query_var' => true,
        		'rewrite' => array( 'slug' => $setup3_pointposttype_pt6p,'hierarchical'=>true ),
        	  ));

        	}

    /**
    *End: Features Taxonomy
    **/

    /**
    *Start: Conditions Taxonomy
    **/

        if($setup3_pt14_check == 1){
              $labels = array(
                'name' => ''.$setup3_pt14.'',
                'singular_name' => ''.$setup3_pt14.'',
                'search_items' =>  sprintf(esc_html__( 'Search %s', 'pointfindert2d' ),$setup3_pt14),
                'popular_items' => sprintf(esc_html__( 'Popular %s', 'pointfindert2d' ),$setup3_pt14),
                'all_items' => sprintf(esc_html__( 'All %s', 'pointfindert2d' ),$setup3_pt14),
                'parent_item' => null,
                'parent_item_colon' => null,
                'edit_item' => sprintf(esc_html__( 'Edit %s', 'pointfindert2d' ),$setup3_pt14s),
                'update_item' => sprintf(esc_html__( 'Update %s', 'pointfindert2d' ),$setup3_pt14s),
                'add_new_item' => sprintf(esc_html__( 'Add New %s', 'pointfindert2d' ),$setup3_pt14s),
                'new_item_name' => sprintf(esc_html__( 'New %s', 'pointfindert2d' ),$setup3_pt14s),
                'separate_items_with_commas' => sprintf(esc_html__( 'Separate %s with commas', 'pointfindert2d' ),$setup3_pt14),
                'add_or_remove_items' => sprintf(esc_html__( 'Add or remove %s', 'pointfindert2d' ),$setup3_pt14s),
                'choose_from_most_used' => sprintf(esc_html__( 'Choose from the most used %s', 'pointfindert2d' ),$setup3_pt14s),
                'menu_name' => ''.$setup3_pt14.'',
              );

              register_taxonomy('pointfinderconditions',''.$setup3_pointposttype_pt1.'',array(
                'hierarchical' => true,
                'labels' => $labels,
                'show_ui' => true,
                'show_admin_column' => false,
                'show_in_nav_menus' => true,
                'update_count_callback' => '_update_post_term_count',
                'query_var' => true,
                'rewrite' => array( 'slug' => $setup3_pt14p,'hierarchical'=>true ),
              ));

            }

    /**
    *End: Conditions Taxonomy
    **/

}

/* Disable parent selection for conditions */
add_action('init', 'create_post_type_pointfinder',0);

add_action( 'admin_head-edit-tags.php', 'pfconditions_remove_parent_category' );

function pfconditions_remove_parent_category()
{
    if ( 'pointfinderconditions' != $_GET['taxonomy'] )
        return;

    $parent = 'parent()';

    if ( isset( $_GET['action'] ) )
        $parent = 'parent().parent()';

    ?>
        <script type="text/javascript">
            jQuery(document).ready(function($)
            {
                $('label[for=parent]').<?php echo $parent; ?>.remove();
            });
        </script>
    <?php
}

/**
*Start: Post Type Column Filters
**/
    /*Start:Added with v1.6.2*/
    add_action('admin_menu', 'pointfinder_remove_submenu_cpts');
    function pointfinder_remove_submenu_cpts() {
        global $submenu;
        unset($submenu['edit.php?post_type=pointfinderinvoices'][10]);
        unset($submenu['edit.php?post_type=pointfindermorders'][10]);
        unset($submenu['edit.php?post_type=pointfinderorders'][10]);
        unset($submenu['edit.php?post_type=pointfinderreviews'][10]);
    }

    add_action('admin_head', 'pointfinder_remove_unwanted_cpts');
    function pointfinder_remove_unwanted_cpts(){
        $screen = get_current_screen();
        $setup3_pointposttype_pt11 = PFSAIssetControl('setup3_pointposttype_pt11','','testimonials');

        if (isset($screen->post_type)) {
            switch ($screen->post_type) {
                case 'pointfinderorders':
                    echo '<style type="text/css">#titlediv{margin-bottom: 10px;}.row-actions .view {display:none;}.wrap .page-title-action{display:none;}</style>';
                    break;
                case 'pointfindermorders':
                    echo '<style type="text/css">#titlediv{margin-bottom: 10px;}.row-actions .view {display:none;}.wrap .page-title-action{display:none;}</style>';
                    break;
                case 'pointfinderreviews':
                    echo '<style type="text/css">#titlediv{margin-bottom: 10px;}#edit-slug-box{display: none;}#favorite-actions {display:none;}.wrap .page-title-action{display:none;}.tablenav .bulkactions{display:none;}</style>';
                    break;
                case $setup3_pointposttype_pt11:
                    echo '<style type="text/css">#edit-slug-box{display: none;}</style>';
                    break;
            }
        }

    };

    function pointfinder_remove_unwanted_pra($actions, $page_object){
        global $post;
        $setup3_pointposttype_pt11 = PFSAIssetControl('setup3_pointposttype_pt11','','testimonials');
        $setup3_pointposttype_pt1 = PFSAIssetControl('setup3_pointposttype_pt1','','pfitemfinder');

        switch ($page_object->post_type) {
            case 'pointfindermorders':
            case 'pointfinderorders':
            case 'pointfinderinvoices':
                unset($actions['edit']);unset($actions['inline hide-if-no-js']);unset($actions['edit_as_new_draft']);
                break;
            case 'pointfinderreviews':
                unset($actions['view']);
                unset($actions['inline hide-if-no-js']);
                unset($actions['edit_as_new_draft']);
                unset( $actions['trash'] );
                $actions['trash'] = "<a class='submitdelete' title='" . esc_attr(esc_html__('Delete this item permanently','pointfindert2d')) . "' href='" . get_delete_post_link($post->ID, '', true) . "'>" . esc_html__('Delete','pointfindert2d') . "</a>";
                if ($post->post_status == 'pendingapproval') {
                    $actions['view'] = "<a class='submitdelete' title='" . esc_attr(esc_html__('Publish this item permanently','pointfindert2d')) . "' href='" . admin_url("edit.php?post_type=pointfinderreviews&publishrevid=".$post->ID) . "'>" . esc_html__('Publish','pointfindert2d') . "</a>";
                }
                break;
            case $setup3_pointposttype_pt11:
                unset($actions['view']);
                break;
            case $setup3_pointposttype_pt1:
                unset($actions['inline hide-if-no-js']);
                if ($post->post_status == 'pendingapproval' || $post->post_status == 'pendingpayment') {
                    $actions['inline'] = "<a class='submitdelete' title='" . esc_attr(esc_html__('Publish this item permanently','pointfindert2d')) . "' href='" . admin_url("edit.php?post_type=".$setup3_pointposttype_pt1."&publishitemid=".$post->ID) . "'>" . esc_html__('Publish','pointfindert2d') . "</a>";
                }
                break;
        }
        return $actions;
    }
    add_filter('page_row_actions', 'pointfinder_remove_unwanted_pra', 10, 2);

    function pointfinder_unwanted_remove_meta_box($post_type) {
        $setup3_pointposttype_pt1 = PFSAIssetControl('setup3_pointposttype_pt1','','pfitemfinder');

        switch ($post_type) {
            case 'pfmembershippacks':
                remove_meta_box( 'mymetabox_revslider_0', 'pfmembershippacks', 'normal' );
                break;
            case 'pointfinderorders':
                remove_meta_box( 'submitdiv', 'pointfinderorders','side');
                remove_meta_box( 'slugdiv', 'pointfinderorders','normal');
                remove_meta_box( 'mymetabox_revslider_0', 'pointfinderorders', 'normal' );
                break;
            case 'pointfindermorders':
                remove_meta_box( 'submitdiv', 'pointfindermorders','side');
                remove_meta_box( 'slugdiv', 'pointfindermorders','normal');
                remove_meta_box( 'mymetabox_revslider_0', 'pointfindermorders', 'normal' );
                break;
            case $setup3_pointposttype_pt1:
                remove_meta_box( 'mymetabox_revslider_0', $setup3_pointposttype_pt1, 'normal' );
                break;
            case 'pointfinderreviews':
                remove_meta_box( 'submitdiv', 'pointfinderreviews','side');
                remove_meta_box( 'slugdiv', 'pointfinderreviews','normal');
                remove_meta_box( 'mymetabox_revslider_0', 'pointfinderreviews', 'normal' );
                break;
            case 'pointfinderinvoices':
                remove_meta_box( 'submitdiv', 'pointfinderinvoices','side');
                remove_meta_box( 'slugdiv', 'pointfinderinvoices','normal');
                remove_meta_box( 'mymetabox_revslider_0', 'pointfinderinvoices', 'normal' );
                break;
        }
    }
    add_action( 'add_meta_boxes', 'pointfinder_unwanted_remove_meta_box', 10,1);
    /*End:Added with v1.6.2*/

    get_template_part('admin/estatemanagement/ptfilters/pfitems-pt','filters');
    get_template_part('admin/estatemanagement/ptfilters/review-pt','filters');
    get_template_part('admin/estatemanagement/ptfilters/orders-pt','filters');
    get_template_part('admin/estatemanagement/ptfilters/invoices-pt','filters');
/**
*End: Post Type Column Filters
**/

/**
*Start: Post Type Listing Page Works
**/

    add_action( 'admin_head-edit.php', 'pointfinder_admin_head_custompost_listing' );
    function pointfinder_admin_head_custompost_listing() {
        global $post_type;

        /* Main post type filters */
        $setup3_pointposttype_pt1 = PFSAIssetControl('setup3_pointposttype_pt1','','pfitemfinder');
        if($post_type == $setup3_pointposttype_pt1){
            $setup3_pointposttype_pt4_check = PFSAIssetControl('setup3_pointposttype_pt4_check','','1');
            $setup3_pointposttype_pt5_check = PFSAIssetControl('setup3_pointposttype_pt5_check','','1');
            $pftaxarray = array('pointfinderltypes');
            if($setup3_pointposttype_pt4_check == 1){$pftaxarray[] = 'pointfinderitypes';}
            if($setup3_pointposttype_pt5_check == 1){$pftaxarray[] = 'pointfinderlocations';}
            require_once( get_template_directory().'/admin/estatemanagement/taxonomy-filter-class.php');
            new Tax_CTP_Filter(array($setup3_pointposttype_pt1 => $pftaxarray));

            /* One click item approval */
            if (isset($_GET['publishitemid']) && current_user_can( 'activate_plugins' )) {
               if (!empty($_GET['publishitemid'])) {
                    $itemid = sanitize_text_field($_GET['publishitemid']);
                    if (get_post_status($itemid) != 'publish') {
                        wp_update_post(array('ID' => $itemid, 'post_status' => 'publish'));
                    }
               }
            }

        }

        /* One click review approval */
        if ($post_type == 'pointfinderreviews') {
            if (isset($_GET['publishrevid']) && current_user_can( 'activate_plugins' )) {
               if (!empty($_GET['publishrevid'])) {
                    $revid = sanitize_text_field($_GET['publishrevid']);
                    if (get_post_status($revid) != 'publish') {
                        wp_update_post(array('ID' => $revid, 'post_status' => 'publish'));
                    }
               }
            }
        }

    }

    /* Additional Filters
    add_action( 'admin_head-post.php', 'pointfinder_admin_head_post_editing' );
    add_action( 'admin_head-post-new.php',  'pointfinder_admin_head_post_new' );

    function pointfinder_admin_head_post_editing() {
        //edit
    }

    function pointfinder_admin_head_post_new() {
      //edit
    }
    */

/**
*End: Post Type Listing Page Works
**/

?>


text:
//
// NeuroLoopGain Library
// Library containing helper classes used to implement the NeuroLoopGain analysis.
//
// Copyright 2012 Marco Roessen
//
//   Licensed under the Apache License, Version 2.0 (the "License");
//   you may not use this file except in compliance with the License.
//   You may obtain a copy of the License at
//
//       http://www.apache.org/licenses/LICENSE-2.0
//
//   Unless required by applicable law or agreed to in writing, software
//   distributed under the License is distributed on an "AS IS" BASIS,
//   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
//   See the License for the specific language governing permissions and
//   limitations under the License.

using System;
using System.Diagnostics;

namespace NeuroLoopGainLibrary.Edf
{
  public class EdfFile : EdfFileBase
  {
		#region public properties

    public override short[] DataBuffer
    {
      get { return _dataBuffer ?? (_dataBuffer = CreateDataBuffer()); }
    }

		#endregion public properties

		#region public methods

    public static bool IsValidFile(string filename, bool doStrictChecking = false)
    {
      try
      {
        EdfFile edf = new EdfFile(filename,true,false,doStrictChecking,false) {CheckVersionOnOpen = true};
        return edf.ValidFormat;
      }
      catch (Exception)
      {
        return false;
      }
    }

		#endregion public methods

    #region Constructors
    public EdfFile() { }

    public EdfFile(string aFileName, bool doOpenReadOnly, bool doUseMemoryStream, bool doStrictChecking, bool doOpen)
    {
      FileName = aFileName;
      OpenReadOnly = doOpenReadOnly;
      UseMemoryStream = doUseMemoryStream;
      StrictChecking = doStrictChecking;
      if (doOpen)
        Active = true;
    }
    #endregion

    #region Protected members

    protected int _currentDataBlock;
    protected short[] _dataBuffer;

    protected override void DoDataBufferSizeChanged()
    {
      base.DoDataBufferSizeChanged();
      _dataBuffer = CreateDataBuffer();
    }

    #endregion

    #region Public members
    public override void ReadDataBlock(int blockNr)
    {
      base.ReadDataBlock(blockNr);
      Debug.Assert(DataBuffer != null, "Databuffer not initialized");
      if (!DoReadDataBlock(blockNr, ref _dataBuffer))
        throw new DataFileReadDataException(DataFileConsts.DataFileReadData);
    }

    public override void WriteDataBlock(int blockNr)
    {
      base.WriteDataBlock(blockNr);
      Debug.Assert(DataBuffer != null, "Databuffer not initialized");
      if (!DoWriteDataBlock(blockNr, DataBuffer))
        throw new DataFileWriteDataException(DataFileConsts.DataFileWriteData);
    }
    #endregion

    #region Properties
    public int CurrentDataBlock { get { return _currentDataBlock; } }

    public new OpenStreamEvent OnOpenStream
    {
      get { return base.OnOpenStream; }
      set { base.OnOpenStream = value; }
    }

    public new bool StrictChecking
    {
      get { return base.StrictChecking; }
      set { base.StrictChecking = value; }
    }
    #endregion
  }
}


text:
<?php
/**
 * This file is part of BraincraftedBootstrapBundle.
 *
 * (c) 2012-2013 by Florian Eckerstorfer
 */

namespace Braincrafted\Bundle\BootstrapBundle\Twig;

use Twig_Extension;
use Twig_SimpleFunction;

/**
 * BootstrapLabelExtension
 *
 * @category   TwigExtension
 * @package    BraincraftedBootstrapBundle
 * @subpackage Twig
 * @author     Florian Eckerstorfer <florian@eckerstorfer.co>
 * @copyright  2012-2013 Florian Eckerstorfer
 * @license    http://opensource.org/licenses/MIT The MIT License
 * @link       http://bootstrap.braincrafted.com Bootstrap for Symfony2
 */
class BootstrapLabelExtension extends Twig_Extension
{
    /**
     * {@inheritDoc}
     */
    public function getFunctions()
    {
        $options = array('pre_escape' => 'html', 'is_safe' => array('html'));

        return array(
            new Twig_SimpleFunction('label', array($this, 'labelFunction'), $options),
            new Twig_SimpleFunction('label_primary', array($this, 'labelPrimaryFunction'), $options),
            new Twig_SimpleFunction('label_success', array($this, 'labelSuccessFunction'), $options),
            new Twig_SimpleFunction('label_info', array($this, 'labelInfoFunction'), $options),
            new Twig_SimpleFunction('label_warning', array($this, 'labelWarningFunction'), $options),
            new Twig_SimpleFunction('label_danger', array($this, 'labelDangerFunction'), $options)
        );
    }

    /**
     * Returns the HTML code for a label.
     *
     * @param string $text The text of the label
     * @param string $type The type of label
     *
     * @return string The HTML code of the label
     */
    public function labelFunction($text, $type = 'default')
    {
        return sprintf('%s', ($type ? ' label-' . $type : ''), $text);
    }

    /**
     * @param string $text
     *
     * @return string
     */
    public function labelPrimaryFunction($text)
    {
        return $this->labelFunction($text, 'primary');
    }

    /**
     * Returns the HTML code for a success label.
     *
     * @param string $text The text of the label
     *
     * @return string The HTML code of the label
     */
    public function labelSuccessFunction($text)
    {
        return $this->labelFunction($text, 'success');
    }

    /**
     * Returns the HTML code for a warning label.
     *
     * @param string $text The text of the label
     *
     * @return string The HTML code of the label
     */
    public function labelWarningFunction($text)
    {
        return $this->labelFunction($text, 'warning');
    }

    /**
     * Returns the HTML code for a important label.
     *
     * @param string $text The text of the label
     *
     * @return string The HTML code of the label
     */
    public function labelDangerFunction($text)
    {
        return $this->labelFunction($text, 'danger');
    }

    /**
     * Returns the HTML code for a info label.
     *
     * @param string $text The text of the label
     *
     * @return string The HTML code of the label
     */
    public function labelInfoFunction($text)
    {
        return $this->labelFunction($text, 'info');
    }

    /**
     * {@inheritDoc}
     */
    public function getName()
    {
        return 'braincrafted_bootstrap_label';
    }
}


text:
package com.sdl.odata.parser

import com.sdl.odata.api.parser._

import scala.util.parsing.combinator.RegexParsers

trait ResourcePathParser extends RegexParsers {
  this: NamesAndIdentifiersParser with LiteralsParser with EntityDataModelHelpers =>

  def resourcePath: Parser[ResourcePath] =
    entitySetResourcePath | singletonEntityResourcePath | operationImportCall | crossjoin | all

  // Resource path that starts at an entity set
  def entitySetResourcePath: Parser[EntitySetPath] = entitySetName into {
    entitySetName =>
      val entityTypeName = getEntitySetTypeName(entitySetName).get
      (opt(collectionNavigation(entityTypeName)) ^^ { case subPath => EntitySetPath(entitySetName, subPath) })
        .withFailureMessage(s"The URI contains an invalid path into the entity set: $entitySetName")
  }

  // Resource path that starts at a singleton entity
  def singletonEntityResourcePath: Parser[SingletonPath] = singletonEntity into {
    singletonName =>
      val entityTypeName = getSingletonTypeName(singletonName).get
      (opt(singleNavigation(entityTypeName)) ^^ { case subPath => SingletonPath(singletonName, subPath) })
        .withFailureMessage(s"The URI contains an invalid path into the singleton: $entitySetName")
  }

  // A path into a collection of entities
  def collectionNavigation(contextTypeName: String): Parser[EntityCollectionPath] =
    opt("/" ~> qualifiedEntityTypeName.withFailureMessage("The URI contains an invalid path into a collection of entities")) into {
      derivedTypeNameOpt =>
        val entityTypeName = derivedTypeNameOpt.getOrElse(contextTypeName)

        // The filter here is to make the parser fail when it matches empty input
        (opt(collectionNavPath(entityTypeName)) filter { case path => derivedTypeNameOpt.isDefined || path.isDefined }) ^^ {
          case subPath => EntityCollectionPath(derivedTypeNameOpt, subPath)
        }
    }

  // Path used in collectionNavigation
  def collectionNavPath(contextTypeName: String): Parser[PathSegment] =
    keyPredicatePathSegment(contextTypeName) | collectionPath(contextTypeName) | ref

  // A key predicate path into a collection of entities
  def keyPredicatePathSegment(contextTypeName: String): Parser[KeyPredicatePath] =
    keyPredicate(contextTypeName) ~ opt(singleNavigation(contextTypeName)) ^^ {
      case keyPredicate ~ subPath => KeyPredicatePath(keyPredicate, subPath)
    }

  def keyPredicate(contextTypeName: String): Parser[KeyPredicate] = simpleKey | compoundKey(contextTypeName)

  def simpleKey: Parser[SimpleKeyPredicate] = "(" ~> primitiveLiteral <~ ")" ^^ SimpleKeyPredicate

  def compoundKey(contextTypeName: String): Parser[CompoundKeyPredicate] =
    "(" ~> rep1sep(keyValuePair(contextTypeName), ",") <~ ")" ^^ {
      case values => CompoundKeyPredicate(values.toMap)
    }

  def keyValuePair(contextTypeName: String): Parser[(String, Literal)] =
    (primitiveKeyProperty(contextTypeName) | keyPropertyAlias(contextTypeName)) ~ ("=" ~> primitiveLiteral) ^^ {
      case key ~ value => (key, value)
    }

  // Note: Check that alias is a valid key property alias for the relevant entity type
  def keyPropertyAlias(contextTypeName: String): Parser[String] = odataIdentifier

  // A path into a single entity
  def singleNavigation(contextTypeName: String): Parser[EntityPath] =
    opt("/" ~> qualifiedEntityTypeName.withFailureMessage("The URI contains an invalid path into an entity")) into {
      derivedTypeNameOpt =>
        val entityTypeName = derivedTypeNameOpt.getOrElse(contextTypeName)

        // The filter here is to make the parser fail when it matches empty input
        (opt(singleNavPath(entityTypeName)) filter { case path => derivedTypeNameOpt.isDefined || path.isDefined }) ^^ {
          case subPath => EntityPath(derivedTypeNameOpt, subPath)
        }
    }

  // Path used in singleNavigation
  def singleNavPath(contextTypeName: String): Parser[PathSegment] =
    ("/" ~> propertyPath(contextTypeName)) | ("/" ~> boundOperation(contextTypeName)) | ref | value

  // A path from a single entity or complex object to a property of that entity or complex object
  def propertyPath(contextTypeName: String): Parser[PropertyPath] =
    (entityNavPropertyPath(contextTypeName) | entityColNavPropertyPath(contextTypeName) |
    complexPropertyPath(contextTypeName) | complexColPropertyPath(contextTypeName) |
    primitivePropertyPath(contextTypeName) | primitiveColPropertyPath(contextTypeName) |
    streamPropertyPath(contextTypeName))
      .withFailureMessage("The URI contains an invalid path to a property of an entity or complex object")

  // A path to a navigation property; the type of the navigation property is a singular entity type (not a collection)
  def entityNavPropertyPath(contextTypeName: String): Parser[PropertyPath] =
    entityNavigationProperty(contextTypeName) into {
      propertyName =>
        val propertyTypeName = getSinglePropertyTypeName(contextTypeName, propertyName).get
        opt(singleNavigation(propertyTypeName)) ^^ { case subPath => PropertyPath(propertyName, subPath) }
    }

  // A path to a navigation property, the type of the navigation property is a collection of an entity type
  def entityColNavPropertyPath(contextTypeName: String): Parser[PropertyPath] =
    entityColNavigationProperty(contextTypeName) into {
      propertyName =>
        val propertyElementTypeName = getPropertyElementTypeName(contextTypeName, propertyName).get
        opt(collectionNavigation(propertyElementTypeName)) ^^ { case subPath => PropertyPath(propertyName, subPath) }
    }

  // A path to a property; the type of the property is a singular complex type (not a collection)
  def complexPropertyPath(contextTypeName: String): Parser[PropertyPath] =
    complexProperty(contextTypeName) into {
      propertyName =>
        val propertyTypeName = getSinglePropertyTypeName(contextTypeName, propertyName).get
        opt(complexPath(propertyTypeName)) ^^ { case subPath => PropertyPath(propertyName, subPath) }
    }

  // A path to a property; the type of the property is a collection of a complex type
  def complexColPropertyPath(contextTypeName: String): Parser[PropertyPath] =
    complexColProperty(contextTypeName) into {
      propertyName =>
        val propertyElementTypeName = getPropertyElementTypeName(contextTypeName, propertyName).get
        opt(collectionPath(propertyElementTypeName)) ^^ { case subPath => PropertyPath(propertyName, subPath) }
    }

  // A path to a property; the type of the property is a singular primitive type (not a collection)
  def primitivePropertyPath(contextTypeName: String): Parser[PropertyPath] =
    primitiveProperty(contextTypeName) into {
      propertyName =>
        val propertyTypeName = getSinglePropertyTypeName(contextTypeName, propertyName).get
        opt(singlePath(propertyTypeName)) ^^ { case subPath => PropertyPath(propertyName, subPath) }
    }

  // A path to a property; the type of the property is a collection of a primitive type
  def primitiveColPropertyPath(contextTypeName: String): Parser[PropertyPath] =
    primitiveColProperty(contextTypeName) into {
      propertyName =>
        val propertyElementTypeName = getPropertyElementTypeName(contextTypeName, propertyName).get
        opt(collectionPath(propertyElementTypeName)) ^^ { case subPath => PropertyPath(propertyName, subPath) }
    }

  // A path to a property; the property is a stream property
  def streamPropertyPath(contextTypeName: String): Parser[PropertyPath] =
    streamProperty(contextTypeName) into {
      propertyName =>
        // Note: What is the property type in case of a stream property?
        opt(boundOperation("TODO.TODO")) ^^ { case subPath => PropertyPath(propertyName, subPath) }
    }

  // A path into a collection of complex objects or primitive values
  def collectionPath(contextTypeName: String): Parser[PathSegment] = count | "/" ~> boundOperation(contextTypeName)

  // A path into a single primitive value
  def singlePath(contextTypeName: String): Parser[PathSegment] = value | boundOperation(contextTypeName)

  // A path into a single complex object
  def complexPath(contextTypeName: String): Parser[ComplexPath] =
    opt("/" ~> qualifiedComplexTypeName) into {
      derivedTypeNameOpt =>
        val complexTypeName = derivedTypeNameOpt.getOrElse(contextTypeName)

        (("/" ~> propertyPath(complexTypeName)) | ("/" ~> boundOperation(complexTypeName))) ^^ {
          case subPath => ComplexPath(derivedTypeNameOpt, Some(subPath))
        }
    }

  def count: Parser[CountPath.type] = "/$count" ^^^ CountPath

  def ref: Parser[RefPath.type] = "/$ref" ^^^ RefPath

  def value: Parser[ValuePath.type] = "/$value" ^^^ ValuePath

  // Call to an imported operation (an operation is an action or a function)
  def operationImportCall: Parser[OperationImportCall] = actionImportCall | functionImportCall

  // Call to an imported action
  def actionImportCall: Parser[ActionImportCall] = actionImport ^^ ActionImportCall

  // Call to an imported function
  def functionImportCall: Parser[FunctionImportCall] = entityFunctionImportCall | entityColFunctionImportCall |
    complexFunctionImportCall | complexColFunctionImportCall | primitiveFunctionImportCall

  def generalFunctionImportCall(pathSegmentParser: String => Parser[PathSegment]): Parser[FunctionImportCall] = functionImport into {
    functionImportName =>
      opt(functionParameters) ~ opt(pathSegmentParser(getFunctionImportReturnType(functionImportName).get)) ^^ {
        case args ~ subPath => FunctionImportCall(functionImportName, args, subPath)
      }
  }

  // Call to an imported function that returns a single entity
  def entityFunctionImportCall: Parser[FunctionImportCall] = generalFunctionImportCall(singleNavigation)

  // Call to an imported function that returns a collection of entities
  def entityColFunctionImportCall: Parser[FunctionImportCall] = generalFunctionImportCall(collectionNavigation)

  // Call to an imported function that returns a single complex object
  def complexFunctionImportCall: Parser[FunctionImportCall] = generalFunctionImportCall(complexPath)

  // Call to an imported function that returns a collection of complex objects
  // Call to an imported function that returns a collection of primitive values
  def complexColFunctionImportCall: Parser[FunctionImportCall] = generalFunctionImportCall(collectionPath)

  // Call to an imported function that returns a single primitive value
  def primitiveFunctionImportCall: Parser[FunctionImportCall] = generalFunctionImportCall(singlePath)

  // Call to a bound operation (an operation is an action or a function)
  def boundOperation(contextTypeName: String): Parser[BoundOperationCallPath] =
    boundActionCall(contextTypeName) | boundFunctionCall(contextTypeName)

  // Call to a bound action
  def boundActionCall(contextTypeName: String): Parser[BoundActionCallPath] = namespace ~ action ^^ {
    case ns ~ actionName => BoundActionCallPath(ns + actionName)
  }

  // Call to a bound function
  def boundFunctionCall(contextTypeName: String): Parser[BoundFunctionCallPath] = boundEntityFuncCall(contextTypeName) |
    boundEntityColFuncCall(contextTypeName) | boundComplexFuncCall(contextTypeName) |
    boundComplexColFuncCall(contextTypeName) | boundPrimitiveFuncCall(contextTypeName)

  def generalBoundFunctionCall(pathSegmentParser: String => Parser[PathSegment]): Parser[BoundFunctionCallPath] = namespace into {
    namespaceName =>
      function into {
        functionName =>
          opt(functionParameters) ~ opt(pathSegmentParser(getFunctionReturnType(functionName).get)) ^^ {
            case args ~ subPath => BoundFunctionCallPath(namespaceName + functionName, args, subPath)
          }
      }
  }

  // Call to a bound function that returns a single entity
  def boundEntityFuncCall(contextTypeName: String): Parser[BoundFunctionCallPath] = generalBoundFunctionCall(singleNavigation)

  // Call to a bound function that returns a collection of entities
  def boundEntityColFuncCall(contextTypeName: String): Parser[BoundFunctionCallPath] = generalBoundFunctionCall(collectionNavigation)

  // Call to a bound function that returns a single complex object
  def boundComplexFuncCall(contextTypeName: String): Parser[BoundFunctionCallPath] = generalBoundFunctionCall(complexPath)

  // Call to a bound function that returns a collection of complex objects
  // Call to a bound function that returns a collection of primitive values
  def boundComplexColFuncCall(contextTypeName: String): Parser[BoundFunctionCallPath] = generalBoundFunctionCall(collectionPath)

  // Call to a bound function that returns a single primitive value
  def boundPrimitiveFuncCall(contextTypeName: String): Parser[BoundFunctionCallPath] = generalBoundFunctionCall(singlePath)

  def functionParameters: Parser[Map[String, FunctionParam]] =
    "(" ~> repsep(functionParameter, ",") <~ ")" ^^ { case params => params.toMap }

  def functionParameter: Parser[(String, FunctionParam)] =
    odataIdentifier ~ ("=" ~> (aliasFunctionParam | literalFunctionParam)) ^^ { case name ~ param => (name, param) }

  def aliasFunctionParam: Parser[AliasFunctionParam] = "@" ~> odataIdentifier ^^ AliasFunctionParam

  def literalFunctionParam: Parser[LiteralFunctionParam] = primitiveLiteral ^^ LiteralFunctionParam

  // Crossjoin resource path
  def crossjoin: Parser[CrossJoinPath] =
    "$crossjoin(" ~> rep1sep(entitySetName, ",") <~ ")" ^^ CrossJoinPath

  // All resource path
  def all: Parser[AllPath.type] = "$all" ^^^ AllPath

  // Determine the type that a resource path resolves to
  def resolveResourcePathTypeName(resourcePath: ResourcePath): String = resourcePath match {
    case EntitySetPath(entitySetName, subPath) =>
      resolvePathSegmentTypeName(getEntitySetTypeName(entitySetName).get, subPath)

    case SingletonPath(singletonName, subPath) =>
      resolvePathSegmentTypeName(getSingletonTypeName(singletonName).get, subPath)

    case ActionImportCall(actionName) =>
      // Note: Determine the type that the action resolves to
      "UNKNOWN.UNKNOWN"

    case FunctionImportCall(functionName, args, subPath) =>
      // Note: Determine the type that the function resolves to
      resolvePathSegmentTypeName("UNKNOWN.UNKNOWN", subPath)

    case CrossJoinPath(entitySetNames) =>
      // Note: This is hard, because this doesn't resolve to a type name. Instead, query options must address types by
      // starting with one of the entity set names mentioned in the crossjoin. Like this:
      //
      //    http://host/service/$crossjoin(Products,Sales)?$filter=Products/ID eq Sales/ProductID
      //
      // See OData Version 4.0 Part 2: URL Conventions paragraph 4.11
      // NOTE: This syntax is not in the OData ABNF syntax! That seems to be an error in the ABNF specification.
      "UNKNOWN.UNKNOWN"

    case AllPath =>
      // Note: Similar problem as with CrossJoinPath.
      "UNKNOWN.UNKNOWN"
  }

  def resolvePathSegmentTypeName(contextTypeName: String, pathSegment: Option[PathSegment]): String =
    pathSegment match {
      case Some(EntityCollectionPath(derivedTypeName, subPath)) =>
        resolvePathSegmentTypeName(derivedTypeName.getOrElse(contextTypeName), subPath)

      case Some(KeyPredicatePath(_, subPath)) =>
        resolvePathSegmentTypeName(contextTypeName, subPath)

      case Some(EntityPath(derivedTypeName, subPath)) =>
        resolvePathSegmentTypeName(derivedTypeName.getOrElse(contextTypeName), subPath)

      case Some(ComplexPath(derivedTypeName, subPath)) =>
        resolvePathSegmentTypeName(derivedTypeName.getOrElse(contextTypeName), subPath)

      case Some(PropertyPath(propertyName, subPath)) =>
        val subPathContextTypeName = getSinglePropertyTypeName(contextTypeName, propertyName)
          .orElse(getPropertyElementTypeName(contextTypeName, propertyName)).get
        resolvePathSegmentTypeName(subPathContextTypeName, subPath)

      case Some(CountPath) => contextTypeName
      case Some(RefPath) => contextTypeName
      case Some(ValuePath) => contextTypeName

      case Some(BoundActionCallPath(actionName)) =>
        // Note: Determine the type that the action resolves to
        "UNKNOWN.UNKNOWN"

      case Some(BoundFunctionCallPath(functionName, args, subPath)) =>
        // Note: Determine the type that the function resolves to
        resolvePathSegmentTypeName("UNKNOWN.UNKNOWN", subPath)

      case None => contextTypeName
    }
}


text:
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
  <component name="ProjectModuleManager">
    <modules>
      <module fileurl="file://$PROJECT_DIR$/Kontact.iml" filepath="$PROJECT_DIR$/Kontact.iml" />
      <module fileurl="file://$PROJECT_DIR$/kontact/kontact.iml" filepath="$PROJECT_DIR$/kontact/kontact.iml" />
      <module fileurl="file://$PROJECT_DIR$/kontact-rxjava/kontact-rxjava.iml" filepath="$PROJECT_DIR$/kontact-rxjava/kontact-rxjava.iml" />
      <module fileurl="file://$PROJECT_DIR$/kontact-rxjava2/kontact-rxjava2.iml" filepath="$PROJECT_DIR$/kontact-rxjava2/kontact-rxjava2.iml" />
      <module fileurl="file://$PROJECT_DIR$/sample/sample.iml" filepath="$PROJECT_DIR$/sample/sample.iml" />
    </modules>
  </component>
</project>


text:
/********************************
 ** Widget Theme: ac20ac para IE6
 ** Base Color: #ac20ac
 *******************************/
#popcard.dialog .content,
#popcard.dialog .t,
#popcard.dialog .b,
#popcard.dialog .b div {
	_background: none;
}

#popcard.dialog .content .wrapper_pink {
	/* IE */
	_height: 1px; /* Para que se active isLayout y se acomode */
	_padding:23px 12px 20px 0px;
	_background: none;
	_background-image: expression(
        this.style.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + Popego.Env.baseUrl + "/images/widget/card_background_ac20ac.png', sizingMethod='scale')"
    );
}


text:
/**
 * <!-- Package description. -->
 * Contains bootstrap aggregation (bagging) trainer allowing to combine some other trainers and return a bagged version of them.
 */
package org.apache.ignite.ml.composition.bagging;


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

<TITLE>
PropertyIDMap (POI API Documentation)
</TITLE>

<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">

      Overview
      Package
    Class
      Use
      Tree
      Deprecated
      Index
      Help

 PREV CLASS
 NEXT CLASS

  FRAMES
 NO FRAMES

  All Classes

  SUMMARY: NESTED | FIELD | CONSTR | METHOD

DETAIL: FIELD | CONSTR | METHOD

org.apache.poi.hpsf.wellknown

Class PropertyIDMap

java.lang.Object
  java.util.AbstractMap<K,V>
      java.util.HashMap<java.lang.Long,java.lang.String>
          org.apache.poi.hpsf.wellknown.PropertyIDMap

All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, java.util.Map<java.lang.Long,java.lang.String>

public class PropertyIDMap
extends java.util.HashMap<java.lang.Long,java.lang.String>

This is a dictionary which maps property ID values to property
 ID strings.

The methods getSummaryInformationProperties() and getDocumentSummaryInformationProperties() return singleton PropertyIDMaps. An application that wants to extend these maps
 should treat them as unmodifiable, copy them and modifiy the
 copies.

Author:

Rainer Klute <klute@rainer-klute.de>

See Also:
Serialized Form

Nested Class Summary

Nested classes/interfaces inherited from class java.util.AbstractMap

java.util.AbstractMap.SimpleEntry<K,V>, java.util.AbstractMap.SimpleImmutableEntry<K,V>

Field Summary

static int
PID_APPNAME

          ID of the property that denotes the application that created the
 document

static int
PID_AUTHOR

          ID of the property that denotes the document's author

static int
PID_BYTECOUNT

          Number of bytes.

static int
PID_CATEGORY

          The entry is a string denoting the category the file belongs
 to, e.g.

static int
PID_CCHWITHSPACES

          The entry specifies an estimate of the number of characters
  in the document, including whitespace, as an integer

static int
PID_CHARCOUNT

          ID of the property that denotes the number of characters in the
 document

static int
PID_CODEPAGE

          The entry denotes a code page.

static int
PID_COMMENTS

          ID of the property that denotes the document's comments

static int
PID_COMPANY

          This entry contains the company name.

static int
PID_CONTENTSTATUS

          This entry contains a string of the document status.

static int
PID_CONTENTTYPE

          This entry contains a string of the content type of the file.

static int
PID_CREATE_DTM

          ID of the property that denotes the date and time the document was
 created.

static int
PID_DICTIONARY

          The entry is a dictionary.

static int
PID_DIGSIG

          This entry contains the VBA digital signature for the VBA project
  embedded in the document.

static int
PID_DOCPARTS

          This entry contains the names of document parts (word: names
 of the documents in the master document, excel: sheet names,
 power point: slide titles, binder: document names).

static int
PID_DOCVERSION

          This entry contains a string of the document version, but
  normally should be empty

static int
PID_EDITTIME

          ID of the property that denotes the document's edit time

static int
PID_HEADINGPAIR

          This entry denotes an internally used property.

static int
PID_HIDDENCOUNT

          Number of hidden slides.

static int
PID_HYPERLINKSCHANGED

          This entry contains a boolean which marks if the User Defined
  Property Set has been updated outside of the Application, if so the
  hyperlinks should be updated on document load.

static int
PID_KEYWORDS

          ID of the property that denotes the document's keywords

static int
PID_LANGUAGE

          This entry contains a string of the document language, but
  normally should be empty.

static int
PID_LASTAUTHOR

          ID of the property that denotes the document's last author

static int
PID_LASTPRINTED

          ID of the property that denotes the date and time the document was
 last printed

static int
PID_LASTSAVE_DTM

          ID of the property that denotes the date and time the document was
 saved

static int
PID_LINECOUNT

          Number of lines.

static int
PID_LINKSDIRTY

          If this entry is -1 the links are dirty and should be
 re-evaluated.

static int
PID_MANAGER

          This entry contains the name of the project manager.

static int
PID_MAX

          The highest well-known property ID.

static int
PID_MMCLIPCOUNT

          Number of multimedia clips, e.g.

static int
PID_NOTECOUNT

          Number of slides with notes.

static int
PID_PAGECOUNT

          ID of the property that denotes the number of pages in the
 document

static int
PID_PARCOUNT

          Number of paragraphs.

static int
PID_PRESFORMAT

          Target format for power point presentation, e.g.

static int
PID_REVNUMBER

          ID of the property that denotes the document's revision number

static int
PID_SCALE

          This entry is set to -1 when scaling of the thumbnail is
 desired.

static int
PID_SECURITY

          ID of the property that denotes whether read/write access to the
 document is allowed or whether is should be opened as read-only.

static int
PID_SLIDECOUNT

          Number of slides in a power point presentation.

static int
PID_SUBJECT

          ID of the property that denotes the document's subject

static int
PID_TEMPLATE

          ID of the property that denotes the document's template

static int
PID_THUMBNAIL

          ID of the property that denotes the document's thumbnail

static int
PID_TITLE

          ID of the property that denotes the document's title

static int
PID_VERSION

          This entry contains the version of the Application which wrote the
  Property set, stored with the two high order bytes having the major
  version number, and the two low order bytes the minor version number.

static int
PID_WORDCOUNT

          ID of the property that denotes the number of words in the
 document

Constructor Summary

PropertyIDMap(int initialCapacity,
              float loadFactor)

          Creates a PropertyIDMap.

PropertyIDMap(java.util.Map<java.lang.Long,java.lang.String> map)

          Creates a PropertyIDMap backed by another map.

Method Summary

 java.lang.Object
get(long id)

          Gets the ID string for an ID from the PropertyIDMap.

static PropertyIDMap
getDocumentSummaryInformationProperties()

          Returns the Document Summary Information properties
 singleton.

static PropertyIDMap
getSummaryInformationProperties()

static void
main(java.lang.String[] args)

          For the most basic testing.

 java.lang.Object
put(long id,
    java.lang.String idString)

          Puts a ID string for an ID into the PropertyIDMap.

Methods inherited from class java.util.HashMap

clear, clone, containsKey, containsValue, entrySet, get, isEmpty, keySet, put, putAll, remove, size, values

Methods inherited from class java.util.AbstractMap

equals, hashCode, toString

Methods inherited from class java.lang.Object

finalize, getClass, notify, notifyAll, wait, wait, wait

Methods inherited from interface java.util.Map

equals, hashCode

Field Detail

PID_TITLE

public static final int PID_TITLE

ID of the property that denotes the document's title

See Also:
Constant Field Values

PID_SUBJECT

public static final int PID_SUBJECT

ID of the property that denotes the document's subject

See Also:
Constant Field Values

PID_AUTHOR

public static final int PID_AUTHOR

ID of the property that denotes the document's author

See Also:
Constant Field Values

PID_KEYWORDS

public static final int PID_KEYWORDS

ID of the property that denotes the document's keywords

See Also:
Constant Field Values

PID_COMMENTS

public static final int PID_COMMENTS

ID of the property that denotes the document's comments

See Also:
Constant Field Values

PID_TEMPLATE

public static final int PID_TEMPLATE

ID of the property that denotes the document's template

See Also:
Constant Field Values

PID_LASTAUTHOR

public static final int PID_LASTAUTHOR

ID of the property that denotes the document's last author

See Also:
Constant Field Values

PID_REVNUMBER

public static final int PID_REVNUMBER

ID of the property that denotes the document's revision number

See Also:
Constant Field Values

PID_EDITTIME

public static final int PID_EDITTIME

ID of the property that denotes the document's edit time

See Also:
Constant Field Values

PID_LASTPRINTED

public static final int PID_LASTPRINTED

ID of the property that denotes the date and time the document was
 last printed

See Also:
Constant Field Values

PID_CREATE_DTM

public static final int PID_CREATE_DTM

ID of the property that denotes the date and time the document was
 created.

See Also:
Constant Field Values

PID_LASTSAVE_DTM

public static final int PID_LASTSAVE_DTM

ID of the property that denotes the date and time the document was
 saved

See Also:
Constant Field Values

PID_PAGECOUNT

public static final int PID_PAGECOUNT

ID of the property that denotes the number of pages in the
 document

See Also:
Constant Field Values

PID_WORDCOUNT

public static final int PID_WORDCOUNT

ID of the property that denotes the number of words in the
 document

See Also:
Constant Field Values

PID_CHARCOUNT

public static final int PID_CHARCOUNT

ID of the property that denotes the number of characters in the
 document

See Also:
Constant Field Values

PID_THUMBNAIL

public static final int PID_THUMBNAIL

ID of the property that denotes the document's thumbnail

See Also:
Constant Field Values

PID_APPNAME

public static final int PID_APPNAME

ID of the property that denotes the application that created the
 document

See Also:
Constant Field Values

PID_SECURITY

public static final int PID_SECURITY

ID of the property that denotes whether read/write access to the
 document is allowed or whether is should be opened as read-only. It can
 have the following values:

Value

Description

0

No restriction

2

Read-only recommended

4

Read-only enforced

See Also:
Constant Field Values

PID_DICTIONARY

public static final int PID_DICTIONARY

The entry is a dictionary.

See Also:
Constant Field Values

PID_CODEPAGE

public static final int PID_CODEPAGE

The entry denotes a code page.

See Also:
Constant Field Values

PID_CATEGORY

public static final int PID_CATEGORY

The entry is a string denoting the category the file belongs
 to, e.g. review, memo, etc. This is useful to find documents of
 same type.

See Also:
Constant Field Values

PID_PRESFORMAT

public static final int PID_PRESFORMAT

Target format for power point presentation, e.g. 35mm,
 printer, video etc.

See Also:
Constant Field Values

PID_BYTECOUNT

public static final int PID_BYTECOUNT

Number of bytes.

See Also:
Constant Field Values

PID_LINECOUNT

public static final int PID_LINECOUNT

Number of lines.

See Also:
Constant Field Values

PID_PARCOUNT

public static final int PID_PARCOUNT

Number of paragraphs.

See Also:
Constant Field Values

PID_SLIDECOUNT

public static final int PID_SLIDECOUNT

Number of slides in a power point presentation.

See Also:
Constant Field Values

PID_NOTECOUNT

public static final int PID_NOTECOUNT

Number of slides with notes.

See Also:
Constant Field Values

PID_HIDDENCOUNT

public static final int PID_HIDDENCOUNT

Number of hidden slides.

See Also:
Constant Field Values

PID_MMCLIPCOUNT

public static final int PID_MMCLIPCOUNT

Number of multimedia clips, e.g. sound or video.

See Also:
Constant Field Values

PID_SCALE

public static final int PID_SCALE

This entry is set to -1 when scaling of the thumbnail is
 desired. Otherwise the thumbnail should be cropped.

See Also:
Constant Field Values

PID_HEADINGPAIR

public static final int PID_HEADINGPAIR

This entry denotes an internally used property. It is a
 vector of variants consisting of pairs of a string (VT_LPSTR)
 and a number (VT_I4). The string is a heading name, and the
 number tells how many document parts are under that
 heading.

See Also:
Constant Field Values

PID_DOCPARTS

public static final int PID_DOCPARTS

This entry contains the names of document parts (word: names
 of the documents in the master document, excel: sheet names,
 power point: slide titles, binder: document names).

See Also:
Constant Field Values

PID_MANAGER

public static final int PID_MANAGER

This entry contains the name of the project manager.

See Also:
Constant Field Values

PID_COMPANY

public static final int PID_COMPANY

This entry contains the company name.

See Also:
Constant Field Values

PID_LINKSDIRTY

public static final int PID_LINKSDIRTY

If this entry is -1 the links are dirty and should be
 re-evaluated.

See Also:
Constant Field Values

PID_CCHWITHSPACES

public static final int PID_CCHWITHSPACES

The entry specifies an estimate of the number of characters
  in the document, including whitespace, as an integer

See Also:
Constant Field Values

PID_HYPERLINKSCHANGED

public static final int PID_HYPERLINKSCHANGED

This entry contains a boolean which marks if the User Defined
  Property Set has been updated outside of the Application, if so the
  hyperlinks should be updated on document load.

See Also:
Constant Field Values

PID_VERSION

public static final int PID_VERSION

This entry contains the version of the Application which wrote the
  Property set, stored with the two high order bytes having the major
  version number, and the two low order bytes the minor version number.

See Also:
Constant Field Values

PID_DIGSIG

public static final int PID_DIGSIG

This entry contains the VBA digital signature for the VBA project
  embedded in the document.

See Also:
Constant Field Values

PID_CONTENTTYPE

public static final int PID_CONTENTTYPE

This entry contains a string of the content type of the file.

See Also:
Constant Field Values

PID_CONTENTSTATUS

public static final int PID_CONTENTSTATUS

This entry contains a string of the document status.

See Also:
Constant Field Values

PID_LANGUAGE

public static final int PID_LANGUAGE

This entry contains a string of the document language, but
  normally should be empty.

See Also:
Constant Field Values

PID_DOCVERSION

public static final int PID_DOCVERSION

This entry contains a string of the document version, but
  normally should be empty

See Also:
Constant Field Values

PID_MAX

public static final int PID_MAX

The highest well-known property ID. Applications are free to use
  higher values for custom purposes. (This value is based on Office 12,
  earlier versions of Office had lower values)

See Also:
Constant Field Values

Constructor Detail

PropertyIDMap

public PropertyIDMap(int initialCapacity,
                     float loadFactor)

Creates a PropertyIDMap.

Parameters:
initialCapacity - The initial capacity as defined for
 HashMap
loadFactor - The load factor as defined for HashMap

PropertyIDMap

public PropertyIDMap(java.util.Map<java.lang.Long,java.lang.String> map)

Creates a PropertyIDMap backed by another map.

Parameters:
map - The instance to be created is backed by this map.

Method Detail

put

public java.lang.Object put(long id,
                            java.lang.String idString)

Puts a ID string for an ID into the PropertyIDMap.

Parameters:
id - The ID.
idString - The ID string.

Returns:
As specified by the Map interface, this method
 returns the previous value associated with the specified
 <var>id</var>, or null if there was no mapping for
 key.

get

public java.lang.Object get(long id)

Gets the ID string for an ID from the PropertyIDMap.

Parameters:
id - The ID.

Returns:
The ID string associated with <var>id</var>.

getSummaryInformationProperties

public static PropertyIDMap getSummaryInformationProperties()

Returns:
the Summary Information properties singleton

getDocumentSummaryInformationProperties

public static PropertyIDMap getDocumentSummaryInformationProperties()

Returns the Document Summary Information properties
 singleton.

Returns:
The Document Summary Information properties singleton.

main

public static void main(java.lang.String[] args)

For the most basic testing.

Parameters:
args - The command-line arguments

      Overview
      Package
    Class
      Use
      Tree
      Deprecated
      Index
      Help

 PREV CLASS
 NEXT CLASS

  FRAMES
 NO FRAMES

  All Classes

  SUMMARY: NESTED | FIELD | CONSTR | METHOD

DETAIL: FIELD | CONSTR | METHOD

                Copyright 2016 The Apache Software Foundation or
        its licensors, as applicable.


text:
"""
Copyright (C) 2017 Open Source Robotics Foundation

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
"""

from geometry.latlon import LatLon

from builders import OsmCityBuilder
from builders import ProceduralCityBuilder
from builders import SimpleCityBuilder
from city_generation_process import CityGenerationProcess

import argparse
import sys
import os

# For the time being we use an arbitrary (lat, lon) as the origin
RNDF_ORIGIN = LatLon(10, 65)

parser = argparse.ArgumentParser()

# The builder class
parser.add_argument('-b',
                    '--builder',
                    required=True,
                    help='class name of the builder to invoke')
# The output file
parser.add_argument('-d',
                    '--destination',
                    default='generated_worlds/',
                    help='destination file name')
# Extra named parameters passed to the builder when creating it
parser.add_argument('-p',
                    '--parameters',
                    nargs='*',
                    default='',
                    help='extra parameters to pass to the builder. Must be \
                    formatted as <key>=<value> pairs')
# Extra named parameters passed to the builder when creating it
parser.add_argument('-x',
                    '--debug',
                    action='store_true',
                    help='Generates extra output files, useful for debugging')

arguments = parser.parse_args()

# Get the base path to generate the different files (join to make sure it has
# a trailing slash)
base_path = os.path.join(arguments.destination, '')

# Get the class of the builder to use
builders_list = [
    OsmCityBuilder,
    ProceduralCityBuilder,
    SimpleCityBuilder
]
assert(arguments.builder in [x.__name__ for x in builders_list])
builder_class = getattr(sys.modules[__name__], arguments.builder)

# Get the remaining parameters to pass to the builder as <key>=<value> pairs
# as a dictionary
builder_parameters = dict(pair.split('=', 1) for pair in arguments.parameters)

# Make sure size is an integer
if 'size' in builder_parameters:
    builder_parameters['size'] = int(builder_parameters['size'])

# Create the builder instance. Unpack the parameter dictionary to be used as
# keyword parameters
builder = builder_class(**builder_parameters)

process = CityGenerationProcess(builder, RNDF_ORIGIN, base_path, arguments.debug)
process.run()


text:
using System;
using System.Collections;
using System.Collections.Generic;
using OpenTK.Graphics.OpenGL;

namespace csgl {
  public enum TextureType {
    TEXTURE0,
    TEXTURE1,
    TEXTURE2,
    TEXTURE3,
  };

  public class Texture: IDisposable {
    public Resource resource;
    private string name;
    private int _descriptor;
    public static Dictionary< TextureType, string > TextureType2uniformName = new Dictionary< TextureType, string >();

    public int descriptor {
      get { return this._descriptor; }
      private set { this.descriptor = value; }
    }

    private Texture() {
      this._descriptor = 0;
    }

    public unsafe Texture( string setName, Image image ) {
      this.name = setName;
      this._descriptor = GL.GenTexture();
      GL.BindTexture( TextureTarget.Texture2D, this.descriptor );
      GL.TexParameter( TextureTarget.Texture2D, TextureParameterName.TextureMagFilter, ( int ) TextureMagFilter.Nearest );
      GL.TexParameter( TextureTarget.Texture2D, TextureParameterName.TextureMinFilter, ( int ) TextureMinFilter.Nearest );
      fixed( byte *rawImage = image.GetRawPointer() ) {
        GL.TexImage2D( TextureTarget.Texture2D, 0, PixelInternalFormat.Rgba, image.width, image.height, 0, PixelFormat.Rgba, PixelType.UnsignedByte, ( IntPtr ) rawImage );
      }
      GL.BindTexture( TextureTarget.Texture2D, 0 );
    }

    public void Bind( TextureTarget target = TextureTarget.Texture2D ) {
      Console.WriteLine( "bind texture {0} = {1}", this.name, this.descriptor );
      GL.BindTexture( target, this.descriptor );
    }

    static public void BindNull( TextureTarget target = TextureTarget.Texture2D ) {
      GL.BindTexture( target, 0 );
    }

    ~Texture() {
      this.Dispose( true );
    }

    public void Dispose() {
      this.Dispose( true );
      GC.SuppressFinalize( this );
    }

    protected virtual void Dispose( bool disposing ) {
      if( disposing ) {
        if( this.descriptor != 0 ) {
          Console.WriteLine( "~Texture {0}", this.name );
          GL.DeleteTexture( this.descriptor );
          this._descriptor = 0;
          if( this.resource != null ) {
            this.resource.Dispose();
            this.resource = null;
          }
          Console.WriteLine( "~Texture {0} done", this.name );
        }
      }
    }

    public override String ToString() {
      return string.Format( "texture:%s", this.name );
    }
  }
}


text:
'use strict';

module.exports = function(app) {
	var users = require('../../app/controllers/users.server.controller');
	var processes = require('../../app/controllers/processes.server.controller');

	// Processes Routes
	app.route('/processes')
		.get(processes.list)
		.post(users.requiresLogin, processes.create);

	app.route('/processes/:processId')
		.get(processes.read)
		.put(users.requiresLogin, processes.hasAuthorization, processes.update)
		.delete(users.requiresLogin, processes.hasAuthorization, processes.delete);

	// Finish by binding the Process middleware
	app.param('processId', processes.processByID);
};


text:
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif /* HAVE_CONFIG_H */

#include <string.h>
#include <errno.h>
#include <stdlib.h>

#include "tre.h"
#include "tre-internal.h"
#include "xmalloc.h"

int
tre_regncomp(regex_t *preg, const char *regex, size_t n, int cflags)
{
  int ret;
#if TRE_WCHAR
  tre_char_t *wregex;
  size_t wlen;

  wregex = xmalloc(sizeof(tre_char_t) * (n + 1));
  if (wregex == NULL)
    return REG_ESPACE;

  /* If the current locale uses the standard single byte encoding of
     characters, we don't do a multibyte string conversion.  If we did,
     many applications which use the default locale would break since
     the default "C" locale uses the 7-bit ASCII character set, and
     all characters with the eighth bit set would be considered invalid. */
#if TRE_MULTIBYTE
  if (TRE_MB_CUR_MAX == 1)
#endif /* TRE_MULTIBYTE */
    {
      unsigned int i;
      const unsigned char *str = (const unsigned char *)regex;
      tre_char_t *wstr = wregex;

      for (i = 0; i < n; i++)
	*(wstr++) = *(str++);
      wlen = n;
    }
#if TRE_MULTIBYTE
  else
    {
      int consumed;
      tre_char_t *wcptr = wregex;
#ifdef HAVE_MBSTATE_T
      mbstate_t state;
      memset(&state, '\0', sizeof(state));
#endif /* HAVE_MBSTATE_T */
      while (n > 0)
	{
	  consumed = tre_mbrtowc(wcptr, regex, n, &state);

	  switch (consumed)
	    {
	    case 0:
	      if (*regex == '\0')
		consumed = 1;
	      else
		{
		  xfree(wregex);
		  return REG_BADPAT;
		}
	      break;
	    case -1:
	      DPRINT(("mbrtowc: error %d: %s.\n", errno, strerror(errno)));
	      xfree(wregex);
	      return REG_BADPAT;
	    case -2:
	      /* The last character wasn't complete.  Let's not call it a
		 fatal error. */
	      consumed = n;
	      break;
	    }
	  regex += consumed;
	  n -= consumed;
	  wcptr++;
	}
      wlen = wcptr - wregex;
    }
#endif /* TRE_MULTIBYTE */

  wregex[wlen] = L'\0';
  ret = tre_compile(preg, wregex, wlen, cflags);
  xfree(wregex);
#else /* !TRE_WCHAR */
  ret = tre_compile(preg, (const tre_char_t *)regex, n, cflags);
#endif /* !TRE_WCHAR */

  return ret;
}

int
tre_regcomp(regex_t *preg, const char *regex, int cflags)
{
  return tre_regncomp(preg, regex, regex ? strlen(regex) : 0, cflags);
}

#ifdef TRE_WCHAR
int
tre_regwncomp(regex_t *preg, const wchar_t *regex, size_t n, int cflags)
{
  return tre_compile(preg, regex, n, cflags);
}

int
tre_regwcomp(regex_t *preg, const wchar_t *regex, int cflags)
{
  return tre_compile(preg, regex, regex ? wcslen(regex) : 0, cflags);
}
#endif /* TRE_WCHAR */

void
tre_regfree(regex_t *preg)
{
  tre_free(preg);
}

/* EOF */