text:
package net.automatalib.serialization.dot;

import java.io.IOException;
import java.io.InputStream;
import java.io.Reader;
import java.util.Iterator;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;

import net.automatalib.commons.util.IOUtil;
import org.testng.Assert;
import org.testng.annotations.BeforeMethod;
import org.testng.annotations.Test;

/**
 * @author frohme
 */
public class InternalDOTParserTest {

    private List<Node> nodes;
    private List<Edge> edges;

    private int nodesChecked;

    @BeforeMethod
    public void setUp() throws IOException {
        try (InputStream is = InternalDOTParserTest.class.getResourceAsStream(DOTSerializationUtil.PARSER_RESOURCE);
             Reader r = IOUtil.asUncompressedBufferedNonClosingUTF8Reader(is)) {

            final InternalDOTParser parser = new InternalDOTParser(r);
            parser.parse();

            this.nodes = parser.getNodes();
            this.edges = new LinkedList<>(parser.getEdges());
        }
    }

    @Test
    public void checkNodes() {
        checkNodeProperties("n1", "label", "Node 1", "color", "blue");
        checkNodeProperties("n2", "label", "Node 2", "style", "dashed", "color", "red");
        checkNodeProperties("", "label", "empty", "style", "dashed");
        checkNodeProperties("n3", "style", "dashed");
        checkNodeProperties("n4", "label", "Sub 1", "style", "dashed");
        checkNodeProperties("n5", "label", "Sub 2", "style", "dashed");
        checkNodeProperties("n6", "style", "dashed");
        checkNodeProperties("n7", "style", "dashed");

        checkNodeProperties("n10", "style", "dashed", "shape", "octagon");
        checkNodeProperties("n11", "style", "dashed", "shape", "octagon");
        checkNodeProperties("n12", "style", "dashed", "shape", "octagon");
        checkNodeProperties("n13", "style", "dashed", "shape", "octagon");
        checkNodeProperties("n14", "style", "dashed", "shape", "octagon");
        checkNodeProperties("n15", "style", "dashed", "shape", "octagon");

        Assert.assertEquals(nodesChecked, 14);
    }

    @Test
    public void checkEdges() {
        Assert.assertEquals(edges.size(), 27);

        checkEdgeProperties("n1", "n2", "label", "Input 1", "color", "green");
        checkEdgeProperties("n1", "n2", "label", "Input 2", "color", "red", "style", "solid");
        checkEdgeProperties("n1", "n3", "label", "arg", "color", "green", "style", "dashed");
        checkEdgeProperties("n3", "n2", "label", "arg", "color", "green", "style", "dashed");

        // subgraph edges
        checkEdgeProperties("n3", "n4", "color", "green", "style", "dashed");
        checkEdgeProperties("n3", "n5", "color", "green", "style", "dashed");

        checkEdgeProperties("n2", "n5", "color", "green", "style", "dashed");

        checkEdgeProperties("n6", "n1", "color", "green", "style", "dashed");
        checkEdgeProperties("n7", "n1", "color", "green", "style", "dashed");

        // first set of nested transitions
        checkEdgeProperties("n10", "n12", "color", "red", "style", "dashed");
        checkEdgeProperties("n10", "n13", "color", "red", "style", "dashed");
        checkEdgeProperties("n10", "n14", "color", "red", "style", "dashed");
        checkEdgeProperties("n10", "n15", "color", "red", "style", "dashed");
        checkEdgeProperties("n11", "n12", "color", "red", "style", "dashed");
        checkEdgeProperties("n11", "n13", "color", "red", "style", "dashed");
        checkEdgeProperties("n11", "n14", "color", "red", "style", "dashed");
        checkEdgeProperties("n11", "n15", "color", "red", "style", "dashed");
        checkEdgeProperties("n13", "n14", "color", "blue", "style", "dashed");
        checkEdgeProperties("n13", "n15", "color", "blue", "style", "dashed");

        // second set of nested transitions
        checkEdgeProperties("n10", "n12", "color", "green", "style", "dashed");
        checkEdgeProperties("n10", "n13", "color", "green", "style", "dashed");
        checkEdgeProperties("n11", "n12", "color", "green", "style", "dashed");
        checkEdgeProperties("n11", "n13", "color", "green", "style", "dashed");
        checkEdgeProperties("n12", "n14", "color", "green", "style", "dashed");
        checkEdgeProperties("n12", "n15", "color", "green", "style", "dashed");
        checkEdgeProperties("n13", "n14", "color", "green", "style", "dashed");
        checkEdgeProperties("n13", "n15", "color", "green", "style", "dashed");

        Assert.assertEquals(edges.size(), 0);
    }

    private void checkNodeProperties(String id, String... props) {

        assert props.length % 2 == 0;

        Node node = null;
        for (Node n : nodes) {
            if (id.equals(n.id)) {
                node = n;
                break;
            }
        }

        Assert.assertNotNull(node);
        Map<String, String> attributes = node.attributes;

        // Assure that we check all properties
        Assert.assertEquals(attributes.size(), props.length / 2);

        for (int i = 0; i < props.length; i += 2) {
            String key = props[i];
            String value = props[i + 1];

            Assert.assertTrue(attributes.containsKey(key));
            Assert.assertEquals(attributes.get(key), value);
        }

        nodesChecked++;
    }

    private void checkEdgeProperties(String src, String tgt, String... props) {

        assert props.length % 2 == 0;

        Iterator<Edge> iter = this.edges.iterator();

        edge:
        while (iter.hasNext()) {
            Edge edge = iter.next();

            // potential match
            if (src.equals(edge.src) && tgt.equals(edge.tgt) && edge.attributes.size() == props.length / 2) {
                for (int i = 0; i < props.length; i += 2) {
                    String key = props[i];
                    String value = props[i + 1];

                    if (!edge.attributes.containsKey(key) || !value.equals(edge.attributes.get(key))) {
                        // not a match, continue
                        continue edge;
                    }
                }

                // mark edge as checked by removing it
                iter.remove();
                return;
            }
        }
        Assert.fail("Expected edge not found");
    }
}


text:
A phantom type is a data type which contains extra hidden
generic parameters. These extra parameters hold no storage values.
They are checked statically at compile time and only
at compile time; they have no run-time behavior.

{phantom.play}

