text:
/*
 * (C) 2007-2012 Alibaba Group Holding Limited.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 * Authors:
 *   wuhua <wq163@163.com> , boyan <killme2008@gmail.com>
 */
package com.taobao.metamorphosis.utils.monitor;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

/**
 * @author mengting
 * @date 2008-06-17
 */

public class Keys implements Serializable {

    private static final long serialVersionUID = 1L;
    private static final String placeholder = "level-";
    private List<String> keys = new ArrayList<String>(4);

    private String key1;
    private String key2;
    private String key3;
    private String appName;

    public Keys() {

    }

    public Keys(final List<String> keys) {
        this.keys.addAll(keys);
        if (keys != null && keys.size() == 4) {
            this.appName = keys.get(1);
        }
    }

    public Keys(final String key) {
        this(null, key, null, null);
    }

    public Keys(final String key1, final String key2) {
        this(null, key1, key2, null);

    }

    public Keys(final String key1, final String key2, final String key3) {
        this(null, key1, key2, key3);
    }

    public Keys(final String appName, final String key1, final String key2, final String key3) {
        this.keys.add(appName);
        this.keys.add(key1);
        this.keys.add(key2);
        this.keys.add(key3);

        this.appName = appName;
        this.key1 = key1;
        this.key2 = key2;
        this.key3 = key3;

    }

    @Override
    public boolean equals(final Object comparedKeys) {
        if (!(comparedKeys instanceof Keys)) {
            return false;
        }
        return keys.equals(((Keys) comparedKeys).getKeys());
    }

    @Override
    public int hashCode() {
        return keys.hashCode();
    }

    public String getString(final String splitter) {
        final StringBuilder sb = new StringBuilder();
        boolean isNotFirst = false;
        int i = 0;
        for (String key : keys) {

            if (++i == 1 && key == null && appName == null) {
                continue;
            }
            else if (key == null) {
                key = placeholder + (i - 1);
            }

            if (isNotFirst) {
                sb.append(splitter);
            }
            else {
                isNotFirst = true;
            }

            sb.append(key);
        }

        return sb.toString();
    }

    private List<String> getKeys() {
        return keys;
    }

    public void setKeys(final List<String> keys) {
        this.keys = keys;
    }

    public String getKey1() {
        return key1;
    }

    public void setKey1(final String key1) {
        this.key1 = key1;
    }

    public String getKey2() {
        return key2;
    }

    public void setKey2(final String key2) {
        this.key2 = key2;
    }

    public String getKey3() {
        return key3;
    }

    public void setKey3(final String key3) {
        this.key3 = key3;
    }

    public String getAppName() {
        return appName;
    }

    public void setAppName(final String appName) {
        this.appName = appName;
    }
}


text:
Adds an AWS::Glue::Table.StorageDescriptor resource property to the template.
Describes the physical storage of table data.

## SYNTAX

```
Add-VSGlueTableStorageDescriptor [[-StoredAsSubDirectories] <Object>] [[-Parameters] <Object>]
 [[-BucketColumns] <Object>] [[-SkewedInfo] <Object>] [[-InputFormat] <Object>] [[-NumberOfBuckets] <Object>]
 [[-OutputFormat] <Object>] [[-Columns] <Object>] [[-SerdeInfo] <Object>] [[-SortColumns] <Object>]
 [[-Compressed] <Object>] [[-Location] <Object>] [<CommonParameters>]
```

## DESCRIPTION
Adds an AWS::Glue::Table.StorageDescriptor resource property to the template.
Describes the physical storage of table data.

## PARAMETERS

### -StoredAsSubDirectories
True if the table data is stored in subdirectories, or False if not.

Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-storagedescriptor.html#cfn-glue-table-storagedescriptor-storedassubdirectories
PrimitiveType: Boolean
UpdateType: Mutable

```yaml
Type: Object
Parameter Sets: (All)
Aliases:

Required: False
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```

### -Parameters
The user-supplied properties in key-value form.

Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-storagedescriptor.html#cfn-glue-table-storagedescriptor-parameters
PrimitiveType: Json
UpdateType: Mutable

```yaml
Type: Object
Parameter Sets: (All)
Aliases:

Required: False
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```

### -BucketColumns
A list of reducer grouping columns, clustering columns, and bucketing columns in the table.

PrimitiveItemType: String
Type: List
Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-storagedescriptor.html#cfn-glue-table-storagedescriptor-bucketcolumns
UpdateType: Mutable

```yaml
Type: Object
Parameter Sets: (All)
Aliases:

Required: False
Position: 3
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```

### -SkewedInfo
The information about values that appear frequently in a column skewed values.

Type: SkewedInfo
Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-storagedescriptor.html#cfn-glue-table-storagedescriptor-skewedinfo
UpdateType: Mutable

```yaml
Type: Object
Parameter Sets: (All)
Aliases:

Required: False
Position: 4
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```

### -InputFormat
The input format: SequenceFileInputFormat binary, or TextInputFormat, or a custom format.

Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-storagedescriptor.html#cfn-glue-table-storagedescriptor-inputformat
PrimitiveType: String
UpdateType: Mutable

```yaml
Type: Object
Parameter Sets: (All)
Aliases:

Required: False
Position: 5
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```

### -NumberOfBuckets
Must be specified if the table contains any dimension columns.

Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-storagedescriptor.html#cfn-glue-table-storagedescriptor-numberofbuckets
PrimitiveType: Integer
UpdateType: Mutable

```yaml
Type: Object
Parameter Sets: (All)
Aliases:

Required: False
Position: 6
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```

### -OutputFormat
The output format: SequenceFileOutputFormat binary, or IgnoreKeyTextOutputFormat, or a custom format.

Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-storagedescriptor.html#cfn-glue-table-storagedescriptor-outputformat
PrimitiveType: String
UpdateType: Mutable

```yaml
Type: Object
Parameter Sets: (All)
Aliases:

Required: False
Position: 7
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```

### -Columns
A list of the Columns in the table.

Type: List
Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-storagedescriptor.html#cfn-glue-table-storagedescriptor-columns
ItemType: Column
UpdateType: Mutable

```yaml
Type: Object
Parameter Sets: (All)
Aliases:

Required: False
Position: 8
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```

### -SerdeInfo
The serialization/deserialization SerDe information.

Type: SerdeInfo
Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-storagedescriptor.html#cfn-glue-table-storagedescriptor-serdeinfo
UpdateType: Mutable

```yaml
Type: Object
Parameter Sets: (All)
Aliases:

Required: False
Position: 9
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```

### -SortColumns
A list specifying the sort order of each bucket in the table.

Type: List
Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-storagedescriptor.html#cfn-glue-table-storagedescriptor-sortcolumns
ItemType: Order
UpdateType: Mutable

```yaml
Type: Object
Parameter Sets: (All)
Aliases:

Required: False
Position: 10
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```

### -Compressed
True if the data in the table is compressed, or False if not.

Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-storagedescriptor.html#cfn-glue-table-storagedescriptor-compressed
PrimitiveType: Boolean
UpdateType: Mutable

```yaml
Type: Object
Parameter Sets: (All)
Aliases:

Required: False
Position: 11
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```

### -Location
The physical location of the table.
By default, this takes the form of the warehouse location, followed by the database location in the warehouse, followed by the table name.

Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-storagedescriptor.html#cfn-glue-table-storagedescriptor-location
PrimitiveType: String
UpdateType: Mutable

```yaml
Type: Object
Parameter Sets: (All)
Aliases:

Required: False
Position: 12
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```

### CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).

## INPUTS

## OUTPUTS

### Vaporshell.Resource.Glue.Table.StorageDescriptor
## NOTES

## RELATED LINKS

[http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-storagedescriptor.html](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-storagedescriptor.html)

redpajama_set_name: RedPajamaGithub


text:
package com.Da_Technomancer.crossroads.API.effects.goggles;

import com.Da_Technomancer.crossroads.API.packets.ModPackets;
import com.Da_Technomancer.crossroads.API.packets.SendLooseBeamToClient;
import com.Da_Technomancer.crossroads.API.technomancy.LooseBeamRenderable;
import net.minecraft.block.state.IBlockState;
import net.minecraft.entity.Entity;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Blocks;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.util.EntitySelectors;
import net.minecraft.util.math.AxisAlignedBB;
import net.minecraft.util.math.BlockPos;
import net.minecraft.util.math.RayTraceResult;
import net.minecraft.util.math.Vec3d;
import net.minecraft.world.World;
import net.minecraftforge.fml.common.network.NetworkRegistry;

import java.awt.*;
import java.util.ArrayList;
import java.util.List;

public class RubyGoggleEffect implements IGoggleEffect{

	@Override
	public void armorTick(World world, EntityPlayer player, ArrayList<String> chat, RayTraceResult ray){
		if(world.getTotalWorldTime() % 5 == 0){
			Entity entHit = null;
			Vec3d start = new Vec3d(player.posX - Math.cos(Math.toRadians(player.getRotationYawHead())) * 0.18D, player.posY + player.getEyeHeight() + 0.03D, player.posZ - Math.sin(Math.toRadians(player.getRotationYawHead())) * 0.18D);
			Vec3d end = start;

			for(double d = 0; d < 16; d += 0.2D){
				Vec3d tar = player.getPositionEyes(0).addVector(0, 0.2D, 0).add(player.getLookVec().scale(d));
				List<Entity> ents = world.getEntitiesInAABBexcluding(player, new AxisAlignedBB(tar.x - 0.1D, tar.y - 0.1D, tar.z - 0.1D, tar.x + 0.1D, tar.y + 0.1D, tar.z + 0.1D), EntitySelectors.IS_ALIVE);
				if(!ents.isEmpty()){
					entHit = ents.get((int) (Math.random() * ents.size()));
					end = tar;
					break;
				}
				IBlockState state = world.getBlockState(new BlockPos(tar));
				if(!state.getBlock().isAir(state, world, new BlockPos(tar))){
					break;
				}
				end = tar;
			}

			if(entHit != null){
				entHit.setFire(3);
			}else{
				world.setBlockState(new BlockPos(end), Blocks.FIRE.getDefaultState());
			}

			NBTTagCompound beamNBT = new NBTTagCompound();
			new LooseBeamRenderable(start.x, start.y, start.z, (int) Math.sqrt(end.squareDistanceTo(start)), player.rotationPitch, player.rotationYawHead, (byte) 1, Color.RED.getRGB()).saveToNBT(beamNBT);
			ModPackets.network.sendToAllAround(new SendLooseBeamToClient(beamNBT), new NetworkRegistry.TargetPoint(player.dimension, player.posX, player.posY, player.posZ, 512));
		}
	}
}


text:
package turing123.lockmanager;

