text:
<!DOCTYPE html>

		<title>Sutra CMS: Quickstart Theme</title>

		<meta name="description" content="Your description">
		<meta name="keywords" content="Your,Keywords">
		<meta name="author" content="ResponsiveWebInc">

		<meta name="viewport" content="width=device-width, initial-scale=1.0">
		<link href='http://fonts.googleapis.com/css?family=Open+Sans:400,600,700' rel='stylesheet' type='text/css'>
		<link href='http://fonts.googleapis.com/css?family=Lobster+Two' rel='stylesheet' type='text/css'>

		<link href='http://fonts.googleapis.com/css?family=Droid+Serif:400,400italic' rel='stylesheet' type='text/css'>

		<link href="css/bootstrap.min.css" rel="stylesheet">

		<link href="css/font-awesome.min.css" rel="stylesheet">

		<link href="css/style.css" rel="stylesheet">

		<link rel="shortcut icon" href="#">

Quickstart .

							Home
							About
							Blog
							Contact

Blog.

Sed justo  ut constur scelerisque

								 23-8-2013
								 Admin

								 General

									 2 COMMENTS

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum pellentesque suscipit metus nec blandit. Praesent consectetur feugiat eros eu rhoncus. Phasellus mattis tortor ac nisl pretium, in molestie lectus adipiscing. Nulla in scelerisque enim, sed lobortis nunc. Nullam porttitor porttitor leo at interdum. Aliquam erat volutpat. Nullam nec lectus ligula. Integer ligula tellus, placerat id gravida nec, venenatis ac arcu.

Etiam sapien ante, condimentum in libero a, hendrerit commodo urna. Aliquam interdum risus vel pharetra consectetur. Fusce congue mollis commodo. Nullam a nunc gravida, lacinia ipsum at, interdum augue. Morbi sed turpis rhoncus, fringilla lectus in, cursus lacus. Praesent sed sollicitudin est, scelerisque facilisis massa.

Sharing

2 Comments

Ashok

Commented on 25/12/2012

Nulla facilisi. Sed justo dui, scelerisque ut consectetur vel, eleifend id erat. Phasellus condimentum rutrum aliquet. Quisque eu consectetur erat.

Ashok

Commented on 25/12/2012

Nulla facilisi. Sed justo dui, scelerisque ut consectetur vel, eleifend id erat. Phasellus condimentum rutrum aliquet. Quisque eu consectetur erat.

Post Reply

                                   <form class="form-horizontal" role="form">

                                         Name

											   <input type="text" class="form-control" id="name">

                                         Email

											   <input type="text" class="form-control" id="email">

                                         Website

											   <input type="text" class="form-control" id="website">

                                         Comment

											   <textarea class="form-control" id="comment" rows="3"></textarea>

                                         <button type="submit" class="btn btn-primary">Submit</button>
                                         <button type="reset" class="btn btn-default">Reset</button>

                                   </form>

« Previous Post

Next Post »

Recent Post

Etiam adipiscing posuere justo, nec iaculis justo dictum non

Etiam adipiscing posuere justo, nec iaculis justo dictum non

Aenean ullamcorper justo tincidunt justo aliquet et lobortis diam faucibus

Maecenas hendrerit neque id ante dictum mattis

Maecenas hendrerit neque id ante dictum mattis

About

Nullam porttitor porttitor leo at interdum. Aliquam erat volutpat. Nullam nec lectus ligula. Integer ligula tellus, placerat id gravida nec, venenatis ac arcu.

Phasellus

							Nullam pharetra nec

							Vulputate vitae

							Phasellus

Pulvinar

							Aliquam nec

							Nam pulvinar massa

							Maecenas fringilla nec

Commodo

							Consectetur adipiscing elit

							Commodo a fermentum vel

							Eleifend neque

Start

							Pellentesque

							Startups

							Habitasse platea dictumst

							© 2013 Quickstart - A default Sutra CMS theme.


text:
<?php
namespace Elastica\Test;

use Elastica\Document;
use Elastica\Query;
use Elastica\ResultSet;
use Elastica\ScanAndScroll;
use Elastica\Search;
use Elastica\Test\Base as BaseTest;

class ScanAndScrollTest extends BaseTest
{
    /**
     * Full foreach test.
     *
     * @group functional
     */
    public function testForeach()
    {
        $scanAndScroll = new ScanAndScroll($this->_prepareSearch(), '1m', 2);
        $docCount = 0;

        /** @var ResultSet $resultSet */
        foreach ($scanAndScroll as $scrollId => $resultSet) {
            $docCount += $resultSet->count();
        }

        /*
         * number of loops and documents per iteration may fluctuate
         * => only test end results
         */
        $this->assertEquals(12, $docCount);
    }

    /**
     * query size revert options.
     *
     * @group functional
     */
    public function testQuerySizeRevert()
    {
        $search = $this->_prepareSearch();
        $search->getQuery()->setSize(9);

        $scanAndScroll = new ScanAndScroll($search);

        $scanAndScroll->rewind();
        $this->assertEquals(9, $search->getQuery()->getParam('size'));

        $scanAndScroll->next();
        $this->assertEquals(9, $search->getQuery()->getParam('size'));
    }

    /**
     * index: 12 docs, 2 shards.
     *
     * @return Search
     */
    private function _prepareSearch()
    {
        $index = $this->_createIndex('', true, 2);
        $index->refresh();

        $docs = [];
        for ($x = 1; $x <= 12; ++$x) {
            $docs[] = new Document($x, ['id' => $x, 'key' => 'value']);
        }

        $type = $index->getType('scanAndScrollTest');
        $type->addDocuments($docs);
        $index->refresh();

        $search = new Search($this->_getClient());
        $search->addIndex($index)->addType($type);

        return $search;
    }
}

redpajama_set_name: RedPajamaGithub


text:
package com.linkedin.thirdeye.bootstrap.topkrollup.phase2;

import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
import java.io.DataInputStream;
import java.io.DataOutputStream;
import java.io.IOException;

import com.linkedin.thirdeye.api.MetricSchema;
import com.linkedin.thirdeye.api.MetricTimeSeries;

public class TopKRollupPhaseTwoMapOutputValue {

  String dimensionValue;
  MetricTimeSeries series;

  public TopKRollupPhaseTwoMapOutputValue(String dimensionValue, MetricTimeSeries series) {

    this.dimensionValue = dimensionValue;
    this.series = series;
  }

  public MetricTimeSeries getSeries() {
    return series;
  }

  public String getDimensionValue() {
    return dimensionValue;
  }

  public byte[] toBytes() throws IOException {

    ByteArrayOutputStream baos = new ByteArrayOutputStream();
    DataOutputStream dos = new DataOutputStream(baos);
    byte[] bytes;
    // dimension value
    bytes = dimensionValue.getBytes();
    dos.writeInt(bytes.length);
    dos.write(bytes);
    // series
    bytes = series.toBytes();
    dos.writeInt(bytes.length);
    dos.write(bytes);

    baos.close();
    dos.close();
    return baos.toByteArray();
  }

  public static TopKRollupPhaseTwoMapOutputValue fromBytes(byte[] buffer, MetricSchema schema) throws IOException {
    DataInputStream dis = new DataInputStream(new ByteArrayInputStream(buffer));
    int length;
    byte[] bytes;
    // dimension value
    length = dis.readInt();
    bytes = new byte[length];
    dis.read(bytes);
    String dimensionValue = new String(bytes);
    // series
    length = dis.readInt();
    bytes = new byte[length];
    dis.read(bytes);
    MetricTimeSeries series = MetricTimeSeries.fromBytes(bytes, schema);

    TopKRollupPhaseTwoMapOutputValue wrapper;
    wrapper = new TopKRollupPhaseTwoMapOutputValue(dimensionValue, series);
    return wrapper;
  }

}


text:
<?xml version="1.0" encoding="utf-8"?>
<doctrine-mapping xmlns="http://doctrine-project.org/schemas/orm/doctrine-mapping" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://doctrine-project.org/schemas/orm/doctrine-mapping http://doctrine-project.org/schemas/orm/doctrine-mapping.xsd">
  <entity name="ShcpAboPostProced" table="shcp_abo_post_proced">
    <indexes>
      <index name="IDX_CA15838BCDD53299" columns="id_admin_proceden"/>
    </indexes>
    <id name="id" type="integer" column="id">
      <generator strategy="SEQUENCE"/>
    </id>
    <field name="postpFechaFin" type="date" column="postp_fecha_fin" nullable="true"/>
    <field name="postProcedimiento" type="time" column="post_procedimiento_" nullable="true"/>
    <field name="postpConsejCuidBas" type="string" column="postp_consej_cuid_bas" nullable="true"/>
    <field name="postpRespCuidBas" type="string" column="postp_resp_cuid_bas" length="30" nullable="true"/>
    <field name="postpConsejSigAlarma" type="string" column="postp_consej_sig_alarma" nullable="true"/>
    <field name="postpRespSigAlarma" type="string" column="postp_resp_sig_alarma" length="30" nullable="true"/>
    <field name="postpConsejAnticon" type="string" column="postp_consej_anticon" nullable="true"/>
    <field name="postpRespAnticon" type="string" column="postp_resp_anticon" length="30" nullable="true"/>
    <field name="postpCitaSeg" type="string" column="postp_cita_seg" nullable="true"/>
    <field name="postpRespCitaSeg" type="string" column="postp_resp_cita_seg" length="30" nullable="true"/>
    <field name="postpFecCtrlSeg" type="date" column="postp_fec_ctrl_seg" nullable="true"/>
    <field name="postpInfeccGeniPelv" type="string" column="postp_infecc_geni_pelv" nullable="true"/>
    <field name="postpDanioOrgPelv" type="string" column="postp_danio_org_pelv" nullable="true"/>
    <field name="postpHemogTardExces" type="string" column="postp_hemog_tard_exces" nullable="true"/>
    <field name="postpShock" type="string" column="postp_shock" nullable="true"/>
    <field name="postpOtraComp" type="string" column="postp_otra_comp" nullable="true"/>
    <field name="postpOtraCompDetalle" type="string" column="postp_otra_comp_detalle" length="30" nullable="true"/>
    <many-to-one field="idAdminProceden" target-entity="ShcpAboAdmisionProceden">
      <join-columns>
        <join-column name="id_admin_proceden" referenced-column-name="id"/>
      </join-columns>
    </many-to-one>
  </entity>
</doctrine-mapping>


text:
title: Plot Data with NPlot
description: How to plot data using NPlot in C# projects
date: 2020-05-15
lastmod: 2022-03-16
weight: 60
---

**NPlot is a charting library for .NET Framework applications.** It can be used to render graphs as Bitmaps (suitable for use in console applications) and it has a mouse-interactive user control for Windows Forms. NPlot is simple, but it lacks many features, and it only targets .NET Framework.