###See also:
[Derive](http://rustbyexample.com/trait/derive.html),
[struct](http://rustbyexample.com/structs.html), and
[TupleStructs](http://rustbyexample.com/structs.html)

redpajama_set_name: RedPajamaGithub


text:
function indexifyName(prefix, names = []) {
  let index = 1;
  let name;
  do {
    name = `${prefix} ${index++}`;
  } while (names.indexOf(name) !== -1);
  return name;
}
export function genNotebookName(names) {
  return indexifyName('Notebook', names);
}
export function genChapterName(names) {
  return indexifyName('Chapter', names);
}
export function genPageName(names) {
  return indexifyName('Page', names);
}


text:
@interface CLTAppDelegate : UIResponder <UIApplicationDelegate>

@property (strong, nonatomic) UIWindow *window;
@property (nonatomic)DDFileLogger* fileLogger;
@end


text:
<?xml version="1.0" encoding="UTF-8"?>
<CommandInterface xmlns="http://v8.1c.ru/8.3/xcf/extrnprops" xmlns:xr="http://v8.1c.ru/8.3/xcf/readable" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
	<CommandsVisibility>
		<Command name="CommonCommand.КорзинаПокупателя">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.СписокЗаказовСамообслуживание">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.ДокументыРеализации">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.АктыВыполненныхРабот">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.СчетаНаОплату">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.МоиСоглашения">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.МоиКонтактныеЛица">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.МоиКонтрагенты">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="DataProcessor.акУправлениеПроектами.Command.ОткрытьПроекты">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="Document.ЗаказКлиента.StandardCommand.OpenList">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="Document.КоммерческоеПредложениеКлиенту.StandardCommand.OpenList">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="CommonCommand.акЗаказыНаДоставку">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="CommonCommand.ЗаказыНаМонтаж">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="Document.РеализацияТоваровУслуг.StandardCommand.OpenList">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="Catalog.СделкиСКлиентами.StandardCommand.OpenList">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="Catalog.Партнеры.StandardCommand.OpenList">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="CommonCommand.СостояниеВзаиморасчетовСамообслуживание">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="DataProcessor.РабочееМестоДоставкиМонтажа.StandardCommand.Open">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="DataProcessor.ФормированиеЗаказовНаДоставкуИлиМонтаж.Command.СоздатьЗаказНаДоставку">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="DataProcessor.ФормированиеЗаказовНаДоставкуИлиМонтаж.Command.СоздатьЗаказНаМонтаж">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.ИзменитьКонтактнуюИнформацию">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.МоиНастройки">
			<Visibility>
				<xr:Common>true</xr:Common>
			</Visibility>
		</Command>
	</CommandsVisibility>
	<CommandsPlacement>
		<Command name="CommonCommand.КорзинаПокупателя">
			<CommandGroup>NavigationPanelImportant</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.СписокЗаказовСамообслуживание">
			<CommandGroup>NavigationPanelImportant</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.ДокументыРеализации">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.АктыВыполненныхРабот">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.СчетаНаОплату">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.МоиСоглашения">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.МоиКонтактныеЛица">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.МоиКонтрагенты">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="DataProcessor.акУправлениеПроектами.Command.ОткрытьПроекты">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="Document.ЗаказКлиента.StandardCommand.OpenList">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="Document.КоммерческоеПредложениеКлиенту.StandardCommand.OpenList">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="CommonCommand.акЗаказыНаДоставку">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="CommonCommand.ЗаказыНаМонтаж">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="Document.РеализацияТоваровУслуг.StandardCommand.OpenList">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="Catalog.СделкиСКлиентами.StandardCommand.OpenList">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="Catalog.Партнеры.StandardCommand.OpenList">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="CommonCommand.СостояниеВзаиморасчетовСамообслуживание">
			<CommandGroup>ActionsPanelReports</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="DataProcessor.РабочееМестоДоставкиМонтажа.StandardCommand.Open">
			<CommandGroup>ActionsPanelTools</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="DataProcessor.ФормированиеЗаказовНаДоставкуИлиМонтаж.Command.СоздатьЗаказНаДоставку">
			<CommandGroup>ActionsPanelTools</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="DataProcessor.ФормированиеЗаказовНаДоставкуИлиМонтаж.Command.СоздатьЗаказНаМонтаж">
			<CommandGroup>ActionsPanelTools</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.ИзменитьКонтактнуюИнформацию">
			<CommandGroup>ActionsPanelTools</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.МоиНастройки">
			<CommandGroup>ActionsPanelTools</CommandGroup>
			<Placement>Manual</Placement>
		</Command>
	</CommandsPlacement>
	<CommandsOrder>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.ДокументыРеализации">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.АктыВыполненныхРабот">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.СчетаНаОплату">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.МоиСоглашения">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.МоиКонтактныеЛица">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.МоиКонтрагенты">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
		</Command>
		<Command name="DataProcessor.акУправлениеПроектами.Command.ОткрытьПроекты">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
		</Command>
		<Command name="Document.ЗаказКлиента.StandardCommand.OpenList">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
		</Command>
		<Command name="Document.КоммерческоеПредложениеКлиенту.StandardCommand.OpenList">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
		</Command>
		<Command name="CommonCommand.акЗаказыНаДоставку">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
		</Command>
		<Command name="CommonCommand.ЗаказыНаМонтаж">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
		</Command>
		<Command name="Document.РеализацияТоваровУслуг.StandardCommand.OpenList">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
		</Command>
		<Command name="Catalog.СделкиСКлиентами.StandardCommand.OpenList">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
		</Command>
		<Command name="Catalog.Партнеры.StandardCommand.OpenList">
			<CommandGroup>NavigationPanelOrdinary</CommandGroup>
		</Command>
		<Command name="DataProcessor.РабочееМестоДоставкиМонтажа.StandardCommand.Open">
			<CommandGroup>ActionsPanelTools</CommandGroup>
		</Command>
		<Command name="DataProcessor.ФормированиеЗаказовНаДоставкуИлиМонтаж.Command.СоздатьЗаказНаДоставку">
			<CommandGroup>ActionsPanelTools</CommandGroup>
		</Command>
		<Command name="DataProcessor.ФормированиеЗаказовНаДоставкуИлиМонтаж.Command.СоздатьЗаказНаМонтаж">
			<CommandGroup>ActionsPanelTools</CommandGroup>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.ИзменитьКонтактнуюИнформацию">
			<CommandGroup>ActionsPanelTools</CommandGroup>
		</Command>
		<Command name="DataProcessor.СамообслуживаниеПартнеров.Command.МоиНастройки">
			<CommandGroup>ActionsPanelTools</CommandGroup>
		</Command>
	</CommandsOrder>
	<GroupsOrder>
		<Group>NavigationPanelOrdinary</Group>
		<Group>ActionsPanelTools</Group>
	</GroupsOrder>
</CommandInterface>


text:
tron-js
=======

A temp repository for the Tron Game Render


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


text:
require('../../modules/es6.object.is-frozen');
module.exports = require('../../modules/_core').Object.isFrozen;


text:
<!-- Note: This file is automatically generated from source code comments. Changes made in this file will be overridden. -->

# Function asinh

Calculate the hyperbolic arcsine of a value,
defined as `asinh(x) = ln(x + sqrt(x^2 + 1))`.

For matrices, the function is evaluated element wise.

## Syntax

```js
math.asinh(x)
```

### Parameters

Parameter | Type | Description
--------- | ---- | -----------
`x` | number | Complex | Array | Matrix | Function input

### Returns

Type | Description
---- | -----------
number | Complex | Array | Matrix | Hyperbolic arcsine of x

## Examples

```js
math.asinh(0.5);       // returns 0.48121182505960347
```

## See also

[acosh](acosh.md),
[atanh](atanh.md)


text:
You can check a user's status, represented by little circles to the left of a
user's name, in the user list located at the right sidebar by default.

 * A green circle
   () means the
   user is "active" — the browser has determined that the Zulip page
   has "focus" at the moment on the user's computer.

 * A white, circle () means the user is
   not active and was not recently so.

 * An orange half-filled circle
   ()
   means the user is "not active" but was recently so.

!!! tip ""
    You can also view a user's status by hovering over their name in the user list.

 If you have messaged users in a group PM, their names will appear
 at the bottom of the right sidebar. In that case, a pale green circle () means that some were recently active but
 currently inactive, while others' statuses are unknown. A regular green circle
 () means all users in the group PM
 have been recently active.


text:
<bill session="110" type="s" number="760" updated="2009-01-09T13:08:27-05:00">
	<status><introduced date="1173070800" datetime="2007-03-05"/></status>

	<introduced date="1173070800" datetime="2007-03-05"/>
	<titles>
		<title type="short" as="introduced">Four Corners Television Access Act of 2007</title>
		<title type="official" as="introduced">A bill to provide certain counties with the ability to receive television broadcast signals of their choice.</title>
	</titles>
	<sponsor id="400619"/>
	<cosponsors>

	</cosponsors>
	<actions>
		<action date="1173070800" datetime="2007-03-05"><text>Read twice and referred to the Committee on Commerce, Science, and Transportation.</text></action>
	</actions>
	<committees>

	</committees>
	<relatedbills>

	</relatedbills>
	<subjects>

	</subjects>
	<amendments>

	</amendments>

	3/5/2007--Introduced.
Four Corners Television Access Act of 2007 - Amends federal copyright law and the Communications Act of 1934 to allow certain counties and areas to receive broadcast transmissions of network television stations located in the capital of the state in which such counties and areas are located. Allows, notwithstanding any other provision of law, a satellite carrier, cable system, or translator station that elects to provide secondary transmission only to subscribers in the state who otherwise would not receive the primary transmission because the subscribers are in a designated market area outside of that state if: (1) the Federal Communications Commission (FCC) determines that it is in the best interest of the public welfare; and (2) the satellite carrier, cable system, or translator station agrees to also provide the secondary transmission in the assigned designated market area.

</bill>


text: CKEDITOR.plugins.setLang("print","en-ca",{toolbar:"Print"});


text:
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.resourcemanager.datamigration.models;

import com.azure.core.annotation.Immutable;
import com.azure.core.util.logging.ClientLogger;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.fasterxml.jackson.annotation.JsonTypeName;
import java.time.OffsetDateTime;

/** The MigrateSqlServerSqlMISyncTaskOutputMigrationLevel model. */
@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "resultType")
@JsonTypeName("MigrationLevelOutput")
@Immutable
public final class MigrateSqlServerSqlMISyncTaskOutputMigrationLevel extends MigrateSqlServerSqlMISyncTaskOutput {
    @JsonIgnore
    private final ClientLogger logger = new ClientLogger(MigrateSqlServerSqlMISyncTaskOutputMigrationLevel.class);

    /*
     * Count of databases
     */
    @JsonProperty(value = "databaseCount", access = JsonProperty.Access.WRITE_ONLY)
    private Integer databaseCount;

    /*
     * Current state of migration
     */
    @JsonProperty(value = "state", access = JsonProperty.Access.WRITE_ONLY)
    private MigrationState state;

    /*
     * Migration start time
     */
    @JsonProperty(value = "startedOn", access = JsonProperty.Access.WRITE_ONLY)
    private OffsetDateTime startedOn;

    /*
     * Migration end time
     */
    @JsonProperty(value = "endedOn", access = JsonProperty.Access.WRITE_ONLY)
    private OffsetDateTime endedOn;

    /*
     * Source server name
     */
    @JsonProperty(value = "sourceServerName", access = JsonProperty.Access.WRITE_ONLY)
    private String sourceServerName;

    /*
     * Source server version
     */
    @JsonProperty(value = "sourceServerVersion", access = JsonProperty.Access.WRITE_ONLY)
    private String sourceServerVersion;

    /*
     * Source server brand version
     */
    @JsonProperty(value = "sourceServerBrandVersion", access = JsonProperty.Access.WRITE_ONLY)
    private String sourceServerBrandVersion;

    /*
     * Target server name
     */
    @JsonProperty(value = "targetServerName", access = JsonProperty.Access.WRITE_ONLY)
    private String targetServerName;

    /*
     * Target server version
     */
    @JsonProperty(value = "targetServerVersion", access = JsonProperty.Access.WRITE_ONLY)
    private String targetServerVersion;

    /*
     * Target server brand version
     */
    @JsonProperty(value = "targetServerBrandVersion", access = JsonProperty.Access.WRITE_ONLY)
    private String targetServerBrandVersion;

    /*
     * Number of database level errors
     */
    @JsonProperty(value = "databaseErrorCount", access = JsonProperty.Access.WRITE_ONLY)
    private Integer databaseErrorCount;

    /**
     * Get the databaseCount property: Count of databases.
     *
     * @return the databaseCount value.
     */
    public Integer databaseCount() {
        return this.databaseCount;
    }

    /**
     * Get the state property: Current state of migration.
     *
     * @return the state value.
     */
    public MigrationState state() {
        return this.state;
    }

    /**
     * Get the startedOn property: Migration start time.
     *
     * @return the startedOn value.
     */
    public OffsetDateTime startedOn() {
        return this.startedOn;
    }

    /**
     * Get the endedOn property: Migration end time.
     *
     * @return the endedOn value.
     */
    public OffsetDateTime endedOn() {
        return this.endedOn;
    }

    /**
     * Get the sourceServerName property: Source server name.
     *
     * @return the sourceServerName value.
     */
    public String sourceServerName() {
        return this.sourceServerName;
    }

    /**
     * Get the sourceServerVersion property: Source server version.
     *
     * @return the sourceServerVersion value.
     */
    public String sourceServerVersion() {
        return this.sourceServerVersion;
    }

    /**
     * Get the sourceServerBrandVersion property: Source server brand version.
     *
     * @return the sourceServerBrandVersion value.
     */
    public String sourceServerBrandVersion() {
        return this.sourceServerBrandVersion;
    }

    /**
     * Get the targetServerName property: Target server name.
     *
     * @return the targetServerName value.
     */
    public String targetServerName() {
        return this.targetServerName;
    }

    /**
     * Get the targetServerVersion property: Target server version.
     *
     * @return the targetServerVersion value.
     */
    public String targetServerVersion() {
        return this.targetServerVersion;
    }

    /**
     * Get the targetServerBrandVersion property: Target server brand version.
     *
     * @return the targetServerBrandVersion value.
     */
    public String targetServerBrandVersion() {
        return this.targetServerBrandVersion;
    }

    /**
     * Get the databaseErrorCount property: Number of database level errors.
     *
     * @return the databaseErrorCount value.
     */
    public Integer databaseErrorCount() {
        return this.databaseErrorCount;
    }

    /**
     * Validates the instance.
     *
     * @throws IllegalArgumentException thrown if the instance is not valid.
     */
    @Override
    public void validate() {
        super.validate();
    }
}


text:
package com.twineworks.collections.champ;

import org.junit.Test;

import java.util.*;

import static org.assertj.core.api.Assertions.assertThat;

public class TransientChampMapTest {

  private static class Collider{
    private final String name;

    private Collider(String name) {
      this.name = name;
    }

    @Override
    public boolean equals(Object o) {
      if (this == o) return true;
      if (o == null || getClass() != o.getClass()) return false;
      Collider collider = (Collider) o;
      return Objects.equals(name, collider.name);
    }

    @Override
    public int hashCode() {
      // always collide
      return 42;
    }
  }

  private static ArrayList<String> strKeys = new ArrayList<>();

  static {
    for (char c = 1;  c < 128; c++){
      for (char d = 1; d < 128; d++){
        for (char e = 1; d < 128; d++) {
          strKeys.add((String.valueOf(c) + d) + e);
        }
      }
    }
  }

  @Test
  public void empty_has_zero_size() {
    assertThat(new TransientChampMap<>().size()).isEqualTo(0);
  }

  @Test
  public void insert_into_empty() {

    TransientChampMap<String, Long> map = new TransientChampMap<>();

    map.set("a",1L);
    assertThat(map.size()).isEqualTo(1);

    assertThat(map.containsKey("a")).isTrue();
    assertThat(map.get("a")).isEqualTo(1L);

    assertThat(map.containsKey("b")).isFalse();
    assertThat(map.get("b")).isNull();
  }

  @Test
  public void reset_in_singleton() {

    TransientChampMap<String, Long> map = new TransientChampMap<>();

    map.set("a",1L);
    map.set("a",1L);
    assertThat(map.size()).isEqualTo(1);

    assertThat(map.containsKey("a")).isTrue();
    assertThat(map.get("a")).isEqualTo(1L);

    assertThat(map.containsKey("b")).isFalse();
    assertThat(map.get("b")).isNull();
  }

  @Test
  public void replace_in_singleton() {

    TransientChampMap<String, Long> map = new TransientChampMap<>();

    map.set("a",1L);
    map.set("a",2L);
    assertThat(map.size()).isEqualTo(1);

    assertThat(map.containsKey("a")).isTrue();
    assertThat(map.get("a")).isEqualTo(2L);

    assertThat(map.containsKey("b")).isFalse();
    assertThat(map.get("b")).isNull();
  }

  @Test
  public void split_common_prefix_insert() {

    TransientChampMap<Long, Long> map = new TransientChampMap<>();

    map.set(1L, 1L);
    map.set(1025L, 2L);
    assertThat(map.size()).isEqualTo(2);

    assertThat(map.containsKey(1L)).isTrue();
    assertThat(map.get(1L)).isEqualTo(1L);

    assertThat(map.containsKey(1025L)).isTrue();
    assertThat(map.get(1025L)).isEqualTo(2L);

    assertThat(map.containsKey(2L)).isFalse();
    assertThat(map.get(2L)).isNull();
  }

  @Test
  public void hash_collision_insert() {

    TransientChampMap<Collider, Long> map = new TransientChampMap<>();

    Collider a = new Collider("a");
    Collider b = new Collider("b");
    Collider c = new Collider("c");

    assertThat(a.hashCode()).isEqualTo(b.hashCode());

    map.set(a, 1L);
    map.set(b, 2L);
    assertThat(map.size()).isEqualTo(2);

    assertThat(map.containsKey(a)).isTrue();
    assertThat(map.get(a)).isEqualTo(1L);

    assertThat(map.containsKey(b)).isTrue();
    assertThat(map.get(b)).isEqualTo(2L);

    assertThat(map.containsKey(c)).isFalse();
    assertThat(map.get(c)).isNull();
  }

  @Test
  public void insert_and_remove_many() {

    TransientChampMap<String, String> map = new TransientChampMap<>();

    for(String k: strKeys){
      map.set(k, k);
      assertThat(map.containsKey(k)).isTrue();
      assertThat(map.get(k)).isEqualTo(k);
    }

    assertThat(map.size()).isEqualTo(strKeys.size());

    int size = map.size();
    for (String s : strKeys) {

      map.remove(s);
      size--;

      assertThat(map.containsKey(s)).isFalse();
      assertThat(map.get(s)).isNull();
      assertThat(map.size()).isEqualTo(size);
    }

  }

  @Test
  public void insert_into_and_remove_from_empty() {

    TransientChampMap<String, Long> map = new TransientChampMap<>();

    map.set("a",1L);
    assertThat(map.size()).isEqualTo(1);
    map.remove("a");

    assertThat(map.size()).isEqualTo(0);
    assertThat(map.containsKey("a")).isFalse();
    assertThat(map.get("a")).isNull();
  }

  @Test
  public void freezes_after_inserts() {

    TransientChampMap<Long, Long> map = new TransientChampMap<>();

    map.set(0L, 0L);
    map.set(1L, 1L);
    map.set(2L, 2L);
    map.set(3L, 3L);
    map.set(64L, 64L);
    map.set(1025L, 1025L);

    ChampMap<Long, Long> p = map.freeze();
    Iterator<Map.Entry<Long, Long>> iter = p.entryIterator();

    ArrayList<Long> ks = new ArrayList<>();
    ArrayList<Long> vs = new ArrayList<>();

    while(iter.hasNext()){
      Map.Entry<Long, Long> entry = iter.next();
      ks.add(entry.getKey());
      vs.add(entry.getValue());
    }

    assertThat(ks).isEqualTo(vs);

    ks.sort(Comparator.comparingLong((x) -> x));

    assertThat(ks.get(0)).isEqualTo(0L);
    assertThat(ks.get(1)).isEqualTo(1L);
    assertThat(ks.get(2)).isEqualTo(2L);
    assertThat(ks.get(3)).isEqualTo(3L);
    assertThat(ks.get(4)).isEqualTo(64L);
    assertThat(ks.get(5)).isEqualTo(1025L);

  }

  @Test
  public void compares_as_equal_after_inserts() {

    TransientChampMap<Long, Long> map = new TransientChampMap<>();
    map.set(0L, 0L);
    map.set(1L, 1L);
    map.set(2L, 2L);
    map.set(3L, 3L);
    map.set(64L, 64L);
    map.set(1025L, 1025L);
    ChampMap<Long, Long> p = map.freeze();

    ChampMap<Long, Long> p2 = ChampMap.empty();
    p2 = p2.set(0L, 0L);
    p2 = p2.set(1L, 1L);
    p2 = p2.set(2L, 2L);
    p2 = p2.set(3L, 3L);
    p2 = p2.set(64L, 64L);
    p2 = p2.set(1025L, 1025L);

    assertThat(p).isEqualTo(p2);

  }

  @Test
  public void compares_as_equal_after_insert_and_remove_many() {

    TransientChampMap<String, String> map = new TransientChampMap<>();
    ChampMap<String, String> p2 = ChampMap.empty();

    for(String k: strKeys){
      map.set(k, k);
      p2 = p2.set(k, k);
    }

    for (String s : strKeys) {
      map.remove(s);
      p2 = p2.remove(s);
    }
    ChampMap<String, String> p1 = map.freeze();

    assertThat(p1).isEqualTo(p2);

  }

  @Test
  public void compares_as_equal_after_insert_many() {

    TransientChampMap<String, String> map = new TransientChampMap<>();
    ChampMap<String, String> p2 = ChampMap.empty();

    for(String k: strKeys){
      map.set(k, k);
      p2 = p2.set(k, k);
    }

    ChampMap<String, String> p1 = map.freeze();
    assertThat(p1).isEqualTo(p2);

  }

}


text:
// Copyright 2014 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "src/compiler/js-operator.h"

#include <limits>

#include "src/base/lazy-instance.h"
#include "src/compiler/opcodes.h"
#include "src/compiler/operator.h"

namespace v8 {
namespace internal {
namespace compiler {

std::ostream& operator<<(std::ostream& os, CallFunctionParameters const& p) {
  return os << p.arity() << ", " << p.flags() << ", " << p.language_mode();
}

const CallFunctionParameters& CallFunctionParametersOf(const Operator* op) {
  DCHECK_EQ(IrOpcode::kJSCallFunction, op->opcode());
  return OpParameter<CallFunctionParameters>(op);
}

bool operator==(CallRuntimeParameters const& lhs,
                CallRuntimeParameters const& rhs) {
  return lhs.id() == rhs.id() && lhs.arity() == rhs.arity();
}

bool operator!=(CallRuntimeParameters const& lhs,
                CallRuntimeParameters const& rhs) {
  return !(lhs == rhs);
}

size_t hash_value(CallRuntimeParameters const& p) {
  return base::hash_combine(p.id(), p.arity());
}

std::ostream& operator<<(std::ostream& os, CallRuntimeParameters const& p) {
  return os << p.id() << ", " << p.arity();
}

const CallRuntimeParameters& CallRuntimeParametersOf(const Operator* op) {
  DCHECK_EQ(IrOpcode::kJSCallRuntime, op->opcode());
  return OpParameter<CallRuntimeParameters>(op);
}

ContextAccess::ContextAccess(size_t depth, size_t index, bool immutable)
    : immutable_(immutable),
      depth_(static_cast<uint16_t>(depth)),
      index_(static_cast<uint32_t>(index)) {
  DCHECK(depth <= std::numeric_limits<uint16_t>::max());
  DCHECK(index <= std::numeric_limits<uint32_t>::max());
}

bool operator==(ContextAccess const& lhs, ContextAccess const& rhs) {
  return lhs.depth() == rhs.depth() && lhs.index() == rhs.index() &&
         lhs.immutable() == rhs.immutable();
}

bool operator!=(ContextAccess const& lhs, ContextAccess const& rhs) {
  return !(lhs == rhs);
}

size_t hash_value(ContextAccess const& access) {
  return base::hash_combine(access.depth(), access.index(), access.immutable());
}

std::ostream& operator<<(std::ostream& os, ContextAccess const& access) {
  return os << access.depth() << ", " << access.index() << ", "
            << access.immutable();
}

ContextAccess const& ContextAccessOf(Operator const* op) {
  DCHECK(op->opcode() == IrOpcode::kJSLoadContext ||
         op->opcode() == IrOpcode::kJSStoreContext);
  return OpParameter<ContextAccess>(op);
}

bool operator==(VectorSlotPair const& lhs, VectorSlotPair const& rhs) {
  return lhs.slot().ToInt() == rhs.slot().ToInt() &&
         lhs.vector().is_identical_to(rhs.vector());
}

size_t hash_value(VectorSlotPair const& p) {
  // TODO(mvstanton): include the vector in the hash.
  base::hash<int> h;
  return h(p.slot().ToInt());
}

bool operator==(LoadNamedParameters const& lhs,
                LoadNamedParameters const& rhs) {
  return lhs.name() == rhs.name() &&
         lhs.contextual_mode() == rhs.contextual_mode() &&
         lhs.feedback() == rhs.feedback();
}

bool operator!=(LoadNamedParameters const& lhs,
                LoadNamedParameters const& rhs) {
  return !(lhs == rhs);
}

size_t hash_value(LoadNamedParameters const& p) {
  return base::hash_combine(p.name(), p.contextual_mode(), p.feedback());
}

std::ostream& operator<<(std::ostream& os, LoadNamedParameters const& p) {
  return os << Brief(*p.name().handle()) << ", " << p.contextual_mode();
}

std::ostream& operator<<(std::ostream& os, LoadPropertyParameters const& p) {
  // Nothing special to print.
  return os;
}

bool operator==(LoadPropertyParameters const& lhs,
                LoadPropertyParameters const& rhs) {
  return lhs.feedback() == rhs.feedback();
}

bool operator!=(LoadPropertyParameters const& lhs,
                LoadPropertyParameters const& rhs) {
  return !(lhs == rhs);
}

const LoadPropertyParameters& LoadPropertyParametersOf(const Operator* op) {
  DCHECK_EQ(IrOpcode::kJSLoadProperty, op->opcode());
  return OpParameter<LoadPropertyParameters>(op);
}

size_t hash_value(LoadPropertyParameters const& p) {
  return hash_value(p.feedback());
}

const LoadNamedParameters& LoadNamedParametersOf(const Operator* op) {
  DCHECK_EQ(IrOpcode::kJSLoadNamed, op->opcode());
  return OpParameter<LoadNamedParameters>(op);
}

bool operator==(StoreNamedParameters const& lhs,
                StoreNamedParameters const& rhs) {
  return lhs.language_mode() == rhs.language_mode() && lhs.name() == rhs.name();
}

bool operator!=(StoreNamedParameters const& lhs,
                StoreNamedParameters const& rhs) {
  return !(lhs == rhs);
}

size_t hash_value(StoreNamedParameters const& p) {
  return base::hash_combine(p.language_mode(), p.name());
}

std::ostream& operator<<(std::ostream& os, StoreNamedParameters const& p) {
  return os << p.language_mode() << ", " << Brief(*p.name().handle());
}

const StoreNamedParameters& StoreNamedParametersOf(const Operator* op) {
  DCHECK_EQ(IrOpcode::kJSStoreNamed, op->opcode());
  return OpParameter<StoreNamedParameters>(op);
}

bool operator==(CreateClosureParameters const& lhs,
                CreateClosureParameters const& rhs) {
  return lhs.pretenure() == rhs.pretenure() &&
         lhs.shared_info().is_identical_to(rhs.shared_info());
}

bool operator!=(CreateClosureParameters const& lhs,
                CreateClosureParameters const& rhs) {
  return !(lhs == rhs);
}

size_t hash_value(CreateClosureParameters const& p) {
  // TODO(mstarzinger): Include hash of the SharedFunctionInfo here.
  base::hash<PretenureFlag> h;
  return h(p.pretenure());
}

std::ostream& operator<<(std::ostream& os, CreateClosureParameters const& p) {
  return os << p.pretenure() << ", " << Brief(*p.shared_info());
}

const CreateClosureParameters& CreateClosureParametersOf(const Operator* op) {
  DCHECK_EQ(IrOpcode::kJSCreateClosure, op->opcode());
  return OpParameter<CreateClosureParameters>(op);
}

#define CACHED_OP_LIST(V)                                 \
  V(Equal, Operator::kNoProperties, 2, 1)                 \
  V(NotEqual, Operator::kNoProperties, 2, 1)              \
  V(StrictEqual, Operator::kPure, 2, 1)                   \
  V(StrictNotEqual, Operator::kPure, 2, 1)                \
  V(UnaryNot, Operator::kPure, 1, 1)                      \
  V(ToBoolean, Operator::kPure, 1, 1)                     \
  V(ToNumber, Operator::kNoProperties, 1, 1)              \
  V(ToString, Operator::kNoProperties, 1, 1)              \
  V(ToName, Operator::kNoProperties, 1, 1)                \
  V(ToObject, Operator::kNoProperties, 1, 1)              \
  V(Yield, Operator::kNoProperties, 1, 1)                 \
  V(Create, Operator::kEliminatable, 0, 1)                \
  V(HasProperty, Operator::kNoProperties, 2, 1)           \
  V(TypeOf, Operator::kPure, 1, 1)                        \
  V(InstanceOf, Operator::kNoProperties, 2, 1)            \
  V(StackCheck, Operator::kNoProperties, 0, 0)            \
  V(CreateFunctionContext, Operator::kNoProperties, 1, 1) \
  V(CreateWithContext, Operator::kNoProperties, 2, 1)     \
  V(CreateBlockContext, Operator::kNoProperties, 2, 1)    \
  V(CreateModuleContext, Operator::kNoProperties, 2, 1)   \
  V(CreateScriptContext, Operator::kNoProperties, 2, 1)

#define CACHED_OP_LIST_WITH_LANGUAGE_MODE(V)           \
  V(LessThan, Operator::kNoProperties, 2, 1)           \
  V(GreaterThan, Operator::kNoProperties, 2, 1)        \
  V(LessThanOrEqual, Operator::kNoProperties, 2, 1)    \
  V(GreaterThanOrEqual, Operator::kNoProperties, 2, 1) \
  V(BitwiseOr, Operator::kNoProperties, 2, 1)          \
  V(BitwiseXor, Operator::kNoProperties, 2, 1)         \
  V(BitwiseAnd, Operator::kNoProperties, 2, 1)         \
  V(ShiftLeft, Operator::kNoProperties, 2, 1)          \
  V(ShiftRight, Operator::kNoProperties, 2, 1)         \
  V(ShiftRightLogical, Operator::kNoProperties, 2, 1)  \
  V(Add, Operator::kNoProperties, 2, 1)                \
  V(Subtract, Operator::kNoProperties, 2, 1)           \
  V(Multiply, Operator::kNoProperties, 2, 1)           \
  V(Divide, Operator::kNoProperties, 2, 1)             \
  V(Modulus, Operator::kNoProperties, 2, 1)            \
  V(StoreProperty, Operator::kNoProperties, 3, 0)

struct JSOperatorGlobalCache final {
#define CACHED(Name, properties, value_input_count, value_output_count)  \
  struct Name##Operator final : public Operator {                        \
    Name##Operator()                                                     \
        : Operator(IrOpcode::kJS##Name, properties, "JS" #Name,          \
                   value_input_count, Operator::ZeroIfPure(properties),  \
                   Operator::ZeroIfEliminatable(properties),             \
                   value_output_count, Operator::ZeroIfPure(properties), \
                   Operator::ZeroIfNoThrow(properties)) {}               \
  };                                                                     \
  Name##Operator k##Name##Operator;
  CACHED_OP_LIST(CACHED)
#undef CACHED

#define CACHED_WITH_LANGUAGE_MODE(Name, properties, value_input_count,        \
                                  value_output_count)                         \
  template <LanguageMode kLanguageMode>                                       \
  struct Name##Operator final : public Operator1<LanguageMode> {              \
    Name##Operator()                                                          \
        : Operator1<LanguageMode>(                                            \
              IrOpcode::kJS##Name, properties, "JS" #Name, value_input_count, \
              Operator::ZeroIfPure(properties),                               \
              Operator::ZeroIfEliminatable(properties), value_output_count,   \
              Operator::ZeroIfPure(properties),                               \
              Operator::ZeroIfNoThrow(properties), kLanguageMode) {}          \
  };                                                                          \
  Name##Operator<SLOPPY> k##Name##SloppyOperator;                             \
  Name##Operator<STRICT> k##Name##StrictOperator;                             \
  Name##Operator<STRONG> k##Name##StrongOperator;
  CACHED_OP_LIST_WITH_LANGUAGE_MODE(CACHED_WITH_LANGUAGE_MODE)
#undef CACHED_WITH_LANGUAGE_MODE
};

static base::LazyInstance<JSOperatorGlobalCache>::type kCache =
    LAZY_INSTANCE_INITIALIZER;

JSOperatorBuilder::JSOperatorBuilder(Zone* zone)
    : cache_(kCache.Get()), zone_(zone) {}

#define CACHED(Name, properties, value_input_count, value_output_count) \
  const Operator* JSOperatorBuilder::Name() {                           \
    return &cache_.k##Name##Operator;                                   \
  }
CACHED_OP_LIST(CACHED)
#undef CACHED

#define CACHED_WITH_LANGUAGE_MODE(Name, properties, value_input_count,  \
                                  value_output_count)                   \
  const Operator* JSOperatorBuilder::Name(LanguageMode language_mode) { \
    switch (language_mode) {                                            \
      case SLOPPY:                                                      \
        return &cache_.k##Name##SloppyOperator;                         \
      case STRICT:                                                      \
        return &cache_.k##Name##StrictOperator;                         \
      case STRONG:                                                      \
        return &cache_.k##Name##StrongOperator;                         \
      case STRONG_BIT:                                                  \
        break; /* %*!%^$#@ */                                           \
    }                                                                   \
    UNREACHABLE();                                                      \
    return nullptr;                                                     \
  }
CACHED_OP_LIST_WITH_LANGUAGE_MODE(CACHED_WITH_LANGUAGE_MODE)
#undef CACHED_WITH_LANGUAGE_MODE

const Operator* JSOperatorBuilder::CallFunction(size_t arity,
                                                CallFunctionFlags flags,
                                                LanguageMode language_mode) {
  CallFunctionParameters parameters(arity, flags, language_mode);
  return new (zone()) Operator1<CallFunctionParameters>(   // --
      IrOpcode::kJSCallFunction, Operator::kNoProperties,  // opcode
      "JSCallFunction",                                    // name
      parameters.arity(), 1, 1, 1, 1, 2,                   // inputs/outputs
      parameters);                                         // parameter
}

const Operator* JSOperatorBuilder::CallRuntime(Runtime::FunctionId id,
                                               size_t arity) {
  CallRuntimeParameters parameters(id, arity);
  const Runtime::Function* f = Runtime::FunctionForId(parameters.id());
  DCHECK(f->nargs == -1 || f->nargs == static_cast<int>(parameters.arity()));
  return new (zone()) Operator1<CallRuntimeParameters>(   // --
      IrOpcode::kJSCallRuntime, Operator::kNoProperties,  // opcode
      "JSCallRuntime",                                    // name
      parameters.arity(), 1, 1, f->result_size, 1, 2,     // inputs/outputs
      parameters);                                        // parameter
}

const Operator* JSOperatorBuilder::CallConstruct(int arguments) {
  return new (zone()) Operator1<int>(                       // --
      IrOpcode::kJSCallConstruct, Operator::kNoProperties,  // opcode
      "JSCallConstruct",                                    // name
      arguments, 1, 1, 1, 1, 2,                             // counts
      arguments);                                           // parameter
}

const Operator* JSOperatorBuilder::LoadNamed(const Unique<Name>& name,
                                             const VectorSlotPair& feedback,
                                             ContextualMode contextual_mode,
                                             PropertyICMode load_ic) {
  LoadNamedParameters parameters(name, feedback, contextual_mode, load_ic);
  return new (zone()) Operator1<LoadNamedParameters>(   // --
      IrOpcode::kJSLoadNamed, Operator::kNoProperties,  // opcode
      "JSLoadNamed",                                    // name
      1, 1, 1, 1, 1, 2,                                 // counts
      parameters);                                      // parameter
}

const Operator* JSOperatorBuilder::LoadProperty(
    const VectorSlotPair& feedback) {
  LoadPropertyParameters parameters(feedback);
  return new (zone()) Operator1<LoadPropertyParameters>(   // --
      IrOpcode::kJSLoadProperty, Operator::kNoProperties,  // opcode
      "JSLoadProperty",                                    // name
      2, 1, 1, 1, 1, 2,                                    // counts
      parameters);                                         // parameter
}

const Operator* JSOperatorBuilder::StoreNamed(LanguageMode language_mode,
                                              const Unique<Name>& name,
                                              PropertyICMode store_ic) {
  StoreNamedParameters parameters(language_mode, name, store_ic);
  return new (zone()) Operator1<StoreNamedParameters>(   // --
      IrOpcode::kJSStoreNamed, Operator::kNoProperties,  // opcode
      "JSStoreNamed",                                    // name
      2, 1, 1, 0, 1, 2,                                  // counts
      parameters);                                       // parameter
}

const Operator* JSOperatorBuilder::DeleteProperty(LanguageMode language_mode) {
  return new (zone()) Operator1<LanguageMode>(               // --
      IrOpcode::kJSDeleteProperty, Operator::kNoProperties,  // opcode
      "JSDeleteProperty",                                    // name
      2, 1, 1, 1, 1, 2,                                      // counts
      language_mode);                                        // parameter
}

const Operator* JSOperatorBuilder::LoadContext(size_t depth, size_t index,
                                               bool immutable) {
  ContextAccess access(depth, index, immutable);
  return new (zone()) Operator1<ContextAccess>(  // --
      IrOpcode::kJSLoadContext,                  // opcode
      Operator::kNoWrite | Operator::kNoThrow,   // flags
      "JSLoadContext",                           // name
      1, 1, 0, 1, 1, 0,                          // counts
      access);                                   // parameter
}

const Operator* JSOperatorBuilder::StoreContext(size_t depth, size_t index) {
  ContextAccess access(depth, index, false);
  return new (zone()) Operator1<ContextAccess>(  // --
      IrOpcode::kJSStoreContext,                 // opcode
      Operator::kNoRead | Operator::kNoThrow,    // flags
      "JSStoreContext",                          // name
      2, 1, 1, 0, 1, 0,                          // counts
      access);                                   // parameter
}

const Operator* JSOperatorBuilder::CreateClosure(
    Handle<SharedFunctionInfo> shared_info, PretenureFlag pretenure) {
  CreateClosureParameters parameters(shared_info, pretenure);
  return new (zone()) Operator1<CreateClosureParameters>(  // --
      IrOpcode::kJSCreateClosure, Operator::kNoThrow,      // opcode
      "JSCreateClosure",                                   // name
      1, 1, 1, 1, 1, 0,                                    // counts
      parameters);                                         // parameter
}

const Operator* JSOperatorBuilder::CreateLiteralArray(int literal_flags) {
  return new (zone()) Operator1<int>(                            // --
      IrOpcode::kJSCreateLiteralArray, Operator::kNoProperties,  // opcode
      "JSCreateLiteralArray",                                    // name
      3, 1, 1, 1, 1, 2,                                          // counts
      literal_flags);                                            // parameter
}

const Operator* JSOperatorBuilder::CreateLiteralObject(int literal_flags) {
  return new (zone()) Operator1<int>(                             // --
      IrOpcode::kJSCreateLiteralObject, Operator::kNoProperties,  // opcode
      "JSCreateLiteralObject",                                    // name
      3, 1, 1, 1, 1, 2,                                           // counts
      literal_flags);                                             // parameter
}

const Operator* JSOperatorBuilder::CreateCatchContext(
    const Unique<String>& name) {
  return new (zone()) Operator1<Unique<String>>(                 // --
      IrOpcode::kJSCreateCatchContext, Operator::kNoProperties,  // opcode
      "JSCreateCatchContext",                                    // name
      2, 1, 1, 1, 1, 2,                                          // counts
      name);                                                     // parameter
}

}  // namespace compiler
}  // namespace internal
}  // namespace v8