/**
 * This class represents the interface for read_write_lock_managers.
 *
 * Any implementation of this interface should guarantee that:
 * (1) the customers of this implementation can acquire and release a read lock or a write lock for
 * a specified key;
 * (2) the acquisition and release of locks obey to the semantics of java.util.concurrent.locks.ReentrantReadWriteLock;
 * (3) no memory leak is introduced, that is, the lock objects are correctly managed, they should be
 * constructed and deconstructed at right time.
 *
 *  From the perspective of customers, following is an example of event sequence when using the lock manager:
 *  (1) customer1 tries to acquire the read lock for the key K1;
 *  (2) customer1 acquires the read lock successfully;
 *  (3) customer2 tries to acquire the write lock for the key K1;
 *  (4) customer2 will be blocked until the read lock for K1 is released;
 *  (5) Customer3 tries to acquire the write lock for the key K2;
 *  (6) Customer3 acquires the write lock successfully;
 *  (7) customer4 tries to acquire the read lock for the key K2;
 *  (8) Customer4 will be blocked until the write lock for K2 is released;
 *  (9) Customer1 releases the read lock for K1;
 *  (10) Customer2 acquires the write lock for K1.
 *  (11) Customer3 releases the write lock for K2;
 *  (12) Customer4 acquires the read lock for K2;
 *
 *
 */
public interface ReadWriteLockManager<E> {

  /**
   * Acquire the read lock for the specified key.
   * @param key
   */
  void acquireReadLock(E key);

  /**
   * Release the read lock for the specified key.
   * @param key
   */
  void releaseReadLock(E key);

  /**
   * Acquire the write lock for the specified key.
   * @param key
   */
  void acquireWriteLock(E key);

  /**
   * Release the write lock for the specified key.
   * @param key
   */
  void releaseWriteLock(E key);

}


text:
// Copyright 2021-2022, University of Colorado Boulder

import TReadOnlyProperty from '../../../axon/js/TReadOnlyProperty.js';
import { Color } from '../imports.js';

/**
 * Type representing a ColorDef
 * Please see Color.toColor() for a way to transform these colors.
 *
 * @author Jonathan Olson <jonathan.olson@colorado.edu>
 */

type TColor = TReadOnlyProperty<Color | string | null> | TReadOnlyProperty<Color | string> | TReadOnlyProperty<Color> | TReadOnlyProperty<string> | Color | string | null;

export default TColor;


text:
void UrlmonUploadDataStream::Initialize(net::UploadData* upload_data) {
  upload_data_ = upload_data;
  request_body_stream_.reset(net::UploadDataStream::Create(upload_data, NULL));
  DCHECK(request_body_stream_.get());
}

STDMETHODIMP UrlmonUploadDataStream::Read(void* pv, ULONG cb, ULONG* read) {
  if (pv == NULL) {
    NOTREACHED();
    return E_POINTER;
  }

  // Have we already read past the end of the stream?
  if (request_body_stream_->eof()) {
    if (read) {
      *read = 0;
    }
    return S_FALSE;
  }

  uint64 total_bytes_to_copy = std::min(static_cast<uint64>(cb),
      static_cast<uint64>(request_body_stream_->buf_len()));

  uint64 bytes_copied = 0;

  char* write_pointer = reinterpret_cast<char*>(pv);
  while (bytes_copied < total_bytes_to_copy) {
    net::IOBuffer* buf = request_body_stream_->buf();

    // Make sure our length doesn't run past the end of the available data.
    size_t bytes_to_copy_now = static_cast<size_t>(
        std::min(static_cast<uint64>(request_body_stream_->buf_len()),
                 total_bytes_to_copy - bytes_copied));

    memcpy(write_pointer, buf->data(), bytes_to_copy_now);

    // Advance our copy tally
    bytes_copied += bytes_to_copy_now;

    // Advance our write pointer
    write_pointer += bytes_to_copy_now;

    // Advance the UploadDataStream read pointer:
    request_body_stream_->MarkConsumedAndFillBuffer(bytes_to_copy_now);
  }

  DCHECK(bytes_copied == total_bytes_to_copy);

  if (read) {
    *read = static_cast<ULONG>(total_bytes_to_copy);
  }

  return S_OK;
}

STDMETHODIMP UrlmonUploadDataStream::Seek(LARGE_INTEGER move, DWORD origin,
                                          ULARGE_INTEGER* new_pos) {
  // UploadDataStream is really not very seek-able, so for now allow
  // STREAM_SEEK_SETs to work with a 0 offset, but fail on everything else.
  if (origin == STREAM_SEEK_SET && move.QuadPart == 0) {
    if (request_body_stream_->position() != 0) {
      request_body_stream_.reset(
          net::UploadDataStream::Create(upload_data_, NULL));
      DCHECK(request_body_stream_.get());
    }
    if (new_pos) {
      new_pos->QuadPart = 0;
    }
    return S_OK;
  }

  DCHECK(false) << __FUNCTION__;
  return STG_E_INVALIDFUNCTION;
}

STDMETHODIMP UrlmonUploadDataStream::Stat(STATSTG *stat_stg,
                                          DWORD grf_stat_flag) {
  if (stat_stg == NULL)
    return E_POINTER;

  memset(stat_stg, 0, sizeof(STATSTG));
  if (0 == (grf_stat_flag & STATFLAG_NONAME)) {
    const wchar_t kStreamBuffer[] = L"PostStream";
    stat_stg->pwcsName =
        static_cast<wchar_t*>(::CoTaskMemAlloc(sizeof(kStreamBuffer)));
    lstrcpy(stat_stg->pwcsName, kStreamBuffer);
  }
  stat_stg->type = STGTY_STREAM;
  stat_stg->cbSize.QuadPart = upload_data_->GetContentLength();
  return S_OK;
}


text:
angular.module("umbraco")
.controller("Umbraco.Editors.MemberTypes.MoveController",
    function($scope){

    });


text:
package com.google.appengine.api.search.dev;

import com.google.apphosting.api.search.DocumentPb.FieldValue;
import com.google.apphosting.api.search.DocumentPb.FieldValue.ContentType;
import java.util.Comparator;
import java.util.List;
import org.apache.lucene.document.Document;

/**
 * Abstract base class for all expression evaluators.
 *
 */
public abstract class Expression {

  /**
   * Evaluate the expression to field value proto for the specified document.
   */
  public abstract FieldValue eval(Document doc) throws EvaluationException;

  /** Helper function to make field value proto from specified content. */
  public static final FieldValue makeValue(ContentType type, String stringValue) {
    return FieldValue.newBuilder().setType(type).setStringValue(stringValue).build();
  }

  /** Sort class for potential multi dimensional sorting of the expression. */
  public static interface Sorter extends Comparator<Object> {

    /** Evaluate expression to intermediate value suitable for sorting. */
    public Object eval(Document doc);

    /** Sort intermediate values. */
    @Override
    public int compare(Object left, Object right);
  }

  /**
   * Get list of sort classes for the expression. Usually it contains just
   * one element, but for field expressions it can potentially return 2
   * sorters when both numeric and text fields exist with a field name.
   */
  public abstract List<Sorter> getSorters(
      int sign, double defaultValueNumeric, String defaultValueText);
}


text:
'use strict';

angular.module('core')
	.config(['uiGmapGoogleMapApiProvider',
		function(uiGmapGoogleMapApiProvider) {
			uiGmapGoogleMapApiProvider.configure({
		        key: 'AIzaSyBoO8_3duAcbhVfirq0IrwVIhfKbyhX0yQ',
		        v: '3.17',
		        libraries: 'places,weather,geometry,visualization'
		    });
		}
	]);


text:
/*
 * @(#)PrintGCStat.java	1.6 10/03/23
 *
 * Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * -Redistribution of source code must retain the above copyright notice, this
 *  list of conditions and the following disclaimer.
 *
 * -Redistribution in binary form must reproduce the above copyright notice,
 *  this list of conditions and the following disclaimer in the documentation
 *  and/or other materials provided with the distribution.
 *
 * Neither the name of Oracle or the names of contributors may
 * be used to endorse or promote products derived from this software without
 * specific prior written permission.
 *
 * This software is provided "AS IS," without a warranty of any kind. ALL
 * EXPRESS OR IMPLIED CONDITIONS, REPRESENTATIONS AND WARRANTIES, INCLUDING
 * ANY IMPLIED WARRANTY OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE
 * OR NON-INFRINGEMENT, ARE HEREBY EXCLUDED. SUN MICROSYSTEMS, INC. ("SUN")
 * AND ITS LICENSORS SHALL NOT BE LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
 * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING THIS SOFTWARE OR ITS
 * DERIVATIVES. IN NO EVENT WILL SUN OR ITS LICENSORS BE LIABLE FOR ANY LOST
 * REVENUE, PROFIT OR DATA, OR FOR DIRECT, INDIRECT, SPECIAL, CONSEQUENTIAL,
 * INCIDENTAL OR PUNITIVE DAMAGES, HOWEVER CAUSED AND REGARDLESS OF THE THEORY
 * OF LIABILITY, ARISING OUT OF THE USE OF OR INABILITY TO USE THIS SOFTWARE,
 * EVEN IF SUN HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
 *
 * You acknowledge that this software is not designed, licensed or intended
 * for use in the design, construction, operation or maintenance of any
 * nuclear facility.
 */

/*
 * @(#)PrintGCStat.java	1.6 10/03/23
 */

import static java.lang.management.ManagementFactory.*;
import java.lang.management.*;
import javax.management.*;
import java.io.*;
import java.util.*;

/**
 * Example of using the java.lang.management API to monitor
 * the memory usage and garbage collection statistics.
 *
 * @author  Mandy Chung
 * @version %% 03/23/10
 */
public class PrintGCStat {
    private RuntimeMXBean rmbean;
    private MemoryMXBean mmbean;
    private List<MemoryPoolMXBean> pools;
    private List<GarbageCollectorMXBean> gcmbeans;

    /**
     * Constructs a PrintGCStat object to monitor a remote JVM.
     */
    public PrintGCStat(MBeanServerConnection server) throws IOException {
        // Create the platform mxbean proxies
        this.rmbean = newPlatformMXBeanProxy(server,
                                             RUNTIME_MXBEAN_NAME,
                                             RuntimeMXBean.class);
        this.mmbean = newPlatformMXBeanProxy(server,
                                             MEMORY_MXBEAN_NAME,
                                             MemoryMXBean.class);
        ObjectName poolName = null;
        ObjectName gcName = null;
        try {
            poolName = new ObjectName(MEMORY_POOL_MXBEAN_DOMAIN_TYPE+",*");
            gcName = new ObjectName(GARBAGE_COLLECTOR_MXBEAN_DOMAIN_TYPE+",*");
        } catch (MalformedObjectNameException e) {
            // should not reach here
            assert(false);
        }

        Set mbeans = server.queryNames(poolName, null);
        if (mbeans != null) {
            pools = new ArrayList<MemoryPoolMXBean>();
            Iterator iterator = mbeans.iterator();
            while (iterator.hasNext()) {
                ObjectName objName = (ObjectName) iterator.next();
                MemoryPoolMXBean p =
                    newPlatformMXBeanProxy(server,
                                           objName.getCanonicalName(),
                                           MemoryPoolMXBean.class);
                pools.add(p);
            }
        }

        mbeans = server.queryNames(gcName, null);
        if (mbeans != null) {
            gcmbeans = new ArrayList<GarbageCollectorMXBean>();
            Iterator iterator = mbeans.iterator();
            while (iterator.hasNext()) {
                ObjectName objName = (ObjectName) iterator.next();
                GarbageCollectorMXBean gc =
                    newPlatformMXBeanProxy(server,
                                           objName.getCanonicalName(),
                                           GarbageCollectorMXBean.class);
                gcmbeans.add(gc);
            }
        }
    }