### NPlot is no longer developed
* [NPlot WIKI](http://netcontrols.org/nplot/wiki/index.php) has been inactive since 2014
* [NPlot on GitHub](https://github.com/mhowlett/nplot) has a single commit from 2016
* [NPlot on NuGet](https://www.nuget.org/packages/NPlot/) has a single package uploaded in 2016

## Quickstart

* Get the `NPlot` NuGet package

* Drag a `PlotSurface2D` from the toolbox onto your form

### Sample Data

This code generates random data we can practice plotting

```cs
private Random rand = new Random(0);
private double[] RandomWalk(int points = 5, double start = 100, double mult = 50)
{
    // return an array of difting random numbers
    double[] values = new double[points];
    values[0] = start;
    for (int i = 1; i < points; i++)
        values[i] = values[i - 1] + (rand.NextDouble() - .5) * mult;
    return values;
}
```

### Interactive Line Plot

I found I could display lines of 10,000 points, but by 100,000 points the program became very sluggish.

```cs
// generate some random Y data
int pointCount = 10_000;
double[] ys1 = RandomWalk(pointCount);
double[] ys2 = RandomWalk(pointCount);
double[] ys3 = RandomWalk(pointCount);

// create a line plot containing the data
var linePlot1 = new NPlot.LinePlot { DataSource = ys1, Color = Color.Red };
var linePlot2 = new NPlot.LinePlot { DataSource = ys2, Color = Color.Green };
var linePlot3 = new NPlot.LinePlot { DataSource = ys3, Color = Color.Blue };

// add the line plot to the plot surface (user control)
plotSurface2D1.Clear();
plotSurface2D1.Add(linePlot1);
plotSurface2D1.Add(linePlot2);
plotSurface2D1.Add(linePlot3);
plotSurface2D1.Title = $"Line Plot ({pointCount:n0} points each)";
plotSurface2D1.YAxis1.Label = "Vertical Axis Label";
plotSurface2D1.XAxis1.Label = "Horizontal Axis Label";
plotSurface2D1.Refresh();

// allow the plot to be mouse-interactive
plotSurface2D1.AddInteraction(new NPlot.Windows.PlotSurface2D.Interactions.HorizontalDrag());
plotSurface2D1.AddInteraction(new NPlot.Windows.PlotSurface2D.Interactions.VerticalDrag());
plotSurface2D1.AddInteraction(new NPlot.Windows.PlotSurface2D.Interactions.AxisDrag(true));
```

## Console Application Support

Users who aren't using Windows Forms (or the PlotSurface2D user control) can render directly on `Bitmap` objects using the `Bitmap.PlotSurface2D` class. This allows NPlot to be used in console applications (or in server applications such as ASP.NET)

```cs
var linePlot = new NPlot.PointPlot { DataSource = RandomWalk(20) };
var surface = new NPlot.Bitmap.PlotSurface2D(400, 300);
surface.BackColor = Color.White;
surface.Add(linePlot);
surface.Title = $"Scatter Plot from a Console Application";
surface.YAxis1.Label = "Vertical Axis Label";
surface.XAxis1.Label = "Horizontal Axis Label";
surface.Refresh();
surface.Bitmap.Save("nplot-console-quickstart.png");
```

## WPF Support

NPlot is designed for Windows Forms, but the author noted [it can be used in WPF](http://netcontrols.org/nplot/wiki/index.php?n=Main.WPFNotes) applications too. This seems to be accomplished by rendering plots to Bitmap objects and displaying them in WPF. [WChart](https://github.com/mhowlett/WChart) is a modified version of NPlot designed for WPF, but it hasn't been updated since 2015.

## Resources
* [Creating Graphs and Plot Charts Quickly with NPlot](https://www.oreilly.com/library/view/windows-developer-power/0596527543/ch04s08.html) (O'Reilly)

## Source Code

* [NPlot Quickstart](https://github.com/swharden/Csharp-Data-Visualization/tree/main/dev/old/plotting/nplot/NPlotQuickstart)


text:
#define SWRST SICA_SWRST
#define SYSCR SICA_SYSCR
#define bfin_write_SWRST(val) bfin_write_SICA_SWRST(val)
#define bfin_write_SYSCR(val) bfin_write_SICA_SYSCR(val)

#define WDOG_CNT WDOGA_CNT
#define WDOG_CTL WDOGA_CTL
#define bfin_write_WDOG_CNT(val) bfin_write_WDOGA_CNT(val)
#define bfin_write_WDOG_CTL(val) bfin_write_WDOGA_CTL(val)
#define bfin_write_WDOG_STAT(val) bfin_write_WDOGA_STAT(val)

#include "gpio.h"
#include "portmux.h"
#include "ports.h"

#define BF561_FAMILY 1	/* Linux glue */


text:
#ifndef _EMU2413_H_
#define _EMU2413_H_

#include <stdint.h>

#ifdef __cplusplus
extern "C" {
#endif

#define OPLL_DEBUG 0

enum OPLL_TONE_ENUM { OPLL_2413_TONE = 0, OPLL_VRC7_TONE = 1, OPLL_281B_TONE = 2 };

/* voice data */
typedef struct __OPLL_PATCH {
  uint32_t TL, FB, EG, ML, AR, DR, SL, RR, KR, KL, AM, PM, WS;
} OPLL_PATCH;

/* slot */
typedef struct __OPLL_SLOT {
  uint8_t number;

  /* type flags:
   * 000000SM
   *       |+-- M: 0:modulator 1:carrier
   *       +--- S: 0:normal 1:single slot mode (sd, tom, hh or cym)
   */
  uint8_t type;

  OPLL_PATCH *patch; /* voice parameter */

  /* slot output */
  int32_t output[2]; /* output value, latest and previous. */

  /* phase generator (pg) */
  uint16_t *wave_table; /* wave table */
  uint32_t pg_phase;    /* pg phase */
  uint32_t pg_out;      /* pg output, as index of wave table */
  uint8_t pg_keep;      /* if 1, pg_phase is preserved when key-on */
  uint16_t blk_fnum;    /* (block << 9) | f-number */
  uint16_t fnum;        /* f-number (9 bits) */
  uint8_t blk;          /* block (3 bits) */

  /* envelope generator (eg) */
  uint8_t eg_state;  /* current state */
  int32_t volume;    /* current volume */
  uint8_t key_flag;  /* key-on flag 1:on 0:off */
  uint8_t sus_flag;  /* key-sus option 1:on 0:off */
  uint16_t tll;      /* total level + key scale level*/
  uint8_t rks;       /* key scale offset (rks) for eg speed */
  uint8_t eg_rate_h; /* eg speed rate high 4bits */
  uint8_t eg_rate_l; /* eg speed rate low 2bits */
  uint32_t eg_shift; /* shift for eg global counter, controls envelope speed */
  uint32_t eg_out;   /* eg output */

  uint32_t update_requests; /* flags to debounce update */

#if OPLL_DEBUG
  uint8_t last_eg_state;
#endif
} OPLL_SLOT;

/* mask */
#define OPLL_MASK_CH(x) (1 << (x))
#define OPLL_MASK_HH (1 << (9))
#define OPLL_MASK_CYM (1 << (10))
#define OPLL_MASK_TOM (1 << (11))
#define OPLL_MASK_SD (1 << (12))
#define OPLL_MASK_BD (1 << (13))
#define OPLL_MASK_RHYTHM (OPLL_MASK_HH | OPLL_MASK_CYM | OPLL_MASK_TOM | OPLL_MASK_SD | OPLL_MASK_BD)

/* rate conveter */
typedef struct __OPLL_RateConv {
  int ch;
  double timer;
  double f_ratio;
  int16_t *sinc_table;
  int16_t **buf;
} OPLL_RateConv;

OPLL_RateConv *OPLL_RateConv_new(double f_inp, double f_out, int ch);
void OPLL_RateConv_reset(OPLL_RateConv *conv);
void OPLL_RateConv_putData(OPLL_RateConv *conv, int ch, int16_t data);
int16_t OPLL_RateConv_getData(OPLL_RateConv *conv, int ch);
void OPLL_RateConv_delete(OPLL_RateConv *conv);

typedef struct __OPLL {
  uint32_t clk;
  uint32_t rate;

  uint8_t chip_type;

  uint32_t adr;

  double inp_step;
  double out_step;
  double out_time;

  uint8_t reg[0x40];
  uint8_t test_flag;
  uint32_t slot_key_status;
  uint8_t rhythm_mode;

  uint32_t eg_counter;

  uint32_t pm_phase;
  int32_t am_phase;

  uint8_t lfo_am;

  uint32_t noise;
  uint8_t short_noise;

  int32_t patch_number[9];
  OPLL_SLOT slot[18];
  OPLL_PATCH patch[19 * 2];

  uint8_t pan[16];
  float pan_fine[16][2];

  uint32_t mask;

  /* channel output */
  /* 0..8:tone 9:bd 10:hh 11:sd 12:tom 13:cym */
  int16_t ch_out[14];

  int16_t mix_out[2];

  OPLL_RateConv *conv;
} OPLL;

OPLL *OPLL_new(uint32_t clk, uint32_t rate);
void OPLL_delete(OPLL *);

void OPLL_reset(OPLL *);
void OPLL_resetPatch(OPLL *, uint8_t);

/**
 * Set output wave sampling rate.
 * @param rate sampling rate. If clock / 72 (typically 49716 or 49715 at 3.58MHz) is set, the internal rate converter is
 * disabled.
 */
void OPLL_setRate(OPLL *opll, uint32_t rate);

/**
 * Set internal calcuration quality. Currently no effects, just for compatibility.
 * >= v1.0.0 always synthesizes internal output at clock/72 Hz.
 */
void OPLL_setQuality(OPLL *opll, uint8_t q);

/**
 * Set pan pot (extra function - not YM2413 chip feature)
 * @param ch 0..8:tone 9:bd 10:hh 11:sd 12:tom 13:cym 14,15:reserved
 * @param pan 0:mute 1:right 2:left 3:center
 * ```
 * pan: 76543210
 *            |+- bit 1: enable Left output
 *            +-- bit 0: enable Right output
 * ```
 */
void OPLL_setPan(OPLL *opll, uint32_t ch, uint8_t pan);

/**
 * Set fine-grained panning
 * @param ch 0..8:tone 9:bd 10:hh 11:sd 12:tom 13:cym 14,15:reserved
 * @param pan output strength of left/right channel.
 *            pan[0]: left, pan[1]: right. pan[0]=pan[1]=1.0f for center.
 */
void OPLL_setPanFine(OPLL *opll, uint32_t ch, float pan[2]);

/**
 * Set chip type. If vrc7 is selected, r#14 is ignored.
 * This method not change the current ROM patch set.
 * To change ROM patch set, use OPLL_resetPatch.
 * @param type 0:YM2413 1:VRC7
 */
void OPLL_setChipType(OPLL *opll, uint8_t type);

void OPLL_writeIO(OPLL *opll, uint32_t reg, uint8_t val);
void OPLL_writeReg(OPLL *opll, uint32_t reg, uint8_t val);

/**
 * Calculate one sample
 */
int16_t OPLL_calc(OPLL *opll);

/**
 * Calulate stereo sample
 */
void OPLL_calcStereo(OPLL *opll, int32_t out[2]);

void OPLL_setPatch(OPLL *, const uint8_t *dump);
void OPLL_copyPatch(OPLL *, int32_t, OPLL_PATCH *);

/**
 * Force to refresh.
 * External program should call this function after updating patch parameters.
 */
void OPLL_forceRefresh(OPLL *);

void OPLL_dumpToPatch(const uint8_t *dump, OPLL_PATCH *patch);
void OPLL_patchToDump(const OPLL_PATCH *patch, uint8_t *dump);
void OPLL_getDefaultPatch(int32_t type, int32_t num, OPLL_PATCH *);

/**
 *  Set channel mask
 *  @param mask mask flag: OPLL_MASK_* can be used.
 *  - bit 0..8: mask for ch 1 to 9 (OPLL_MASK_CH(i))
 *  - bit 9: mask for Hi-Hat (OPLL_MASK_HH)
 *  - bit 10: mask for Top-Cym (OPLL_MASK_CYM)
 *  - bit 11: mask for Tom (OPLL_MASK_TOM)
 *  - bit 12: mask for Snare Drum (OPLL_MASK_SD)
 *  - bit 13: mask for Bass Drum (OPLL_MASK_BD)
 */
uint32_t OPLL_setMask(OPLL *, uint32_t mask);

/**
 * Toggler channel mask flag
 */
uint32_t OPLL_toggleMask(OPLL *, uint32_t mask);

/* for compatibility */
#define OPLL_set_rate OPLL_setRate
#define OPLL_set_quality OPLL_setQuality
#define OPLL_set_pan OPLL_setPan
#define OPLL_set_pan_fine OPLL_setPanFine
#define OPLL_calc_stereo OPLL_calcStereo
#define OPLL_reset_patch OPLL_resetPatch
#define OPLL_dump2patch OPLL_dumpToPatch
#define OPLL_patch2dump OPLL_patchToDump
#define OPLL_setChipMode OPLL_setChipType

#ifdef __cplusplus
}
#endif

#endif


text:
package models.dao;

import javax.inject.Singleton;

import models.SecurityRole;
import play.utils.dao.CachedDAO;

@Singleton
public class SecurityRoleDAO extends CachedDAO<Long, SecurityRole> {

	public SecurityRoleDAO() {
		super(Long.class, SecurityRole.class);
	}

}


text:
"""
    Stakeholder engagement API

    This API enables Intelligent Engagement for your Business. iEngage is a platform that combines process, augmented intelligence and rewards to help you intelligently engage customers.

    OpenAPI spec version: 1.0

    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""

from pprint import pformat
from six import iteritems
import re

class Discussion(object):
    """
    NOTE: This class is auto generated by the swagger code generator program.
    Do not edit the class manually.
    """
    def __init__(self, discussion_id=None, user=None, subject=None, description=None, creation_time=None, sentiment=None, sentiment_details=None, sentiment_weightage=None, entity=None):
        """
        Discussion - a model defined in Swagger

        :param dict swaggerTypes: The key is attribute name
                                  and the value is attribute type.
        :param dict attributeMap: The key is attribute name
                                  and the value is json key in definition.
        """
        self.swagger_types = {
            'discussion_id': 'int',
            'user': 'User',
            'subject': 'str',
            'description': 'str',
            'creation_time': 'datetime',
            'sentiment': 'str',
            'sentiment_details': 'Sentiment',
            'sentiment_weightage': 'float',
            'entity': 'list[NER]'
        }

        self.attribute_map = {
            'discussion_id': 'discussionId',
            'user': 'user',
            'subject': 'subject',
            'description': 'description',
            'creation_time': 'creationTime',
            'sentiment': 'sentiment',
            'sentiment_details': 'sentimentDetails',
            'sentiment_weightage': 'sentimentWeightage',
            'entity': 'entity'
        }

        self._discussion_id = discussion_id
        self._user = user
        self._subject = subject
        self._description = description
        self._creation_time = creation_time
        self._sentiment = sentiment
        self._sentiment_details = sentiment_details
        self._sentiment_weightage = sentiment_weightage
        self._entity = entity

    @property
    def discussion_id(self):
        """
        Gets the discussion_id of this Discussion.

        :return: The discussion_id of this Discussion.
        :rtype: int
        """
        return self._discussion_id

    @discussion_id.setter
    def discussion_id(self, discussion_id):
        """
        Sets the discussion_id of this Discussion.

        :param discussion_id: The discussion_id of this Discussion.
        :type: int
        """

        self._discussion_id = discussion_id

    @property
    def user(self):
        """
        Gets the user of this Discussion.

        :return: The user of this Discussion.
        :rtype: User
        """
        return self._user

    @user.setter
    def user(self, user):
        """
        Sets the user of this Discussion.

        :param user: The user of this Discussion.
        :type: User
        """

        self._user = user

    @property
    def subject(self):
        """
        Gets the subject of this Discussion.

        :return: The subject of this Discussion.
        :rtype: str
        """
        return self._subject

    @subject.setter
    def subject(self, subject):
        """
        Sets the subject of this Discussion.

        :param subject: The subject of this Discussion.
        :type: str
        """

        self._subject = subject

    @property
    def description(self):
        """
        Gets the description of this Discussion.

        :return: The description of this Discussion.
        :rtype: str
        """
        return self._description

    @description.setter
    def description(self, description):
        """
        Sets the description of this Discussion.

        :param description: The description of this Discussion.
        :type: str
        """

        self._description = description

    @property
    def creation_time(self):
        """
        Gets the creation_time of this Discussion.

        :return: The creation_time of this Discussion.
        :rtype: datetime
        """
        return self._creation_time

    @creation_time.setter
    def creation_time(self, creation_time):
        """
        Sets the creation_time of this Discussion.

        :param creation_time: The creation_time of this Discussion.
        :type: datetime
        """

        self._creation_time = creation_time

    @property
    def sentiment(self):
        """
        Gets the sentiment of this Discussion.

        :return: The sentiment of this Discussion.
        :rtype: str
        """
        return self._sentiment

    @sentiment.setter
    def sentiment(self, sentiment):
        """
        Sets the sentiment of this Discussion.

        :param sentiment: The sentiment of this Discussion.
        :type: str
        """

        self._sentiment = sentiment

    @property
    def sentiment_details(self):
        """
        Gets the sentiment_details of this Discussion.

        :return: The sentiment_details of this Discussion.
        :rtype: Sentiment
        """
        return self._sentiment_details

    @sentiment_details.setter
    def sentiment_details(self, sentiment_details):
        """
        Sets the sentiment_details of this Discussion.

        :param sentiment_details: The sentiment_details of this Discussion.
        :type: Sentiment
        """

        self._sentiment_details = sentiment_details

    @property
    def sentiment_weightage(self):
        """
        Gets the sentiment_weightage of this Discussion.

        :return: The sentiment_weightage of this Discussion.
        :rtype: float
        """
        return self._sentiment_weightage

    @sentiment_weightage.setter
    def sentiment_weightage(self, sentiment_weightage):
        """
        Sets the sentiment_weightage of this Discussion.

        :param sentiment_weightage: The sentiment_weightage of this Discussion.
        :type: float
        """

        self._sentiment_weightage = sentiment_weightage

    @property
    def entity(self):
        """
        Gets the entity of this Discussion.

        :return: The entity of this Discussion.
        :rtype: list[NER]
        """
        return self._entity

    @entity.setter
    def entity(self, entity):
        """
        Sets the entity of this Discussion.

        :param entity: The entity of this Discussion.
        :type: list[NER]
        """

        self._entity = entity

    def to_dict(self):
        """
        Returns the model properties as a dict
        """
        result = {}

        for attr, _ in iteritems(self.swagger_types):
            value = getattr(self, attr)
            if isinstance(value, list):
                result[attr] = list(map(
                    lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
                    value
                ))
            elif hasattr(value, "to_dict"):
                result[attr] = value.to_dict()
            elif isinstance(value, dict):
                result[attr] = dict(map(
                    lambda item: (item[0], item[1].to_dict())
                    if hasattr(item[1], "to_dict") else item,
                    value.items()
                ))
            else:
                result[attr] = value

        return result

    def to_str(self):
        """
        Returns the string representation of the model
        """
        return pformat(self.to_dict())

    def __repr__(self):
        """
        For `print` and `pprint`
        """
        return self.to_str()

    def __eq__(self, other):
        """
        Returns true if both objects are equal
        """
        return self.__dict__ == other.__dict__

    def __ne__(self, other):
        """
        Returns true if both objects are not equal
        """
        return not self == other


text:
package board.service;

import java.util.List;

import board.entity.Board;

public class EmployeeService extends AbstractService<Board> {

    public List<Board> selectPerPage(String pageno) {
        final int PER_PAGE = 5;
         return select()
                 .orderBy("id")
                 .limit(PER_PAGE)
                 .offset((Integer.parseInt(pageno)-1)*PER_PAGE)
                 .getResultList();
    }
    public List<Board> findByMemo(String keyword) {
        return select()
        		.where("memo LIKE '%" + keyword + "%'")
                .orderBy("id")
                .getResultList();
    }
}


text:
    {{section}}

    <router-outlet></router-outlet>


text:
/*****************************************************************************/
/**
*
* @file xgpiops.h
* @addtogroup gpiops_v2_1
* @{
* @details
*
* The Xilinx PS GPIO driver. This driver supports the Xilinx PS GPIO
* Controller.
*
* The GPIO Controller supports the following features:
*	- 4 banks
*	- Masked writes (There are no masked reads)
*	- Bypass mode
*	- Configurable Interrupts (Level/Edge)
*
* This driver is intended to be RTOS and processor independent. Any needs for
* dynamic memory management, threads or thread mutual exclusion, virtual
* memory, or cache control must be satisfied by the layer above this driver.

* This driver supports all the features listed above, if applicable.
*
* Driver Description
*
* The device driver enables higher layer software (e.g., an application) to
* communicate to the GPIO.
*
* Interrupts
*
* The driver provides interrupt management functions and an interrupt handler.
* Users of this driver need to provide callback functions. An interrupt handler
* example is available with the driver.
*
* Threads
*
* This driver is not thread safe. Any needs for threads or thread mutual
* exclusion must be satisfied by the layer above this driver.
*
* Asserts
*
* Asserts are used within all Xilinx drivers to enforce constraints on argument
* values. Asserts can be turned off on a system-wide basis by defining, at
* compile time, the NDEBUG identifier. By default, asserts are turned on and it
* is recommended that users leave asserts on during development.
*
* Building the driver
*
* The XGpioPs driver is composed of several source files. This allows the user
* to build and link only those parts of the driver that are necessary.
*

*
*

* MODIFICATION HISTORY:
*
* Ver   Who  Date     Changes
* ----- ---- -------- -----------------------------------------------
* 1.00a sv   01/15/10 First Release
* 1.01a sv   04/15/12 Removed the APIs XGpioPs_SetMode, XGpioPs_SetModePin
*                     XGpioPs_GetMode, XGpioPs_GetModePin as they are not
*		      relevant to Zynq device.The interrupts are disabled
*		      for output pins on all banks during initialization.
* 1.02a hk   08/22/13 Added low level reset API
* 2.1   hk   04/29/14 Use Input data register DATA_RO for read. CR# 771667.
*
*

*
******************************************************************************/
#ifndef XGPIOPS_H		/* prevent circular inclusions */
#define XGPIOPS_H		/* by using protection macros */

#ifdef __cplusplus
extern "C" {
#endif

/***************************** Include Files *********************************/

#include "xstatus.h"
#include "xgpiops_hw.h"

/************************** Constant Definitions *****************************/

/** @name Interrupt types
 *  @{
 * The following constants define the interrupt types that can be set for each
 * GPIO pin.
 */
#define XGPIOPS_IRQ_TYPE_EDGE_RISING	0  /**< Interrupt on Rising edge */
#define XGPIOPS_IRQ_TYPE_EDGE_FALLING	1  /**< Interrupt Falling edge */
#define XGPIOPS_IRQ_TYPE_EDGE_BOTH	2  /**< Interrupt on both edges */
#define XGPIOPS_IRQ_TYPE_LEVEL_HIGH	3  /**< Interrupt on high level */
#define XGPIOPS_IRQ_TYPE_LEVEL_LOW	4  /**< Interrupt on low level */
/*@}*/

#define XGPIOPS_BANK0			0  /**< GPIO Bank 0 */
#define XGPIOPS_BANK1			1  /**< GPIO Bank 1 */
#define XGPIOPS_BANK2			2  /**< GPIO Bank 2 */
#define XGPIOPS_BANK3			3  /**< GPIO Bank 3 */

#define XGPIOPS_MAX_BANKS		4  /**< Max banks in a GPIO device */
#define XGPIOPS_BANK_MAX_PINS		32 /**< Max pins in a GPIO bank */

#define XGPIOPS_DEVICE_MAX_PIN_NUM	118 /*< Max pins in the GPIO device
					      * 0 - 31,  Bank 0
					      * 32 - 53, Bank 1
					      *	54 - 85, Bank 2
					      *	86 - 117, Bank 3
					      */

/**************************** Type Definitions *******************************/

/****************************************************************************/
/**
 * This handler data type allows the user to define a callback function to
 * handle the interrupts for the GPIO device. The application using this
 * driver is expected to define a handler of this type, to support interrupt
 * driven mode. The handler executes in an interrupt context such that minimal
 * processing should be performed.
 *
 * @param	CallBackRef is a callback reference passed in by the upper layer
 *		when setting the callback functions for a GPIO bank. It is
 *		passed back to the upper layer when the callback is invoked. Its
 *		type is not important to the driver component, so it is a void
 *		pointer.
 * @param	Bank is the bank for which the interrupt status has changed.
 * @param	Status is the Interrupt status of the GPIO bank.
 *
 *****************************************************************************/
typedef void (*XGpioPs_Handler) (void *CallBackRef, int Bank, u32 Status);

/**
 * This typedef contains configuration information for a device.
 */
typedef struct {
	u16 DeviceId;		/**< Unique ID of device */
	u32 BaseAddr;		/**< Register base address */
} XGpioPs_Config;

/**
 * The XGpioPs driver instance data. The user is required to allocate a
 * variable of this type for the GPIO device in the system. A pointer
 * to a variable of this type is then passed to the driver API functions.
 */
typedef struct {
	XGpioPs_Config GpioConfig;	/**< Device configuration */
	u32 IsReady;			/**< Device is initialized and ready */
	XGpioPs_Handler Handler;	/**< Status handlers for all banks */
	void *CallBackRef; 		/**< Callback ref for bank handlers */
} XGpioPs;

/***************** Macros (Inline Functions) Definitions *********************/

/************************** Function Prototypes ******************************/

/*
 * Functions in xgpiops.c
 */
int XGpioPs_CfgInitialize(XGpioPs *InstancePtr, XGpioPs_Config *ConfigPtr,
			   u32 EffectiveAddr);

/*
 * Bank APIs in xgpiops.c
 */
u32 XGpioPs_Read(XGpioPs *InstancePtr, u8 Bank);
void XGpioPs_Write(XGpioPs *InstancePtr, u8 Bank, u32 Data);
void XGpioPs_SetDirection(XGpioPs *InstancePtr, u8 Bank, u32 Direction);
u32 XGpioPs_GetDirection(XGpioPs *InstancePtr, u8 Bank);
void XGpioPs_SetOutputEnable(XGpioPs *InstancePtr, u8 Bank, u32 Enable);
u32 XGpioPs_GetOutputEnable(XGpioPs *InstancePtr, u8 Bank);
void XGpioPs_GetBankPin(u8 PinNumber,	u8 *BankNumber, u8 *PinNumberInBank);

/*
 * Pin APIs in xgpiops.c
 */
int XGpioPs_ReadPin(XGpioPs *InstancePtr, int Pin);
void XGpioPs_WritePin(XGpioPs *InstancePtr, int Pin, int Data);
void XGpioPs_SetDirectionPin(XGpioPs *InstancePtr, int Pin, int Direction);
int XGpioPs_GetDirectionPin(XGpioPs *InstancePtr, int Pin);
void XGpioPs_SetOutputEnablePin(XGpioPs *InstancePtr, int Pin, int Enable);
int XGpioPs_GetOutputEnablePin(XGpioPs *InstancePtr, int Pin);

/*
 * Diagnostic functions in xgpiops_selftest.c
 */
int XGpioPs_SelfTest(XGpioPs *InstancePtr);

/*
 * Functions in xgpiops_intr.c
 */
/*
 * Bank APIs in xgpiops_intr.c
 */
void XGpioPs_IntrEnable(XGpioPs *InstancePtr, u8 Bank, u32 Mask);
void XGpioPs_IntrDisable(XGpioPs *InstancePtr, u8 Bank, u32 Mask);
u32 XGpioPs_IntrGetEnabled(XGpioPs *InstancePtr, u8 Bank);
u32 XGpioPs_IntrGetStatus(XGpioPs *InstancePtr, u8 Bank);
void XGpioPs_IntrClear(XGpioPs *InstancePtr, u8 Bank, u32 Mask);
void XGpioPs_SetIntrType(XGpioPs *InstancePtr, u8 Bank, u32 IntrType,
			  u32 IntrPolarity, u32 IntrOnAny);
void XGpioPs_GetIntrType(XGpioPs *InstancePtr, u8 Bank, u32 *IntrType,
			  u32 *IntrPolarity, u32 *IntrOnAny);
void XGpioPs_SetCallbackHandler(XGpioPs *InstancePtr, void *CallBackRef,
			     XGpioPs_Handler FuncPtr);
void XGpioPs_IntrHandler(XGpioPs *InstancePtr);

/*
 * Pin APIs in xgpiops_intr.c
 */
void XGpioPs_SetIntrTypePin(XGpioPs *InstancePtr, int Pin, u8 IrqType);
u8 XGpioPs_GetIntrTypePin(XGpioPs *InstancePtr, int Pin);

void XGpioPs_IntrEnablePin(XGpioPs *InstancePtr, int Pin);
void XGpioPs_IntrDisablePin(XGpioPs *InstancePtr, int Pin);
int XGpioPs_IntrGetEnabledPin(XGpioPs *InstancePtr, int Pin);
int XGpioPs_IntrGetStatusPin(XGpioPs *InstancePtr, int Pin);
void XGpioPs_IntrClearPin(XGpioPs *InstancePtr, int Pin);

/*
 * Functions in xgpiops_sinit.c
 */
XGpioPs_Config *XGpioPs_LookupConfig(u16 DeviceId);

#ifdef __cplusplus
}
#endif

#endif /* end of protection macro */
/** @} */


text:
@interface MSScrollView()<UIScrollViewDelegate>
{
    ScrollViewState _state;
    ScrollViewDirection _direction;
    ScrollViewAction _action;
    CGFloat _dragStartX;
    CGFloat _dragEndX;
    CGFloat _dragOutStartX;
    CGFloat _dragStartY;
    CGFloat _dragEndY;
    CGFloat _dragOutStartY;
}
@property (nonatomic, strong) UIPageControl *innerPageControl;
@end
@implementation MSScrollView

- (id)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];

    if (self)
    {
        self.delegate = self;
    }

    return self;
}

- (id)initWithCoder:(NSCoder *)aDecoder
{
    self = [super initWithCoder:aDecoder];

    if (self)
    {
        self.delegate = self;
    }

    return self;
}

- (void)setPageControl:(CGPoint)centerPoint;
{
    if(!_innerPageControl)
    {
        self.innerPageControl = [[UIPageControl alloc] initWithFrame:(CGRect){0,0,PAGE_CONTROL_WIDTH,PAGE_CONTROL_HEIGHT}];
        _innerPageControl.numberOfPages = (_mode == HORIZONTAL_SCROLL_MODE)?self.contentSize.width / self.frame.size.width:
                                                                            self.contentSize.height / self.frame.size.height;
    }

    [self.superview addSubview:_innerPageControl];

    _innerPageControl.center = centerPoint;
}

- (void)didMoveToSuperview
{
    if(_innerPageControl)
        [self.superview addSubview:_innerPageControl];

    [super didMoveToSuperview];
}

- (void)scrollViewDidScroll:(UIScrollView *)scrollView
{
    if(_mode == HORIZONTAL_SCROLL_MODE)
    {
        if(_state & (BEGIN_DRAGGING + END_DRAGGING))
        {
            if(_dragStartX - scrollView.contentOffset.x < 0)
            {
                _direction = LEFT_SCROLLING;
            }
            else if(_dragStartX - scrollView.contentOffset.x > 0)
            {
                _direction = RIGHT_SCROLLING;
            }

            if(_didscroll)
                _didscroll(NO, _direction, _action);
        }
        else if(_state == BEGIN_DECELARTING)
        {
            if(_direction == LEFT_SCROLLING)
            {
                if(_dragOutStartX==0)
                    _dragOutStartX = scrollView.contentOffset.x;

                if(_dragOutStartX - _dragEndX >= 1)
                {
                    _action = GO_THROUGH;
                    if(_didscroll)
                        _didscroll(YES, _direction, _action);
                }
                else
                {
                    if(scrollView.contentOffset.x > (2*_dragStartX+self.frame.size.width)*0.5)
                    {
                        _action = GO_THROUGH;
                        if(_didscroll)
                            _didscroll(YES, _direction, _action);
                    }
                    else
                    {
                        _action = BOUNCE_BACK;
                        if(_didscroll)
                            _didscroll(YES, _direction, _action);
                    }
                }
            }
            else if(_direction == RIGHT_SCROLLING)
            {
                if(_dragOutStartX==0)
                    _dragOutStartX = scrollView.contentOffset.x;

                if(_dragOutStartX - _dragEndX <= 1)
                {
                    _action = GO_THROUGH;
                    if(_didscroll)
                        _didscroll(YES, _direction, _action);
                }
                else
                {
                    if(scrollView.contentOffset.x < (2*_dragStartX-self.frame.size.width)*0.5)
                    {
                        _action = GO_THROUGH;
                        if(_didscroll)
                            _didscroll(YES, _direction, _action);
                    }
                    else
                    {
                        _action = BOUNCE_BACK;
                        if(_didscroll)
                            _didscroll(YES, _direction, _action);
                    }
                }
            }
        }

        if(_innerPageControl)
        {
            CGFloat pageWidth = scrollView.frame.size.width;
            float fractionalPage = scrollView.contentOffset.x / pageWidth;
            _innerPageControl.currentPage = lround(fractionalPage);
        }
    }
    else if(_mode == VERTICAL_SCROLL_MODE)
    {
        if(_state & (BEGIN_DRAGGING + END_DRAGGING))
        {
            if(_dragStartY - scrollView.contentOffset.y < 0)
            {
                _direction = UP_SCROLLING;
            }
            else if(_dragStartY - scrollView.contentOffset.y > 0)
            {
                _direction = DOWN_SCROLLING;
            }

            if(_didscroll)
                _didscroll(NO, _direction, _action);
        }
        else if(_state == BEGIN_DECELARTING)
        {
            if(_direction == UP_SCROLLING)
            {
                if(_dragOutStartY==0)
                    _dragOutStartY = scrollView.contentOffset.y;

                if(_dragOutStartY - _dragEndY > 1)
                {
                    _action = GO_THROUGH;
                    if(_didscroll)
                        _didscroll(YES, _direction, _action);
                }
                else
                {
                    if(scrollView.contentOffset.y > (2*_dragStartY+self.frame.size.height)*0.5)
                    {
                        _action = GO_THROUGH;
                        if(_didscroll)
                            _didscroll(YES, _direction, _action);
                    }
                    else
                    {
                        _action = BOUNCE_BACK;
                        if(_didscroll)
                            _didscroll(YES, _direction, _action);
                    }
                }
            }
            else if(_direction == DOWN_SCROLLING)
            {
                if(_dragOutStartY==0)
                    _dragOutStartY = scrollView.contentOffset.y;

                if(_dragOutStartY - _dragEndY < 1)
                {
                    _action = GO_THROUGH;
                    if(_didscroll)
                        _didscroll(YES, _direction, _action);
                }
                else
                {
                    if(scrollView.contentOffset.y < (2*_dragStartY-self.frame.size.height)*0.5)
                    {
                        _action = GO_THROUGH;
                        if(_didscroll)
                            _didscroll(YES, _direction, _action);
                    }
                    else
                    {
                        _action = BOUNCE_BACK;
                        if(_didscroll)
                            _didscroll(YES, _direction, _action);
                    }
                }
            }
        }

        if(_innerPageControl)
        {
            CGFloat pageHeight = scrollView.frame.size.height;
            float fractionalPage = scrollView.contentOffset.y / pageHeight;
            _innerPageControl.currentPage = lround(fractionalPage);
        }
    }
}

- (void)scrollViewWillBeginDragging:(UIScrollView *)scrollView
{
    _state = BEGIN_DRAGGING;

    if(_mode == HORIZONTAL_SCROLL_MODE)
    {
        _dragOutStartX = 0;

        _dragStartX = scrollView.contentOffset.x;
    }
    else if(_mode == VERTICAL_SCROLL_MODE)
    {
        _dragOutStartY = 0;

        _dragStartY = scrollView.contentOffset.y;
    }

    _action = UNKNOWN_ACTION;

    if(_beginDragging)
        _beginDragging();
}

- (void)scrollViewDidEndDragging:(UIScrollView *)scrollView willDecelerate:(BOOL)decelerate
{
    _state = END_DRAGGING;

    if(_mode == HORIZONTAL_SCROLL_MODE)
    {
        _dragEndX = scrollView.contentOffset.x;

        if(decelerate)
        {
            if (_dragStartX < scrollView.contentOffset.x)
            {
                _direction = LEFT_SCROLLING;
            }
            else if (_dragStartX > scrollView.contentOffset.x)
            {
                _direction = RIGHT_SCROLLING;
            }
        }
    }
    else if(_mode == VERTICAL_SCROLL_MODE)
    {
        _dragEndY = scrollView.contentOffset.y;

        if(decelerate)
        {
            if (_dragStartY < scrollView.contentOffset.y)
            {
                _direction = UP_SCROLLING;
            }
            else if (_dragStartY > scrollView.contentOffset.y)
            {
                _direction = DOWN_SCROLLING;
            }
        }
    }

    if(_endDragging)
        _endDragging();
}

- (void)scrollViewWillBeginDecelerating:(UIScrollView *)scrollView
{
    _state = BEGIN_DECELARTING;

    if(_beginDecelerating)
        _beginDecelerating();
}

- (void)scrollViewDidEndDecelerating:(UIScrollView *)scrollView
{
    _state = END_DECELARTING;

    if(_mode == HORIZONTAL_SCROLL_MODE)
    {
        if(_action == GO_THROUGH)
        {
            _action = GO_THROUGH_COMPLETE;
            if(_didscroll)
                _didscroll(YES, _direction, _action);
        }
        else if(_action == BOUNCE_BACK)
        {
            _action = BOUNCE_BACK_COMPLETE;
            if(_didscroll)
                _didscroll(YES, _direction, _action);
        }

        _dragStartX = 0;
        _dragEndX = 0;
    }
    else if(_mode == VERTICAL_SCROLL_MODE)
    {
        if(_action == GO_THROUGH)
        {
            _action = GO_THROUGH_COMPLETE;
            if(_didscroll)
                _didscroll(YES, _direction, _action);
        }
        else if(_action == BOUNCE_BACK)
        {
            _action = BOUNCE_BACK_COMPLETE;
            if(_didscroll)
                _didscroll(YES, _direction, _action);
        }

        _dragStartY = 0;
        _dragEndY = 0;
    }

    if(_endDecelerating)
        _endDecelerating();
}

@end


text:
#import <UIKit/UIKit.h>

@interface PacoFindMyExperimentsViewController : UIViewController

@end


text:
<component name="InspectionProjectProfileManager">
  <profile version="1.0">
    <option name="myName" value="Project Default" />
    <inspection_tool class="PyCompatibilityInspection" enabled="true" level="WARNING" enabled_by_default="true">
      <option name="ourVersions">
        <value>
          <list size="1">
            <item index="0" class="java.lang.String" itemvalue="3.6" />
          </list>
        </value>
      </option>
    </inspection_tool>
    <inspection_tool class="PyMissingTypeHintsInspection" enabled="true" level="WEAK WARNING" enabled_by_default="true" />
    <inspection_tool class="PyPackageRequirementsInspection" enabled="true" level="WARNING" enabled_by_default="true">
      <option name="ignoredPackages">
        <value>
          <list size="1">
            <item index="0" class="java.lang.String" itemvalue="pytest" />
          </list>
        </value>
      </option>
    </inspection_tool>
    <inspection_tool class="PyPep8Inspection" enabled="true" level="WEAK WARNING" enabled_by_default="true">
      <option name="ignoredErrors">
        <list>
          <option value="E111" />
        </list>
      </option>
    </inspection_tool>
    <inspection_tool class="PyTypeCheckerInspection" enabled="true" level="ERROR" enabled_by_default="true" />
    <inspection_tool class="PyUnresolvedReferencesInspection" enabled="true" level="WARNING" enabled_by_default="true">
      <option name="ignoredIdentifiers">
        <list>
          <option value="type.sort_values" />
        </list>
      </option>
    </inspection_tool>
  </profile>
</component>


text:
function Position() {
    this.DENSITY = Ti.Platform.displayCaps.density;
    this.DPI = Ti.Platform.displayCaps.dpi;
    this.XDPI = Ti.Platform.displayCaps.xdpi;
    this.YDPI = Ti.Platform.displayCaps.ydpi;
    this.DENSITY_FACTOR = Ti.Platform.displayCaps.logicalDensityFactor;
    this.SCREEN_WIDTH_PX = Ti.Platform.displayCaps.platformWidth;
    this.SCREEN_HEIGHT_PX = Ti.Platform.displayCaps.platformHeight;
    this.SCREEN_WIDTH_DP = null;
    this.SCREEN_HEIGHT_DP = null;
    var self;
    switch (this.DENSITY) {
      case "extra high":
        this.SCALE = 2;
        this.PPI = 320;
        break;

      case "high":
        this.SCALE = 1.5;
        this.PPI = 240;
        break;

      case "low":
        this.SCALE = .75;
        this.PPI = 120;
        break;

      case "medium":
      default:
        this.SCALE = 1;
        this.PPI = 160;
    }
    this.__centerView = function(view, parentViewWidth) {
        var viewWidth = view.toImage().width;
        var x = parentViewWidth / 2 - viewWidth / 2;
        view.__centerloaded = true;
        view.setLeft(x);
    };
    this.centerViewHorizontal = function(view) {
        view.__centerloaded = false;
        view.addEventListener("postlayout", function(e) {
            var v = e.source;
            if (false === v.__centerloaded) {
                var parent = view.getParent();
                var parentWidth = self.SCREEN_WIDTH_DP;
                if (parent) {
                    parent.width && (parentWidth = parent.width);
                    parent.rect && (parentWidth = parent.rect.width);
                }
                v.__centerloaded = true;
                self.__centerView(v, parentWidth);
            }
        });
    };
    this.convertPxToDp = function(px) {
        return px / (this.DPI / this.PPI);
    };
    this.convertDpToPx = function(dp) {
        return dp * (this.DPI / this.PPI);
    };
    this.SCREEN_WIDTH_DP = this.convertPxToDp(this.SCREEN_WIDTH_PX);
    this.SCREEN_HEIGHT_DP = this.convertPxToDp(this.SCREEN_HEIGHT_PX);
    self = this;
}

var position = new Position();

module.exports = position;


text:
/** Utility functions for OpenCL */
#ifndef __OPENCL_UTIL_H__
#define __OPENCL_UTIL_H__

#include <shogun/lib/config.h>
#ifdef HAVE_VIENNACL
#include <viennacl/ocl/backend.hpp>
#include <viennacl/ocl/kernel.hpp>
#include <viennacl/ocl/program.hpp>
#include <viennacl/ocl/utils.hpp>
#include <viennacl/tools/tools.hpp>

#include <shogun/mathematics/linalg/internal/opencl_config.h>

#include <string>

#include <initializer_list>
#include <shogun/mathematics/linalg/internal/implementation/operations/Parameter.h>

namespace shogun
{

namespace linalg
{

namespace implementation
{

namespace ocl
{

/** Returns a string representing type T */
template <class T>
std::string get_type_string()
{
	return viennacl::ocl::type_to_string<T>::apply();
}

/** Return a source code string with some appropriate definitions for:
 * DATATYPE, KERNEL_NAME, WORK_GROUP_SIZE_1D, WORK_GROUP_SIZE_2D
 *
 * If the datatype is float64_t, the appropriate pragma for enabling double
 * precision is also appended to the source code
 */
template <class T>
std::string generate_kernel_preamble(std::string kernel_name)
{
	std::string type_string = get_type_string<T>();

	std::string source = "";
	viennacl::ocl::append_double_precision_pragma<T>(viennacl::ocl::current_context(), source);
	source.append("#define DATATYPE " + type_string + "\n");
	source.append("#define KERNEL_NAME " + kernel_name + "\n");
	source.append("#define WORK_GROUP_SIZE_1D " + std::to_string(OCL_WORK_GROUP_SIZE_1D) + "\n");
	source.append("#define WORK_GROUP_SIZE_2D " + std::to_string(OCL_WORK_GROUP_SIZE_2D) + "\n");

	return source;
}

/** Returns true if the kernel has already been compiled into the current context */
inline bool kernel_exists(std::string kernel_name)
{
	return viennacl::ocl::current_context().has_program(kernel_name);
}

/** Returns a kernel that has already been compiled */
inline viennacl::ocl::kernel& get_kernel(std::string kernel_name)
{
	return viennacl::ocl::current_context().get_program(kernel_name).get_kernel(kernel_name);
}

/** Compiles and returns a kernel */
inline viennacl::ocl::kernel& compile_kernel(std::string kernel_name, std::string source)
{
	viennacl::ocl::program & prog =
		viennacl::ocl::current_context().add_program(source, kernel_name);

	return prog.get_kernel(kernel_name);
}

/** Aligns a given value to a multiple of OCL_WORK_GROUP_SIZE_1D */
inline uint32_t align_to_multiple_1d(uint32_t n)
{
	return viennacl::tools::align_to_multiple<uint32_t>(n, OCL_WORK_GROUP_SIZE_1D);
}

/** Aligns a given value to a multiple of OCL_WORK_GROUP_SIZE_2D */
inline uint32_t align_to_multiple_2d(uint32_t n)
{
	return viennacl::tools::align_to_multiple<uint32_t>(n, OCL_WORK_GROUP_SIZE_2D);
}

/** Generates a kernel that performs a single argument elementwise operation on
 * a vector
 *
 * The operation is specified by a string containing OpenCL code that performs
 * an operation on a variable called "element" and returns the result. For
 * example the operation string: "return element+1;" will produce a kernel that
 * adds 1 to all elements of a vector.
 *
 * The kernel will have the following arguments:
 * __global DATATYPE* vec, int size, int vec_offset, __global DATATYPE* result,
 * int result_offset
 */
template <class T>
viennacl::ocl::kernel& generate_single_arg_elementwise_kernel(
	std::string kernel_name, std::string operation)
{
	if (ocl::kernel_exists(kernel_name))
		return ocl::get_kernel(kernel_name);

	std::string source = ocl::generate_kernel_preamble<T>(kernel_name);

	source.append("inline DATATYPE operation(DATATYPE element)\n{\n");
	source.append(operation);
	source.append("\n}\n");

	source.append(
		R"(
			__kernel void KERNEL_NAME(
				__global DATATYPE* vec, int size, int vec_offset,
				__global DATATYPE* result, int result_offset)
			{
				int i = get_global_id(0);

				if (i<size)
					result[i+result_offset] = operation(vec[i+vec_offset]);
			}
		)"
	);

	viennacl::ocl::kernel& kernel = ocl::compile_kernel(kernel_name, source);

	kernel.local_work_size(0, OCL_WORK_GROUP_SIZE_1D);

	return kernel;
}

/** Generates a kernel that performs a two-argument elementwise operation on
 * a vector
 *
 * The operation is specified by a string containing OpenCL code that performs
 * an operation on variables called "element1" and "element2" and returns the result. For
 * example the operation string: "return element1+element2;" will produce a kernel that
 * adds adds two vectors together
 *
 * The kernel will have the following arguments:
 * __global DATATYPE* vec1, int size, int vec1_offset,
 * __global DATATYPE* vec2, int vec2_offset,
 * __global DATATYPE* result, int result_offset
 */
template <class T>
viennacl::ocl::kernel& generate_two_arg_elementwise_kernel(
	std::string kernel_name, std::string operation)
{
	if (ocl::kernel_exists(kernel_name))
		return ocl::get_kernel(kernel_name);

	std::string source = ocl::generate_kernel_preamble<T>(kernel_name);

	source.append("inline DATATYPE operation(DATATYPE element1, DATATYPE element2)\n{\n");
	source.append(operation);
	source.append("\n}\n");

	source.append(
		R"(
			__kernel void KERNEL_NAME(
				__global DATATYPE* vec1, int size, int vec1_offset,
				__global DATATYPE* vec2, int vec2_offset,
				__global DATATYPE* result, int result_offset)
			{
				int i = get_global_id(0);

				if (i<size)
					result[i+result_offset] =
						operation(vec1[i+vec1_offset], vec2[i+vec2_offset]);
			}
		)"
	);

	viennacl::ocl::kernel& kernel = ocl::compile_kernel(kernel_name, source);

	kernel.local_work_size(0, OCL_WORK_GROUP_SIZE_1D);

	return kernel;
}

/**
 * This method replaces all occurances of a string with another string.
 * The code is based on a Stack Overflow answer, link below.
 *
 * http://stackoverflow.com/questions/2896600/how-to-replace-all-occurrences-of-a-character-in-string
 *
 * @param str The string in which the substitution is going to occur.
 * @param from The string which will be substituted
 * @param to The string which will be the substitution for 'from'
 * @return The string with all occurances of 'from' substituted by 'to'
 */
inline std::string replace_all(std::string str, const std::string& from, const std::string& to)
{
	size_t start_pos=0;
	while ((start_pos=str.find(from, start_pos))!=std::string::npos)
	{
		str.replace(start_pos, from.length(), to);
		start_pos+=to.length(); // Handles case where 'to' is a substring of 'from'
	}
	return str;
}

/**
 * This method can be used to pass custom operations to be performed by OpenCL
 * element-wise for GPU vectors/matrices. The users can pass a format-string
 * for their desired expressions with optional parameters (if there are any),
 * enclosed by opening and closing braces, e.g. "{param_name1}". In case there
 * are any such parameters, then this string should be followed by a number of
 * shogun::linalg::ocl::Parameter objects to be substituted in place of those params.
 * These Parameter objects can be created on the fly.
 *
 * See ElementwiseOperations_unittest.cc and elementwise_benchmark.cpp for an
 * example of its usage.
 *
 * @param str The format string
 * @param params The initializer list of optional Parameters
 * @return The final expression string ready to be used by the OpenCL kernel.
 */
inline std::string format(const char* str, std::initializer_list<shogun::linalg::ocl::Parameter> params)
{
	std::string fmt(str);
	for (auto i=params.begin(); i!=params.end(); ++i)
		fmt=replace_all(fmt, "{"+i->m_name+"}", *i);
	return fmt.append("\n");
}

} // ocl

} // implementation

} // linalg

} // shogun

#endif // HAVE_VIENNACL

#endif // __OPENCL_UTIL_H__


text:
<?php

declare(strict_types=1);

namespace Sylius\Bundle\CoreBundle\Context;

use Sylius\Component\Channel\Context\ChannelContextInterface;
use Sylius\Component\Channel\Context\ChannelNotFoundException;
use Sylius\Component\Core\Repository\OrderRepositoryInterface;
use Sylius\Component\Customer\Context\CustomerContextInterface;
use Sylius\Component\Order\Context\CartContextInterface;
use Sylius\Component\Order\Context\CartNotFoundException;
use Sylius\Component\Order\Model\OrderInterface;

final class CustomerAndChannelBasedCartContext implements CartContextInterface
{
    /** @var CustomerContextInterface */
    private $customerContext;

    /** @var ChannelContextInterface */
    private $channelContext;

    /** @var OrderRepositoryInterface */
    private $orderRepository;

    public function __construct(
        CustomerContextInterface $customerContext,
        ChannelContextInterface $channelContext,
        OrderRepositoryInterface $orderRepository
    ) {
        $this->customerContext = $customerContext;
        $this->channelContext = $channelContext;
        $this->orderRepository = $orderRepository;
    }

    public function getCart(): OrderInterface
    {
        try {
            $channel = $this->channelContext->getChannel();
        } catch (ChannelNotFoundException $exception) {
            throw new CartNotFoundException('Sylius was not able to find the cart, as there is no current channel.');
        }

        $customer = $this->customerContext->getCustomer();
        if (null === $customer) {
            throw new CartNotFoundException('Sylius was not able to find the cart, as there is no logged in user.');
        }

        $cart = $this->orderRepository->findLatestCartByChannelAndCustomer($channel, $customer);
        if (null === $cart) {
            throw new CartNotFoundException('Sylius was not able to find the cart for currently logged in user.');
        }

        return $cart;
    }
}


text:
[Click here to get in touch](https://bytescout.zendesk.com/hc/en-us/requests/new?subject=ByteScout%20PDF%20Extractor%20SDK%20Question)

or just send email to [support@bytescout.com](mailto:support@bytescout.com?subject=ByteScout%20PDF%20Extractor%20SDK%20Question)

## ON-PREMISE OFFLINE SDK

[Get Your 60 Day Free Trial](https://bytescout.com/download/web-installer?utm_source=github-readme)
[Explore Documentation](https://bytescout.com/documentation/index.html?utm_source=github-readme)
[Explore Source Code Samples](https://github.com/bytescout/ByteScout-SDK-SourceCode/)
[Sign Up For Online Training](https://academy.bytescout.com/)

## ON-DEMAND REST WEB API

[Get your API key](https://app.pdf.co/signup?utm_source=github-readme)
[Security](https://pdf.co/security)
[Explore Web API Documentation](https://apidocs.pdf.co?utm_source=github-readme)
[Explore Web API Samples](https://github.com/bytescout/ByteScout-SDK-SourceCode/tree/master/PDF.co%20Web%20API)

## VIDEO REVIEW

[https://www.youtube.com/watch?v=s28W3_KMraU](https://www.youtube.com/watch?v=s28W3_KMraU)

<!-- code block begin -->

##### **ExtractAllImages.bat:**

```
@echo off

if "%~1"=="" (
	echo -----------------------------------------------------
	echo Invalid parameter!
	echo -----------------------------------------------------
	echo Usage: ExtractAllImages.bat file_name
	echo Example: ExtractAllImages.bat "sample1.pdf"
	echo -----------------------------------------------------
	if not "%NOPAUSE%"=="1" pause
	exit /b 1
)

powershell -NoProfile -ExecutionPolicy Bypass -Command "& .\ExtractAllImages.ps1" "%1"
echo Script finished with errorlevel=%errorlevel%

pause
```

<!-- code block end -->

<!-- code block begin -->

##### **ExtractAllImages.ps1:**

```
#*******************************************************************************************#
#                                                                                #
# Download Free Evaluation Version From: https://bytescout.com/download/web-installer       #
#                                                                                #
# Also available as Web API! Get Your Free API Key: https://app.pdf.co/signup               #
#                                                                                #
# Copyright © 2017-2020 ByteScout, Inc. All rights reserved.                                #
# https://www.bytescout.com                                                                 #
# https://pdf.co                                                                            #
#                                                                                #
#*******************************************************************************************#

Param (
    [Parameter(Mandatory = $true)]
    [string] $InputFileName = ""
)

#Add reference to Bytescout.PDFExtractor.dll assembly
Add-Type -Path "C:\Program Files\Bytescout PDF Extractor SDK\net4.00\Bytescout.PDFExtractor.dll"

# Check input file exists
if ((Test-Path $InputFileName) -eq $false) {

    Write-Host "Input file does not exist." -ForegroundColor Red
    Exit 0
}

# Create and activate Bytescout.PDFExtractor.ImageExtractor instance
$Extractor = New-Object Bytescout.PDFExtractor.ImageExtractor
$Extractor.RegistrationName = "demo"
$Extractor.RegistrationKey = "demo"

try {
    # Load sample PDF document
    $Extractor.LoadDocumentFromFile($InputFileName)

    # Advance image enumeration
    if ($Extractor.GetFirstImage() -eq $true) {

        $i = 0
        do {
            # Construct output file name
            $OutputFileName = "image$i.png"
            # Save image to file
            $Extractor.SaveCurrentImageToFile($OutputFileName)
            $i++
        } while ($Extractor.GetNextImage() -eq $true) # Advance image enumeration
    }
} catch {

    Write-Host $_.Exception.Message
}

$Extractor.Dispose()
```

<!-- code block end -->


text:
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:orientation="vertical"
    android:layout_height="match_parent"
    xmlns:app="http://schemas.android.com/apk/res-auto">

    <android.support.v7.widget.Toolbar
        android:id="@+id/id_toolbar"
        app:title="App Title"
        app:subtitle="Sub Title"
        app:navigationIcon="@drawable/ic_toc_white_24dp"
        android:layout_height="wrap_content"
        android:minHeight="?attr/actionBarSize"
        android:layout_width="match_parent"
        android:background="?attr/colorPrimary" />

    <android.support.v4.widget.DrawerLayout
        android:id="@+id/id_drawerlayout"
        android:layout_width="match_parent"
        android:layout_height="match_parent">

        <FrameLayout
            android:layout_width="match_parent"
            android:layout_height="match_parent">
            <android.support.v7.widget.GridLayout
                android:background="#44ff0000"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:id="@+id/id_content"
                android:layout_gravity="center_horizontal"

                app:useDefaultMargins="true"
                app:columnCount="3">

                <TextView
                    android:text="First Name:"
                    app:layout_gravity="right" />

                <EditText
                    android:ems="10"
                    app:layout_columnSpan="2" />

                <TextView
                    android:text="Last Name:"

                    app:layout_column="0"
                    app:layout_gravity="right" />

                <EditText
                    android:ems="10"
                    app:layout_columnSpan="2" />

                <TextView
                    android:text="Visit Type:"

                    app:layout_column="0"
                    app:layout_gravity="right" />

                <RadioGroup app:layout_columnSpan="2">

                    <RadioButton
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="Business" />

                    <RadioButton
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="Social" />

                </RadioGroup>

                <Button
                    android:text="Ok"
                    app:layout_column="1" />

                <Button
                    android:text="Cancel"
                    app:layout_column="2" />

            </android.support.v7.widget.GridLayout>

            </FrameLayout>

        <ListView
            android:id="@+id/id_leftmenu"
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:layout_gravity="left"
            android:background="#ffffffff"></ListView>

    </android.support.v4.widget.DrawerLayout>

</LinearLayout>


text:
package com.alibaba.jstorm.common.metric;

import com.alibaba.jstorm.common.metric.operator.convert.DefaultConvertor;
import com.alibaba.jstorm.common.metric.operator.merger.SumMerger;
import com.alibaba.jstorm.common.metric.operator.updater.AddUpdater;
import com.alibaba.jstorm.common.metric.window.Metric;

/**
 * The class is similar to com.codahale.metrics.Counter
 *
 * Sum all window's value
 *
 * how to use Counter , please refer to Sampling Interface
 *
 * @author zhongyan.feng
 *
 * @param <T>
 */
public class Counter<T extends Number> extends Metric<T, T> {
    private static final long serialVersionUID = -1362345159511508074L;

    /**
     *
     * @param defaultValue
     */
    public Counter(T zero) {
        updater = new AddUpdater<T>();
        merger = new SumMerger<T>();
        convertor = new DefaultConvertor<T>();
        defaultValue = zero;

        init();
    }

    public static void main(String[] args) {

    }
}


text:
Veidt is a deep learning library for materials science. It builds on top of
the popular pymatgen (Python Materials Genomics) materials analysis library
and well-known deep learning libraries like Keras and Tensorflow. The aim is
to link the power of both kinds of libraries for rapid experimentation and
learning of materials data.

License
=======

Veidt is released under the BSD License::

    Copyright (c) 2015, Regents of the University of California
    All rights reserved.

    Redistribution and use in source and binary forms, with or without modification,
    are permitted provided that the following conditions are met:

    1. Redistributions of source code must retain the above copyright notice, this
       list of conditions and the following disclaimer.

    2. Redistributions in binary form must reproduce the above copyright notice,
       this list of conditions and the following disclaimer in the documentation
       and/or other materials provided with the distribution.

    3. Neither the name of the copyright holder nor the names of its contributors
       may be used to endorse or promote products derived from this software
       without specific prior written permission.

    THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
    ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
    WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
    DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
    FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
    DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
    SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
    CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
    OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
    OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.


text:
FOUNDATION_EXPORT double Pods_JHToast_ExampleVersionNumber;
FOUNDATION_EXPORT const unsigned char Pods_JHToast_ExampleVersionString[];


text:
/* jshint undef: true, unused: true, browser: true, quotmark: single, curly: true */
(function($) {
    var resultRenderers = {};

    $.registerSiteSearchRenderer = function(classes, groupTitle, renderer) {
        if (typeof classes == 'string') {
            classes = [classes];
        }

        renderer.groupTitle = groupTitle;
        renderer.classes = classes;

        $.each(classes, function(index, className) {
            resultRenderers[className] = renderer;
        });
    };

    $(function() {
        $('.js-site-search').each(function() {
            var $searchForm = $(this),
                $searchField = $searchForm.find('input[name=q]'),
                $resultsList = $('
').appendTo($searchForm).addClass('search-results dropdown-menu').hide(),
                lastTypedQuery, lastRequestedQuery, searchTimeout, searchXHR, hideResultsOnBlur;

            // bind events to search field
            $searchField.attr('autocomplete', 'off');

            $searchField.keyup(function() {
                var query = $searchField.val();

                if (query == lastTypedQuery) {
                    return;
                }

                lastTypedQuery = query;

                // abort any pending search timeout
                if (searchTimeout) {
                    clearTimeout(searchTimeout);
                    searchTimeout = null;
                }

                // execute or clear search
                if (query.length >= 2 && query) {
                    $searchForm.addClass('is-waiting');
                    $resultsList.show();
                    searchTimeout = setTimeout(_doSearch, 300);
                } else {
                    $resultsList.hide().empty();
                    lastRequestedQuery = null;

                    // abort any pending query
                    if (searchXHR) {
                        searchXHR.abort();
                        searchXHR = null;
                    }
                }
            });

            $searchField.focus(function() {
                if (lastRequestedQuery) {
                    $resultsList.show();
                }
            });

            // bind body event to hide results
            $(document).click(function(e) {
                if (!$searchForm.is(e.target) && !$searchForm.has(e.target).length) {
                    $resultsList.hide();
                }
            });

            $(document).keydown(function(e) {
                var waitingToRun = hideResultsOnBlur,
                    activeEl = $(document.activeElement);

                if (!$resultsList.is(':visible') || waitingToRun === true) {
                    return;
                }

                if (activeEl && activeEl != $resultsList && activeEl != $searchForm && !activeEl.closest($searchForm).length && !activeEl.closest($resultsList).length) {
                    hideResultsOnBlur = true;
                    setTimeout(function() {
                        $resultsList.hide();
                        hideResultsOnBlur = false;
                    }, 100);
                }
            });

            // bind form events for keyboard navigation
            $searchForm.keydown(function(e) {
                var isDown = e.which == 40, // 40 = down arrow
                    $resultLinks, lastLinkIndex, currentLinkIndex, nextLinkIndex;

                if (!isDown && e.which != 38) { // 38 = up arrow
                    return;
                }

                e.preventDefault();

                if (!$resultsList.is(':visible')) {
                    return;
                }

                $resultLinks = $resultsList.find('a');
                lastLinkIndex = $resultLinks.length - 1;
                currentLinkIndex = $resultLinks.index($(e.target).closest('a'));

                if (currentLinkIndex == -1) {
                    focusLinkIndex = isDown ? 0 : lastLinkIndex;
                } else {
                    if ( (currentLinkIndex == 0 && !isDown) || (currentLinkIndex == lastLinkIndex && isDown) ) {
                        // return focus to field at ends of results list
                        $searchField.focus();
                        return;
                    }

                    focusLinkIndex = currentLinkIndex + (isDown ? 1 : -1);
                }

                $resultLinks[focusLinkIndex].focus();
            });

            // workflow methods
            function _doSearch() {
                var query = $searchField.val(),
                    params = {
                        q: query,
                        include: 'recordTitle,recordURL'
                    };

                $searchForm.removeClass('is-waiting');

                if (searchXHR) {
                    searchXHR.abort();
                    searchXHR = null;
                }

                if (query == lastRequestedQuery) {
                    return;
                }

                lastRequestedQuery = query;
                $searchForm.addClass('is-loading');
                searchXHR = $.ajax({
                    url: '/search',
                    headers: {
                        Accept: 'application/json'
                    },
                    data: params,
                    success: _renderResults
                });
            }

            function _renderResults(results) {
                $searchForm.removeClass('is-loading');

                if (results.totalResults) {
                    $searchForm.removeClass('no-results');
                    $resultsList.empty();
                    $.each(results.data, function(key, value) {
                        if (!value.length) {
                            return;
                        }

                        var $section = $('
').addClass('results-group');
                        $('
').appendTo($section).addClass('group-title dropdown-header').text(
                            key in resultRenderers ? resultRenderers[key].groupTitle : key
                        );

                        $.each(value.slice(0, 5), function(index, result) {
                            $('
').addClass('search-result').append(
                                (resultRenderers[result.Class] || _defaultResultRenderer)(result).addClass('dropdown-item')
                            ).appendTo($section);
                        });

                        if (value.length > 5) {
                            $('
').addClass('search-result').append(
                                $('')
                                    .html((value.length - 5) + ' more…')
                                    .attr('href', '/search?q=' + encodeURIComponent(lastRequestedQuery))
                            ).appendTo($section);
                        }

                        $section.appendTo($resultsList);
                    });
                } else {
                    $searchForm.addClass('no-results');
                    $resultsList.html('
No results
');
                }
            }

            function _defaultResultRenderer(result) {
                return $('')
                    .text(result.recordTitle)
                    .attr('href', result.recordURL);
            }

        }); // end form.site-search loop

    });
}(jQuery));


text:
from pyqode.qt import QtCore, QtGui, QtWidgets

class Ui_Dialog(object):
    def setupUi(self, Dialog):
        Dialog.setObjectName("Dialog")
        Dialog.resize(277, 126)
        self.gridLayout = QtWidgets.QGridLayout(Dialog)
        self.gridLayout.setObjectName("gridLayout")
        self.formLayout = QtWidgets.QFormLayout()
        self.formLayout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout.setObjectName("formLayout")
        self.label = QtWidgets.QLabel(Dialog)
        self.label.setObjectName("label")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.label)
        self.lblCurrentLine = QtWidgets.QLabel(Dialog)
        self.lblCurrentLine.setObjectName("lblCurrentLine")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.lblCurrentLine)
        self.label_3 = QtWidgets.QLabel(Dialog)
        self.label_3.setObjectName("label_3")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.label_3)
        self.label_4 = QtWidgets.QLabel(Dialog)
        self.label_4.setObjectName("label_4")
        self.formLayout.setWidget(2, QtWidgets.QFormLayout.LabelRole, self.label_4)
        self.lblLineCount = QtWidgets.QLabel(Dialog)
        self.lblLineCount.setObjectName("lblLineCount")
        self.formLayout.setWidget(2, QtWidgets.QFormLayout.FieldRole, self.lblLineCount)
        self.spinBox = QtWidgets.QSpinBox(Dialog)
        self.spinBox.setObjectName("spinBox")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.spinBox)
        self.gridLayout.addLayout(self.formLayout, 0, 0, 1, 1)
        self.buttonBox = QtWidgets.QDialogButtonBox(Dialog)
        self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
        self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.Cancel|QtWidgets.QDialogButtonBox.Ok)
        self.buttonBox.setObjectName("buttonBox")
        self.gridLayout.addWidget(self.buttonBox, 1, 0, 1, 1)

        self.retranslateUi(Dialog)
        self.buttonBox.accepted.connect(Dialog.accept)
        self.buttonBox.rejected.connect(Dialog.reject)
        QtCore.QMetaObject.connectSlotsByName(Dialog)

    def retranslateUi(self, Dialog):

        Dialog.setWindowTitle(_("Go to line"))
        self.label.setText(_("You are here:"))
        self.lblCurrentLine.setText(_("1"))
        self.label_3.setText(_("You want to go:"))
        self.label_4.setText(_("You can\'t go further than:"))
        self.lblLineCount.setText(_("1"))


text:
<?xml version="1.0" encoding="UTF-8"?>

<data xmlns="ns:workflow" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="ns:workflow resource:WorkflowData">
	<ruleAttributes xmlns="ns:workflow/RuleAttribute" xsi:schemaLocation="ns:workflow/RuleAttribute resource:RuleAttribute">
		<ruleAttribute>
			<name>XMLSearchableAttributeString</name>
			<className>org.kuali.rice.kew.docsearch.TestXMLSearchableAttributeString</className>
			XML Searchable attribute
			<description>XML Searchable attribute</description>
			<type>SearchableAttribute</type>
		</ruleAttribute>
		<ruleAttribute>
			<name>CustomSecurityFilterAttribute</name>
			<className>org.kuali.rice.kew.docsearch.CustomSecurityFilterAttribute</className>
			CustomSecurityFilterAttribute
			<description>CustomSecurityFilterAttribute</description>
			<type>DocumentSecurityAttribute</type>
		</ruleAttribute>
		<ruleAttribute>
			<name>UserEmployeeId</name>
			<className>org.kuali.rice.kew.docsearch.xml.StandardGenericXMLSearchableAttribute</className>
			Visible Search Attribute
			<description>Searchable attribute is visible</description>
			<type>SearchableXmlAttribute</type>
			<searchingConfig>
				<fieldDef name="employeeId" title="Employee Id">
					<display>
						<type>text</type>
					</display>
					<fieldEvaluation>
						<xpathexpression>//putWhateverWordsIwantInsideThisTag/employeeId/value</xpathexpression>
					</fieldEvaluation>
				</fieldDef>
				<xmlSearchContent>
					<putWhateverWordsIwantInsideThisTag>
						<employeeId>
							<value>%employeeId%</value>
						</employeeId>
					</putWhateverWordsIwantInsideThisTag>
				</xmlSearchContent>
			</searchingConfig>
		</ruleAttribute>
	</ruleAttributes>
	<ruleTemplates xmlns="ns:workflow/RuleTemplate" xsi:schemaLocation="ns:workflow/RuleTemplate resource:RuleTemplate">
		<ruleTemplate>
			<name>MatchAllTemplate</name>
			<description>Template that matches always</description>
		</ruleTemplate>
	</ruleTemplates>
	<documentTypes xmlns="ns:workflow/DocumentType" xsi:schemaLocation="ns:workflow/DocumentType resource:DocumentType">
		<documentType>
			<name>SecurityDocument</name>
			<description>SecurityDocument</description>
			SecurityDocument
			<postProcessorName>org.kuali.rice.kew.postprocessor.DefaultPostProcessor</postProcessorName>
			<docHandler>_blank</docHandler>
			<superUserGroupName namespace="KR-WKFLW">TestWorkgroup</superUserGroupName>
			<blanketApproveGroupName namespace="KR-WKFLW">TestWorkgroup</blanketApproveGroupName>
			<defaultExceptionGroupName namespace="KR-WKFLW">TestWorkgroup</defaultExceptionGroupName>
			<active>true</active>
			<policies>
				<policy>
					<name>DEFAULT_APPROVE</name>
					<value>false</value>
				</policy>
			</policies>
			<attributes>
				<attribute>
					<name>XMLSearchableAttributeString</name>
				</attribute>
			</attributes>
			<routePaths>
				<routePath>
					<start name="Initial" nextNode="First" />
					<requests name="First" />
				</routePath>
			</routePaths>
			<routeNodes>
				<start name="Initial">
					<activationType>P</activationType>
				</start>
				<requests name="First">
					<activationType>S</activationType>
					<ruleTemplate>MatchAllTemplate</ruleTemplate>
				</requests>
			</routeNodes>
		</documentType>
		<documentType>
			<name>SecurityDoc_InitiatorOnly</name>
			<parent>SecurityDocument</parent>
			SecurityDoc_InitiatorOnly
			<docHandler>_blank</docHandler>
			<security>
			    <initiator>true</initiator>
			</security>
		</documentType>
		<documentType>
			<name>SecurityDoc_RouteLogAuthOnly</name>
			<parent>SecurityDocument</parent>
			SecurityDoc_RouteLogAuthOnly
			<docHandler>_blank</docHandler>
			<security>
			    <routeLogAuthenticated>true</routeLogAuthenticated>
			</security>
		</documentType>
		<documentType>
			<name>SecurityDoc_WorkgroupOnly</name>
			<parent>SecurityDocument</parent>
			SecurityDoc_WorkgroupOnly
			<docHandler>_blank</docHandler>
			<security>
			    <groupName namespace="KR-WKFLW">Test_Security_Group</groupName>
			</security>
		</documentType>
		<documentType>
			<name>SecurityDoc_SearchAttributeOnly</name>
			<parent>SecurityDocument</parent>
			SecurityDoc_SearchAttributeOnly
			<docHandler>_blank</docHandler>
			<attributes>
				<attribute>
					<name>XMLSearchableAttributeString</name>
				</attribute>
				<attribute>
					<name>UserEmployeeId</name>
				</attribute>
			</attributes>
			<security>
			    <searchableAttribute name="employeeId" idType="authenticationId"/>
			</security>
		</documentType>
		<documentType>
			<name>SecurityDoc_SecurityAttributeOnly_Class</name>
			<parent>SecurityDocument</parent>
			SecurityDoc_SecurityAttributeOnly_Class
			<docHandler>_blank</docHandler>
			<security>
			    <securityAttribute class="org.kuali.rice.kew.docsearch.CustomSecurityFilterAttribute" />
			</security>
		</documentType>
		<documentType>
			<name>SecurityDoc_SecurityAttributeOnly_Name</name>
			<parent>SecurityDocument</parent>
			SecurityDoc_SecurityAttributeOnly_Name
			<docHandler>_blank</docHandler>
			<security>
			    <securityAttribute name="CustomSecurityFilterAttribute" />
			</security>
		</documentType>
		<documentType>
			<name>SecurityDoc_PermissionOnly</name>
			<parent>SecurityDocument</parent>
			SecurityDoc_PermissionOnly
			<docHandler>_blank</docHandler>
			<security>
			   <permission name="Log In Kuali Portal" namespace="KUALI">
			     <qualification name="principalId">${document.initiatorPrincipalId}</qualification>
			     <qualification name="documentTypeName">${document.docTypeName}</qualification>
			     <qualification name="documentId">${document.documentId}</qualification>
			     <qualification name="dateCreated">${document.dateCreated}</qualification>
			     <qualification name="fyiRequested">${document.fyiRequested}</qualification>
			   </permission>
			</security>
		</documentType>

		<documentType>
			<name>SecurityDoc_InvalidPermissionOnly</name>
			<parent>SecurityDocument</parent>
			SecurityDoc_PermissionOnly
			<docHandler>_blank</docHandler>
			<security>
			   <permission name="Log In Badly" namespace="KUALI" />
			</security>
		</documentType>
		<documentType>
			<name>SecurityDoc_Initiator</name>
			<parent>SecurityDocument</parent>
			SecurityDoc_RoleOnly
			<docHandler>_blank</docHandler>
			<security>
			    <initiator>true</initiator>
			</security>
		</documentType>
	</documentTypes>
	<groups xmlns="ns:workflow/Group" xsi:schemaLocation="ns:workflow/Group resource:Group">
		<group>
			<id>9776</id>
			<name>Test_Security_Group</name>
			<namespace>KR-WKFLW</namespace>
			<description>Test_Security_Group</description>
			<members>
				<principalName>security_user</principalName>
			</members>
		</group>
	</groups>
	<rules xmlns="ns:workflow/Rule" xsi:schemaLocation="ns:workflow/Rule resource:Rule">
		<rule>
			<documentType>SecurityDocument</documentType>
            <ruleTemplate>MatchAllTemplate</ruleTemplate>
			<description>Search attribute rule test</description>
			<forceAction>true</forceAction>
			<responsibilities>
				<responsibility>
					<user>user2</user>
					<actionRequested>A</actionRequested>
					<priority>1</priority>
				</responsibility>
			</responsibilities>
		</rule>
	</rules>
</data>


text:
from __future__ import unicode_literals

from django.db import models, migrations

class Migration(migrations.Migration):

    dependencies = [
        ('monitoring', '0003_auto_20150324_1806'),
    ]

    operations = [
        migrations.AlterUniqueTogether(
            name='inventoryspecimen',
            unique_together=set([('inventory', 'specimen')]),
        ),
    ]


text:
package org.mrgeo.mapalgebra.vector.paint;

import org.mrgeo.data.raster.RasterUtils;
import org.mrgeo.data.raster.RasterWritable;
import org.mrgeo.geometry.Geometry;
import org.mrgeo.geometry.Point;
import org.mrgeo.utils.tms.Bounds;
import org.mrgeo.utils.tms.TMSUtils;
import org.mrgeo.utils.tms.Tile;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import java.awt.*;
import java.awt.image.BufferedImage;
import java.awt.image.DataBuffer;
import java.awt.image.Raster;
import java.awt.image.WritableRaster;
import java.io.IOException;

public class VectorPainter
{
static final Logger log = LoggerFactory.getLogger(VectorPainter.class);

public enum AggregationType {
  SUM, MASK, MIN, MAX, AVERAGE, GAUSSIAN
}

private AggregationType aggregationType;
private String valueColumn;
private int tileSize;
private int zoom;

private GeometryPainter rasterPainter;
private Composite composite;
private WritableRaster raster;
private GeometryPainter totalPainter = null;
private WritableRaster totalRaster;

/**
 * Use this constructor if you need to use this class outside of the context of
 * a map/reduce 1 job.
 *
 */
public VectorPainter(int zoom, AggregationType aggregationType, String valueColumn,
    int tileSize)
{
  this.zoom = zoom;
  this.aggregationType = aggregationType;
  this.valueColumn = valueColumn;
  this.tileSize = tileSize;
}

public void beforePaintingTile(final long tileId)
{
  if (aggregationType == AggregationType.MIN)
  {
    composite = new MinCompositeDouble();
  }
  else if (aggregationType == AggregationType.MAX)
  {
    composite = new MaxCompositeDouble();
  }
  else if (aggregationType == AggregationType.MASK)
  {
    // When a feature is painted in MASK mode, the src raster will contain
    // 1.0 in each pixel that overlaps the feature. The MaskComposite will
    // write a 0.0 to each pixel that was originally painted, and if any
    // polygon holes are painted after that, those are written as NaN.
    composite = new MaskComposite(1.0, 0.0, Double.NaN);
  }
  else if (aggregationType == AggregationType.GAUSSIAN)
  {
    composite = new GaussianComposite();
  }
  else
  {
    composite = new AdditiveCompositeDouble();
  }

  // Because of how MASK works, and having to properly handle inner rings of
  // polygons, the raster is initialized to all 0's for the MASK aggregation.
  // There is no way to paint NaN values onto the raster using the GeometryPainter
  // so the non-masked pixels will be set to a value of 0 (which can be painted).
  raster = RasterUtils.createEmptyRaster(tileSize, tileSize, 1,
      DataBuffer.TYPE_DOUBLE, Double.NaN);

  totalRaster = null;

  final Tile tile = TMSUtils.tileid(tileId, zoom);
  final Bounds tb = TMSUtils.tileBounds(tile.tx, tile.ty, zoom, tileSize);
  Bounds b = new Bounds(tb.w, tb.s, tb.e, tb.n);
  if (aggregationType == AggregationType.AVERAGE)
  {
    totalRaster = raster.createCompatibleWritableRaster();

    final BufferedImage bi = RasterUtils.makeBufferedImage(totalRaster);
    final Graphics2D gr = bi.createGraphics();

    gr.setComposite(new AdditiveComposite());
    gr.setStroke(new BasicStroke(0));

    totalPainter = new GeometryPainter(gr, totalRaster, new Color(1, 1, 1), new Color(0, 0, 0));
    totalPainter.setBounds(b);
  }

  final BufferedImage bi = RasterUtils.makeBufferedImage(raster);
  final Graphics2D gr = bi.createGraphics();

  gr.setComposite(composite);
  gr.setStroke(new BasicStroke(0));

  rasterPainter = new GeometryPainter(gr, raster, new Color(1, 1, 1),
      new Color(0, 0, 0));
  rasterPainter.setBounds(b);
}

public void paintGeometry(Geometry g)
{
  if (valueColumn == null || aggregationType == AggregationType.MASK)
  {
    rasterPainter.paint(g);
  }
  else
  {
    final String sv = g.getAttribute(valueColumn);
    if (sv != null)
    {
      final double v = Double.parseDouble(sv);
      ((WeightedComposite)composite).setWeight(v);

      rasterPainter.paint(g);

      if (aggregationType == AggregationType.AVERAGE && totalPainter != null)
      {
        totalPainter.paint(g);
      }
    }
    else
    {
      log.info("Ignoring feature because there is no column: " + valueColumn);
    }
  }
}

public void paintEllipse(Point center, double majorWidth, double minorWidth, double orientation, double weight) {

  if (composite instanceof WeightedComposite)
  {
    ((WeightedComposite) composite).setWeight(weight);
  }
  if (composite instanceof GaussianComposite)
  {
    ((GaussianComposite) composite).setEllipse(center, majorWidth, minorWidth, orientation, rasterPainter.getTransform());
  }

  rasterPainter.paintEllipse(center, majorWidth, minorWidth, orientation);
}

public RasterWritable afterPaintingTile() throws IOException
{
  if (aggregationType == AggregationType.AVERAGE)
  {
    averageRaster(raster, totalRaster);
  }

  return RasterWritable.toWritable(raster);
}

private static void averageRaster(final WritableRaster raster, final Raster count)
{
  for (int y = 0; y < raster.getHeight(); y++)
  {
    for (int x = 0; x < raster.getWidth(); x++)
    {
      for (int b = 0; b < raster.getNumBands(); b++)
      {
        double v = raster.getSampleDouble(x, y, b);
        final double c = count.getSampleDouble(x, y, b);

        if (!Double.isNaN(v))
        {
          if (c == 0.0)
          {
            v = Double.NaN;
          }
          else
          {
            v /= c;
          }

          raster.setSample(x, y, b, v);
        }
      }
    }
  }
}
}


text:
module ActiveScaffold::Config
  class Sortable < Base
    def initialize(core_config)
      @options = {}
      @core = core_config

      self.column = core_config.model.new.position_column unless (@core.model.instance_methods & [:acts_as_list_class, 'acts_as_list_class']).empty?
      self.column = core_config.model.new.left_column_name unless (@core.model.instance_methods & [:nested_set_scope, 'nested_set_scope']).empty?
      if self.column.nil?
        raise "ActiveScaffoldSortable: Missing sortable attribute '#{core_config.model.new.position_column}' in model '#{core_config.model.to_s}'" if @core.model.instance_methods.include? 'acts_as_list_class'
        raise "ActiveScaffoldSortable: Missing sortable attribute '#{core_config.model.new.left_column_name}' in model '#{core_config.model.to_s}'" if @core.model.instance_methods.include? 'nested_set_scope'
      end

    end

    cattr_accessor :plugin_directory
    @@plugin_directory = File.expand_path(__FILE__).match(%{(^.*)/lib/active_scaffold/config/sortable.rb})[1]

    self.crud_type = :update

    attr_reader :column
    def column=(column_name)
      @column = @core.columns[column_name]
      Rails.logger.error("ActiveScaffold Sortable: postion column: #{column_name} not found in model") if @column.nil?
      @column
    end

    attr_accessor :options
  end
end


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

    <meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Using ContainerEffect Transitions</title>

<link rel="stylesheet" type="text/css" href="../../build/fonts/fonts-min.css" />
<link rel="stylesheet" type="text/css" href="../../build/container/assets/skins/sam/container.css" />

Using ContainerEffect Transitions

The Container Family of controls, including Overlay and all of its subclasses (Panel, Tooltip, Dialog, SimpleDialog), can implement built-in transition effects using the effect property and the ContainerEffect object.  This example demonstrates the fade and slide transitions provided with Container.

Use the buttons below to show and hide Overlays, noting their transition treatments as they appear and disappear.

overlay1 (fade in):
<button id="show1">Show</button>
<button id="hide1">Hide</button>

overlay2 (slide in):
<button id="show2">Show</button>
<button id="hide2">Hide</button>

overlay3 (fade and slide):
<button id="show3">Show</button>
<button id="hide3">Hide</button>

Overlay #1 from Markup

This is a Overlay that was marked up in the document.

End of Overlay #1

Overlay #2 from Markup

This is a Overlay that was marked up in the document.

End of Overlay #2

Overlay #3 from Markup

This is a Overlay that was marked up in the document.

End of Overlay #3


text:
import { expect } from 'chai';
import { ClientFunction } from 'testcafe';

fixture `gh845`
    .page `http://localhost:3000/fixtures/regression/gh-845/pages/index.html`;

const MAX_UNLOADING_TIMEOUT = 17 * 1000;
const getDelay              = ClientFunction(() => Date.now() - window.startTime);
const setStartTime          = ClientFunction(() => {
    window.startTime = Date.now();
});

test('Click on a download link', async t => {
    await setStartTime();

    await t.click('#link');

    const delay = await getDelay();

    expect(delay).to.be.below(MAX_UNLOADING_TIMEOUT);
});

test('Click on a download link in iframe', async t => {
    await t.switchToIframe('#iframe');

    await setStartTime();

    await t.click('#link');

    const delay = await getDelay();

    expect(delay).to.be.below(MAX_UNLOADING_TIMEOUT);
});


text:
using System.Collections.Generic;

namespace KeyPay.DomainModels.V2.Business
{
    public class ChartOfAccountsModel
    {
        public bool Complete { get; set; }
        public ChartOfAccountsGroupModel ChartofAccounts { get; set; }
        public List<ChartOfAccountsLocationGroupModel> LocationSpecificChartOfAccounts { get; set; }
    }

    public class ChartOfAccountsGroupModel
    {
        public ChartOfAccountsDefaultAccountsModel DefaultAccounts { get; set; }
        public List<ChartOfAccountsCategoryModel> PayCategories { get; set; }
        public List<ChartOfAccountsLiabilityCategoryModel> DeductionCategories { get; set; }
        public List<ChartOfAccountsCategoryModel> EmployeeExpenseCategories { get; set; }
        public List<ChartOfAccountsLiabilityCategoryModel> EmployerLiabilityCategories { get; set; }
    }

    public class ChartOfAccountsDefaultAccountsModel : ChartOfAccountsLocationAccountsModel
    {
        public bool PaymentAccountSplitByLocation { get; set; }
        public bool PaygLiabilityAccountSplitByLocation { get; set; }
        public bool PaygExpenseSplitByLocation { get; set; }
        public bool SuperannuationExpenseSplitByLocation { get; set; }
        public bool SuperannuationLiabilitySplitByLocation { get; set; }
        public bool DefaultExpenseSplitByLocation { get; set; }
        public bool EmployeeExpenseSplitByLocation { get; set; }
        public bool EmployerLiabilityExpenseSplitByLocation { get; set; }
        public bool EmployerLiabilityLiabilitySplitByLocation { get; set; }
        public bool DefaultLiabilitySplitByLocation { get; set; }
    }

    public class ChartOfAccountsCategoryModel : ChartOfAccountsLocationCategoryModel
    {
        public bool SplitByLocation { get; set; }
    }

    public class ChartOfAccountsLiabilityCategoryModel: ChartOfAccountsCategoryModel
    {
        public int? LiabilityAccountId { get; set; }
    }
}