text:
const projectBasePath = require('path').resolve(__dirname, '../../')

const WebpackIsomorphicTools = require('webpack-isomorphic-tools')
global.webpackIsomorphicTools = new WebpackIsomorphicTools(require('../../webpack-isomorphic-tools'))
  .development(process.env.NODE_ENV === 'development')
  .server(projectBasePath, () => {
    const server = process.env.NODE_ENV === 'development' ? './server.dev' : './server'
    require(server)
  })


text:
/* -*- Mode: c++; c-basic-offset: 2; indent-tabs-mode: nil; tab-width: 40 -*- */
/* vim: set ts=2 et sw=2 tw=80: */
/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this file,
 * You can obtain one at http://mozilla.org/MPL/2.0/. */

#ifndef mozilla_dom_bluetooth_bluedroid_bluetoothdaemonsocketinterface_h__
#define mozilla_dom_bluetooth_bluedroid_bluetoothdaemonsocketinterface_h__

#include "BluetoothDaemonHelpers.h"
#include "BluetoothInterface.h"
#include "BluetoothInterfaceHelpers.h"

BEGIN_BLUETOOTH_NAMESPACE

using namespace mozilla::ipc;

class BlutoothDaemonInterface;

class BluetoothDaemonSocketModule
{
public:
  virtual nsresult Send(BluetoothDaemonPDU* aPDU, void* aUserData) = 0;