    /**
     * Constructs a PrintGCStat object to monitor the local JVM.
     */
    public PrintGCStat() {
        // Obtain the platform mxbean instances for the running JVM.
        this.rmbean = getRuntimeMXBean();
        this.mmbean = getMemoryMXBean();
        this.pools = getMemoryPoolMXBeans();
        this.gcmbeans = getGarbageCollectorMXBeans();
    }

    /**
     * Prints the verbose GC log to System.out to list the memory usage
     * of all memory pools as well as the GC statistics.
     */
    public void printVerboseGc() {
        System.out.print("Uptime: " + formatMillis(rmbean.getUptime()));
        for (GarbageCollectorMXBean gc : gcmbeans) {
            System.out.print(" [" + gc.getName() + ": ");
            System.out.print("Count=" + gc.getCollectionCount());
            System.out.print(" GCTime=" + formatMillis(gc.getCollectionTime()));
            System.out.print("]");
        }
        System.out.println();
        for (MemoryPoolMXBean p : pools) {
            System.out.print("  [" + p.getName() + ":");
            MemoryUsage u = p.getUsage();
            System.out.print(" Used=" + formatBytes(u.getUsed()));
            System.out.print(" Committed=" + formatBytes(u.getCommitted()));
            System.out.println("]");
        }
    }

    private String formatMillis(long ms) {
        return String.format("%.4fsec", ms / (double) 1000);
    }
    private String formatBytes(long bytes) {
        long kb = bytes;
        if (bytes > 0) {
            kb = bytes / 1024;
        }
        return kb + "K";
    }
}


text:
.. _mars-on-ray:

Mars on Ray
============

.. _`issue on GitHub`: https://github.com/mars-project/mars/issues

`Mars`_ is a tensor-based unified framework for large-scale data computation which scales Numpy, Pandas and Scikit-learn.
Mars on Ray makes it easy to scale your programs with a Ray cluster.

.. note::

  This API is experimental in Mars. If you encounter any bugs, please file an `issue on GitHub`_.

.. _`Mars`: https://docs.pymars.org

Installation
-------------
You can simply install Mars via pip:

.. code-block:: bash

    pip install pymars>=0.6.0a1

Getting started
----------------

It's easy to run Mars jobs on a Ray cluster. Use ``from mars.session import new_session``
and run ``new_session(backend='ray').as_default()``; this will create
a Mars session for Ray as the default session, and then all Mars tasks will be
submitted to Ray. Arguments will be passed to ``ray.init()`` when
creating a Mars session like this:
``new_session(backend='ray', address=<address>, num_cpus=<num_cpus>)``.

.. code-block:: python

    from mars.session import new_session
    ray_session = new_session(backend='ray').as_default()

    import mars.dataframe as md
    import mars.tensor as mt

    t = mt.random.rand(100, 4, chunk_size=30)
    df = md.DataFrame(t, columns=list('abcd'))
    print(df.describe().execute())

.. warning::

  `Mars remote API`_ is not available for now.

.. _`Mars remote API`: https://docs.pymars.org/en/latest/getting_started/remote.html


text:
package org.elasticsearch.common.unit;

import org.elasticsearch.ElasticsearchParseException;
import org.elasticsearch.common.io.stream.BytesStreamOutput;
import org.elasticsearch.common.io.stream.StreamInput;
import org.elasticsearch.test.ESTestCase;
import org.joda.time.PeriodType;
import org.junit.Test;

import java.io.IOException;
import java.util.concurrent.TimeUnit;

import static org.hamcrest.Matchers.equalTo;
import static org.hamcrest.Matchers.lessThan;

public class TimeValueTests extends ESTestCase {

    public void testSimple() {
        assertThat(TimeUnit.MILLISECONDS.toMillis(10), equalTo(new TimeValue(10, TimeUnit.MILLISECONDS).millis()));
        assertThat(TimeUnit.MICROSECONDS.toMicros(10), equalTo(new TimeValue(10, TimeUnit.MICROSECONDS).micros()));
        assertThat(TimeUnit.SECONDS.toSeconds(10), equalTo(new TimeValue(10, TimeUnit.SECONDS).seconds()));
        assertThat(TimeUnit.MINUTES.toMinutes(10), equalTo(new TimeValue(10, TimeUnit.MINUTES).minutes()));
        assertThat(TimeUnit.HOURS.toHours(10), equalTo(new TimeValue(10, TimeUnit.HOURS).hours()));
        assertThat(TimeUnit.DAYS.toDays(10), equalTo(new TimeValue(10, TimeUnit.DAYS).days()));
    }

    public void testToString() {
        assertThat("10ms", equalTo(new TimeValue(10, TimeUnit.MILLISECONDS).toString()));
        assertThat("1.5s", equalTo(new TimeValue(1533, TimeUnit.MILLISECONDS).toString()));
        assertThat("1.5m", equalTo(new TimeValue(90, TimeUnit.SECONDS).toString()));
        assertThat("1.5h", equalTo(new TimeValue(90, TimeUnit.MINUTES).toString()));
        assertThat("1.5d", equalTo(new TimeValue(36, TimeUnit.HOURS).toString()));
        assertThat("1000d", equalTo(new TimeValue(1000, TimeUnit.DAYS).toString()));
    }

    public void testFormat() {
        assertThat(new TimeValue(1025, TimeUnit.MILLISECONDS).format(PeriodType.dayTime()), equalTo("1 second and 25 milliseconds"));
        assertThat(new TimeValue(1, TimeUnit.MINUTES).format(PeriodType.dayTime()), equalTo("1 minute"));
        assertThat(new TimeValue(65, TimeUnit.MINUTES).format(PeriodType.dayTime()), equalTo("1 hour and 5 minutes"));
        assertThat(new TimeValue(24 * 600 + 85, TimeUnit.MINUTES).format(PeriodType.dayTime()), equalTo("241 hours and 25 minutes"));
    }

    public void testMinusOne() {
        assertThat(new TimeValue(-1).nanos(), lessThan(0l));
    }

    public void testParseTimeValue() {
        // Space is allowed before unit:
        assertEquals(new TimeValue(10, TimeUnit.MILLISECONDS),
                     TimeValue.parseTimeValue("10 ms", null, "test"));
        assertEquals(new TimeValue(10, TimeUnit.MILLISECONDS),
                     TimeValue.parseTimeValue("10ms", null, "test"));
        assertEquals(new TimeValue(10, TimeUnit.MILLISECONDS),
                     TimeValue.parseTimeValue("10 MS", null, "test"));
        assertEquals(new TimeValue(10, TimeUnit.MILLISECONDS),
                     TimeValue.parseTimeValue("10MS", null, "test"));

        assertEquals(new TimeValue(10, TimeUnit.SECONDS),
                     TimeValue.parseTimeValue("10 s", null, "test"));
        assertEquals(new TimeValue(10, TimeUnit.SECONDS),
                     TimeValue.parseTimeValue("10s", null, "test"));
        assertEquals(new TimeValue(10, TimeUnit.SECONDS),
                     TimeValue.parseTimeValue("10 S", null, "test"));
        assertEquals(new TimeValue(10, TimeUnit.SECONDS),
                     TimeValue.parseTimeValue("10S", null, "test"));

        assertEquals(new TimeValue(100, TimeUnit.MILLISECONDS),
                    TimeValue.parseTimeValue("0.1s", null, "test"));

        assertEquals(new TimeValue(10, TimeUnit.MINUTES),
                     TimeValue.parseTimeValue("10 m", null, "test"));
        assertEquals(new TimeValue(10, TimeUnit.MINUTES),
                     TimeValue.parseTimeValue("10m", null, "test"));
        assertEquals(new TimeValue(10, TimeUnit.MINUTES),
                     TimeValue.parseTimeValue("10 M", null, "test"));
        assertEquals(new TimeValue(10, TimeUnit.MINUTES),
                     TimeValue.parseTimeValue("10M", null, "test"));

        assertEquals(new TimeValue(10, TimeUnit.HOURS),
                     TimeValue.parseTimeValue("10 h", null, "test"));
        assertEquals(new TimeValue(10, TimeUnit.HOURS),
                     TimeValue.parseTimeValue("10h", null, "test"));
        assertEquals(new TimeValue(10, TimeUnit.HOURS),
                     TimeValue.parseTimeValue("10 H", null, "test"));
        assertEquals(new TimeValue(10, TimeUnit.HOURS),
                     TimeValue.parseTimeValue("10H", null, "test"));

        assertEquals(new TimeValue(10, TimeUnit.DAYS),
                     TimeValue.parseTimeValue("10 d", null, "test"));
        assertEquals(new TimeValue(10, TimeUnit.DAYS),
                     TimeValue.parseTimeValue("10d", null, "test"));
        assertEquals(new TimeValue(10, TimeUnit.DAYS),
                     TimeValue.parseTimeValue("10 D", null, "test"));
        assertEquals(new TimeValue(10, TimeUnit.DAYS),
                     TimeValue.parseTimeValue("10D", null, "test"));

        assertEquals(new TimeValue(70, TimeUnit.DAYS),
                     TimeValue.parseTimeValue("10 w", null, "test"));
        assertEquals(new TimeValue(70, TimeUnit.DAYS),
                     TimeValue.parseTimeValue("10w", null, "test"));
        assertEquals(new TimeValue(70, TimeUnit.DAYS),
                     TimeValue.parseTimeValue("10 W", null, "test"));
        assertEquals(new TimeValue(70, TimeUnit.DAYS),
                     TimeValue.parseTimeValue("10W", null, "test"));
    }

    private void assertEqualityAfterSerialize(TimeValue value) throws IOException {
        BytesStreamOutput out = new BytesStreamOutput();
        value.writeTo(out);

        StreamInput in = StreamInput.wrap(out.bytes());
        TimeValue inValue = TimeValue.readTimeValue(in);

        assertThat(inValue, equalTo(value));
    }

    public void testSerialize() throws Exception {
        assertEqualityAfterSerialize(new TimeValue(100, TimeUnit.DAYS));
        assertEqualityAfterSerialize(new TimeValue(-1));
        assertEqualityAfterSerialize(new TimeValue(1, TimeUnit.NANOSECONDS));
    }

    @Test(expected = ElasticsearchParseException.class)
    public void testFailOnUnknownUnits() {
        TimeValue.parseTimeValue("23tw", null, "test");
    }

    @Test(expected = ElasticsearchParseException.class)
    public void testFailOnMissingUnits() {
        TimeValue.parseTimeValue("42", null, "test");
    }

    @Test(expected = ElasticsearchParseException.class)
    public void testNoDotsAllowed() {
        TimeValue.parseTimeValue("42ms.", null, "test");
    }
}


text:
..
     Copyright 2013 Pixar

     Licensed under the Apache License, Version 2.0 (the "Apache License")
     with the following modification; you may not use this file except in
     compliance with the Apache License and the following modification to it:
     Section 6. Trademarks. is deleted and replaced with:

     6. Trademarks. This License does not grant permission to use the trade
        names, trademarks, service marks, or product names of the Licensor
        and its affiliates, except as required to comply with Section 4(c) of
        the License and to reproduce the content of the NOTICE file.

     You may obtain a copy of the Apache License at

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

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