  // Commands
  //

  nsresult ListenCmd(BluetoothSocketType aType,
                     const nsAString& aServiceName,
                     const uint8_t aServiceUuid[16],
                     int aChannel, bool aEncrypt, bool aAuth,
                     BluetoothSocketResultHandler* aRes);

  nsresult ConnectCmd(const nsAString& aBdAddr,
                      BluetoothSocketType aType,
                      const uint8_t aUuid[16],
                      int aChannel, bool aEncrypt, bool aAuth,
                      BluetoothSocketResultHandler* aRes);

  nsresult AcceptCmd(int aFd, BluetoothSocketResultHandler* aRes);

  nsresult CloseCmd(BluetoothSocketResultHandler* aRes);

protected:

  void HandleSvc(const BluetoothDaemonPDUHeader& aHeader,
                 BluetoothDaemonPDU& aPDU, void* aUserData);

  nsresult Send(BluetoothDaemonPDU* aPDU, BluetoothSocketResultHandler* aRes);

private:
  class AcceptWatcher;
  class ConnectWatcher;
  class ListenInitOp;

  uint8_t SocketFlags(bool aEncrypt, bool aAuth);

  // Responses
  //

  typedef BluetoothResultRunnable0<BluetoothSocketResultHandler, void>
    ResultRunnable;