FAR Overview
------------

.. contents::
   :local:
   :backlinks: none

Feature Adaptive Representation (Far)
=====================================

Far is a serialized topoloigcal data representation.Far uses hbr to create and
cache fast run time data structures for table driven subdivision of vertices and
cubic patches for limit surface evaluation. `Feature-adaptive <subdivision_surfaces.html#feature-adaptive-subdivision>`__
refinement logic is used to adaptively refine coarse topology near features like
extraordinary vertices and creases in order to make the topology amenable to
cubic patch evaluation. Far is also a generic, templated algorithmic base API
that clients in higher levels instantiate and use by providing an implementation
of a vertex class. It supports these subdivision schemes:

Factories & Tables
==================

Subdivision Tables
==================

Patch Tables
============

Stencil Tables
==============

Stencils are the most direct method of evaluation of specific locations on the
limit of a subdivision surface starting from the coarse vertices of the control
cage.

.. image:: images/far_stencil0.png
   :align: center

Sample Location
***************

Each stencil is associated with a singular parametric location on the coarse
mesh. The paramatric location is defined as face location and local [0.0 - 1.0]
(u,v) triplet:

In the case of a non-coarse quad face, the parametric sub-face quadrant needs to
be identified. This can be done either explicitly or implicitly by using the
unique ptex face indices for instance.

.. image:: images/far_stencil6.png
   :align: center

Principles
**********

Iterative subdivision algorithms such as the one used in `FarSubdivisionTables <#subdivision-tables>`__
converge towards the limit surface by sucessively refining the vertices of the
coarse control cage.

.. image:: images/far_stencil4.png
   :align: center

Each step is dependent upon the previous subidivion step being completed, and a
substantial number of steps may be required in order approximate the limit. Since
each subdivision step incurs an O(4 :superscript:`n`) growing amount of
computations, the accrued number of interpolations can be quite large.

However, every intermediate subdivided vertex can be expressed as a linear
interpolation of vertice from the previous step. So, eventually, every point at
on the limit surface can be expressed as a weighted average of the set of coarse
control vertices from the one-ring surrounding the face that the point is in:

.. image:: images/far_stencil3.png
   :align: center

Where:

.. image:: images/far_stencil2.png
   :align: center

Stencils are created by combining the list of control vertices of the 1-ring
to a set of interpolation weights obtained by successive accumulation of
subdivision interpolation weights.

The weight accumulation process is made efficient by adaptively subdividing the
control cage only around extraordinary locations, and otherwise reverting to fast
bi-cubic bspline patch evaluation. The use of bi-cubic patches also allows the
accumulation of analytical derivatives.

API Architecture
****************

The base container for stencil data is the FarStencilTables class. As with most
other Far entities, it has an associated FarStencilTablesFactory that requires
an HbrMesh:

.. image:: images/far_stencil5.png
   :align: center

Assuming a properly qualified HbrMesh:

.. code:: c++

    HMesh<OpenSubdiv::FarStencilFactoryVertex> * mesh;

    FarStencilTables controlStencils;

    OpenSubdiv::FarStencilTablesFactory<> factory(mesh);

    for (int i=0; i<nfaces; ++i) {

        HFace * f = mesh->GetFace(i);

        int nv = f->GetNumVertices();

        if (nv!=4) {

            // if the face is not a quad, we have to iterate over sub-quad(rants)
            for (int j=0; j<f->GetNumVertices(); ++j) {

                factory.SetCurrentFace(i,j);

                factory.AppendStencils( &controlStencils, nsamples/nv, u, v, reflevel );
            }
        } else {

            factory.SetCurrentFace(i);

            factory.AppendStencils( &controlStencils, g_nsamples, u, v, reflevel );
        }
    }

When the control vertices (controlPoints) move in space, the limit locations can
be very efficiently recomputed simply by applying the blending weights to the
series of coarse control vertices:

.. code:: c++

    class StencilType {
    public:

        void Clear() {
            memset( &x, 0, sizeof(StencilType));
        }

        void AddWithWeight( StencilType const & cv, float weight  ) {
            x += cv.x * weight;
            y += cv.y * weight;
            z += cv.z * weight;
        }

        float x,y,z;
    };

    std::vector<StencilType> controlPoints,
                             points,
                             utan,
                             vtan;

    // Uppdate points by applying stencils
    controlStencils.UpdateValues<StencilType>( reinterpret_cast<StencilType const *>(
        &controlPoints[0]), &points[0] );

    // Uppdate tangents by applying derivative stencils
    controlStencils.UpdateDerivs<StencilType>( reinterpret_cast<StencilType const *>(
        &controlPoints[0]), &utan[0], &vtan[0] );


text:
@class DBSHARINGGroupMembershipInfo;
@class DBSHARINGInviteeMembershipInfo;
@class DBSHARINGSharedFolderMembers;
@class DBSHARINGUserMembershipInfo;

NS_ASSUME_NONNULL_BEGIN

#pragma mark - API Object

///
/// The `SharedFolderMembers` struct.
///
/// Shared folder user and group membership.
///
/// This class implements the `DBSerializable` protocol (serialize and
/// deserialize instance methods), which is required for all Obj-C SDK API route
/// objects.
///
@interface DBSHARINGSharedFolderMembers : NSObject <DBSerializable, NSCopying>

#pragma mark - Instance fields

/// The list of user members of the shared folder.
@property (nonatomic, readonly) NSArray<DBSHARINGUserMembershipInfo *> *users;

/// The list of group members of the shared folder.
@property (nonatomic, readonly) NSArray<DBSHARINGGroupMembershipInfo *> *groups;

/// The list of invitees to the shared folder.
@property (nonatomic, readonly) NSArray<DBSHARINGInviteeMembershipInfo *> *invitees;

/// Present if there are additional shared folder members that have not been
/// returned yet. Pass the cursor into `listFolderMembersContinue` to list
/// additional members.
@property (nonatomic, readonly, copy, nullable) NSString *cursor;

#pragma mark - Constructors

///
/// Full constructor for the struct (exposes all instance variables).
///
/// @param users The list of user members of the shared folder.
/// @param groups The list of group members of the shared folder.
/// @param invitees The list of invitees to the shared folder.
/// @param cursor Present if there are additional shared folder members that
/// have not been returned yet. Pass the cursor into `listFolderMembersContinue`
/// to list additional members.
///
/// @return An initialized instance.
///
- (instancetype)initWithUsers:(NSArray<DBSHARINGUserMembershipInfo *> *)users
                       groups:(NSArray<DBSHARINGGroupMembershipInfo *> *)groups
                     invitees:(NSArray<DBSHARINGInviteeMembershipInfo *> *)invitees
                       cursor:(nullable NSString *)cursor;

///
/// Convenience constructor (exposes only non-nullable instance variables with
/// no default value).
///
/// @param users The list of user members of the shared folder.
/// @param groups The list of group members of the shared folder.
/// @param invitees The list of invitees to the shared folder.
///
/// @return An initialized instance.
///
- (instancetype)initWithUsers:(NSArray<DBSHARINGUserMembershipInfo *> *)users
                       groups:(NSArray<DBSHARINGGroupMembershipInfo *> *)groups
                     invitees:(NSArray<DBSHARINGInviteeMembershipInfo *> *)invitees;

- (instancetype)init NS_UNAVAILABLE;

@end

#pragma mark - Serializer Object

///
/// The serialization class for the `SharedFolderMembers` struct.
///
@interface DBSHARINGSharedFolderMembersSerializer : NSObject

///
/// Serializes `DBSHARINGSharedFolderMembers` instances.
///
/// @param instance An instance of the `DBSHARINGSharedFolderMembers` API
/// object.
///
/// @return A json-compatible dictionary representation of the
/// `DBSHARINGSharedFolderMembers` API object.
///
+ (nullable NSDictionary<NSString *, id> *)serialize:(DBSHARINGSharedFolderMembers *)instance;

///
/// Deserializes `DBSHARINGSharedFolderMembers` instances.
///
/// @param dict A json-compatible dictionary representation of the
/// `DBSHARINGSharedFolderMembers` API object.
///
/// @return An instantiation of the `DBSHARINGSharedFolderMembers` object.
///
+ (DBSHARINGSharedFolderMembers *)deserialize:(NSDictionary<NSString *, id> *)dict;

@end

NS_ASSUME_NONNULL_END


text:
var testGen = require('../testGen');

describe('Interlace', function () {

	describe('GrayScale', function () {

		describe('1-bit', function () {

			testGen.addDecodeTests({
				resourceGroup: 'interlace',
				resourceFile: 'basi0g01', // black & white
				imageCheck: true,

				chunkTypes: ['gAMA'],

				headerCheck: true,
				width: 32,
				height: 32,
				bitDepth: 1,
				colorType: 0,
				filter: 0,
				compression: 0,
				interlace: 1
			});
		});

		describe('2-bit', function () {

			testGen.addDecodeTests({
				resourceGroup: 'interlace',
				resourceFile: 'basi0g02', // 2 bit (4 level) grayscale
				imageCheck: true,

				chunkTypes: ['gAMA'],

				headerCheck: true,
				width: 32,
				height: 32,
				bitDepth: 2,
				colorType: 0,
				filter: 0,
				compression: 0,
				interlace: 1
			});
		});

		describe('4-bit', function () {

			testGen.addDecodeTests({
				resourceGroup: 'interlace',
				resourceFile: 'basi0g04', // 4 bit (16 level) grayscale
				imageCheck: true,

				chunkTypes: ['gAMA'],

				headerCheck: true,
				width: 32,
				height: 32,
				bitDepth: 4,
				colorType: 0,
				filter: 0,
				compression: 0,
				interlace: 1
			});
		});

		describe('8-bit', function () {

			testGen.addDecodeTests({
				resourceGroup: 'interlace',
				resourceFile: 'basi0g08', // 8 bit (256 level) grayscale
				imageCheck: true,

				chunkTypes: ['gAMA'],

				headerCheck: true,
				width: 32,
				height: 32,
				bitDepth: 8,
				colorType: 0,
				filter: 0,
				compression: 0,
				interlace: 1
			});
		});

		describe('16-bit', function () {

			testGen.addDecodeTests({
				resourceGroup: 'interlace',
				resourceFile: 'basi0g16', // 16 bit (64k level) grayscale
				imageCheck: true,

				chunkTypes: ['gAMA'],

				headerCheck: true,
				width: 32,
				height: 32,
				bitDepth: 16,
				colorType: 0,
				filter: 0,
				compression: 0,
				interlace: 1
			});
		});
	});

	describe('GrayScale with Alpha', function () {

		describe('8-bit', function () {

			testGen.addDecodeTests({
				resourceGroup: 'interlace',
				resourceFile: 'basi4a08', // 8 bit grayscale + 8 bit alpha-channel
				imageCheck: true,

				chunkTypes: ['gAMA'],

				headerCheck: true,
				width: 32,
				height: 32,
				bitDepth: 8,
				colorType: 4,
				filter: 0,
				compression: 0,
				interlace: 1
			});
		});

		describe('16-bit', function () {

			testGen.addDecodeTests({
				resourceGroup: 'interlace',
				resourceFile: 'basi4a16', // 16 bit grayscale + 16 bit alpha-channel
				imageCheck: true,

				chunkTypes: ['gAMA'],

				headerCheck: true,
				width: 32,
				height: 32,
				bitDepth: 16,
				colorType: 4,
				filter: 0,
				compression: 0,
				interlace: 1
			});
		});
	});

	describe('TrueColor', function () {

		describe('8-bit', function () {

			testGen.addDecodeTests({
				resourceGroup: 'interlace',
				resourceFile: 'basi2c08', // 3x8 bits rgb color
				imageCheck: true,

				chunkTypes: ['gAMA'],

				headerCheck: true,
				width: 32,
				height: 32,
				bitDepth: 8,
				colorType: 2,
				filter: 0,
				compression: 0,
				interlace: 1
			});
		});

		describe('16-bit', function () {

			testGen.addDecodeTests({
				resourceGroup: 'interlace',
				resourceFile: 'basi2c16', // 3x16 bits rgb color
				imageCheck: true,

				chunkTypes: ['gAMA'],

				headerCheck: true,
				width: 32,
				height: 32,
				bitDepth: 16,
				colorType: 2,
				filter: 0,
				compression: 0,
				interlace: 1
			});
		});
	});

	describe('TrueColor with Alpha', function () {

		describe('8-bit', function () {

			testGen.addDecodeTests({
				resourceGroup: 'interlace',
				resourceFile: 'basi6a08', // 3x8 bits rgb color + 8 bit alpha-channel
				imageCheck: true,

				chunkTypes: ['gAMA'],

				headerCheck: true,
				width: 32,
				height: 32,
				bitDepth: 8,
				colorType: 6,
				filter: 0,
				compression: 0,
				interlace: 1
			});
		});

		describe('16-bit', function () {

			testGen.addDecodeTests({
				resourceGroup: 'interlace',
				resourceFile: 'basi6a16', // 3x16 bits rgb color + 16 bit alpha-channel
				imageCheck: true,

				chunkTypes: ['gAMA'],

				headerCheck: true,
				width: 32,
				height: 32,
				bitDepth: 16,
				colorType: 6,
				filter: 0,
				compression: 0,
				interlace: 1
			});
		});
	});

	describe('Indexed-Color', function () {

		describe('1-bit', function () {

			testGen.addDecodeTests({
				resourceGroup: 'interlace',
				resourceFile: 'basi3p01', // 1 bit (2 color) paletted
				imageCheck: true,

				chunkTypes: ['gAMA'],

				headerCheck: true,
				width: 32,
				height: 32,
				bitDepth: 1,
				colorType: 3,
				filter: 0,
				compression: 0,
				interlace: 1
			});
		});

		describe('2-bit', function () {

			testGen.addDecodeTests({
				resourceGroup: 'interlace',
				resourceFile: 'basi3p02', // 2 bit (4 color) paletted
				imageCheck: true,

				chunkTypes: ['gAMA'],

				headerCheck: true,
				width: 32,
				height: 32,
				bitDepth: 2,
				colorType: 3,
				filter: 0,
				compression: 0,
				interlace: 1
			});
		});

		describe('4-bit', function () {

			testGen.addDecodeTests({
				resourceGroup: 'interlace',
				resourceFile: 'basi3p04', // 4 bit (16 color) paletted
				imageCheck: true,

				chunkTypes: ['gAMA'],

				headerCheck: true,
				width: 32,
				height: 32,
				bitDepth: 4,
				colorType: 3,
				filter: 0,
				compression: 0,
				interlace: 1
			});
		});

		describe('8-bit', function () {

			testGen.addDecodeTests({
				resourceGroup: 'interlace',
				resourceFile: 'basi3p08', // 8 bit (256 color) paletted
				imageCheck: true,

				chunkTypes: ['gAMA'],

				headerCheck: true,
				width: 32,
				height: 32,
				bitDepth: 8,
				colorType: 3,
				filter: 0,
				compression: 0,
				interlace: 1
			});
		});
	});
});


text:
from hubcheck.pageobjects.widgets.form_base import FormBase
from hubcheck.pageobjects.basepageelement import Checkbox
from hubcheck.pageobjects.basepageelement import TextArea

class GroupsDeleteForm(FormBase):
    def __init__(self, owner, locatordict={}):
        super(GroupsDeleteForm,self).__init__(owner,locatordict)

        # load hub's classes
        GroupsDeleteForm_Locators = self.load_class('GroupsDeleteForm_Locators')

        # update this object's locator defaults
        self.locators.update(GroupsDeleteForm_Locators.locators)

        # update the locators with those from the owner
        self.update_locators_from_owner()

        # setup page object's components
        self.message = TextArea(self,{'base':'message'})
        self.confirm = Checkbox(self,{'base':'confirm'})

        self.fields += ['message','confirm']

        # update the component's locators with this objects overrides
        self._updateLocators()

class GroupsDeleteForm_Locators_Base(object):
    """locators for GroupsDeleteForm object"""

    locators = {
        'base'    : "css=#hubForm",
        'message' : "css=#msg",
        'confirm' : "css=#confirmdel",
        'submit'  : "css=#hubForm [type='submit']",
    }


text:
var imgAside = document.getElementById('pic');
window.onscroll = function()
{
    animation(imgAside, scroll().top + 50);
};
function scroll()
{
    if(window.pageYOffset != null) {  // ie9+ 高版本浏览器

        return {
            left: window.pageXOffset,
            top: window.pageYOffset
        }
    }
    else if(document.compatMode === "CSS1Compat")
    {    // 标准浏览器   来判断有没有声明DTD
        return {
            left: document.documentElement.scrollLeft,
            top: document.documentElement.scrollTop
        }
    }
    return {   // 未声明 DTD
        left: document.body.scrollLeft,
        top: document.body.scrollTop
    }
}

function animation(obj, target)
{
    clearInterval(obj.timer);
    obj.timer = setInterval(function()
    {
        var step = (target - obj.offsetTop) / 10;
        step = step > 0 ? Math.ceil(step) : Math.floor(step);
        if(target == obj.offsetTop)
        {
            clearInterval(obj.timer);
        }
        else
        {
            obj.style.top = obj.offsetTop + step + 'px';
        }
    }, 20);
}


text:
// Javascript for parsing and displaying departure information
var routes = {};
// Store all the routes we find running at the given stops
var all_route_ids = [];

// Specify a URL here to load settings first from a configuration file
var config_url;

var options =
{
  url: "https://bustracker.pvta.com/InfoPoint/rest/",
  title: "",                      // title to display at top of page
  stops: [],
  routes: [],
  excluded_trips: [],
  sort: "route",                  // default way to sort departures
  interval: 30000,                // default time in ms between refreshes
  work_day_start: 4,              // default time a new transit day starts
  start_animation: 'fadeInDown',  // default animate CSS for each row to be added with
  end_animation: 'fadeOut',       // default animate CSS for everything to be removed with at once
  alternateInterval: 3000,        // default time in ms between alternating time and interval
  disableAlternation: false,      // whether alternation should be disabled
  showMessages: 'yes',            // whether to show messages - 'yes', 'no', or 'only' for no departures
}

var container;
var sort_function;
var refresh_id;
var messages;
var stop_index = 0;

var MINIMUM_REFRESH_TIME = 5; // minimum number of seconds allowed for user input
var CASCADE_SPEED = 75; // time in ms which each row will take to cascade
var END_ANIMATION_TIME = 500; // the amount of time we give the ending animate CSS to work

// The timezone at the beginning of the current day, used for making sure ETAs don't become
// incorrect when switching between DST and...not DST.
var dst_at_start;

// Whether we're currently displaying the departure interval or the departure time.
var currentTimeDisplay = 'interval';
// The ID of the interval process which is alternating the display.
var alternateID;

function QueryStringAsObject() {
  var pairs = location.search.slice(1).split('&');

  var result = {};
  for(var i = 0; i < pairs.length; i++) {
      var pair = pairs[i].split('=');
      result[pair[0]] = decodeURIComponent(pair[1] || '');
  }

  return result;
}

$(function(){
  container = $('.main-content');
  updateOptions();
  initTitle();
  initBoard();
});