  typedef BluetoothResultRunnable1<BluetoothSocketResultHandler, void,
                                   int, int>
    IntResultRunnable;

  typedef BluetoothResultRunnable1<BluetoothSocketResultHandler, void,
                                   BluetoothStatus, BluetoothStatus>
    ErrorRunnable;

  typedef BluetoothResultRunnable3<BluetoothSocketResultHandler, void,
                                   int, nsString, int,
                                   int, const nsAString_internal&, int>
    IntStringIntResultRunnable;

  void ErrorRsp(const BluetoothDaemonPDUHeader& aHeader,
                BluetoothDaemonPDU& aPDU,
                BluetoothSocketResultHandler* aRes);

  void ListenRsp(const BluetoothDaemonPDUHeader& aHeader,
                 BluetoothDaemonPDU& aPDU,
                 BluetoothSocketResultHandler* aRes);

  void ConnectRsp(const BluetoothDaemonPDUHeader& aHeader,
                  BluetoothDaemonPDU& aPDU,
                  BluetoothSocketResultHandler* aRes);
};

class BluetoothDaemonSocketInterface MOZ_FINAL
  : public BluetoothSocketInterface
{
public:
  BluetoothDaemonSocketInterface(BluetoothDaemonSocketModule* aModule);
  ~BluetoothDaemonSocketInterface();

  void Listen(BluetoothSocketType aType,
              const nsAString& aServiceName,
              const uint8_t aServiceUuid[16],
              int aChannel, bool aEncrypt, bool aAuth,
              BluetoothSocketResultHandler* aRes);

  void Connect(const nsAString& aBdAddr,
               BluetoothSocketType aType,
               const uint8_t aUuid[16],
               int aChannel, bool aEncrypt, bool aAuth,
               BluetoothSocketResultHandler* aRes);

  void Accept(int aFd, BluetoothSocketResultHandler* aRes);

  void Close(BluetoothSocketResultHandler* aRes);

private:
  BluetoothDaemonSocketModule* mModule;
};

END_BLUETOOTH_NAMESPACE

#endif


text:
#pragma once
#include <aws/macie2/Macie2_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>

namespace Aws
{
namespace Utils
{
namespace Json
{
  class JsonValue;
  class JsonView;
} // namespace Json
} // namespace Utils
namespace Macie2
{
namespace Model
{

  /**
   *
Provides information about the user who owns an S3 bucket.

See
   * Also:
   AWS
   * API Reference

   */
  class AWS_MACIE2_API S3BucketOwner
  {
  public:
    S3BucketOwner();
    S3BucketOwner(Aws::Utils::Json::JsonView jsonValue);
    S3BucketOwner& operator=(Aws::Utils::Json::JsonView jsonValue);
    Aws::Utils::Json::JsonValue Jsonize() const;

    /**
     *
The display name of the user who owns the bucket.

     */
    inline const Aws::String& GetDisplayName() const{ return m_displayName; }

    /**
     *
The display name of the user who owns the bucket.

     */
    inline bool DisplayNameHasBeenSet() const { return m_displayNameHasBeenSet; }

    /**
     *
The display name of the user who owns the bucket.

     */
    inline void SetDisplayName(const Aws::String& value) { m_displayNameHasBeenSet = true; m_displayName = value; }

    /**
     *
The display name of the user who owns the bucket.

     */
    inline void SetDisplayName(Aws::String&& value) { m_displayNameHasBeenSet = true; m_displayName = std::move(value); }

    /**
     *
The display name of the user who owns the bucket.

     */
    inline void SetDisplayName(const char* value) { m_displayNameHasBeenSet = true; m_displayName.assign(value); }

    /**
     *
The display name of the user who owns the bucket.

     */
    inline S3BucketOwner& WithDisplayName(const Aws::String& value) { SetDisplayName(value); return *this;}

    /**
     *
The display name of the user who owns the bucket.

     */
    inline S3BucketOwner& WithDisplayName(Aws::String&& value) { SetDisplayName(std::move(value)); return *this;}

    /**
     *
The display name of the user who owns the bucket.

     */
    inline S3BucketOwner& WithDisplayName(const char* value) { SetDisplayName(value); return *this;}

    /**
     *
The Amazon Web Services account ID for the user who owns the bucket.

     */
    inline const Aws::String& GetId() const{ return m_id; }

    /**
     *
The Amazon Web Services account ID for the user who owns the bucket.

     */
    inline bool IdHasBeenSet() const { return m_idHasBeenSet; }

    /**
     *
The Amazon Web Services account ID for the user who owns the bucket.

     */
    inline void SetId(const Aws::String& value) { m_idHasBeenSet = true; m_id = value; }

    /**
     *
The Amazon Web Services account ID for the user who owns the bucket.

     */
    inline void SetId(Aws::String&& value) { m_idHasBeenSet = true; m_id = std::move(value); }

    /**
     *
The Amazon Web Services account ID for the user who owns the bucket.

     */
    inline void SetId(const char* value) { m_idHasBeenSet = true; m_id.assign(value); }

    /**
     *
The Amazon Web Services account ID for the user who owns the bucket.

     */
    inline S3BucketOwner& WithId(const Aws::String& value) { SetId(value); return *this;}

    /**
     *
The Amazon Web Services account ID for the user who owns the bucket.

     */
    inline S3BucketOwner& WithId(Aws::String&& value) { SetId(std::move(value)); return *this;}

    /**
     *
The Amazon Web Services account ID for the user who owns the bucket.

     */
    inline S3BucketOwner& WithId(const char* value) { SetId(value); return *this;}

  private:

    Aws::String m_displayName;
    bool m_displayNameHasBeenSet;

    Aws::String m_id;
    bool m_idHasBeenSet;
  };

} // namespace Model
} // namespace Macie2
} // namespace Aws


text:
from xobj import xobj

from robj import errors
from robj.glue import HTTPClient
from robj.http.request import Response
from robj_test import robjhelp as testsuite