function startErrorRoutine() {
  stopRefreshing();
  // We don't have a connectivity notice into the DOM at the moment
  if (container.find('.connectivity_note').length == 0){
    container.append('
No Bus Information Available
');
  }
  $.ajax({
    url: options.url + "PublicMessages/GetCurrentMessages",
    success: function(route_data) {
      container.empty();
      initBoard();
    },
    timeout: 1000,
    error: function(){
      setTimeout(function(){startErrorRoutine()}, 5000)
    }
  });
}

function updateOptions() {
  // First load from a config_url if one is specified
  if (typeof config_url !== "undefined") {
    $.ajax({
      url: config_url,
      dataType: 'json',
      success: function(new_options) {
        // Copy all attributes from new_options to options, replacing existing
        // parameters with the new ones
        $.extend(options, new_options);
      },
      async: false,
      timeout: 1000
    });
  }

  var query = QueryStringAsObject();

  var title_string = query.title;
  if (typeof title_string !== "undefined") {
    // To handle browsers adding a slash after the query string
    if (title_string.slice(-1) == "/") {
      title_string = title_string.slice(0,-1);
    }
    options.title = title_string;
  }

  var stop_query_string = query.stops;
  // Check if a query string has been specified
  if (typeof stop_query_string !== "undefined") {
    var query_parts = stop_query_string.split("+");
    for (var i = 0; i < query_parts.length; i++) {
      if (query_parts[i]) {
        options.stops.push(query_parts[i]);
      }
    }
  }
  // If they didn't enter any stops, or they screwed up, default to stop ID 64, the Integrative Learning Center
  if (options.stops.length == 0) {
    options.stops = [64];
  }

  var route_query_string = query.routes;
  if (typeof route_query_string !== "undefined") {
    var query_parts = route_query_string.split("+");
    for (var i = 0; i < query_parts.length; i++) {
      if (query_parts[i]) {
        options.routes.push(query_parts[i]);
      }
    }
  }

  var excluded_query_string = query.excluded_trips;
  // Check if a query string has been specified
  if (typeof excluded_query_string !== "undefined") {
    var query_parts = excluded_query_string.split("+");
    for (var i = 0; i < query_parts.length; i++) {
      if (query_parts[i]) {
        options.excluded_trips.push(query_parts[i]);
      }
    }
  }

  var sort_query_string = query.sort;
  if (typeof sort_query_string !== "undefined") {
    options.sort = sort_query_string;
  }
  if (options.sort == "time") {
    sort_function = function(a, b) {
      return a.Departure.EDT  parseInt(b.Route.RouteAbbreviation.replace(/\D+/, ''));
    }
  }

  // Expected value is in seconds, we convert to ms
  // Minimum allowed is MINIMUM_REFRESH_TIME seconds
  var interval_query_string = query.interval;
  if (typeof interval_query_string !== 'undefined'){
    options.interval = Math.max(MINIMUM_REFRESH_TIME, parseInt(interval_query_string)) * 1000;
  }

  // Bound alternateInterval between 1 second and half of the refresh interval.
  var alternateIntervalQueryString = query.alternate_interval;
  if (typeof alternateIntervalQueryString !== 'undefined'){
    var alternateInterval = parseInt(alternateIntervalQueryString) * 1000;
    alternateInterval = Math.max(1000, alternateInterval);
    alternateInterval = Math.min(alternateInterval, options.interval / 2);
    options.alternateInterval = alternateInterval;
  }

  var work_day_start_string = query.work_day_start;
  if (typeof work_day_start_string !== "undefined") {
    options.work_day_start = parseInt(work_day_start_string) % 24;
  }

  var start_animation_query_string = query.start_animation;
  if (typeof start_animation_query_string !== 'undefined'){
    options.start_animation = start_animation_query_string
  }

  var end_animation_query_string = query.end_animation;
  if (typeof end_animation_query_string !== 'undefined'){
    options.end_animation = end_animation_query_string
  }

  // If there are no animations specified, don't allow time for them to execute
  if (options.start_animation == 'none' && options.end_animation == 'none'){
    END_ANIMATION_TIME = 0;
  }

  var disableAlternationQueryString = query.disable_alternation;
  if (typeof disableAlternationQueryString !== 'undefined') {
    options.disableAlternation = disableAlternationQueryString == 'true';
  }

  var defaultTimeDisplayQueryString = query.default_time_display;
  if (typeof defaultTimeDisplayQueryString !== 'undefined'){
    if(['interval', 'time'].indexOf(defaultTimeDisplayQueryString) !== -1){
      currentTimeDisplay = defaultTimeDisplayQueryString;
    }
  }

  options.showMessages = query.show_messages;
}

function initTitle() {
  var body = $('body');
  if (typeof options.title !== "undefined" && options.title != "") {
    body.prepend('
' + options.title + '
');
  }
}

function initBoard() {
  // Let's start by preloading all of the route info, because when we query
  // departures, we'll only have the route ID
  $.ajax({
    url: options.url + "routes/getvisibleroutes",
    success: function(route_data) {
    for (var i = 0; i < route_data.length; i++) {
      routes[route_data[i].RouteId] = route_data[i];
    }
    addTables();
    alternateID = setInterval(alternateTimeDisplay, options.alternateInterval);
    startRefreshing();
  },
  dataType: 'json',
  error: startErrorRoutine});
}

function startRefreshing() {
  // Refresh the board every REFRESH_TIME ms
  refresh_id = setInterval(function() {
    removeTables();
    // Since we wait END_ANIMATION_TIME before emptying the page, we wait this
    // long before adding in the new tables.
    setTimeout(function(){
      addTables();
      alternateID = setInterval(alternateTimeDisplay, options.alternateInterval);
    }, END_ANIMATION_TIME)
  }, options.interval);
}

function stopRefreshing() {
  clearInterval(alternateID);
  clearInterval(refresh_id);
}

function addTables() {
  var current = moment();
  // Is it still "yesterday" as far as the transit agency is concerned
  if (current.hour() <= options.work_day_start) {
    dst_at_start = moment([current.year(), current.month(), current.date(), options.work_day_start]).subtract(1, "days").isDST();
  } else {
    dst_at_start = moment([current.year(), current.month(), current.date(), options.work_day_start]).isDST();
  }

  var row, section;
  var size_class = "";
  if (options.stops.length > 1) {
    size_class = "col-lg-12";
  }
  // There are two separate calls here,
  $.ajax({
    url: options.url + "stops/get/" + options.stops[stop_index],
    success: function(stop_info) {
      if (stop_index % 2 == 0) {
        row = $('

');
      } else {
        row = $('.route-holder:last');
      }
      section = $('

"');
      row.append(section);
      if (stop_index % 2 == 0) {
        container.append(row);
      }
      $.ajax({
        url: options.url + "stopdepartures/get/" + options.stops[stop_index],
        success: function(departure_data) {
          // Draw the header for each stop
          section.append('
' + stop_info.Description + "
");
          departure_data[0] = departure_data[0] || {RouteDirections: []}
          var infos = getDepartureInfo(departure_data[0].RouteDirections);
          var done = isDone(departure_data[0].RouteDirections);
          if (infos.length == 0){
            var message = "";
            if (done) {
              message = "No remaining scheduled departures.";
            } else {
              message = "No departures in the next two hours";
            }
            section.append('
' + message + '
');
          }
          var i = 0; // For that soothing cascading effect
          var id = setInterval(function() {
              // If we still have rows to render
              if (i < infos.length) {
                if(options.showMessages !== 'only')
                  renderRow(infos[i], section);
                i++;
              } else { // If not, clear out the timer and move onto the next route
                clearTimeout(id);
                stop_index++;
                // If we run out of stops, reset our index and don't do anything
                if (stop_index < options.stops.length) {
                  addTables(options.stops);
                } else {
                  if(options.showMessages !== 'no')
                    setTimeout(addMessages, CASCADE_SPEED);
                  stop_index = 0;
                }
              }
            }, CASCADE_SPEED);
      },
      dataType: 'json',
      error: startErrorRoutine});
    },
    dataType: 'json',
    error: startErrorRoutine});
}

function addMessages(){
  $.ajax({
    url: options.url + '/publicmessages/getcurrentmessages',
    dataType: 'json',
    success: function(messages){
      var applicableMessages = [];
      // For each message, determine if it applies to the routes which service
      // the stops in question.
      for(var i = 0; i < messages.length; i++){
        var message = messages[i];
        // Show messages which don't apply to any route.
        if(message.Routes.length == 0){
          applicableMessages.push(message);
        }
        else{
          // Check each route ID to see if the message applies to it.
          for(var j = 0; j < all_route_ids.length; j++){
            if($.inArray(all_route_ids[j], message.Routes) !== -1){
              applicableMessages.push(message);
              break;
            }
          }
        }
      }
      if(applicableMessages.length > 0){
        container.append('

')
        for(var i = 0; i < applicableMessages.length; i++){
          var message = applicableMessages[i];
          var routeNames = [];
          for(j = 0; j < message.Routes.length; j++){
            routeNames.push(routes[message.Routes[j]].RouteAbbreviation);
          }
          if(message.Routes.length > 0){
            var messageText = routeNames.join(', ') + ': ' + message.Message;
          }
          else var messageText = message.Message;
          $('.message-holder').append('
' + messageText);
        }
        $('.message-holder').addClass(options.start_animation);
      }
    }
  });
}

//removes the tables in preparation to load in the new ones. fancy CSS magic.
function removeTables() {
  // stop alternating between time and interval
  clearInterval(alternateID);
  //fade out stops and their departures
  $('h1').addClass(options.end_animation);
  $('.route').addClass(options.end_animation);
  $('.message-holder').addClass(options.end_animation);
  //once we've given that END_ANIMATION_TIME to work, remove everything.
  setTimeout(function(){
    container.empty()
  }, END_ANIMATION_TIME);
}

// A bit of a misnomer, we will occassionally render more than one row in here,
// since there may be multiple departures on the same route that we're interested in:
// the most common example being opportunity trips (e.g. Garage via Mass Ave
// at the end of 30-3 EVE, which is on route 30 and northbound, just like North Amherst,
// but has a different trip description).
function renderRow(info, section) {
  var short_proportions = "col-xs-2 col-sm-2 col-md-2 col-lg-2";
  var long_proportions = "col-xs-15 col-sm-15 col-md-15 col-lg-15";
  var arrival_proportions = "col-xs-7 col-sm-7 col-md-7 col-lg-7";
  var offset = 0;
  // If we aren't in the same timezone as we were this morning
  if (dst_at_start != moment().isDST()) {
    // If the day started in DST and isn't any more, that means that the clock
    // has moved back an hour from where we want it to be, and we need to up it
    // an hour to display the correct relative times.
    if (dst_at_start) {
      offset = 1;
    } else {
      offset = -1;
    }
  }
  var interval = departureInterval(info.Departure.EDT, offset);
  var time = departureDisplayTime(info.Departure.EDT);
  var startingTimeDisplay, style;
  if(currentTimeDisplay == 'interval') startingTimeDisplay = interval;
  else startingTimeDisplay = time;

  if (info.Route.Color == '000000') {
    style = 'style="background-color: #' + info.Route.Color + '; color: #' + info.Route.TextColor +
      '; border: solid white"'
  } else {
    style = 'style="background-color: #' + info.Route.Color + '; color: #' + info.Route.TextColor + '"'
  }

  section.append(
    '
' +
      '
' +
        '
' +
          info.Route.RouteAbbreviation +
        '
' +
        '
' +
          info.Departure.Trip.InternetServiceDesc +
        '
' +
        '
' +
           startingTimeDisplay +
        '
'+
      '
'+
    '
'
  );
}

function departureInterval(edt, offset){
  now = moment();
  edt = moment(edt);
  nowInMinutes = (now.hour() + offset) * 60 + now.minute();
  edtInMinutes = edt.hour() * 60 + edt.minute();
  // Since EDT is always after now, the only reason the days will be different
  // is if the EDT is on the next day.
  if(edt.day() != now.day())
    edtInMinutes += 60 * 24;
  interval = edtInMinutes - nowInMinutes;
  if (interval == 0)
    return 'Now';
  else if (interval < 60)
    return interval + ' min';
  else {
    hours = Math.floor(interval / 60);
    minutes = interval % 60;
    return hours + ' hr ' + minutes + ' min';
  }
}

function departureDisplayTime(edt){
  return moment(edt).format('h:mm a');
}

function alternateTimeDisplay(){
  if(!options.disableAlternation){
    if(currentTimeDisplay == 'interval') currentTimeDisplay = 'time';
    else currentTimeDisplay = 'interval';
    $('.route_arrival').each(function(){
      $(this).text($(this).data(currentTimeDisplay));
    })
  }
}

function getDepartureInfo(directions) {
  // This is a little tricky. There's a sort of edge case where we want to
  // display information for multiple buses on the same route, that are doing
  // different things. We differentiate them by using their
  // InternetServiceDesc, which will be different. Since the departures are
  // ordered from soonest to furthest away, we care about the first one with
  // a unique InternetServiceDesc, and that's what we're checking here.
  var unique_ISDs = [];
  departures = [];
  var route_ids = [];
  for (var i = 0; i < directions.length; i++) {
    var direction = directions[i];
    var route = routes[direction.RouteId];
    for (var j = 0; j < direction.Departures.length; j++) {
      var departure = direction.Departures[j];
      //If the departure has a unique InternetServiceDesc,
      if ($.inArray(departure.Trip.InternetServiceDesc, unique_ISDs) == -1
          //and if it's in the allowed routes,
          && (options.routes.length == 0 || $.inArray(route.RouteAbbreviation, options.routes) != -1)
          //and if it's not in the excluded trips
          && (options.excluded_trips.length == 0 || $.inArray(departure.Trip.InternetServiceDesc, options.excluded_trips) == -1)
          //and if it's in the future,
          && moment(departure.EDT).isAfter(Date.now())
          //and it's not skipped
          && departure.StopStatusReportLabel != 'Skipped') {
        // then we push it to the list, and push its ISD to the unique ISDs list.
        unique_ISDs.push(departure.Trip.InternetServiceDesc);
        departures.push({Departure: departure, Route: route});
        route_ids.push(route.RouteId);
        // A global list of routes running on our stops
        all_route_ids.push(route.RouteId);
      }
    }
  }
  return departures.sort(sort_function);
}

// Returns true if there are no departures for any RouteDirection and isDone is true for all of them, false
function isDone(directions) {
  for (var i = 0; i < directions.length; i++) {
    var direction = directions[i];
    // If there are any departures, we're not done
    if (direction.Departures.length > 0) {
      return false;
    }

    // If there's no departures and we're not done, then we're not done
    if (!direction.IsDone) {
      return false;
    }
  }
  // If there are no departures and they all have isDone == true, we're done
  return true;
}


text:
<?php
// remove the following lines when in production mode
defined('YII_DEBUG') or define('YII_DEBUG',true);
if(YII_DEBUG) {
    ini_set("display_errors",1);
    error_reporting(E_ALL);
    $global_counter = 0;
}

// change the following paths if necessary
$yii=dirname(__FILE__).'/../yii/framework/yii.php';
$config=dirname(__FILE__).'/protected/config/main.php';

// specify how many levels of call stack should be shown in each log message
defined('YII_TRACE_LEVEL') or define('YII_TRACE_LEVEL',3);

// define the root of this application
defined('ROOT') or define('ROOT',dirname(__FILE__));
defined('HTTP_HOST') or define('HTTP_HOST',$_SERVER["HTTP_HOST"]);
defined('WEB_ROOT') or define('WEB_ROOT',dirname($_SERVER["HTTP_HOST"].$_SERVER["PHP_SELF"]));

// define local library paths (see StdLib class)
defined('LOCAL_LIBRARY_PATH') or define('LOCAL_LIBRARY_PATH',ROOT.'\\library\\');
defined('LOCAL_IMAGE_LIBRARY') or define('LOCAL_IMAGE_LIBRARY',LOCAL_LIBRARY_PATH."images\\");

// define web library paths (see StdLib class)
defined('WEB_LIBRARY_PATH') or define('WEB_LIBRARY_PATH','//'.WEB_ROOT.'/library/');
defined('WEB_IMAGE_LIBRARY') or define('WEB_IMAGE_LIBRARY',WEB_LIBRARY_PATH."images/");

include ROOT."/protected/models/Functions.php";
require_once($yii);
Yii::createWebApplication($config)->run();


text:
"""
    Lob

    The Lob API is organized around REST. Our API is designed to have predictable, resource-oriented URLs and uses HTTP response codes to indicate any API errors. <p> Looking for our [previous documentation](https://lob.github.io/legacy-docs/)?   # noqa: E501

    The version of the OpenAPI document: 1.3.0
    Contact: lob-openapi@lob.com
    Generated by: https://openapi-generator.tech
"""

import re  # noqa: F401
import sys  # noqa: F401

from lob_python.model_utils import (  # noqa: F401
    ApiTypeError,
    ModelComposed,
    ModelNormal,
    ModelSimple,
    cached_property,
    change_keys_js_to_python,
    convert_js_args_to_python_args,
    date,
    datetime,
    file_type,
    none_type,
    validate_get_composed_info,
    OpenApiModel
)
from lob_python.exceptions import ApiAttributeError

from lob_python.model.city import City
from lob_python.model.country_extended import CountryExtended
from lob_python.model.postal_code import PostalCode
from lob_python.model.recipient import Recipient
from lob_python.model.secondary_line import SecondaryLine
globals()['City'] = City
globals()['CountryExtended'] = CountryExtended
globals()['PostalCode'] = PostalCode
globals()['Recipient'] = Recipient
globals()['SecondaryLine'] = SecondaryLine

class MultipleComponentsIntl(ModelNormal):
    """NOTE: This class is auto generated by OpenAPI Generator.
    Ref: https://openapi-generator.tech

    Do not edit the class manually.

    Attributes:
      allowed_values (dict): The key is the tuple path to the attribute
          and the for var_name this is (var_name,). The value is a dict
          with a capitalized key describing the allowed value and an allowed
          value. These dicts store the allowed enum values.
      attribute_map (dict): The key is attribute name
          and the value is json key in definition.
      discriminator_value_class_map (dict): A dict to go from the discriminator
          variable value to the discriminator class name.
      validations (dict): The key is the tuple path to the attribute
          and the for var_name this is (var_name,). The value is a dict
          that stores validations for max_length, min_length, max_items,
          min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum,
          inclusive_minimum, and regex.
      additional_properties_type (tuple): A tuple of classes accepted
          as additional properties values.
    """

    allowed_values = {
    }

    validations = {
        ('primary_line',): {
            'max_length': 200,
        },
    }

    @cached_property
    def additional_properties_type():
        """
        This must be a method because a model may have properties that are
        of type self, this must run after the class is loaded
        """
        return (bool, date, datetime, dict, float, int, list, str, none_type,)  # noqa: E501

    _nullable = False

    @cached_property
    def openapi_types():
        """
        This must be a method because a model may have properties that are
        of type self, this must run after the class is loaded

        Returns
            openapi_types (dict): The key is attribute name
                and the value is attribute type.
        """
        return {
            'primary_line': (str,),  # noqa: E501
            'country': (CountryExtended,),  # noqa: E501
            'recipient': (str, type(None)),  # noqa: E501
            'secondary_line': (str, type(None)),  # noqa: E501
            'city': (str, type(None)),  # noqa: E501
            'state': (str, type(None)),  # noqa: E501
            'postal_code': (str, type(None)),  # noqa: E501
        }

    @cached_property
    def discriminator():
        return None

    attribute_map = {
        'primary_line': 'primary_line',  # noqa: E501
        'country': 'country',  # noqa: E501
        'recipient': 'recipient',  # noqa: E501
        'secondary_line': 'secondary_line',  # noqa: E501
        'city': 'city',  # noqa: E501
        'state': 'state',  # noqa: E501
        'postal_code': 'postal_code',  # noqa: E501
    }

    read_only_vars = {
    }

    _composed_schemas = {}

    @classmethod
    @convert_js_args_to_python_args
    def _from_openapi_data(cls, primary_line, country, *args, **kwargs):  # noqa: E501
        """MultipleComponentsIntl - a model defined in OpenAPI

        Args:
            primary_line (str): The primary delivery line (usually the street address) of the address.
            country (CountryExtended):

        Keyword Args:
            _check_type (bool): if True, values for parameters in openapi_types
                                will be type checked and a TypeError will be
                                raised if the wrong type is input.
                                Defaults to True
            _path_to_item (tuple/list): This is a list of keys or values to
                                drill down to the model in received_data
                                when deserializing a response
            _spec_property_naming (bool): True if the variable names in the input data
                                are serialized names, as specified in the OpenAPI document.
                                False if the variable names in the input data
                                are pythonic names, e.g. snake case (default)
            _configuration (Configuration): the instance to use when
                                deserializing a file_type parameter.
                                If passed, type conversion is attempted
                                If omitted no type conversion is done.
            _visited_composed_classes (tuple): This stores a tuple of
                                classes that we have traveled through so that
                                if we see that class again we will not use its
                                discriminator again.
                                When traveling through a discriminator, the
                                composed schema that is
                                is traveled through is added to this set.
                                For example if Animal has a discriminator
                                petType and we pass in "Dog", and the class Dog
                                allOf includes Animal, we move through Animal
                                once using the discriminator, and pick Dog.
                                Then in Dog, we will make an instance of the
                                Animal class but this time we won't travel
                                through its discriminator because we passed in
                                _visited_composed_classes = (Animal,)
            recipient (str, type(None)): [optional] # noqa: E501
            secondary_line (str, type(None)): [optional] # noqa: E501
            city (str, type(None)): [optional] # noqa: E501
            state (str, type(None)): The name of the state.. [optional] # noqa: E501
            postal_code (str, type(None)): [optional] # noqa: E501
        """

        _check_type = kwargs.pop('_check_type', True)
        _spec_property_naming = kwargs.pop('_spec_property_naming', False)
        _path_to_item = kwargs.pop('_path_to_item', ())
        _configuration = kwargs.pop('_configuration', None)
        _visited_composed_classes = kwargs.pop('_visited_composed_classes', ())

        self = super(OpenApiModel, cls).__new__(cls)

        if args:
            raise ApiTypeError(
                "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
                    args,
                    self.__class__.__name__,
                ),
                path_to_item=_path_to_item,
                valid_classes=(self.__class__,),
            )

        self._data_store = {}
        self._check_type = _check_type
        self._spec_property_naming = _spec_property_naming
        self._path_to_item = _path_to_item
        self._configuration = _configuration
        self._visited_composed_classes = _visited_composed_classes + (self.__class__,)

        self.primary_line = primary_line
        self.country = country
        for var_name, var_value in kwargs.items():
            if var_name not in self.attribute_map and \
                        self._configuration is not None and \
                        self._configuration.discard_unknown_keys and \
                        self.additional_properties_type is None:
                # discard variable.
                continue
            setattr(self, var_name, var_value)
        return self

    required_properties = set([
        '_data_store',
        '_check_type',
        '_spec_property_naming',
        '_path_to_item',
        '_configuration',
        '_visited_composed_classes',
    ])

    @convert_js_args_to_python_args
    def __init__(self, primary_line, country, *args, **kwargs):  # noqa: E501
        """MultipleComponentsIntl - a model defined in OpenAPI

        Args:
            primary_line (str): The primary delivery line (usually the street address) of the address.
            country (CountryExtended):

        Keyword Args:
            _check_type (bool): if True, values for parameters in openapi_types
                                will be type checked and a TypeError will be
                                raised if the wrong type is input.
                                Defaults to True
            _path_to_item (tuple/list): This is a list of keys or values to
                                drill down to the model in received_data
                                when deserializing a response
            _spec_property_naming (bool): True if the variable names in the input data
                                are serialized names, as specified in the OpenAPI document.
                                False if the variable names in the input data
                                are pythonic names, e.g. snake case (default)
            _configuration (Configuration): the instance to use when
                                deserializing a file_type parameter.
                                If passed, type conversion is attempted
                                If omitted no type conversion is done.
            _visited_composed_classes (tuple): This stores a tuple of
                                classes that we have traveled through so that
                                if we see that class again we will not use its
                                discriminator again.
                                When traveling through a discriminator, the
                                composed schema that is
                                is traveled through is added to this set.
                                For example if Animal has a discriminator
                                petType and we pass in "Dog", and the class Dog
                                allOf includes Animal, we move through Animal
                                once using the discriminator, and pick Dog.
                                Then in Dog, we will make an instance of the
                                Animal class but this time we won't travel
                                through its discriminator because we passed in
                                _visited_composed_classes = (Animal,)
            recipient (str, type(None)): [optional] # noqa: E501
            secondary_line (str, type(None)): [optional] # noqa: E501
            city (str, type(None)): [optional] # noqa: E501
            state (str, type(None)): The name of the state.. [optional] # noqa: E501
            postal_code (str, type(None)): [optional] # noqa: E501
        """

        _check_type = kwargs.pop('_check_type', True)
        _spec_property_naming = kwargs.pop('_spec_property_naming', False)
        _path_to_item = kwargs.pop('_path_to_item', ())
        _configuration = kwargs.pop('_configuration', None)
        _visited_composed_classes = kwargs.pop('_visited_composed_classes', ())

        if args:
            raise ApiTypeError(
                "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
                    args,
                    self.__class__.__name__,
                ),
                path_to_item=_path_to_item,
                valid_classes=(self.__class__,),
            )

        self._data_store = {}
        self._check_type = _check_type
        self._spec_property_naming = _spec_property_naming
        self._path_to_item = _path_to_item
        self._configuration = _configuration
        self._visited_composed_classes = _visited_composed_classes + (self.__class__,)

        self.primary_line = primary_line
        self.country = country
        for var_name, var_value in kwargs.items():
            if var_name not in self.attribute_map and \
                        self._configuration is not None and \
                        self._configuration.discard_unknown_keys and \
                        self.additional_properties_type is None:
                # discard variable.
                continue
            setattr(self, var_name, var_value)
            if var_name in self.read_only_vars:
                raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate "
                                     f"class with read only attributes.")


text:
<nav color="205365">
    <view name="summary" default="true"/>
    <view name="user_activity"/>
    <view name="keycard_activity"/>
    <collection label="Suspicious Activity">
        <view name="offhours_document_access"/>
        <view name="terminated_employee_document_access"/>
        <view name="anomalous_activity"/>
    </collection>
    <view name="customer_monitor"/>
    <view name="search" />
    <view name="alerts" />
    <view name="setup"/>
    <view name="about" />
</nav>


text:
using System.Collections.Generic;

namespace TourDeFrance.Core.Business
{
	public class PagingResult<T>
	{
		public IEnumerable<T> Results { get; set; }

		public int Offset { get; set; }

		public int Max { get; set; }

		public int Total { get; set; }
	}
}


text:
DROP INDEX issuer ON hydra_oauth2_trusted_jwt_bearer_issuer;
DROP INDEX hydra_oauth2_trusted_jwt_bearer_issuer_expires_at_idx ON hydra_oauth2_trusted_jwt_bearer_issuer;


text:
/*!
 * Start Bootstrap - Shop Homepage HTML Template (http://startbootstrap.com)
 * Code licensed under the Apache License v2.0.
 * For details, see http://www.apache.org/licenses/LICENSE-2.0.
 */

body {

    padding-top: 70px; /* Required padding for .navbar-fixed-top. Remove if using .navbar-static-top. Change if height of navigation changes. */
	background:url(../images/rrrr.jpg);
}

.slide-image {
    width: 100%;
}

.carousel-holder {
    margin-bottom: 30px;
}

.carousel-control,
.item {
    border-radius: 4px;
}

.caption {
	height: 180px;
	overflow: hidden;
}

.caption h4 {
    white-space: nowrap;
}

.thumbnail img {
    width: 100%;
}

.ratings {
    padding-right: 10px;
    padding-left: 10px;
    color: #d17581;
}

.thumbnail {
    padding: 0;
}

.thumbnail .caption-full {
    padding: 9px;
    color: #333;
}

footer {
    margin: 20px 0;
	background-color:#000;
}
.lead{
	background: #000080;
	font-size: 18px;
	color: #FF0;
}

.body div.sidebar div a#twitter {
	background:url(../images/icons.png) no-repeat;
	width:28px;
	height:24px;
	text-indent:-99999px;
	display:block;
	float:left;
	margin:18px 0 0 18px;
}
.body div.sidebar div a#twitter:hover {
	background:url(../images/icons.png) no-repeat 0 -73px;
}
.body div.sidebar div a#fb {
	background:url(../images/icons.png) no-repeat 0 -25px;
	width:27px;
	height:23px;
	text-indent:-99999px;
	display:block;
	float:left;
	margin:18px 38px 0;
}
.body div.sidebar div a#fb:hover {
	background:url(../images/icons.png) no-repeat 0 -98px;
}
.body div.sidebar div a#googleplus {
	background:url(../images/icons.png) no-repeat 0 -49px;
	width:23px;
	height:23px;
	text-indent:-99999px;
	display:block;
	float:left;
	margin:18px 0 0;
}
.body div.sidebar div a#googleplus:hover {
	background:url(../images/icons.png) no-repeat 0 -122px;
}
.me {
	float: right;
	color:#FFFBF0;
	font-size:18px;
	font-family:Georgia, "Times New Roman", Times, serif;
}