class ClientTest(testsuite.TestCase):
    def setUp(self):
        testsuite.TestCase.setUp(self)
        self._client = HTTPClient(self.server.geturi('/api/'))

    def testGET(self):
        robj = self._client.do_GET('/')
        api = robj._root

        model = self.getModel('/api')

        # Make sure the xobj that we got from the client layer matches the model
        # on the server side.
        self.failUnlessEqual(api.id, model.id)
        self.failUnlessEqual(api.employees.href, model.employees.href)
        self.failUnlessEqual(api.products.href, model.products.href)
        self.failUnlessEqual(api.version, model.version)

    def testPOST(self):
        # Test POST of an XObj object tree.
        xml = self.getArchiveContents('employee1.xml')
        doc = xobj.parse(xml)
        model = doc.employee

        robj = self._client.do_POST('/employees', model)
        employee = robj._root

        # Make sure the model that is returned matches the one that was sent.
        self.failUnlessEqual(model.name, employee.name)
        self.failUnlessEqual(model.address.street, employee.address.street)
        self.failUnlessEqual(model.address.city, employee.address.city)
        self.failUnlessEqual(model.address.state, employee.address.state)
        self.failUnlessEqual(model.address.zipcode, employee.address.zipcode)
        self.failUnlessEqual(model.phone, employee.phone)
        self.failUnlessEqual(employee.employeeid, '0')
        self.failUnlessEqual(employee.id, '/api/employees/0')

        # Make sure there is an error raised when no document is provided.
        self.failUnlessRaises(TypeError, self._client.do_POST, '/employees')

        # Make sure POST of an XObj document works.
        xml2 = self.getArchiveContents('employee2.xml')
        doc2 = xobj.parse(xml2)

        robj = self._client.do_POST('/employees', doc2)
        employee2 = robj._root

        self.failUnlessEqual(doc2.employee.name, employee2.name)
        self.failUnlessEqual(employee2.employeeid, '1')

    def testPUT(self):
        xml = self.getArchiveContents('employee1.xml')
        doc = xobj.parse(xml)
        model = doc.employee

        # Start by creating the resource
        robj = self._client.do_POST('/employees', model)
        employee = robj._root

        # Make sure the resource matches what we posted
        self.failUnlessEqual(model.phone, employee.phone)

        # Change the phone number.
        employee.phone = '12345'
        robj = self._client.do_PUT(employee.id, employee)
        employee2 = robj._root

        self.failIfEqual(model.phone, employee.phone)
        self.failUnlessEqual(employee.phone, employee2.phone)

    def testDELETE(self):
        xml = self.getArchiveContents('employee1.xml')
        doc = xobj.parse(xml)

        uri = self._client.do_POST('/employees', doc)._root.id

        response = self._client.do_DELETE(uri)
        self.failUnlessEqual(response.status, 200)

        response2 = self._client.do_DELETE(uri)
        self.failUnlessEqual(response2.status, 404)

    def testDELETE204(self):
        xml = self.getArchiveContents('product1.xml')
        doc = xobj.parse(xml)

        uri = self._client.do_POST('/products', doc)._root.id

        response = self._client.do_DELETE(uri)
        self.failUnlessEqual(response.status, 204)

        response2 = self._client.do_DELETE(uri)
        self.failUnlessEqual(response2.status, 404)

    def testRedirect(self):
        def testFail(eclass, path):
            self.failUnlessRaises(eclass, self._client.do_GET, path)
        def clearCache():
            self._client.cache.clear()
            self._client._redirects = {}

        error = errors.HTTPUnhandledRedirectError
        testFail(error, '/redirects/300')
        testFail(error, '/redirects/305')

        obj = self._client.do_GET('/redirects/301')
        self.failUnless('/redirects/301' in self._client._redirects)
        self.failUnless(obj in self._client.cache.values())
        self.failUnlessEqual(obj._uri,
            self._client._redirects['/redirects/301'])

        clearCache()

        obj = self._client.do_GET('/redirects/302')
        self.failIf('/redirects/302' in self._client._redirects)
        self.failUnless(obj in self._client.cache.values())
        self.failUnlessEqual(obj._uri, '/redirects/302')

        clearCache()

        obj = self._client.do_GET('/redirects/303')
        self.failIf('/redirects/303' in self._client._redirects)
        self.failUnless(obj in self._client.cache.values())
        self.failUnlessEqual(obj._uri, '/employees')

        clearCache()

        obj = self._client.do_GET('/redirects/304')
        self.failIf('/redirects/304' in self._client._redirects)
        self.failUnless(obj in self._client.cache.values())
        self.failUnlessEqual(obj._uri, '/redirects/304')

        clearCache()

        obj = self._client.do_GET('/redirects/307')
        self.failIf('/redirects/307' in self._client._redirects)
        self.failIf(obj in self._client.cache.values())
        self.failUnlessEqual(obj._uri, '/redirects/307')

        clearCache()

        self.failUnlessRaises(errors.HTTPMaxRedirectReachedError,
            self._client.do_GET, '/redirects/loop')

        self.failUnlessRaises(errors.HTTPMaxRedirectReachedError,
            self._client.do_GET, '/redirects/1')

    def testErrors(self):
        # test delete error path
        self.failUnlessRaises(errors.HTTPDeleteError,
            self._client.do_DELETE, '/')

        # test normal error path
        self.failUnlessRaises(errors.HTTPNotImplementedError,
            self._client.do_POST, '/', '')

        # test ignored error path
        self._client.error_exceptions[404] = None
        response = self._client.do_GET('/foobar')
        self.failUnless(isinstance(response, Response))

    def testNormalizeUri(self):
        path = self._client._client.path
        baseUri = self._client._client.baseURI

        tests = (
            (baseUri + '/foobar', '/foobar'),
            (path + '/foobar', '/foobar'),
            ('/foobar/', '/foobar'),
        )

        for input, expected in tests:
            self.failUnlessEqual(self._client._normalize_uri(input), expected)

        self.failUnlessRaises(errors.ExternalUriError,
            self._client._normalize_uri, 'httpd://foobar')

    def testSerialize(self):
        self.failUnlessRaises(errors.SerializationError,
            self._client._serialize_document, object())


text:
class Article < ActiveRecord::Base
  has_many :comments, as: :commentable
  belongs_to :category
  belongs_to :user

  validates :title, presence: true, length: {maximum: 140}
  validates :text, presence: true, length: {maximum: 4000}

  acts_as_votable
end


text:
namespace Mono.Cecil.Tests {

	using System;
	using System.IO;
	using System.Collections;

	using NUnit.Framework;

	using Mono.Cecil;

	class Language {

		string m_compiler;
		string m_command;

		public string Compiler {
			get { return m_compiler; }
		}

		public string Command {
			get { return m_command; }
		}

		public Language (string compiler, string command)
		{
			m_compiler = compiler;
			m_command = command;
		}

		static IDictionary m_languages = new Hashtable ();

		static Language ()
		{
<%
	$languages.each { |l|
%>
			m_languages.Add ("<%= l.name %>", new Language (
				"<%= l.compiler %>",
				"<%= l.command %>"
			));
<%
	}
%>
		}

		public static Language GetLanguage (string name)
		{
			return (Language) m_languages [name];
		}
	}

	class TestCase {

		Language m_lang;
		FileInfo m_file;

		public TestCase (Language lang, string file)
		{
			m_lang = lang;
			m_file = new FileInfo (file);
		}
	}

	[TestFixture]
	class GeneratedTests {

		void Test (TestCase test)
		{
		}

<%
	$tests.each { |test|
%>
		[Test]
		public void <%= test.method %> ()
		{
			Test (new TestCase (
				Language.GetLanguage ("<%= test.lang.name %>"),
				@"<%= test.file %>"));
		}
<%
	}
%>
	}
}


text:
require 'thin'
require 'sinatra'
require "json"
require "rack/fiber_pool"
require "fiber"

class Channel
  attr_reader :callbacks

  MESSAGE_BACKLOG = 200

  def initialize
    @messages, @callbacks = [], []
  end

  def append_message(nick, type, text = "")
    m = { :nick => nick, :type => type, :text => text, :timestamp => Time.new.to_i }

    puts case type
      when :msg then "<#{nick}> #{text}"
      when :join then "#{nick} join"
      when :part then "#{nick} part"
    end

    @messages << m

    while @callbacks.length > 0
      @callbacks.shift[:callback].call([m])
    end

    while (@messages.length > MESSAGE_BACKLOG)
      @messages.shift
    end
  end

  def query(since, callback)
    matching = []

    @messages.each do |m|
      matching << m if m[:timestamp] > since
    end

    if matching.length > 0
      callback.call(matching)
    else
      fiber = Fiber.current
      @callbacks << { :timestamp => Time.new, :callback => Proc.new { |messages|
        fiber.resume(messages)
      }}
      callback.call(Fiber.yield)
    end
  end
end

class Session
  attr_reader :id, :nick, :timestamp

  def initialize(nick)
    @id, @nick, @timestamp = (rand*99999999999).floor.to_s, nick, Time.new
  end

  def poke
    @timestamp = Time.new
  end
end

$start_time = Time.new.to_i * 1000
$mem = `ps -o rss= -p #{Process.pid}`.to_i * 1024
$channel = Channel.new
$sessions = {}

CALLBACK_TIMEOUT = 25
SESSION_TIMEOUT = 60

use Rack::FiberPool

set :public, File.dirname(__FILE__) + '/public'

helpers do
  def create_session(nick)
    return nil if nick.length > 50
    return nil if !(/[^\w_\-^!]/ =~ nick).nil?
    return nil if !$sessions.select { |id, session| session.nick == nick}.empty?

    session = Session.new(nick)
    $sessions[session.id] = session;
    session;
  end

  def json_error(error)
    status 400
    content_type :json
    return error.to_json
  end
end

get '/' do
  redirect '/index.html'
end

get '/who' do
  nicks = []
  $sessions.each do |id, session|
    nicks << session.nick
  end
  content_type :json
  { :nicks => nicks, :rss => $mem }.to_json
end

get '/join' do
  puts "/join"
  nick = params[:nick]
  return json_error({ :error => 'Bad nick.' }) if nick.empty?
  session = create_session(nick)
  return json_error({ :error => 'Nick in use' }) if session.nil?
  $channel.append_message(session.nick, :join)
  content_type :json
  { :id => session.id, :nick => session.nick, :rss => $mem, :starttime => $start_time }.to_json
end

get '/part' do
  id = params[:id]
  session = $sessions[id]
  if !session.nil?
    $channel.append_message(session.nick, :part)
    $sessions.delete_if { |id, s| id == session.id }
  end
  content_type :json
  { :rss => $mem }.to_json
end

get '/recv' do
  puts '/recv'
  since = params[:since]
  return json_error({ :error => 'Must supply since parameter' }) if since.empty?
  since = since.to_i

  id = params[:id]
  session = $sessions[id]

  $channel.query(since, Proc.new {|messages|
    session.poke if !session.nil?
    content_type :json
    { :messages => messages, :rss => $mem }.to_json
  })
end

get '/send' do
  id, text = params[:id], params[:text]
  return json_error({ :error => 'No such session id' }) if id.empty? || text.empty?

  session = $sessions[id]
  return json_error({ :error => 'No such session id' }) if session.nil?

  session.poke

  $channel.append_message(session.nick, :msg, text)
  content_type :json
  { :rss => $mem }.to_json
end

EventMachine::next_tick {
  EventMachine::add_periodic_timer(10) do
    $mem = `ps -o rss= -p #{Process.pid}`.to_i * 1024
  end
}

EventMachine::next_tick {
  EventMachine::add_periodic_timer(3) do
    now = Time.new
    while !$channel.callbacks.empty? && now - $channel.callbacks[0][:timestamp] > CALLBACK_TIMEOUT
      $channel.callbacks.shift[:callback].call([])
    end
  end
}

EventMachine::next_tick {
  EventMachine::add_periodic_timer(1) do
    now = Time.new
    $sessions.each do |id, session|
      if now - session.timestamp > SESSION_TIMEOUT
        $channel.append_message(session.nick, :part)
        $sessions.delete_if { |id, session| id == session.id }
      end
    end
  end
}


text:
<?php

namespace Elastica\Aggregation;

/**
 * Class DateRange.
 *
 * @see https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-bucket-daterange-aggregation.html
 */
class DateRange extends Range
{
    /**
     * Set the formatting for the returned date values.
     *
     * @param string $format see documentation for formatting options
     *
     * @return $this
     */
    public function setFormat(string $format): self
    {
        return $this->setParam('format', $format);
    }

    /**
     * Set time zone.
     */
    public function setTimezone(string $timezone): self
    {
        return $this->setParam('time_zone', $timezone);
    }
}


text:
UCLASS( ClassGroup=(Custom), meta=(BlueprintSpawnableComponent) )
class S05_TESTINGGROUNDS_API UActorPool : public UActorComponent
{
	GENERATED_BODY()

public:
	// Sets default values for this component's properties
	UActorPool();

	AActor* Checkout();
	void Return(AActor* ActorToReturn);

	void Add(AActor* ActorToAdd);

private:
	TArray<AActor*> Pool;
};


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

<title>org.bouncycastle.crypto.generators (Bouncy Castle Library 1.54 API Specification)</title>
<meta name="date" content="2015-12-29">
<link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style">

JavaScript is disabled on your browser.

Overview

Package

Class

Tree

Deprecated

Index

Help

Bouncy Castle Cryptography Library 1.54

Prev Package

Next Package

Frames

No Frames

All Classes

Package org.bouncycastle.crypto.generators

Generators for keys, key pairs and password based encryption algorithms.

See: Description

Class Summary

Class
Description

BaseKDFBytesGenerator

Basic KDF generator for derived keys and ivs as defined by IEEE P1363a/ISO
 18033

 This implementation is based on ISO 18033/P1363a.

BCrypt

Core of password hashing scheme Bcrypt,
 designed by Niels Provos and David Mazières,
 corresponds to the C reference implementation.

CramerShoupKeyPairGenerator

a Cramer Shoup key pair generator

CramerShoupParametersGenerator

DESedeKeyGenerator

DESKeyGenerator

DHBasicKeyPairGenerator

a basic Diffie-Hellman key pair generator.

DHKeyPairGenerator

a Diffie-Hellman key pair generator.

DHParametersGenerator