.mok{

	float: left;
	font-size:20px;
	color:#FF0;
	}
	.ok{float:right;
	}

	.wago{
		float:right;
	}

	.ven{
		font-family:Verdana, Geneva, sans-serif;
		font-size:12px;
		color:#FFF;
	}

footer span.copyright {
    text-transform: uppercase;
    text-transform: none;
    font-family: Montserrat,"Helvetica Neue",Helvetica,Arial,sans-serif;
    line-height: 40px;
}

footer ul.quicklinks {
    margin-bottom: 0;
    text-transform: uppercase;
    text-transform: none;
    font-family: Montserrat,"Helvetica Neue",Helvetica,Arial,sans-serif;
    line-height: 40px;
}

ul.social-buttons {
    margin-bottom: 0;
}

ul.social-buttons li a {
    display: block;
    width: 40px;
    height: 40px;
    border-radius: 100%;
    font-size: 16px;
    line-height: 40px;
    outline: 0;
    color: #fff;
    background-color: #222;
    -webkit-transition: all .3s;
    -moz-transition: all .3s;
    transition: all .3s;
}

ul.social-buttons li a:hover,
ul.social-buttons li a:focus,
ul.social-buttons li a:active {
    background-color: #fed136;
}

.btn:focus,
.btn:active,
.btn.active,
.btn:active:focus {
    outline: 0;
}