DSAKeyPairGenerator

a DSA key pair generator.

DSAParametersGenerator

Generate suitable parameters for DSA, in line with FIPS 186-2, or FIPS 186-3.

DSTU4145KeyPairGenerator

ECKeyPairGenerator

ElGamalKeyPairGenerator

a ElGamal key pair generator.

ElGamalParametersGenerator

EphemeralKeyPairGenerator

GOST3410KeyPairGenerator

a GOST3410 key pair generator.

GOST3410ParametersGenerator

generate suitable parameters for GOST3410.

HKDFBytesGenerator

HMAC-based Extract-and-Expand Key Derivation Function (HKDF) implemented
 according to IETF RFC 5869, May 2010 as specified by H.

KDF1BytesGenerator

KDF1 generator for derived keys and ivs as defined by IEEE P1363a/ISO 18033

 This implementation is based on ISO 18033/IEEE P1363a.

KDF2BytesGenerator

KDF2 generator for derived keys and ivs as defined by IEEE P1363a/ISO 18033

 This implementation is based on IEEE P1363/ISO 18033.

KDFCounterBytesGenerator

This KDF has been defined by the publicly available NIST SP 800-108 specification.

KDFDoublePipelineIterationBytesGenerator

This KDF has been defined by the publicly available NIST SP 800-108 specification.

KDFFeedbackBytesGenerator

This KDF has been defined by the publicly available NIST SP 800-108 specification.

MGF1BytesGenerator

Generator for MGF1 as defined in PKCS 1v2

NaccacheSternKeyPairGenerator

Key generation parameters for NaccacheStern cipher.

OpenBSDBCrypt

Password hashing scheme BCrypt,
 designed by Niels Provos and David Mazières, using the
 String format and the Base64 encoding
 of the reference implementation on OpenBSD

OpenSSLPBEParametersGenerator

Generator for PBE derived keys and ivs as usd by OpenSSL.

PKCS12ParametersGenerator

Generator for PBE derived keys and ivs as defined by PKCS 12 V1.0.

PKCS5S1ParametersGenerator

Generator for PBE derived keys and ivs as defined by PKCS 5 V2.0 Scheme 1.

PKCS5S2ParametersGenerator

Generator for PBE derived keys and ivs as defined by PKCS 5 V2.0 Scheme 2.

Poly1305KeyGenerator

Generates keys for the Poly1305 MAC.

RSABlindingFactorGenerator

Generate a random factor suitable for use with RSA blind signatures
 as outlined in Chaum's blinding and unblinding as outlined in
 "Handbook of Applied Cryptography", page 475.

RSAKeyPairGenerator

an RSA key pair generator.

SCrypt

Implementation of the scrypt a password-based key derivation function.

Package org.bouncycastle.crypto.generators Description

Generators for keys, key pairs and password based encryption algorithms.

Overview

Package

Class

Tree

Deprecated

Index

Help

Bouncy Castle Cryptography Library 1.54

Prev Package

Next Package

Frames

No Frames

All Classes


text:
<?php
/**
 * Classe du champ media
 *
 * @package		form
 * @author		Michaël V. Dandrieux <@mvdandrieux>
 * @author		Sylvain Frigui <sf@hands.agency>
 * @access		public
 * @link		http://grandcentral.fr
 */
class fieldFile extends _fields
{
	protected $datatype = array('array');
	protected $mediatype;
/**
 * Créer un nouveau champ text et le peupler de ses attributs
 *
 * ex :
 * $param = array(
 * 	'label' => 'The title',
 * 	'descr' => 'Put here the short title',
 * 	'value' => 'Home',
 * 	'cssclass' => 'title',
 * 	'placeholder' => 'Give me a title',
 * 	'required' => true,
 * 	'disabled' => false,
 * 	'readonly' => true,
 * 	'min' => 5,
 * 	'max' => 30,
 * 	...
 * );
 * new field_text('title', $param);
 *
 * @param	string	le nom du champ
 * @param	array	le tableau de paramètres du champ
 * @access	public
 */
	public function __construct($name, $attrs = null)
	{
		parent::__construct($name, $attrs);
		$this->attrs['type'] = 'file';
	}
/**
 * Affecte les types de médias autorisés
 *
 * @param	array	les tableau des types
 * @access	public
 */
	public function set_mediatype($value)
	{
		$this->mediatype = (array) $value;
		return $this;
	}

/**
 * Obtenir la définition des propriétés du champ
 *
 * @return	array 	la liste des propriétés et leurs définitions
 * @access	public
 * @static
 */
	public static function get_properties()
	{

		$properties = parent::get_properties();
		$properties['mediatype'] = 'array';

		return $properties;
	}
}
?>


text:
/**
\brief A BSP module which abstracts away the "bsp_timer" and "radiotimer"
       modules behind the "sctimer".

\author Xavi Vilajosana <xvilajosana@eecs.berkeley.edu>, May 2012.
\author Thomas Watteyne <watteyne@eecs.berkeley.edu>, May 2012.
 */

#include "openwsn.h"
#include "bsp_timer.h"
#include "radiotimer.h"
#include "sctimer.h"
#include "debugpins.h"

//=========================== defines =========================================

#define ABSTIMER_GUARD_TICKS 2

typedef void (*abstimer_cbt)();

//=========================== variables =======================================

typedef enum {
   ABSTIMER_SRC_BSP_TIMER = 0,
   ABSTIMER_SRC_RADIOTIMER_OVERFLOW,
   ABSTIMER_SRC_RADIOTIMER_COMPARE,
   ABSTIMER_SRC_MAX,
} abstimer_src_t;

typedef struct {
   uint16_t                  num_bsp_timer;
   uint16_t                  num_radiotimer_overflow;
   uint16_t                  num_radiotimer_compare;
   uint16_t                  num_late_schedule;
   uint16_t                  nested_isr;
   uint16_t                  consecutive_late;    // total time of the scheduled bsp timer (relative value)
   uint16_t                  count_late;
} abstimer_dbg_t;

abstimer_dbg_t abstimer_dbg;

typedef struct {
   // admin
   bool                      initialized;
   uint16_t                  currentTime;        // current "theoretical" time
   uint16_t                  nextCurrentTime;    // next "theoretical" time
   // timer values
   abstimer_cbt              callback[ABSTIMER_SRC_MAX];
   bool                      isArmed[ABSTIMER_SRC_MAX];
   uint16_t                  compareVal[ABSTIMER_SRC_MAX];
   // radiotimers-specific variables
   uint16_t                  radiotimer_period;
   uint16_t                  radiotimer_overflow_previousVal;
   uint16_t                  radiotimer_compare_offset;
   // bsp-timer-specific variables
   uint16_t                  bsp_timer_total;    // total time of the scheduled bsp timer (relative value)
   //poipoi
   uint8_t                   bitmapInterruptsFired;
} abstimer_vars_t;

abstimer_vars_t abstimer_vars;

//=========================== prototypes ======================================

void     abstimer_init();
void     abstimer_reschedule();
void     sctimer_init();
void     sctimer_schedule(uint16_t val);
uint16_t sctimer_getValue();

//=========================== public ==========================================

//===== from bsp_timer
//void bsp_timer_init() {
//   abstimer_init();
//}
//
//void bsp_timer_set_callback(bsp_timer_cbt cb) {
//   abstimer_vars.callback[ABSTIMER_SRC_BSP_TIMER]               = cb;
//}
//
///**
//\brief Clears the hardware timer and the current data structures, i.e. resets everything.
//*/
//void bsp_timer_reset() {
//   bsp_timer_cancel_schedule();
//}
//
///**
//\brief Schedules the bsp timer to fire in delayTicks.
//*/
//void bsp_timer_scheduleIn(PORT_TIMER_WIDTH delayTicks) {
//   INTERRUPT_DECLARATION();
//   DISABLE_INTERRUPTS();
//   // keep ticks
//   abstimer_vars.bsp_timer_total                                = delayTicks;
//
//   // set the compare value (since last one)
//   abstimer_vars.compareVal[ABSTIMER_SRC_BSP_TIMER]            += delayTicks;
//
//   // I'm using this timer
//   abstimer_vars.isArmed[ABSTIMER_SRC_BSP_TIMER]                = TRUE;
//
//   // reschedule
//   abstimer_reschedule();
//   ENABLE_INTERRUPTS();
//}
//
///**
// * cancels the bsp timer.
// * sets it to not running and schedules any other running timer
// */
//void bsp_timer_cancel_schedule() {
//   INTERRUPT_DECLARATION();
//   DISABLE_INTERRUPTS();
//   // clear total tics.
//   abstimer_vars.bsp_timer_total                                = 0;
//
//   // clear the compare value
//   abstimer_vars.compareVal[ABSTIMER_SRC_BSP_TIMER]             = 0;
//
//   // I'm not using this timer
//   abstimer_vars.isArmed[ABSTIMER_SRC_BSP_TIMER]                = FALSE;
//
//   // reschedule
//   abstimer_reschedule();
//   ENABLE_INTERRUPTS();
//}
//
///**
// * timers are relative to the last compare
// * the elapsed time should be total -(compareVal-current)
// *
// */
//PORT_TIMER_WIDTH bsp_timer_get_currentValue() {
//   PORT_TIMER_WIDTH x,y;
//   INTERRUPT_DECLARATION();
//   DISABLE_INTERRUPTS();
//   x=abstimer_vars.bsp_timer_total;
//        y=(abstimer_vars.compareVal[ABSTIMER_SRC_BSP_TIMER] - sctimer_getValue());
//        x=x-y;
//   ENABLE_INTERRUPTS();
//   return x;
//}

//===== from radiotimer
void radiotimer_init() {
   abstimer_init();
}

void radiotimer_setOverflowCb(radiotimer_compare_cbt cb) {
   abstimer_vars.callback[ABSTIMER_SRC_RADIOTIMER_OVERFLOW]     = cb;
}

void radiotimer_setCompareCb(radiotimer_compare_cbt cb) {
   abstimer_vars.callback[ABSTIMER_SRC_RADIOTIMER_COMPARE]      = cb;
}

void radiotimer_start(uint16_t period) {
   INTERRUPT_DECLARATION();
   DISABLE_INTERRUPTS();
   // remember the period
   abstimer_vars.radiotimer_period                              = period;

   // remember previous overflow value
   abstimer_vars.radiotimer_overflow_previousVal                = abstimer_vars.compareVal[ABSTIMER_SRC_RADIOTIMER_OVERFLOW];

   // update the timer value (calculated as one period since the last one)
   abstimer_vars.compareVal[ABSTIMER_SRC_RADIOTIMER_OVERFLOW]  += abstimer_vars.radiotimer_period;

   // I'm using this timer
   abstimer_vars.isArmed[ABSTIMER_SRC_RADIOTIMER_OVERFLOW]      = TRUE;

   // reschedule
   abstimer_reschedule();
   ENABLE_INTERRUPTS();
}

// this is the elapsed time in this period (now - previous val)
PORT_TIMER_WIDTH radiotimer_getValue() {
   PORT_TIMER_WIDTH x;
   INTERRUPT_DECLARATION();
   DISABLE_INTERRUPTS();
   x= sctimer_getValue()-abstimer_vars.radiotimer_overflow_previousVal;
   ENABLE_INTERRUPTS();
   return x;
}

void radiotimer_setPeriod(uint16_t period) {
   INTERRUPT_DECLARATION();
   DISABLE_INTERRUPTS();
   //why??
   abstimer_vars.radiotimer_period=period+1;

   abstimer_vars.compareVal[ABSTIMER_SRC_RADIOTIMER_OVERFLOW]  = abstimer_vars.radiotimer_overflow_previousVal + abstimer_vars.radiotimer_period;
   // reschedule
   abstimer_reschedule();
   ENABLE_INTERRUPTS();
}