.portfolio-modal .modal-content {
    padding: 100px 0;
    min-height: 100%;
    border: 0;
    border-radius: 0;
    text-align: center;
    background-clip: border-box;
    -webkit-box-shadow: none;
    box-shadow: none;
}

.portfolio-modal .modal-content h2 {
    margin-bottom: 15px;
    font-size: 3em;
}

.portfolio-modal .modal-content p {
    margin-bottom: 30px;
}

.portfolio-modal .modal-content p.item-intro {
    margin: 20px 0 30px;
    font-family: "Droid Serif","Helvetica Neue",Helvetica,Arial,sans-serif;
    font-size: 16px;
    font-style: italic;
}

.portfolio-modal .modal-content ul.list-inline {
    margin-top: 0;
    margin-bottom: 30px;
}

.portfolio-modal .modal-content img {
    margin-bottom: 30px;
}

.portfolio-modal .close-modal {
    position: absolute;
    top: 25px;
    right: 25px;
    width: 75px;
    height: 75px;
    background-color: transparent;
    cursor: pointer;
}

.portfolio-modal .close-modal:hover {
    opacity: .3;
}

.portfolio-modal .close-modal .lr {
    z-index: 1051;
    width: 1px;
    height: 75px;
    margin-left: 35px;
    background-color: #222;
    -webkit-transform: rotate(45deg);
    -ms-transform: rotate(45deg);
    transform: rotate(45deg);
}

.portfolio-modal .close-modal .lr .rl {
    z-index: 1052;
    width: 1px;
    height: 75px;
    background-color: #222;
    -webkit-transform: rotate(90deg);
    -ms-transform: rotate(90deg);
    transform: rotate(90deg);
}

.portfolio-modal .modal-backdrop {
    display: none;
    opacity: 0;
}

::-moz-selection {
    text-shadow: none;
    background: #fed136;
}

::selection {
    text-shadow: none;
    background: #fed136;
}

img::selection {
    background: 0 0;
}

img::-moz-selection {
    background: 0 0;
}


text:
//  Copyright (c) 2015 Artem Babenko. All rights reserved.

package com.inmobi.nativeapp.sample.news.engine;

import java.util.ArrayList;
import java.util.List;

import com.inmobi.monetization.IMNative;

public class FeedInfo {

	private String title;

	private List<FeedItem> items = new ArrayList<FeedInfo.FeedItem>();

	/**
	 * @return the title
	 */
	public String getTitle() {
		return title;
	}

	/**
	 * @param title
	 *            the title to set
	 */
	public void setTitle(String title) {
		this.title = title;
	}

	/**
	 * @return the items
	 */
	public List<FeedItem> getItems() {
		return items;
	}

	/**
	 * @param items
	 *            the items to set
	 */
	public void addItem(FeedItem item) {
		if (item == null) {
			return;
		}
		items.add(item);
		// Log.i(Constants.LOG_TAG, "Items added: " + item);
	}

	/*
	 * (non-Javadoc)
	 *
	 * @see java.lang.Object#toString()
	 */
	@Override
	public String toString() {
		return "FeedInfo [title=" + title + ", items=" + items + "]";
	}

	public static class FeedItem {
		private String title;
		private String iconUrl;
		private String description;
		private String link;
		private String thumbnailurl;
		private IMNative inMobiNativeAd;

		/**
		 * @return the link
		 */
		public String getLink() {
			return link;
		}

		/**
		 * @param link
		 *            the link to set
		 */
		public void setLink(String link) {
			this.link = link;
		}
		/**
		 * @return the title
		 */
		public String getTitle() {
			return title;
		}

		/**
		 * @param title
		 *            the title to set
		 */
		public void setTitle(String title) {
			this.title = title;
		}

		/**
		 * @return the iconUrl
		 */
		public String getIconUrl() {
			return iconUrl;
		}

		/**
		 * @param iconUrl
		 *            the iconUrl to set
		 */
		public void setIconUrl(String iconUrl) {
			this.iconUrl = iconUrl;
		}

		/**
		 * @param thumbnailUrl
		 *            the thumbnailUrl to set
		 */
		public void setthumbnailUrl(String thumbnailUrl) {
			this.thumbnailurl = thumbnailUrl;
		}

		/**
		 * @return the thumbnailUrl
		 */
		public String getthumbnailUrl() {
			return thumbnailurl;
		}

		/**
		 * @return the link
		 */
		public String getdesc() {
			return description;
		}

		/**
		 * @param link
		 *            the link to set
		 */
		public void setdesc(String description) {
			this.description = description;
		}

		/**
		 * @return the inMobiNativeAd
		 */
		public IMNative getInMobiNativeAd() {
			return inMobiNativeAd;
		}

		/**
		 * @param nativeAd1
		 *            the inMobiNativeAd to set
		 */
		public void setInMobiNativeAd(IMNative nativeAd1) {
			this.inMobiNativeAd = nativeAd1;
		}

		/*
		 * (non-Javadoc)
		 *
		 * @see java.lang.Object#toString()
		 */
		@Override
		public String toString() {
			return "FeedItem [title=" + title + ", iconUrl=" + iconUrl
					+ ", description=" + description + ", inMobiNativeAd=" + inMobiNativeAd
					+ "]";
		}

	}

}


text:
module HugsLibs where

import StdLibs
import Number
import ParseLib
import Interact
import AnsiScreen
import AnsiInteract
import ListUtils

-----------------------------------------------------------------------------


text:
ACCEPTED

#### According to
Index Fungorum

#### Published in
null

#### Original name
Lecanora subfusca f. melacarpa Harm.

### Remarks
null