uint16_t radiotimer_getPeriod() {
   return abstimer_vars.radiotimer_period;
}

void radiotimer_schedule(uint16_t offset) {

   INTERRUPT_DECLARATION();
   DISABLE_INTERRUPTS();

   // remember the offset
   abstimer_vars.radiotimer_compare_offset                      = offset;

   // set the compare value since previous *overflow*
   abstimer_vars.compareVal[ABSTIMER_SRC_RADIOTIMER_COMPARE]    = abstimer_vars.radiotimer_overflow_previousVal + \
         abstimer_vars.radiotimer_compare_offset;

   // I'm using this timer
   abstimer_vars.isArmed[ABSTIMER_SRC_RADIOTIMER_COMPARE]       = TRUE;

   // reschedule
   abstimer_reschedule();
   ENABLE_INTERRUPTS();
}

void radiotimer_cancel() {
   INTERRUPT_DECLARATION();
   DISABLE_INTERRUPTS();

   abstimer_vars.isArmed[ABSTIMER_SRC_RADIOTIMER_COMPARE]       = FALSE;

   abstimer_reschedule();
   ENABLE_INTERRUPTS();
}

// the current value as we do not have a capture register.
uint16_t radiotimer_getCapturedTime() {
   return radiotimer_getValue();
}

//=========================== private =========================================

//===== admin
void abstimer_init() {

   // only initialize once
   if (abstimer_vars.initialized==FALSE) {
      // clear module variables
      memset(&abstimer_vars,0,sizeof(abstimer_vars_t));

      // start the HW timer
      sctimer_init();

      // set callback in case the hardware timer needs it. IAR based projects use pragma to bind it.
      sctimer_setCb(radiotimer_isr);

      // declare as initialized
      abstimer_vars.initialized = TRUE;
   }
}

//===== rescheduling

void abstimer_reschedule() {
   // the goal here is to take the next compare time,
   // i.e. the one with the smallest difference to currentTime which is armed

   uint8_t  i;          // iterator
   bool     found;      // TRUE iff a timer could be found to schedule
   uint16_t valToLoad;  // the value to eventually load in the compare register
   uint16_t thisDist;   // the distance in the future of this timer
   uint16_t minDist;    // the minimem distance amoung all timers

   minDist = 0xffff;

   // find the timer closest in time to now
   found = FALSE;
   for (i=0;i<ABSTIMER_SRC_MAX;i++) {
      if (abstimer_vars.isArmed[i]==TRUE) {
         thisDist = abstimer_vars.compareVal[i]-abstimer_vars.currentTime;
         if (
               found==FALSE ||
               thisDist<minDist
         ) {
            valToLoad                  = abstimer_vars.compareVal[i];
            minDist                    = thisDist;
            found                      = TRUE;
         }
      }
   }

   // load that timer, if found
   if (found==TRUE) {
      sctimer_schedule(valToLoad);
      abstimer_vars.nextCurrentTime    = valToLoad;
   } else {
      sctimer_stop();
   }
}

//=========================== interrupts ======================================

//kick_scheduler_t bsp_timer_isr() {
//   // the lptmr module uses only TimerA, so this should never happen
//   while(1);
//}

kick_scheduler_t radiotimer_isr() {
   uint8_t         i;                       // iterator
   uint16_t        now,timeSpent;
   uint16_t        calc;
   uint16_t        min;
   uint16_t        tempcompare;

   // update the current theoretical time -- nextCurrentTime MUST be NOW
   abstimer_vars.currentTime = abstimer_vars.nextCurrentTime;

   //debug -- to detect nested behaviours in case of reentrant interrupt.. should never happen
   abstimer_dbg.nested_isr++;

   //===== step 1. Find out which interrupts just fired

   // Note: we store the list of interrupts which fired in an 8-bit bitmap
   abstimer_vars.bitmapInterruptsFired = 0;

   for (i=0;i<ABSTIMER_SRC_MAX;i++) {
      if (
            (abstimer_vars.isArmed[i]==TRUE) &&
            (abstimer_vars.compareVal[i]==abstimer_vars.currentTime)
      ) {
         abstimer_vars.bitmapInterruptsFired |= (1<<i);
      }
   }
   if ((abstimer_vars.bitmapInterruptsFired & (1<<ABSTIMER_SRC_RADIOTIMER_OVERFLOW)) &&
         (abstimer_vars.bitmapInterruptsFired & (1<<ABSTIMER_SRC_RADIOTIMER_COMPARE))) {
      abstimer_vars.bitmapInterruptsFired &= ~(1<<ABSTIMER_SRC_RADIOTIMER_COMPARE);
   }

   // make sure at least one timer fired
   if (abstimer_vars.bitmapInterruptsFired==0) {
      while(1);
   }

        //how many loops? -- this tells us how many timers have expired at the same time.
   abstimer_dbg.consecutive_late=0;

        //let's execute all of them..
   while (abstimer_vars.bitmapInterruptsFired!=0) {
//check that...
      while (abstimer_vars.bitmapInterruptsFired!=0) {
                        //radiotimer overflow...
         if      (abstimer_vars.bitmapInterruptsFired & (1<<ABSTIMER_SRC_RADIOTIMER_OVERFLOW)) {

            // update debug stats
            abstimer_dbg.num_radiotimer_overflow++;

            // keep previous value -- this is now  poipoi
            abstimer_vars.radiotimer_overflow_previousVal = \
                  abstimer_vars.compareVal[ABSTIMER_SRC_RADIOTIMER_OVERFLOW];
            // remember compare val in case the callback modifies it.
            tempcompare = abstimer_vars.compareVal[ABSTIMER_SRC_RADIOTIMER_OVERFLOW];

            // call the callback
            abstimer_vars.callback[ABSTIMER_SRC_RADIOTIMER_OVERFLOW]();

            //==== step 2. Reschedule the timers which fired and need to be rescheduled

            // reschedule automatically if wasn't changed during callback
            if (abstimer_vars.compareVal[ABSTIMER_SRC_RADIOTIMER_OVERFLOW]==tempcompare) {
               // this is a periodic timer, reschedule automatically -- only if the callback has not already set it.
               abstimer_vars.compareVal[ABSTIMER_SRC_RADIOTIMER_OVERFLOW] += abstimer_vars.radiotimer_period;
            }

            // clear the interrupt flag
            abstimer_vars.bitmapInterruptsFired &= ~(1<<ABSTIMER_SRC_RADIOTIMER_OVERFLOW);
                        //radiotimer compare inside the slot...
         } else if (abstimer_vars.bitmapInterruptsFired & (1<<ABSTIMER_SRC_RADIOTIMER_COMPARE)) {

            // update debug stats
            abstimer_dbg.num_radiotimer_compare++;

            // remember compare val
            tempcompare = abstimer_vars.compareVal[ABSTIMER_SRC_RADIOTIMER_COMPARE];

            // call the callback
            abstimer_vars.callback[ABSTIMER_SRC_RADIOTIMER_COMPARE]();
                                // XV: I do not understand this ... why is rescheduled in the next slot?

            // reschedule automatically if wasn't changed during callback
            if (abstimer_vars.compareVal[ABSTIMER_SRC_RADIOTIMER_COMPARE]==tempcompare) {

               // reschedule automatically after *overflow*
               abstimer_vars.compareVal[ABSTIMER_SRC_RADIOTIMER_COMPARE]  = abstimer_vars.compareVal[ABSTIMER_SRC_RADIOTIMER_OVERFLOW]+ \
                     abstimer_vars.radiotimer_compare_offset;
            }

            // clear the interrupt flag
            abstimer_vars.bitmapInterruptsFired &= ~(1<<ABSTIMER_SRC_RADIOTIMER_COMPARE);
                        //bsp timer
         } else if (abstimer_vars.bitmapInterruptsFired & (1<<ABSTIMER_SRC_BSP_TIMER)) {

            // update debug stats
            abstimer_dbg.num_bsp_timer++;

            // call the callback
            abstimer_vars.callback[ABSTIMER_SRC_BSP_TIMER]();

            // clear the interrupt flag
            abstimer_vars.bitmapInterruptsFired &= ~(1<<ABSTIMER_SRC_BSP_TIMER);

            // no automatic rescheduling

         }
      }

      // make sure all interrupts have been handled
      if (abstimer_vars.bitmapInterruptsFired!=0) {
         while(1);
      }

      //===== step 4. schedule the next operation

      abstimer_reschedule();

      //===== step 5. make sure I'm not late for my next schedule

      // evaluate how much time has passed since theoretical currentTime,
      // (over estimate by ABSTIMER_GUARD_TICKS)
      now   = sctimer_getValue(); //this gets the value of the counter
      timeSpent  = (uint16_t)((uint16_t)now-(uint16_t)abstimer_vars.currentTime);
      timeSpent += ABSTIMER_GUARD_TICKS;

                //debug -- to detect wraps...
      if (timeSpent > 65000){
         //in case of negative wrap, lets say that a small time has elapsed.
         timeSpent=ABSTIMER_GUARD_TICKS;
      }

                // verify that, for each timer, that duration doesn't exceed how much time is left
      //find smallest next timer and mark it in the bitmap to be executed next. Can only be one marked at a time.
      min=0xFFFF;
      for (i=0;i<ABSTIMER_SRC_MAX;i++) {

         // calculate distance to next timeout
         calc = (uint16_t)abstimer_vars.compareVal[i]-(uint16_t)abstimer_vars.currentTime;

         if ((abstimer_vars.isArmed[i]==TRUE) && (timeSpent>calc) && (calc<min)) {
            //this is the nearest in time and we are already late or it is closer to its deadline, (distance < ABSTIMER_GUARD_TICKS)
            min=calc;
            // this interrupt needs to be serviced now
            abstimer_vars.bitmapInterruptsFired = (1<<i);
            // update the next timeout value
            abstimer_vars.nextCurrentTime=abstimer_vars.compareVal[i];
            // update debug statistics
            abstimer_dbg.num_late_schedule++;
            abstimer_dbg.consecutive_late++;

         }
      }
      if (abstimer_vars.bitmapInterruptsFired!=0) {
         abstimer_dbg.count_late++;

                        //a timer (or more) is so close that we need to execute it right now. there are several problems:
                        // 1) the isr function of that timer sets another timeout, also close in time, and the time it takes to execute the actual callback is higher
                        //    than the difference between now and the next timeout.. this will cause a timer to be lost.
                        // 2) if we set currentTime as the time where this late timeout is expecting to be executed, currentTime can be still in the future because
                        //    the GUARD_TIME can be bigger than needed in this case. IN that situation, timeSpent will be "negative" .. i.e close to 65535 and will cause an
                        //    execution of all the subsequent timers (during 2s) in isr mode... (looping here as all are "late")
                        // 3) if we set currentTime ti now, the "late" timer can be in the past or in the future.. in case it is in the future, there is no problem, in case it is in the
                        //    past and this timer sets another timeout, the timeout can also be in the past, causing an interrupt to be lost and possibly hanging the timer sequence for a while.

         //abstimer_vars.currentTime = now;//right now. + a guard time as we want to avoid that the distance calculation becomes negative.;
                        abstimer_vars.currentTime = abstimer_vars.nextCurrentTime ;//this is the expected time... NOte that can be in the past!!
         //abstimer_vars.nextCurrentTime =  abstimer_vars.currentTime ; //next timer is right now as well

      }
   }

   //debug
   if (abstimer_dbg.nested_isr!=1) while(1);

   abstimer_dbg.nested_isr=0;
   sctimer_clearISR();
        debugpins_frame_clr();
   // kick the OS
   return KICK_SCHEDULER;
}