text:
package nextmethod.web.razor.generator;

import java.util.List;

import nextmethod.base.Delegates;
import nextmethod.web.razor.RazorEngineHost;

@FunctionalInterface
interface RazorCodeGeneratorTestRunner {
    void execute(
        final String name,
        String baselineName,
        boolean generatePragmas,
        boolean designTimeMode,
        final List<GeneratedCodeMapping> expectedDesignTimePragmas,
        final TestSpan[] spans,
        TabTest tabTest,
        Delegates.IAction1<RazorEngineHost> hostConfig
    );
}


text:
.class Landroid/widget/GridLayout$7$1;
.super Landroid/widget/GridLayout$Bounds;
.source "GridLayout.java"

# annotations
.annotation system Ldalvik/annotation/EnclosingMethod;
    value = Landroid/widget/GridLayout$7;->getBounds()Landroid/widget/GridLayout$Bounds;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = null
.end annotation

# instance fields
.field private size:I

.field final synthetic this$0:Landroid/widget/GridLayout$7;

# direct methods
.method constructor <init>(Landroid/widget/GridLayout$7;)V
    .locals 1

    .prologue
    .line 2931
    iput-object p1, p0, Landroid/widget/GridLayout$7$1;->this$0:Landroid/widget/GridLayout$7;

    const/4 v0, 0x0

    invoke-direct {p0, v0}, Landroid/widget/GridLayout$Bounds;-><init>(Landroid/widget/GridLayout$1;)V

    return-void
.end method

# virtual methods
.method protected getOffset(Landroid/widget/GridLayout;Landroid/view/View;Landroid/widget/GridLayout$Alignment;IZ)I
    .locals 2
    .param p1, "gl"    # Landroid/widget/GridLayout;
    .param p2, "c"    # Landroid/view/View;
    .param p3, "a"    # Landroid/widget/GridLayout$Alignment;
    .param p4, "size"    # I
    .param p5, "hrz"    # Z

    .prologue
    .line 2959
    const/4 v0, 0x0

    invoke-super/range {p0 .. p5}, Landroid/widget/GridLayout$Bounds;->getOffset(Landroid/widget/GridLayout;Landroid/view/View;Landroid/widget/GridLayout$Alignment;IZ)I

    move-result v1

    invoke-static {v0, v1}, Ljava/lang/Math;->max(II)I

    move-result v0

    return v0
.end method

.method protected include(II)V
    .locals 2
    .param p1, "before"    # I
    .param p2, "after"    # I

    .prologue
    .line 2948
    invoke-super {p0, p1, p2}, Landroid/widget/GridLayout$Bounds;->include(II)V

    .line 2949
    iget v0, p0, Landroid/widget/GridLayout$7$1;->size:I

    add-int v1, p1, p2

    invoke-static {v0, v1}, Ljava/lang/Math;->max(II)I

    move-result v0

    iput v0, p0, Landroid/widget/GridLayout$7$1;->size:I

    .line 2950
    return-void
.end method

.method protected reset()V
    .locals 1

    .prologue
    .line 2942
    invoke-super {p0}, Landroid/widget/GridLayout$Bounds;->reset()V

    .line 2943
    const/high16 v0, -0x80000000

    iput v0, p0, Landroid/widget/GridLayout$7$1;->size:I

    .line 2944
    return-void
.end method

.method protected size(Z)I
    .locals 2
    .param p1, "min"    # Z

    .prologue
    .line 2954
    invoke-super {p0, p1}, Landroid/widget/GridLayout$Bounds;->size(Z)I

    move-result v0

    iget v1, p0, Landroid/widget/GridLayout$7$1;->size:I

    invoke-static {v0, v1}, Ljava/lang/Math;->max(II)I

    move-result v0

    return v0
.end method

redpajama_set_name: RedPajamaGithub


text:
package jenkins.plugins.johnny;

import static org.mockito.Mockito.mock;
import jenkins.plugins.johnny.JohnnyDescriptor;
import hudson.model.AbstractProject;
import junit.framework.TestCase;

public class JohnnyDescriptorTest extends TestCase {

	private JohnnyDescriptor descriptor;

	public void setUp() {
		descriptor = new JohnnyDescriptor();
	}

	public void testGetDisplayName() {
		assertEquals("Activate Johnny", descriptor.getDisplayName());
	}

	public void testIsApplicableGivesTrue() {
		assertTrue(descriptor.isApplicable(mock(AbstractProject.class)
				.getClass()));
	}
}


text:
var adalyzerControllers = angular.module('AdalyzerControllers', ['AdalyzerServices']);

adalyzerControllers.controller('MainController', ['$scope', 'BackendService', function($scope, BackendService) {
}]);

adalyzerControllers.controller('MapController', ['$scope', 'BackendService', function($scope, BackendService, NgMap) {
	$scope.title = 'Key points';

	// initialize an array with markers
	var markers = [];

	// car image
	var image = {
		url: 'img/car.png',
		// This marker is 20 pixels wide by 32 pixels high.
		size: new google.maps.Size(50, 50),
		// The origin for this image is (0, 0).
		origin: new google.maps.Point(0, 0),
		// The anchor for this image is the base of the flagpole at (0, 32).
		anchor: new google.maps.Point(0, 0)
	};

	// mockup car JSON
	var cars = [
		{
			'id':'1',
			'lat':'57.6920538',
			'lng':'11.9746084'
		},
		{
			'id':'2',
			'lat':'57.6860668',
			'lng':'11.9652099'
		},
		{
			'id':'3',
			'lat':'57.7002643',
			'lng':'11.951225'
		}
	];

	// function that runs when the map has initialized
	$scope.$on('mapInitialized', function(event, map) {
		$scope.map = map;
		console.log("Map loaded. Ready to handle new markers");
		for(i = 0; i < cars.length; i++){
			add_markers(cars[i].lat, cars[i].lng);
		}

		// Move a marker to a new position
		//setTimeout(function() { var latlng = new google.maps.LatLng(57.68, 12); markers[0].setPosition(latlng); }, 5000);
	});

	setTimeout(function() {
		BackendService.history().success(function(data) {
			console.log(data);
			// var latLngObj = data["positioning_system"]["location"];
			// var latlng = new google.maps.LatLng(latLngObj['lat'], latLngObj['lng']);
			// markers[0].setPosition(latlng);
		}).error(function() {
			console.log("count: error");
		});
	}, 1000);

	// function to add a new marker using img_id which is a persona id,
	// lat and lng of the car / persona
	function add_markers(lat, lng){
		var marker = new google.maps.Marker({
			title: "car",
			icon: image
		});

		var latlng = new google.maps.LatLng(lat, lng);
		marker.setPosition(latlng);
		marker.setMap($scope.map);

		markers.push(marker);
	}

}]);

/* Controllers fetching data for the different personas */
adalyzerControllers.controller('PersonasController', ['$scope', 'BackendService', function($scope, BackendService) {
	$scope.title = 'Personas';

	var data = [
		{
			'name': 'John Doe',
			'age': '20 y/o',
			'interests': ['Environment', 'Family']
		},
		{
			'name': 'Jane Doe',
			'age': '20 y/o',
			'interests': ['Fast cars', 'Travel']
		},
		{
			'name': 'Steve Jobs',
			'age': '20 y/o',
			'interests': ['Business', 'Environment']
		},
		{
			'name': 'Steve Wozniak',
			'age': '20 y/o',
			'interests': ['Family', 'Business']
		},
	];

	angular.forEach(data, function(value, key) {
		value.img = 'img/persona-' + (key + 1) + '.png';
	});

	$scope.personas = data;
}]);

/* Controller for the Mapping id, which is a map of all personas and their locations */
adalyzerControllers.controller('MappingController', ['$scope', function($scope) {
	$scope.title = 'Ads mapping';

	// array with images of personas
	var images = [{
		url: 'img/persona-map-1.png',
		// This marker is 20 pixels wide by 32 pixels high.
		size: new google.maps.Size(30, 33),
		// The origin for this image is (0, 0).
		origin: new google.maps.Point(0, 0),
		// The anchor for this image is the base of the flagpole at (0, 32).
		anchor: new google.maps.Point(0, 28)
		},
		{
		url: 'img/persona-map-2.png',
		// This marker is 20 pixels wide by 32 pixels high.
		size: new google.maps.Size(30, 33),
		// The origin for this image is (0, 0).
		origin: new google.maps.Point(0, 0),
		// The anchor for this image is the base of the flagpole at (0, 32).
		anchor: new google.maps.Point(0, 28)
		},
		{url: 'img/persona-map-3.png',
		// This marker is 20 pixels wide by 32 pixels high.
		size: new google.maps.Size(30, 33),
		// The origin for this image is (0, 0).
		origin: new google.maps.Point(0, 0),
		// The anchor for this image is the base of the flagpole at (0, 32).
		anchor: new google.maps.Point(0, 28)
		},
		{url: 'img/persona-map-4.png',
		// This marker is 20 pixels wide by 32 pixels high.
		size: new google.maps.Size(30, 33),
		// The origin for this image is (0, 0).
		origin: new google.maps.Point(0, 0),
		// The anchor for this image is the base of the flagpole at (0, 32).
		anchor: new google.maps.Point(0, 28)
		}];

	// function that runs when the map has initialized
	$scope.$on('mapInitialized', function(event, map) {
		$scope.map = map;
		console.log("Map loaded. Ready to handle new markers");
		add_markers(0, 57.6920538, 11.9746084);
		add_markers(1, 57.6920538, 11.9746084);
		add_markers(2, 57.6860668, 11.9652099);
		add_markers(3, 57.7002643, 11.951225);
	});

	// initialize an array with markers
	var markers = [];

	// function to add a new marker using img_id which is a persona id,
	// lat and lng of the car / persona
	function add_markers(img_id, lat, lng){
		var marker = new google.maps.Marker({
			title: "car",
			icon: images[img_id]
		});

		var latlng = new google.maps.LatLng(lat, lng);
		marker.setPosition(latlng);
		marker.setMap($scope.map);

		markers.push(marker);
	}
}]);

adalyzerControllers.controller('StatsController', ['$scope', function($scope) {
	$scope.title = 'Statistics';
}]);


text:
  <link rel="stylesheet" type="text/css" href="../../../funcunit/qunit/qunit.css"/>
  <title>jQuery.event.reverse  QUnit Test</title>

jQuery.event.reverse Test Suite


text:
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright 2021 The Chromium Authors. All rights reserved.
     Use of this source code is governed by a BSD-style license that can be
     found in the LICENSE file. -->

<!-- A site suggestion tile. -->
<org.chromium.chrome.browser.tasks.MvTilesLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:id="@+id/mv_tiles_layout"
    android:layout_width="wrap_content"
    android:layout_height="match_parent"
    android:orientation="horizontal"
    android:paddingBottom="@dimen/tasks_view_items_vertical_spacing">
</org.chromium.chrome.browser.tasks.MvTilesLayout>


text:
#!/bin/bash
# ----------------------------------------------------------------------------------
# @name    : advanced dpkg-scanpackages
# @version : 1.1.3
# @date    : 03/04/2013 08:21:11
#
# TENTANG
# ----------------------------------------------------------------------------------
# Script ini akan menjalankan dpkg-scanpackages, membuat file indeks berupa
# Packages.gz, setelah itu akan mencari dan menghapus/membackup paket-paket lama
# yang tidak digunakan dan tidak diindeks (di-ignore) oleh dpkg-scanpackages.
#
# PERINGATAN..!
# ----------------------------------------------------------------------------------
# Masih experimental, use this script at your own risk.
# Saya rekomendasikan untuk membackup data terlebih dahulu.
#
# KONTAK
# ----------------------------------------------------------------------------------
# Ada bug? saran? sampaikan ke saya.
# Ghozy Arif Fajri / gojigeje
# email    : gojigeje@gmail.com
# web      : goji.web.id
# facebook : facebook.com/gojigeje
# twitter  : @gojigeje
# g+       : gplus.to/gojigeje
#
# LISENSI
# ----------------------------------------------------------------------------------
# Open Source tentunya :)
#  The MIT License (MIT)
#  Copyright (c) 2013 Ghozy Arif Fajri <gojigeje@gmail.com>

# Set dulu lokasi & nama folder tempat mengumpulkan paket-paket .deb
# misal:  File-file .deb tersebut disimpan di  /media/repo/oneiric
# maka:   lokasi="/media/repo" (TANPA SLASH '/' DI AKHIR)
#         namafolder="oneiric" (TANPA SLASH '/' DI AKHIR)
# ----------------------------------------------------------------------------------
# DEFAULT: lokasi="/home/goji/Desktop"
#          namafolder="oneiric"
# silahkan diubah sesuai dengan kebutuhan
lokasi="/media/BACKUP/BACKUP/REPO"
namafolder="reponya.goji.precise"

# escfolder adalah path folder yang sudah ditambahkan escape character,
# yaitu karakter '/' (slash) harus ditambahkan dengan escape character
# '\'(backslash) sebelumnya, biar ndak eror :D
# contoh:
#   /media/repo/oneiric  --> \/media\/repo\/oneiric (TANPA SLASH '/' DI AKHIR)
#
# Cara mudahnnya, di Ubuntu (menggunakan Nautilus), masuk ke folder di mana
# file .deb tersebut berada, lalu tampilkan path folder dengan cara CTRL+L
# (menu Go - Location), copy-paste ke sini dan tinggal menambahkan tanda
# backslash sebelum tanda slash di hasil paste-an.
# ----------------------------------------------------------------------------------
# DEFAULT: escfolder="\/home\/goji\/Desktop\/oneiric"
# silahkan diubah sesuai dengan kebutuhan
escfolder="\/media\/BACKUP\/BACKUP\/REPO\/reponya.goji.precise"

# Mode, untuk menentukan tindakan yang akan dilakukann script terhadap paket-
# paket yang outdated, akan dihapus atau dibackup?
# Bila mode backup, maka paket-paket outdated akan dibackup ke dalam folder
# dengan nama 'outdated' di direktori yang sama folder repo.
# ----------------------------------------------------------------------------------
# Nilai yang bisa diisikan: "hapus" / "backup" <-- jangan lupa tanda petiknya
# DEFAULT: mode="backup"
mode="hapus"

# ----------------------------------------------------------------------------------
# ----------------------------------------------------------------------------------
#  STOP !! JANGAN UBAH APAPUN SETELAH TULISAN INI..!
#          Silahkan diubah apabila benar-benar mengetahui maksud dari
#          script tersebut, dan mungkin hendak menyesuaikan dengan kebutuhan.
#          Buat backup dulu sebelum mengubah.
# ----------------------------------------------------------------------------------
# ----------------------------------------------------------------------------------
# versi, tidak perlu diubah
versi="1.1.3"

mulai() {
   echo "# -------------------------------------------------------------"
   echo "# Advanced ScanPackages $versi by Ghozy Arif Fajri / gojigeje"
   echo "# -------------------------------------------------------------"
   if [[ $EUID -ne 0 ]]; then
      echo "# Script ini harus di-run dengan akses root!"
      echo "# gunakan sudo"
      echo "#"
      exit 1
   fi
   if [ "$mode" = "backup" -o "$mode" = "hapus" ]; then
      tgl=$(date +%Y%m%d-%H%M)
      logfile="di$mode-$tgl.txt"
      mkdir -p $HOME/gojigeje
      mkdir -p $lokasi/$namafolder
      logfolder="$HOME/gojigeje"
      backupfolder=$escfolder"-outdated"
      escfolder=$escfolder"\/"
      jumdeb=$(ls $lokasi/$namafolder/*.deb | wc -l) > /dev/null 2>&1
      cd $lokasi/$namafolder
      totalbefore=$(du -sh | awk '{print $1}')
      separator=":"
   else
      echo "# Nilai variabel 'mode' salah. Isi dengan 'hapus'/'backup'"
      echo "# Program akan keluar..."
      echo "#"
      exit 1
   fi
   if [ "$mode" = "backup" ]; then
      separator=" :"
   fi
   upmode=$(echo "${mode^^}")
   echo "# Lokasi repo : $lokasi"
   echo "# Folder repo : $namafolder"
   echo "# Informasi   : paket-paket lama akan DI$upmode"
   echo "# -------------------------------------------------------------"
   cekdpkgdev
   echo "# Paket-paket lama akan DI$upmode,"
   confirm
}

cekdpkgdev() {
   echo "# Menyiapkan.."
   sleep 1
   echo -n "# Memeriksa dpkg-dev."
   dpkg-query -W -f='${Status}\n' dpkg-dev > $HOME/.gojigeje-dpkgdevstat 2>&1
   echo -n "."
   dpkgdevstat=$(cat $HOME/.gojigeje-dpkgdevstat)
   echo -n "."
   if echo "$dpkgdevstat" | grep installed > /dev/null 2>&1
      then
         echo " [OK]"
         echo "#"
      else
         echo "#"
         echo "# -------------------------------------------------------------"
         echo "# ERROR..!! #"
         echo "# Paket 'dpkg-dev' belum terpasang di sistem. Paket tersebut"
         echo "# diperlukan untuk menjalankan script ini."
         echo "# -------------------------------------------------------------"
         echo "# Pasang dengan 'apt-get install dpkg-dev' (di ubuntu), atau"
         echo "# masukkan huruf 'Y' pada inputan di bawah untuk memasangnya "
         echo "# secara otomatis (butuh koneksi internet). Masukkan huruf 'N'"
         echo "# untuk memasangnya di lain waktu (script akan keluar)."
         echo "# -------------------------------------------------------------"
         echo "#"
         while true; do
             read -p "# Pasang 'dpkg-dev' sekarang? : " yn
             case $yn in
                 [Yy]* )
                     echo "# Memasang 'dpkg-dev' (apt-get install dpkg-dev).."
                     sudo apt-get install dpkg-dev -y -qq
                     echo "# Paket telah terpasang.."
                     echo "#"
                     echo "# Memulai kembali script.."
                     sleep 1
                     echo "#"
                     break
                 ;;
                 [Nn]* )
                     echo "#"
                     echo "# Pasang 'dpkg-dev' terlebih dahulu."
                     echo "# Script akan keluar.."
                     echo "#"
                     exit 1
                 ;;
                 * )
                     echo "# Input salah. Masukkan y atau n";;
             esac
         done
   fi
   rm $HOME/.gojigeje-dpkgdevstat
}

confirm() {
   while true; do
       read -p "# Lanjutkan? (y/n) : " yn
       case $yn in
           [Yy]* )
               do_lanjut
               break
           ;;
           [Nn]* )
               echo "# (Keluar..)"
               exit 1
           ;;
           * )
               echo "# Input salah. Masukkan y atau n"
           ;;
       esac
   done
}

do_lanjut() {
   echo "#"
   sleep 1
   echo "# Memeriksa cache.."
   sleep 1
   do_cekcache
   sleep 2
   echo "#"
   echo "# dpkg-scanpackages..."
   echo "# Membuat file indeks :"
   echo "#  -> $lokasi/$namafolder/Packages.gz"
   echo "# Biasanya agak lama, sabar ya :D"
   cd $lokasi
   sudo dpkg-scanpackages "$namafolder/" /dev/null 2> "$logfolder/scanpackages-warning" | gzip -9c > "$namafolder/Packages.gz"
   echo "# File indeks berhasil dibuat..."
   echo "#"
   echo "# Mencari paket lama yang outdated.."
   sleep 1
   cat "$logfolder/scanpackages-warning" | grep "ignored data from" > "$logfolder/.list1"
   cat "$logfolder/scanpackages-warning" | grep "is repeat;" > "$logfolder/.list2"
   sed 's/^[^$]*\/\/\(.*\)\!.*/\1/' "$logfolder/.list1" > "$logfolder/.list3"
   sed 's/^[^$]*\/\/\(.*\)\ is.*/\1/' "$logfolder/.list2" | tr -d '()' >> "$logfolder/.list3"
   case "$mode" in
      "hapus")
         do_hapus
      ;;
      "backup")
         do_backup
      ;;
   esac
   do_periksa
}

do_cekcache() {
   cd /var/cache/apt/archives
   cekjumlah=$(ls | wc -l)
   if [ "$cekjumlah" = "2" ]; then
      echo "# Tidak ada paket *.deb baru di cache.."
   else
      cekjumdeb=$(( cekjumlah - 2 ))
      cektotal=$(du -sh | awk '{print $1}')
      echo "# Membackup $cekjumdeb file *.deb dari cache, total $cektotal"
      sudo mv *.deb $lokasi/$namafolder/
   fi
}

do_hapus() {
      sed "s/^/rm -rf $escfolder/g" "$logfolder/.list3" > "$logfolder/.list4"
      echo "#!/bin/bash" > "$logfolder/delete"
      cat "$logfolder/.list4" >> "$logfolder/delete"
      chmod +x "$logfolder/delete"
      numfile=$(cat "$logfolder/.list3" | wc -l)
      echo "# Ada $numfile paket outdated di folder repo, akan DIHAPUS.."
      echo "#"
      sleep 1
      echo "# Menghapus file.."
      $logfolder/delete
      sleep 2
      echo "# File-file berhasil dihapus.."
      echo "---------------------------------------------------------------------------------" > $HOME/Desktop/$logfile
      echo "Advanced ScanPackages $versi by Ghozy Arif Fajri / gojigeje" >> $HOME/Desktop/$logfile
      echo "---------------------------------------------------------------------------------" >> $HOME/Desktop/$logfile
      echo "Daftar paket yang dihapus dari folder repo" >> $HOME/Desktop/$logfile
      echo "Path folder repo: $lokasi/$namafolder" >> $HOME/Desktop/$logfile
      echo "Dihapus pada tanggal: $tgl (YYmmdd-HHMM)" >> $HOME/Desktop/$logfile
      echo "" >> $HOME/Desktop/$logfile
      echo "---------------------------------------------------------------------------------" >> $HOME/Desktop/$logfile
      cat "$logfolder/.list3" >> $HOME/Desktop/$logfile
}

do_backup() {
      mkdir -p $lokasi/$namafolder-outdated-$tgl
      sed "s/^/mv -f $escfolder/g" "$logfolder/.list3" > "$logfolder/.list4"
      sed -e "s/$/ $backupfolder-$tgl\//" "$logfolder/.list4" > "$logfolder/.list5"
      echo "#!/bin/bash" > "$logfolder/backup"
      cat "$logfolder/.list5" >> "$logfolder/backup"
      chmod +x "$logfolder/backup"
      numfile=$(cat "$logfolder/.list3" | wc -l)
      echo "# Ada $numfile paket outdated di folder repo, akan DIBACKUP..."
      echo "#"
      sleep 1
      echo "# Membackup file.."
      $logfolder/backup
      sleep 2
      echo "# File-file berhasil dibackup.."
      echo "---------------------------------------------------------------------------------" > $HOME/Desktop/$logfile
      echo "Advanced ScanPackages $versi by Ghozy Arif Fajri / gojigeje" >> $HOME/Desktop/$logfile
      echo "---------------------------------------------------------------------------------" >> $HOME/Desktop/$logfile
      echo "Daftar paket yang dibackup dari folder repo" >> $HOME/Desktop/$logfile
      echo "Path folder repo: $lokasi/$namafolder" >> $HOME/Desktop/$logfile
      echo "Dibackup pada: $tgl (YYmmdd-HHMM)" >> $HOME/Desktop/$logfile
      echo "" >> $HOME/Desktop/$logfile
      echo "File-file berikut ini bisa temukan di backup folder:" >> $HOME/Desktop/$logfile
      echo "$lokasi/$namafolder-outdated-$tgl/" >> $HOME/Desktop/$logfile
      echo "---------------------------------------------------------------------------------" >> $HOME/Desktop/$logfile
      cat "$logfolder/.list3" >> $HOME/Desktop/$logfile
}

do_periksa() {
   jumdebnow=$(ls $lokasi/$namafolder/*.deb | wc -l)
   cd $lokasi/$namafolder
   totaldeb=$(du -sh | awk '{print $1}')
   chmod 777 $HOME/Desktop/$logfile
   echo "# -------------------------------------------------------------"
   echo "# Jumlah paket sebelum scanpackages      $separator $jumdeb"
   echo "# Jumlah paket yang outdated dan di$mode : $numfile"
   echo "# Jumlah paket di folder repo sekarang   $separator $jumdebnow"
   echo "# Ukuran repo sebelum scanpackages       $separator $totalbefore"
   echo "# Total ukuran repo sekarang             $separator $totaldeb"
   if [ "$mode" = "backup" ]; then
      cd $lokasi/$namafolder-outdated-$tgl/
      total=$(du -sh | awk '{print $1}')
      echo "# Berhasil mem-backup paket sebesar       : $total"
      echo "# Backup ini bisa dihapus untuk menghemat disk space.."
      echo "# Lokasi backup folder:"
      echo "# $lokasi/$namafolder-outdated-$tgl/"
      chmod 777 $lokasi/$namafolder-outdated-$tgl -R
   fi
   echo "# -------------------------------------------------------------"
   echo "# Daftar file yang di$mode bisa dilihat di desktop."
   echo "# Selesai.."
   echo "#"
}

mulai

# That's it :D


text:
#ifndef _ASM_ALPHA_PARAM_H
#define _ASM_ALPHA_PARAM_H

/* ??? Gross.  I don't want to parameterize this, and supposedly the
   hardware ignores reprogramming.  We also need userland buy-in to the
   change in HZ, since this is visible in the wait4 resources etc.  */

#ifndef HZ
# ifndef CONFIG_ALPHA_RAWHIDE
#  define HZ	1024
# else
#  define HZ	1200
# endif
#endif

#define USER_HZ		HZ

#define EXEC_PAGESIZE	8192

#ifndef NOGROUP
#define NOGROUP		(-1)
#endif

#define MAXHOSTNAMELEN	64	/* max length of hostname */

#ifdef __KERNEL__
# define CLOCKS_PER_SEC	HZ	/* frequency at which times() counts */
#endif

#endif /* _ASM_ALPHA_PARAM_H */


text:
'use strict';

angular.module('core')
  .directive('stringToNumber', function() {
    return {
      require: 'ngModel',
      link: function(scope, element, attrs, ngModel) {
        ngModel.$parsers.push(function(value) {
          return '' + value;
        });
        ngModel.$formatters.push(function(value) {
          return parseFloat(value);
        });
      }
    };
  });


text:
//
//  KANavigation.h
//  BlurTranstion
//
//  Created by Alex Hung on 27/5/2016.
//  Copyright © 2016 Alex Hung. All rights reserved.
//

#ifndef KABlurTransition_h
#define KABlurTransition_h

#import "UINavigationController+KANavigation.h"
#import "UIViewController+KANavigation.h"
#import "KABlurManager.h"

#endif /* KABlurTransition_h */


text:
package schema1

import (
	"crypto/x509"

	"github.com/Sirupsen/logrus"
	"github.com/docker/libtrust"
)

// Verify verifies the signature of the signed manifest returning the public
// keys used during signing.
func Verify(sm *SignedManifest) ([]libtrust.PublicKey, error) {
	js, err := libtrust.ParsePrettySignature(sm.Raw, "signatures")
	if err != nil {
		logrus.WithField("err", err).Debugf("(*SignedManifest).Verify")
		return nil, err
	}

	return js.Verify()
}

// VerifyChains verifies the signature of the signed manifest against the
// certificate pool returning the list of verified chains. Signatures without
// an x509 chain are not checked.
func VerifyChains(sm *SignedManifest, ca *x509.CertPool) ([][]*x509.Certificate, error) {
	js, err := libtrust.ParsePrettySignature(sm.Raw, "signatures")
	if err != nil {
		return nil, err
	}

	return js.VerifyChains(ca)
}


text:
<android.support.v4.widget.DrawerLayout
    android:id="@+id/drawerLayout"
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    tools:context="xyz.igorgee.mtaperfectfare.MainActivity">

    <android.support.design.widget.CoordinatorLayout
        android:id="@+id/rootLayout"
        android:layout_width="match_parent"
        android:layout_height="match_parent">

        <android.support.design.widget.AppBarLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar">

            <android.support.v7.widget.Toolbar
                android:id="@+id/toolbar"
                android:layout_width="match_parent"
                android:layout_height="?attr/actionBarSize"
                android:background="?attr/colorPrimary"
                app:popupTheme="@style/ThemeOverlay.AppCompat.Light"
                app:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"/>

        </android.support.design.widget.AppBarLayout>

        <android.support.v4.widget.NestedScrollView
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:fillViewport="true"
            app:layout_behavior="@string/appbar_scrolling_view_behavior">

            <LinearLayout
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:paddingTop="16dp"
                android:paddingLeft="16dp"
                android:paddingRight="16dp"
                android:orientation="vertical">

                <TextView
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:text="@string/starting_balance_text_view"
                    android:textSize="30sp"/>

                <android.support.design.widget.TextInputLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content">

                    <EditText
                        android:id="@+id/starting_balance"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:hint="@string/starting_balance_hint"
                        android:inputType="numberDecimal"
                        android:maxLength="5"
                        android:textColorHint="#000000"/>

                </android.support.design.widget.TextInputLayout>

                <TextView
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:layout_marginTop="16dp"
                    android:text="@string/swipes_text_view"
                    android:textSize="30sp"/>

                <android.support.design.widget.TextInputLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content">

                    <EditText
                        android:id="@+id/trips"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:hint="@string/swipes_hint"
                        android:inputType="numberDecimal"
                        android:maxLength="2"
                        android:textColorHint="#000000"/>

                </android.support.design.widget.TextInputLayout>

                <TextView
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:layout_marginTop="16dp"
                    android:text="@string/days_text_view"
                    android:textSize="30sp"/>

                <android.support.design.widget.TextInputLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content">

                    <EditText
                        android:id="@+id/days"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:hint="@string/days_hint"
                        android:inputType="numberDecimal"
                        android:maxLength="1"
                        android:textColorHint="#000000"/>

                </android.support.design.widget.TextInputLayout>

                <TextView
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:layout_marginTop="16dp"
                    android:text="@string/weeks_text_view"
                    android:textSize="30sp"/>

                <android.support.design.widget.TextInputLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content">

                    <EditText
                        android:id="@+id/weeks"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:hint="@string/weeks_hint"
                        android:inputType="numberDecimal"
                        android:maxLength="1"
                        android:textColorHint="#000000"/>

                </android.support.design.widget.TextInputLayout>

            </LinearLayout>
        </android.support.v4.widget.NestedScrollView>

        <android.support.design.widget.FloatingActionButton
            android:id="@+id/fabCalculate"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_gravity="bottom|right"
            android:layout_marginBottom="@dimen/fab_margin_bottom"
            android:layout_marginRight="@dimen/fab_margin_right"
            android:src="@drawable/ic_attach_money_white_48dp"/>

    </android.support.design.widget.CoordinatorLayout>

    <android.support.design.widget.NavigationView
        android:id="@+id/navigation"
        android:layout_width="wrap_content"
        android:layout_height="match_parent"
        android:layout_gravity="start"
        app:headerLayout="@layout/drawer_header"
        app:menu="@menu/navigation_drawer"/>

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


text:
// Copyright (c), Firelight Technologies Pty, Ltd. 2012-2020.

#pragma once

#include "UObject/Class.h"
#include "Engine/EngineTypes.h"
#include "GenericPlatform/GenericPlatform.h"
#include "FMODSettings.generated.h"

class Paths;

UENUM()
enum EFMODLogging
{
    LEVEL_NONE = 0,
    LEVEL_ERROR = 1,
    LEVEL_WARNING = 2,
    LEVEL_LOG = 4,
    TYPE_MEMORY = 100,
    TYPE_FILE = 200,
    TYPE_CODEC = 400,
    TYPE_TRACE = 800,
    DISPLAY_TIMESTAMPS = 10000,
    DISPLAY_LINENUMBERS = 20000,
    DISPLAY_THREAD = 40000
};

UENUM()
namespace EFMODSpeakerMode
{
enum Type
{
    // The speakers are stereo
    Stereo,
    // 5.1 speaker setup
    Surround_5_1,
    // 7.1 speaker setup
    Surround_7_1
};
}

USTRUCT()
struct FCustomPoolSizes
{
    GENERATED_USTRUCT_BODY()

    /** Default = 0 (Disabled) units in bytes*/
    UPROPERTY(config, EditAnywhere, Category = InitSettings, meta = (ClampMin = "0"))
    int32 Desktop;
    /** Default = 0 (Disabled) units in bytes*/
    UPROPERTY(config, EditAnywhere, Category = InitSettings, meta = (ClampMin = "0"))
    int32 Mobile;
    /** Default = 0 (Disabled) units in bytes*/
    UPROPERTY(config, EditAnywhere, Category = InitSettings, meta = (ClampMin = "0"))
    int32 PS4;
    /** Default = 0 (Disabled) units in bytes*/
    UPROPERTY(config, EditAnywhere, Category = InitSettings, meta = (ClampMin = "0"))
    int32 Switch;
    /** Default = 0 (Disabled) units in bytes*/
    UPROPERTY(config, EditAnywhere, Category = InitSettings, meta = (ClampMin = "0"))
    int32 XboxOne;

    FCustomPoolSizes()
        : Desktop(0)
        , Mobile(0)
        , PS4(0)
        , Switch(0)
        , XboxOne(0)
    {
    }
};

USTRUCT()
struct FFMODProjectLocale
{
    GENERATED_USTRUCT_BODY()

    /**
    * Human readable locale name, displayed in Blueprints.
    */
    UPROPERTY(config, EditAnywhere, Category = Localization)
    FString LocaleName;

    /**
    * Locale code. Must correspond to project locale codes in FMOD Studio project.
    */
    UPROPERTY(config, EditAnywhere, Category = Localization)
    FString LocaleCode;

    /**
    * Default locale at startup. Only one locale should be marked as default.
    */
    UPROPERTY(config, EditAnywhere, Category = Localization)
    bool bDefault;
};

UCLASS(config = Engine, defaultconfig)
class FMODSTUDIO_API UFMODSettings : public UObject
{
    GENERATED_UCLASS_BODY()

public:
    /**
	 * Whether to load all banks at startup.
	 */
    UPROPERTY(config, EditAnywhere, Category = Basic)
    bool bLoadAllBanks;

    /**
	 * Whether to load all bank sample data into memory at startup.
	 */
    UPROPERTY(config, EditAnywhere, Category = Basic)
    bool bLoadAllSampleData;

    /**
	 * Enable live update in non-final builds.
	 */
    UPROPERTY(config, EditAnywhere, Category = Basic)
    bool bEnableLiveUpdate;

    /**
    * Enable live update in Editor for Auditioning. *Requires Restart*
    */
    UPROPERTY(Config, EditAnywhere, Category = Basic)
    bool bEnableEditorLiveUpdate;

    /**
	 * Path to find your studio bank output directory, relative to Content directory.
	 */
    UPROPERTY(config, EditAnywhere, Category = Basic, meta = (RelativeToGameContentDir))
    FDirectoryPath BankOutputDirectory;

    /** Project Output Format, should match the mode set up for the Studio project. */
    UPROPERTY(config, EditAnywhere, Category = Basic)
    TEnumAsByte<EFMODSpeakerMode::Type> OutputFormat;

    /**
    * Locales for localized banks. These should match the project locales configured in the FMOD Studio project.
    */
    UPROPERTY(config, EditAnywhere, Category = Localization)
    TArray<FFMODProjectLocale> Locales;

    /**
	 * Whether to enable vol0virtual, which means voices with low volume will automatically go virtual to save CPU.
	 */
    UPROPERTY(config, EditAnywhere, Category = InitSettings)
    bool bVol0Virtual;

    /**
	 * If vol0virtual is enabled, the signal level at which to make channels virtual.
	 */
    UPROPERTY(config, EditAnywhere, Category = InitSettings)
    float Vol0VirtualLevel;

    /**
	 * Sample rate to use, or 0 to match system rate.
	 */
    UPROPERTY(config, EditAnywhere, Category = InitSettings)
    int32 SampleRate;

    /**
	* Whether to match hardware sample rate where reasonable (44.1kHz to 48kHz).
	*/
    UPROPERTY(config, EditAnywhere, Category = InitSettings)
    bool bMatchHardwareSampleRate;

    /**
	 * Number of actual software voices that can be used at once.
	 */
    UPROPERTY(config, EditAnywhere, Category = InitSettings)
    int32 RealChannelCount;

    /**
	 * Total number of voices available that can be either real or virtual.
	 */
    UPROPERTY(config, EditAnywhere, Category = InitSettings)
    int32 TotalChannelCount;

    /**
	 * DSP mixer buffer length (eg. 512, 1024) or 0 for system default.
	 * When changing the Buffer Length, Buffer Count also needs to be set.
	 */
    UPROPERTY(config, EditAnywhere, Category = InitSettings)
    int32 DSPBufferLength;

    /**
	 * DSP mixer buffer count (eg. 2, 4) or 0 for system default.
	 * When changing the Buffer Count, Buffer Length also needs to be set.
	 */
    UPROPERTY(config, EditAnywhere, Category = InitSettings)
    int32 DSPBufferCount;

    /**
	 * File buffer size in bytes (2048 by default).
	 */
    UPROPERTY(config, EditAnywhere, Category = InitSettings)
    int32 FileBufferSize;

    /**
	 * Studio update period in milliseconds, or 0 for default (which means 20ms).
	 */
    UPROPERTY(config, EditAnywhere, Category = InitSettings)
    int32 StudioUpdatePeriod;

    /**
	 * Output device to choose at system start up, or empty for default.
	 */
    UPROPERTY(config, EditAnywhere, Category = InitSettings)
    FString InitialOutputDriverName;

    /**
	 * Lock all mixer buses at startup, making sure they are created up front.
	 */
    UPROPERTY(config, EditAnywhere, Category = InitSettings)
    bool bLockAllBuses;

    /**
     * Use specified memory pool size for platform, units in bytes. Disabled by default.
     * FMOD may become unstable if the limit is exceeded!
     */
    UPROPERTY(config, EditAnywhere, Category = InitSettings)
    FCustomPoolSizes MemoryPoolSizes;

    /**
	 * Live update port to use, or 0 for default.
	 */
    UPROPERTY(config, EditAnywhere, Category = Advanced, meta = (EditCondition = "bEnableLiveUpdate"))
    int32 LiveUpdatePort;

    /**
    * Live update port to use while in editor for auditioning. *Requires Restart*
    */
    UPROPERTY(config, EditAnywhere, Category = Advanced, meta = (EditCondition = "bEnableEditorLiveUpdate"))
    int32 EditorLiveUpdatePort;

    /**
	 * Extra plugin files to load.
	 * The plugin files should sit alongside the FMOD dynamic libraries in the ThirdParty directory.
	 */
    UPROPERTY(config, EditAnywhere, Category = Advanced)
    TArray<FString> PluginFiles;

    /**
	 * Directory for content to appear in content window. Be careful changing this!
	 */
    UPROPERTY(config, EditAnywhere, Category = Advanced)
    FString ContentBrowserPrefix;

    /**
	 * Force platform directory name, or leave empty for automatic (Desktop/Mobile/PS4/XBoxOne)
	 */
    UPROPERTY(config, EditAnywhere, Category = Advanced)
    FString ForcePlatformName;

    /**
	 * Name of master bank.  The default in Studio is "Master Bank".
	 */
    UPROPERTY(config, EditAnywhere, Category = Advanced)
    FString MasterBankName;

    /**
	 * Skip bank files of the given name.
	 * Can be used to load all banks except for a certain set, such as localization banks.
	 */
    UPROPERTY(config, EditAnywhere, Category = Advanced)
    FString SkipLoadBankName;

	/*
    * Specify the key for loading sounds from encrypted banks.
	*/
	UPROPERTY(config, EditAnywhere, Category = Advanced, meta = (DisplayName = "Encryption Key"))
	FString StudioBankKey;

    /**
	* Force wav writer output, for debugging only.  Setting this will prevent normal sound output!
	*/
    UPROPERTY(config, EditAnywhere, Category = Advanced)
    FString WavWriterPath;

    UPROPERTY(config, EditAnywhere, Category = Advanced)
    TEnumAsByte<EFMODLogging> LoggingLevel;

    /**
    * Name of the parameter used in Studio to control Occlusion effects.
    */
    UPROPERTY(config, EditAnywhere, Category = Advanced)
    FString OcclusionParameter;

    /**
    * Name of the parameter used in Studio to control Ambient volume.
    */
    UPROPERTY(config, EditAnywhere, Category = Advanced)
    FString AmbientVolumeParameter;

    /**
    * Name of the parameter used in Studio to control Ambient LPF effects.
    */
    UPROPERTY(config, EditAnywhere, Category = Advanced)
    FString AmbientLPFParameter;

    /** Is the bank path set up . */
    bool IsBankPathSet() const { return !BankOutputDirectory.Path.IsEmpty(); }

    /** Get the full bank path.  Uses the game's content directory as a base. */
    FString GetFullBankPath() const;

    /** Get the master bank filename. */
    FString GetMasterBankFilename() const;

    /** Get the master assets bank filename. */
    FString GetMasterAssetsBankFilename() const;

    /** Get the master strings bank filename. */
    FString GetMasterStringsBankFilename() const;

#if WITH_EDITOR
    /** Check the settings for any configuration issues. */
    enum EProblem
    {
        Okay,
        BankPathNotSet,
        AddedToUFS,
        NotPackaged,
        AddedToBoth
    };

    EProblem Check() const;
#endif // WITH_EDITOR
};


text:
package com.github.kohanyirobert.sggc;

import java.net.URL;

/**
 * Utility class for working with {@linkplain Request requests}.
 */
public final class Requests {

  private Requests() {}

  /**
   * Returns a new request using {@code address}.
   *
   * @param address the address of the request
   * @return a new request using {@code address}
   * @throws NullPointerException if {@code address} is null
   */
  public static Request request(String address) {
    return builder().address(address).build();
  }

  /**
   * Returns a new request builder.
   *
   * @return a new request builder
   */
  public static Request.Builder builder() {
    return new DefaultRequestBuilder();
  }

  static Request request(final URL url) {
    return new ForwardingRequest() {

      @Override
      public URL url() {
        return url;
      }

      @Override
      protected Request delegate() {
        throw new UnsupportedOperationException();
      }
    };
  }
}


text: export { default } from './TextareaAutosize';


text:
package de.wak_sh.client.model;

import java.io.Serializable;

public class Attachment implements Serializable {

	private static final long serialVersionUID = 1L;

	private long id;
	private String name;

	public Attachment(long id, String name) {
		super();
		this.id = id;
		this.name = name;
	}

	public long getId() {
		return id;
	}

	public void setId(long id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	@Override
	public String toString() {
		return "Attachment [id=" + id + ", name=" + name + "]";
	}
}


text:
package info.rnowak.simplega.algorithm

import info.rnowak.simplega.fitness.{FitnessFunction, FitnessValue, IndividualWithFitness}
import info.rnowak.simplega.operators.crossover.binary.OnePointCrossover
import info.rnowak.simplega.operators.mutation.binary.SimpleInversionMutation
import info.rnowak.simplega.operators.selection.SimpleTournamentSelection
import info.rnowak.simplega.population.BinaryPopulation
import info.rnowak.simplega.population.context.BinaryPopulationContext
import info.rnowak.simplega.population.individual.{BinaryIndividual, One}
import org.scalatest.prop.TableDrivenPropertyChecks._
import org.scalatest.{FlatSpec, Matchers}
import info.rnowak.simplega.fitness.FitnessValue._

class GeneticAlgorithmTest extends FlatSpec with Matchers {

  class SomeFunctionFitness() extends FitnessFunction[BinaryPopulation] {

    override def calculate(individual: BinaryIndividual): IndividualWithFitness[BinaryIndividual] = {
      val (_, indexes) = (individual.bits zip (0 to individual.length - 1).reverse filter { case (bit, _) => bit == One }).unzip
      val bitsValue = indexes.foldLeft(0) { (acc, index) => acc + Math.pow(2, index).toInt }
      val range = 3.0
      val x = -1.0 + bitsValue * (range / (Math.pow(2, individual.length) - 1))
      val fValue = x * Math.sin(10*Math.PI * x) + 1.0
      IndividualWithFitness(individual, fValue.fitness)
    }
  }

  "Every population in next generations" should "have the same size" in {
    val generations = 3
    val populationsSize = Table("size", 3, 6, 10, 13)

    forAll(populationsSize) { populationSize =>
      val parameters = new GeneticAlgorithmParameters(desiredFitness = FitnessValue(4),
        maxGenerations = generations,
        generationsWithoutImprovement = 10,
        crossoverProbability = BigDecimal(0.1),
        mutationProbability = BigDecimal(0.3))
      val context = buildDefaultContext(populationSize, 5)
      val ga = new GeneticAlgorithm[BinaryPopulation](parameters, context, new SomeFunctionFitness())

      val result = ga.run()

      result foreach { algorithmStep =>
        algorithmStep.population.size shouldEqual populationSize
      }
    }
  }

  "GA" should "find optimal solution" in {
    val parameters = new GeneticAlgorithmParameters(desiredFitness = FitnessValue(4),
      maxGenerations = 250,
      generationsWithoutImprovement = 5,
      crossoverProbability = BigDecimal(0.01),
      mutationProbability = BigDecimal(0.1))
    val context = buildDefaultContext(50, 22)
    val ga = new GeneticAlgorithm[BinaryPopulation](parameters, context, new SomeFunctionFitness())

    val result = ga.run()

    val resultCalculated = result.toList

    resultCalculated.foreach { step =>
      println(step)
    }

    val bestValue = resultCalculated.last.bestIndividual.fitness.value
    val expectedBestValue = 2.85
    (bestValue - expectedBestValue).abs.toDouble should be < 0.001
  }

  private def buildDefaultContext(populationSize: Int, individualLength: Int): BinaryPopulationContext =
    BinaryPopulationContext(populationSize = populationSize,
      individualLength = individualLength,
      selectionOperator = new SimpleTournamentSelection(),
      crossOverOperator = new OnePointCrossover(),
      mutationOperator = new SimpleInversionMutation())
}


text:
import functools

import novaclient
from novaclient import client as nova_client
from oslo_config import cfg
from oslo_log import log

OPTS = [
    cfg.BoolOpt('nova_http_log_debug',
                default=False,
                help='Allow novaclient\'s debug log output.'),
]

SERVICE_OPTS = [
    cfg.StrOpt('nova',
               default='compute',
               help='Nova service type.'),
]

cfg.CONF.register_opts(OPTS)
cfg.CONF.register_opts(SERVICE_OPTS, group='service_types')
cfg.CONF.import_opt('http_timeout', 'ceilometer.service')
cfg.CONF.import_group('service_credentials', 'ceilometer.service')

LOG = log.getLogger(__name__)

def logged(func):

    @functools.wraps(func)
    def with_logging(*args, **kwargs):
        try:
            return func(*args, **kwargs)
        except Exception as e:
            LOG.exception(e)
            raise

    return with_logging

class Client(object):
    """A client which gets information via python-novaclient."""

    def __init__(self, bypass_url=None, auth_token=None):
        """Initialize a nova client object."""
        conf = cfg.CONF.service_credentials
        tenant = conf.os_tenant_id or conf.os_tenant_name
        self.nova_client = nova_client.Client(
            version=2,
            username=conf.os_username,
            api_key=conf.os_password,
            project_id=tenant,
            auth_url=conf.os_auth_url,
            auth_token=auth_token,
            region_name=conf.os_region_name,
            endpoint_type=conf.os_endpoint_type,
            service_type=cfg.CONF.service_types.nova,
            bypass_url=bypass_url,
            cacert=conf.os_cacert,
            insecure=conf.insecure,
            timeout=cfg.CONF.http_timeout,
            http_log_debug=cfg.CONF.nova_http_log_debug,
            no_cache=True)

    def _with_flavor_and_image(self, instances):
        flavor_cache = {}
        image_cache = {}
        for instance in instances:
            self._with_flavor(instance, flavor_cache)
            self._with_image(instance, image_cache)

        return instances

    def _with_flavor(self, instance, cache):
        fid = instance.flavor['id']
        if fid in cache:
            flavor = cache.get(fid)
        else:
            try:
                flavor = self.nova_client.flavors.get(fid)
            except novaclient.exceptions.NotFound:
                flavor = None
            cache[fid] = flavor

        attr_defaults = [('name', 'unknown-id-%s' % fid),
                         ('vcpus', 0), ('ram', 0), ('disk', 0),
                         ('ephemeral', 0)]

        for attr, default in attr_defaults:
            if not flavor:
                instance.flavor[attr] = default
                continue
            instance.flavor[attr] = getattr(flavor, attr, default)

    def _with_image(self, instance, cache):
        try:
            iid = instance.image['id']
        except TypeError:
            instance.image = None
            instance.kernel_id = None
            instance.ramdisk_id = None
            return

        if iid in cache:
            image = cache.get(iid)
        else:
            try:
                image = self.nova_client.images.get(iid)
            except novaclient.exceptions.NotFound:
                image = None
            cache[iid] = image

        attr_defaults = [('kernel_id', None),
                         ('ramdisk_id', None)]

        instance.image['name'] = (
            getattr(image, 'name') if image else 'unknown-id-%s' % iid)
        image_metadata = getattr(image, 'metadata', None)

        for attr, default in attr_defaults:
            ameta = image_metadata.get(attr) if image_metadata else default
            setattr(instance, attr, ameta)

    @logged
    def instance_get_all_by_host(self, hostname):
        """Returns list of instances on particular host."""
        search_opts = {'host': hostname, 'all_tenants': True}
        return self._with_flavor_and_image(self.nova_client.servers.list(
            detailed=True,
            search_opts=search_opts))

    @logged
    def instance_get_all(self):
        """Returns list of all instances."""
        search_opts = {'all_tenants': True}
        return self.nova_client.servers.list(
            detailed=True,
            search_opts=search_opts)

    @logged
    def floating_ip_get_all(self):
        """Returns all floating ips."""
        return self.nova_client.floating_ips.list()


text:
<?xml version="1.0" encoding="utf-8"?>
<CrawlItem xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <Text>Ne narucivat chilly</Text>
  <Rating>1</Rating>
  <Source>http://pauza.hr/menu/stross</Source>
</CrawlItem>


text:
package de.bytefish.pgbulkinsert.pgsql.model.network;

import java.util.Arrays;
import java.util.List;
import java.util.stream.Collectors;
import java.util.stream.IntStream;
import java.util.stream.StreamSupport;

public class MacAddress {

    private final byte[] addressBytes;

    public MacAddress(byte[] addressBytes) {

        if(addressBytes == null) {
            throw new IllegalArgumentException("addressBytes");
        }

        if(addressBytes.length != 6) {
            throw new IllegalArgumentException("addressBytes");
        }

        this.addressBytes = addressBytes;
    }

    public byte[] getAddressBytes() {
        return addressBytes;
    }

    @Override
    public String toString() {

        List<String> bytesAsHexString = IntStream
                .range(0, addressBytes.length)
                .map(idx -> addressBytes[idx])
                .mapToObj(value -> String.format("0x%x", value))
                .collect(Collectors.toList());

        return String.join("-", bytesAsHexString);
    }
}


text:
'use strict'

const prod = require('../../../lib/api').prod
const helpers = require('../../helpers')
const source = helpers.source
const transform = helpers.transform

const trans = transform((text, encoding, done) => {
  done(null, 'transformed')
})

source(['source'])
  .pipe(prod(trans))
  .on('data', data => console.log(data)) // eslint-disable-line


text:
VERSION="OpenJDK ${PV}"
JAVA_HOME="${EPREFIX}/usr/$(get_libdir)/${PN}-${SLOT}"
JDK_HOME="${EPREFIX}/usr/$(get_libdir)/${PN}-${SLOT}"
JAVAC="\${JAVA_HOME}/bin/javac"
PATH="\${JAVA_HOME}/bin"
ROOTPATH="\${JAVA_HOME}/bin"
LDPATH="\${JAVA_HOME}/lib/:\${JAVA_HOME}/lib/server/"
MANPATH=""
PROVIDES_TYPE="JDK JRE"
PROVIDES_VERSION="${SLOT}"
BOOTCLASSPATH=""
GENERATION="2"
ENV_VARS="JAVA_HOME JDK_HOME JAVAC PATH ROOTPATH LDPATH MANPATH"


text:
package org.apache.flink.container.entrypoint;

import org.apache.flink.annotation.VisibleForTesting;
import org.apache.flink.api.common.JobID;
import org.apache.flink.configuration.Configuration;
import org.apache.flink.runtime.entrypoint.ClusterEntrypoint;
import org.apache.flink.runtime.entrypoint.JobClusterEntrypoint;
import org.apache.flink.runtime.entrypoint.component.DispatcherResourceManagerComponentFactory;
import org.apache.flink.runtime.entrypoint.component.JobDispatcherResourceManagerComponentFactory;
import org.apache.flink.runtime.entrypoint.parser.CommandLineParser;
import org.apache.flink.runtime.jobgraph.SavepointRestoreSettings;
import org.apache.flink.runtime.jobmanager.HighAvailabilityMode;
import org.apache.flink.runtime.resourcemanager.StandaloneResourceManagerFactory;
import org.apache.flink.runtime.util.EnvironmentInformation;
import org.apache.flink.runtime.util.JvmShutdownSafeguard;
import org.apache.flink.runtime.util.SignalHandler;

import javax.annotation.Nonnull;
import javax.annotation.Nullable;

import java.util.Optional;

import static java.util.Objects.requireNonNull;

/**
 * {@link JobClusterEntrypoint} which is started with a job in a predefined
 * location.
 */
public final class StandaloneJobClusterEntryPoint extends JobClusterEntrypoint {

	public static final JobID ZERO_JOB_ID = new JobID(0, 0);

	@Nonnull
	private final JobID jobId;

	@Nonnull
	private final SavepointRestoreSettings savepointRestoreSettings;

	@Nonnull
	private final String[] programArguments;

	@Nullable
	private final String jobClassName;

	private StandaloneJobClusterEntryPoint(
			Configuration configuration,
			@Nonnull JobID jobId,
			@Nonnull SavepointRestoreSettings savepointRestoreSettings,
			@Nonnull String[] programArguments,
			@Nullable String jobClassName) {
		super(configuration);
		this.jobId = requireNonNull(jobId, "jobId");
		this.savepointRestoreSettings = requireNonNull(savepointRestoreSettings, "savepointRestoreSettings");
		this.programArguments = requireNonNull(programArguments, "programArguments");
		this.jobClassName = jobClassName;
	}

	@Override
	protected DispatcherResourceManagerComponentFactory<?> createDispatcherResourceManagerComponentFactory(Configuration configuration) {
		return new JobDispatcherResourceManagerComponentFactory(
			StandaloneResourceManagerFactory.INSTANCE,
			new ClassPathJobGraphRetriever(jobId, savepointRestoreSettings, programArguments, jobClassName));
	}

	public static void main(String[] args) {
		// startup checks and logging
		EnvironmentInformation.logEnvironmentInfo(LOG, StandaloneJobClusterEntryPoint.class.getSimpleName(), args);
		SignalHandler.register(LOG);
		JvmShutdownSafeguard.installAsShutdownHook(LOG);

		final CommandLineParser<StandaloneJobClusterConfiguration> commandLineParser = new CommandLineParser<>(new StandaloneJobClusterConfigurationParserFactory());
		StandaloneJobClusterConfiguration clusterConfiguration = null;

		try {
			clusterConfiguration = commandLineParser.parse(args);
		} catch (Exception e) {
			LOG.error("Could not parse command line arguments {}.", args, e);
			commandLineParser.printHelp(StandaloneJobClusterEntryPoint.class.getSimpleName());
			System.exit(1);
		}

		Configuration configuration = loadConfiguration(clusterConfiguration);
		setDefaultExecutionModeIfNotConfigured(configuration);

		StandaloneJobClusterEntryPoint entrypoint = new StandaloneJobClusterEntryPoint(
			configuration,
			resolveJobIdForCluster(Optional.ofNullable(clusterConfiguration.getJobId()), configuration),
			clusterConfiguration.getSavepointRestoreSettings(),
			clusterConfiguration.getArgs(),
			clusterConfiguration.getJobClassName());

		ClusterEntrypoint.runClusterEntrypoint(entrypoint);
	}

	@VisibleForTesting
	@Nonnull
	static JobID resolveJobIdForCluster(Optional<JobID> optionalJobID, Configuration configuration) {
		return optionalJobID.orElseGet(() -> createJobIdForCluster(configuration));
	}

	@Nonnull
	private static JobID createJobIdForCluster(Configuration globalConfiguration) {
		if (HighAvailabilityMode.isHighAvailabilityModeActivated(globalConfiguration)) {
			return ZERO_JOB_ID;
		} else {
			return JobID.generate();
		}
	}

	@VisibleForTesting
	static void setDefaultExecutionModeIfNotConfigured(Configuration configuration) {
		if (isNoExecutionModeConfigured(configuration)) {
			// In contrast to other places, the default for standalone job clusters is ExecutionMode.DETACHED
			configuration.setString(ClusterEntrypoint.EXECUTION_MODE, ExecutionMode.DETACHED.toString());
		}
	}

	private static boolean isNoExecutionModeConfigured(Configuration configuration) {
		return configuration.getString(ClusterEntrypoint.EXECUTION_MODE, null) == null;
	}
}


text:
<?php

namespace common\models;

use Yii;
use yii\behaviors\SluggableBehavior;

use \common\models\base\Category as BaseCategory;
use \common\models\traits\ExtendModel;

/**
 * This is the model class for table "category".
 */
class Category extends BaseCategory
{
    use ExtendModel;

    public function behaviors()
    {
        return [
            [
                'class' => SluggableBehavior::className(),
                'attribute' => 'name',
                // 'slugAttribute' => 'slug',
            ],
        ];
    }

    public function __toString(){
        return $this->name;
    }
}


text:
console.log('ok')

if (module.exports.__esModule) module.exports = module.exports.default


text:
package us.nineworlds.serenity.test.shadows;

import android.database.sqlite.SQLiteConnection;
import android.database.sqlite.SQLiteCustomFunction;
import org.robolectric.annotation.Implementation;
import org.robolectric.annotation.Implements;
import org.robolectric.annotation.Resetter;

/**
 * A shadow of SQLiteConnection that does absolutely nothing.
 */
@Implements(value = android.database.sqlite.SQLiteConnection.class, isInAndroidSdk = false)
public class DoNothingShadowSQLiteConnection {

  public DoNothingShadowSQLiteConnection() {
  }

  @Implementation public static SQLiteConnection open() {
    return new SQLiteConnection();
  }

  @Implementation public static long nativeOpen(String path, int openFlags, String label, boolean enableTrace, boolean enableProfile) {
    return 0;
  }

  @Implementation public static long nativePrepareStatement(long connectionPtr, String sql) {
    return 0;
  }

  @Resetter public static void reset() {

  }

  @Implementation public static void nativeClose(long connectionPtr) {

  }

  @Implementation public static void nativeFinalizeStatement(long connectionPtr, long statementPtr) {

  }

  @Implementation public static int nativeGetParameterCount(final long connectionPtr, final long statementPtr) {
    return 0;
  }

  @Implementation public static boolean nativeIsReadOnly(final long connectionPtr, final long statementPtr) {
    return true;
  }

  @Implementation public static long nativeExecuteForLong(final long connectionPtr, final long statementPtr) {
    return -1;
  }

  @Implementation public static void nativeExecute(final long connectionPtr, final long statementPtr) {

  }

  @Implementation public static String nativeExecuteForString(final long connectionPtr, final long statementPtr) {
    return null;
  }

  @Implementation public static int nativeGetColumnCount(final long connectionPtr, final long statementPtr) {
    return 0;
  }

  @Implementation public static String nativeGetColumnName(final long connectionPtr, final long statementPtr, final int index) {
    return null;
  }

  @Implementation public static void nativeBindNull(final long connectionPtr, final long statementPtr, final int index) {
  }

  @Implementation public static void nativeBindLong(final long connectionPtr, final long statementPtr, final int index, final long value) {
  }

  @Implementation public static void nativeBindDouble(final long connectionPtr, final long statementPtr, final int index, final double value) {
  }

  @Implementation public static void nativeBindString(final long connectionPtr, final long statementPtr, final int index, final String value) {
  }

  @Implementation public static void nativeBindBlob(final long connectionPtr, final long statementPtr, final int index, final byte[] value) {
  }

  @Implementation public static void nativeRegisterLocalizedCollators(long connectionPtr, String locale) {
  }

  @Implementation public static int nativeExecuteForChangedRowCount(final long connectionPtr, final long statementPtr) {
    return -0;
  }

  @Implementation public static long nativeExecuteForLastInsertedRowId(final long connectionPtr, final long statementPtr) {
    return -0;
  }

  @Implementation public static long nativeExecuteForCursorWindow(
      final long connectionPtr, final long statementPtr, final long windowPtr, int startPos, int requiredPos, boolean countAllRows) {
    return -0;
  }

  @Implementation public static void nativeResetStatementAndClearBindings(final long connectionPtr, final long statementPtr) {

  }

  @Implementation public static void nativeCancel(long connectionPtr) {
  }

  @Implementation public static void nativeResetCancel(long connectionPtr, boolean cancelable) {
  }

  @Implementation public static void nativeRegisterCustomFunction(long connectionPtr, SQLiteCustomFunction function) {
  }

  @Implementation public static int nativeExecuteForBlobFileDescriptor(long connectionPtr, long statementPtr) {
    return -1;
  }

  @Implementation public static int nativeGetDbLookaside(long connectionPtr) {
    return -1;
  }
}


text:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using BetterLogger;
using RemotePlusClientCmd.ClientExtensionSystem;
using RemotePlusLibrary.Core;
using RemotePlusLibrary.SubSystem.Command;
using RemotePlusLibrary.SubSystem.Command.CommandClasses;
using RemotePlusLibrary.SubSystem.Command.CommandClasses.Parsing;

namespace RemotePlusClientCmd
{
    public class ClientCommandExecutor : ICommandExecutor
    {
        private ICommandSubsystem<IClientCmdModule> _commandSubsystem;

        public ClientCommandExecutor(ICommandSubsystem<IClientCmdModule> s)
        {
            _commandSubsystem = s;
        }

        public event EventHandler<CommandEventArgs> CommandNotFound;

        public CommandResponse Execute(CommandRequest request, CommandExecutionMode commandMode, CommandPipeline pipe, ICommandEnvironment env)
        {
            bool throwFlag = false;
            StatusCodeDeliveryMethod scdm = StatusCodeDeliveryMethod.DoNotDeliver;
            try
            {
                if (!_commandSubsystem.HasCommand(request.Arguments[0].ToString()))
                {
                    GlobalServices.Logger.Log("Unknown local command. Please type {#help} for a list of commands.", LogLevel.Error);
                    return new CommandResponse((int)CommandStatus.Fail);
                }
                var command = _commandSubsystem.GetCommand(request.Arguments[0].ToString());
                var ba = _commandSubsystem.GetCommandBehavior(command);
                if (ba != null)
                {
                    if (ba.TopChainCommand && pipe.Count > 0)
                    {
                        GlobalServices.Logger.Log($"This is a top-level command.", LogLevel.Error);
                        return new CommandResponse((int)CommandStatus.AccessDenied);
                    }
                    if (commandMode != ba.ExecutionType)
                    {
                        GlobalServices.Logger.Log($"The command requires you to be in {ba.ExecutionType} mode.", LogLevel.Error);
                        return new CommandResponse((int)CommandStatus.AccessDenied);
                    }
                    if (ba.DoNotCatchExceptions)
                    {
                        throwFlag = true;
                    }
                    if (ba.StatusCodeDeliveryMethod != StatusCodeDeliveryMethod.DoNotDeliver)
                    {
                        scdm = StatusCodeDeliveryMethod.TellMessageToServerConsole;
                    }
                }
                var sc = command(request, pipe, null);
                if (scdm == StatusCodeDeliveryMethod.TellMessage)
                {
                    GlobalServices.Logger.Log($"Command {request.Arguments[0]} finished with status code {sc.ToString()}", LogLevel.Info);
                }
                else if (scdm == StatusCodeDeliveryMethod.TellMessageToServerConsole)
                {
                    GlobalServices.Logger.Log($"Command {request.Arguments[0]} finished with status code {sc.ToString()}", LogLevel.Info);
                }
                return sc;
            }
            catch (Exception ex)
            {
                if (throwFlag)
                {
                    throw;
                }
                else
                {
                    GlobalServices.Logger.Log("Error whie executing local command: " + ex.Message, LogLevel.Error);
                    return new CommandResponse((int)CommandStatus.Fail);
                }
            }
        }
    }
}


text:
layout: post
title: Peace Corps Top Universities
date: '2007-02-16T18:22:00.000-05:00'
author: DA
tags:
modified_time: '2007-02-16T18:24:22.731-05:00'
blogger_id: tag:blogger.com,1999:blog-17447662.post-4272849212169157443
blogger_orig_url: http://daveande.blogspot.com/2007/02/peace-corps-top-universities.html
---

A list of the colleges and universities that produced the most volunteers in 2006.  University of Michigan sits at number 4 with 82 volunteers.


text:
<?php

namespace JHWEB\ContravencionalBundle\Form;

use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilderInterface;
use Symfony\Component\OptionsResolver\OptionsResolver;

class CvCdoCfgEstadoType extends AbstractType
{
    /**
     * {@inheritdoc}
     */
    public function buildForm(FormBuilderInterface $builder, array $options)
    {
        $builder->add('nombre')->add('sigla')->add('simit')->add('dias')->add('habiles')->add('actualiza')->add('activo')->add('formato');
    }/**
     * {@inheritdoc}
     */
    public function configureOptions(OptionsResolver $resolver)
    {
        $resolver->setDefaults(array(
            'data_class' => 'JHWEB\ContravencionalBundle\Entity\CvCdoCfgEstado'
        ));
    }

    /**
     * {@inheritdoc}
     */
    public function getBlockPrefix()
    {
        return 'jhweb_contravencionalbundle_cvcdocfgestado';
    }

}


text:
package example.multitree;

public class TaxonUserObject {

	String name;
	String rank;

	public TaxonUserObject (final String name, final String rank) {
		setName (name);
		setRank (rank);
	}

	public final String getName() {
		return name;
	}

	public final String getRank() {
		return rank;
	}

	public final void setName (final String name) {
		this.name = name;
	}

	public final void setRank (final String rank) {
		this.rank = rank;
	}

	@Override
	public String toString () {
		return name + " (" + rank + ")";
	}
}


text:
Overview
--------

This is a Vagrant based project that demonstrates an advanced Openshift Origin Latest or Container Platform 3.3 install i.e. one using an Ansible playbook.

The documentation for the installation process can be found at

https://docs.openshift.org/latest/welcome/index.html

or

https://docs.openshift.com/container-platform/3.3/install_config/install/planning.html

Pre-requisites
--------------

* (If intending to install Openshift Container Platform then) a Red Hat Account is required so that the VM can be registered via subscription manager.
* Vagrant
* VirtualBox or Libvirt (--provider=libvirt)

Install the following vagrant plugins:

* landrush (1.1.2)
* vagrant-hostmanager (1.8.5)
* (If intending to install Openshift Container Platform then) vagrant-registration (found within the Red Hat CDK 2.2)

The Openshift Container Platform install requires importing a RHEL 7.2 box, the easiest way to do this is use the packet tool from hashicorp. The steps are described at

https://stomp.colorado.edu/blog/blog/2015/12/24/on-building-red-hat-enterprise-linux-vagrant-boxes/

The iso image that the vagrant image is created from should be the 'RHEL 7.2 Binary DVD' image on the Red Hat downloads site. The box name I have used in the Vagrantfile is 'rhel/7.2'

When installing Openshift Container Platform the Vagrantfile assumes a Red Hat Employee subscription 'Employee SKU'. If you aren't a Red Hat Employee then simply override with your pool id of the subscription that gives you access to the Openshift Container Platform rpms (this could be a 30 day trial subscription).

    export RHSM_POOL=<pool id>

The OS for the origin install defaults to centos but can be overridden by the following environment variable

    export ORIGIN_OS=<desired OS>

Installation
------------

    git clone https://github.com/openshift/openshift-ansible-contrib.git
    cd openshift-ansible-contrib/vagrant

then for an Origin install

    vagrant up

or for an Openshift Container Platform install

    export DEPLOYMENT_TYPE=openshift-enterprise
    export SUB_USERNAME=<Red Hat Username>
    export SUB_PASSWORD=<Red Hat Password>
    vagrant up (you will be prompted for your Red Hat account details and the sudo account password on the host during this process)

Two ansible playbooks will start on admin1 after it has booted. The first playbook bootstraps the pre-requisites for the Openshift install. The second playbook is the actual Openshift install. The inventory for the Openshift install is declared inline in the Vagrantfile.

The install comprises one master and two nodes. The NFS share gets created on admin1.

The inventory makes use of the 'openshift_ip' property to force the use of the eth1 network interface which is using the 192.168.50.x ip addresses of the vagrant private network.

Once complete AND after confirming that the docker-registry pod is up and running then

Logon to https://master1.example.com:8443 as admin/admin123, create a project test then

ssh to master1:

    ssh master1
    oc login -u=system:admin
    oc annotate namespace test openshift.io/node-selector='region=primary' --overwrite

On the host machine (the following assumes RHEL/Centos, other OS may differ) first verify the contents of /etc/dnsmasq.d/vagrant-landrush gives

    server=/example.com/127.0.0.1#10053

then update the dns entries thus

    vagrant landrush set apps.example.com 192.168.50.20

In the web console create a PHP app and wait for it to complete the deployment. Navigate to the overview page for the test app and click on the link for the service i.e.

    cakephp-example-test.apps.example.com

What has just been demonstrated? The new app is deployed into a project with a node selector which requires the region label to be 'primary', this means the app gets deployed to either node1 or node2. The landrush DNS wild card entry for apps.example.com points to master1 which is where the router is running, therefore being able to render the home page of the app means that the SDN of Openshift is working properly with Vagrant.

Notes
-----

The landrush plugin creates a small DNS server to that the guest VMs can resolve each others hostnames and also the host can resolve the guest VMs hostnames. The landrush DNS server is listens on 127.0.0.1 on port 10053. It uses a dnsmasq process to redirect dns traffic to landrush. If this isn't working verify that:

    cat /etc/dnsmasq.d/vagrant-landrush

gives

    server=/example.com/127.0.0.1#10053

and that /etc/resolv.conf has an entry

    # Added by landrush, a vagrant plugin
    nameserver 127.0.0.1


text:
package thahn.java.agui.app;

import thahn.java.agui.view.View;
import thahn.java.agui.widget.FrameLayout;

/**
 * Pre-Honeycomb versions of the platform don't have {@link View#setSaveFromParentEnabled(boolean)},
 * so instead we insert this between the view and its parent.
 */
class NoSaveStateFrameLayout extends FrameLayout {
	static View wrap(View child) {
		return child;
	}
//    static ViewGroup wrap(View child) {
//        NoSaveStateFrameLayout wrapper = new NoSaveStateFrameLayout(child.getContext());
//        ViewGroup.LayoutParams childParams = child.getLayoutParams();
//        if (childParams != null) {
//            wrapper.setLayoutParams(childParams);
//        }
//        NoSaveStateFrameLayout.LayoutParams lp = new NoSaveStateFrameLayout.LayoutParams(
//                ViewGroup.LayoutParams.FILL_PARENT, ViewGroup.LayoutParams.FILL_PARENT);
//        child.setLayoutParams(lp);
//        wrapper.addView(child);
//        return wrapper;
//    }

    public NoSaveStateFrameLayout(Context context) {
        super(context);
    }

//    /**
//     * Override to prevent freezing of any child views.
//     */
//    @Override
//    protected void dispatchSaveInstanceState(SparseArray<Parcelable> container) {
//        dispatchFreezeSelfOnly(container);
//    }
//
//    /**
//     * Override to prevent thawing of any child views.
//     */
//    @Override
//    protected void dispatchRestoreInstanceState(SparseArray<Parcelable> container) {
//        dispatchThawSelfOnly(container);
//    }
}


text:
class CurrentThreadDemo {

	public static void main(String args[]){

	  Thread t=Thread.currentThread();
	  System.out.println("Current: " +t);

	  try {
		for(int n=0; n<5; n++) {
			System.out.println(n);
			Thread.sleep(1000);
			}
		} catch(InterruptedException e){
			System.out.println("Interrupted");
			}
	  catch(Exception ex){
		  System.out.println("Catched All");
	  }
	}//end of main
}//end of class


text:
using System.Collections.Generic;
using Azure.Core;
using Azure.ResourceManager;
using Azure.ResourceManager.Models;
using Azure.ResourceManager.Resources.Models;

namespace Azure.ResourceManager.Resources
{
    /// <summary> A class representing the JitRequestDefinition data model. </summary>
    public partial class JitRequestDefinitionData : TrackedResource
    {
        /// <summary> Initializes a new instance of JitRequestDefinitionData. </summary>
        /// <param name="location"> The location. </param>
        public JitRequestDefinitionData(Location location) : base(location)
        {
            JitAuthorizationPolicies = new ChangeTrackingList<JitAuthorizationPolicies>();
        }

        /// <summary> Initializes a new instance of JitRequestDefinitionData. </summary>
        /// <param name="id"> The id. </param>
        /// <param name="name"> The name. </param>
        /// <param name="type"> The type. </param>
        /// <param name="tags"> The tags. </param>
        /// <param name="location"> The location. </param>
        /// <param name="applicationResourceId"> The parent application id. </param>
        /// <param name="publisherTenantId"> The publisher tenant id. </param>
        /// <param name="jitAuthorizationPolicies"> The JIT authorization policies. </param>
        /// <param name="jitSchedulingPolicy"> The JIT request properties. </param>
        /// <param name="provisioningState"> The JIT request provisioning state. </param>
        /// <param name="jitRequestState"> The JIT request state. </param>
        /// <param name="createdBy"> The client entity that created the JIT request. </param>
        /// <param name="updatedBy"> The client entity that last updated the JIT request. </param>
        internal JitRequestDefinitionData(ResourceIdentifier id, string name, ResourceType type, IDictionary<string, string> tags, Location location, string applicationResourceId, string publisherTenantId, IList<JitAuthorizationPolicies> jitAuthorizationPolicies, JitSchedulingPolicy jitSchedulingPolicy, ProvisioningState? provisioningState, JitRequestState? jitRequestState, ApplicationClientDetails createdBy, ApplicationClientDetails updatedBy) : base(id, name, type, tags, location)
        {
            ApplicationResourceId = applicationResourceId;
            PublisherTenantId = publisherTenantId;
            JitAuthorizationPolicies = jitAuthorizationPolicies;
            JitSchedulingPolicy = jitSchedulingPolicy;
            ProvisioningState = provisioningState;
            JitRequestState = jitRequestState;
            CreatedBy = createdBy;
            UpdatedBy = updatedBy;
        }

        /// <summary> The parent application id. </summary>
        public string ApplicationResourceId { get; set; }
        /// <summary> The publisher tenant id. </summary>
        public string PublisherTenantId { get; }
        /// <summary> The JIT authorization policies. </summary>
        public IList<JitAuthorizationPolicies> JitAuthorizationPolicies { get; }
        /// <summary> The JIT request properties. </summary>
        public JitSchedulingPolicy JitSchedulingPolicy { get; set; }
        /// <summary> The JIT request provisioning state. </summary>
        public ProvisioningState? ProvisioningState { get; }
        /// <summary> The JIT request state. </summary>
        public JitRequestState? JitRequestState { get; }
        /// <summary> The client entity that created the JIT request. </summary>
        public ApplicationClientDetails CreatedBy { get; }
        /// <summary> The client entity that last updated the JIT request. </summary>
        public ApplicationClientDetails UpdatedBy { get; }
    }
}


text:
public class JavaWrite {
    public static void main(String[] args) {
        new Main().setVariable(false);
    }
}


text:
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html
     PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

  <title>File: CHANGELOG</title>
  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  <meta http-equiv="Content-Script-Type" content="text/javascript" />
  <link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />

CHANGELOG

      Path:
      CHANGELOG

      Last Update:
      Sat Jan 05 00:53:21 +0100 2008

1.1

2008-01-05

Fixed padding problem (bug 15885)

Fixed encrypt/decrypt stream

1.0

2007-07-30

Initial release: RAA project import

Added a C extension for speed along the 6 other versions (see README)

Minor changes in the API

[Validate]


text:
import terrainpy
import argparse
import json
import os.path
import requests
from requests.packages.urllib3.exceptions import InsecureRequestWarning
requests.packages.urllib3.disable_warnings(InsecureRequestWarning)

token_cache = '~/.agave/current'

if __name__ == '__main__':

    # arguments
    parser = argparse.ArgumentParser(description = 'Submit a job.')
    parser.add_argument('-f', '--description_file', dest = 'description_file', nargs = '?', help = 'file containing JSON job description')
    parser.add_argument('-v', '--verbose', dest = 'verbose', action = 'store_true', help = 'verbose output')
    parser.add_argument('-z', '--accesstoken', dest = 'accesstoken', nargs = '?', help = 'access token')
    args = parser.parse_args()

    # if token not supplied, get from token_cache
    if args.accesstoken is None:
    	args.accesstoken = terrainpy.get_cached_token()

    # if description file not supplied, prompt user
    if args.description_file is None:
        args.description_file = terrainpy.prompt_user('description_file')

    # build header
    header = {
   	'Authorization': 'Bearer ' + args.accesstoken,
   	'Content-Type' : 'application/json'
    }

    # get job description from description_file
    job_description = open(args.description_file)

    # submit job
    submit_job = requests.post('https://agave.iplantc.org/terrain/v2/analyses',
   				headers = header,
   				data = job_description
   			      )
    submit_job.raise_for_status
    submit_job = submit_job.json()

    # print output based on -v flag
    if args.verbose:
	print json.dumps(submit_job, sort_keys = True, indent = 4, separators = (',', ': '))
    else:
	print submit_job['name'], submit_job['id'], submit_job['status']


text:
<?php

namespace Goodwong\User\Handlers;

use Goodwong\User\Events\UserCreated;
use Goodwong\User\Entities\User;

class UserHandler
{
    /**
     * construct
     *
     * @return void
     */
    public function __construct()
    {
        //
    }

    /**
     * create
     *
     * @param  array  $attributes
     * @return User
     */
    public function create($attributes)
    {
        if (!isset($attributes['password'])) {
            $attributes['password'] = bcrypt(uniqid());
        }
        if (!data_get($attributes, 'name')) {
            $attributes['name'] = '';
        }
        $user = User::create($attributes);

        event(new UserCreated($user));

        return $user;
    }
}


text:
/**
 * @file
 * Administration CSS for Display Suite.
 */
.ds-extras-field-template {
  margin-bottom: 1em;
}

#field-display-overview .ft-settings .ft-group {
  border-top: 1px solid #aaa;
  padding: 5px 0;
  overflow: auto;
}

#field-display-overview .field-formatter-settings-edit-form .ft-group .form-item {
  margin: 0;
}

.ds-layout-preview-title {
  font-weight: bold;
}

.ds-layout-preview-image {
  float: left;
  width: 150px;
  padding-top: 10px;
}

.ds-layout-preview-image img {
  width: 150px;
}

.ds-layout-preview-suggestion {
  min-width: 150px;
  overflow: hidden;
  padding-left: 30px;
}

.ft-group div.form-item {
  float: left;
  width: 130px;
}

.ds-after-suggestion{
  clear: both;
  padding-top: 10px;
}

/**
 * Displays list
 */
table th.ds-display-list-options {
  width: 300px;
}

/**
 * Limit
 */
.limit-float {
  float: left;
  margin-right: 5px;
}

/**
 * Fieldset in vertical tabs.
 */
.vertical-tabs fieldset#edit-additional-settings-ds-page-title-options-page-option-contexts {
  margin: 1em 0;
  padding: 2.5em 0 0;
  border: 1px solid #CCCCCC;
}

#edit-additional-settings-ds-page-title-options-page-option-contexts legend {
  display: block;
}

/**
 * Change layout screen.
 */
.change-ds-layout-info {
  margin-bottom: 10px;
}

.change-ds-layout-old-region {
  font-weight: bold;
}

.ds-layout-change-save {
    clear: both;
}

.ds-layout-preview-arrow {
    float: left;
    margin: 80px 10px 0 5px;
}

.ds-layout-regions {
    float: left;
    width: 210px;
}


text:
<!doctype html>
<meta charset="utf-8" />
<title>input type=text onmouseover</title>

	Move your mouse over the text field below.  Its value should change to
	"foobar".

<form>

		<input name="test" type="text" value="Move mouse over me!" onmouseover="this.value = 'foobar';" />

</form>


text:
package companyreg

//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.
//
// Code generated by Alibaba Cloud SDK Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenerated.

import (
	"github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests"
	"github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses"
)

// CloseIntentionForPartner invokes the companyreg.CloseIntentionForPartner API synchronously
func (client *Client) CloseIntentionForPartner(request *CloseIntentionForPartnerRequest) (response *CloseIntentionForPartnerResponse, err error) {
	response = CreateCloseIntentionForPartnerResponse()
	err = client.DoAction(request, response)
	return
}

// CloseIntentionForPartnerWithChan invokes the companyreg.CloseIntentionForPartner API asynchronously
func (client *Client) CloseIntentionForPartnerWithChan(request *CloseIntentionForPartnerRequest) (<-chan *CloseIntentionForPartnerResponse, <-chan error) {
	responseChan := make(chan *CloseIntentionForPartnerResponse, 1)
	errChan := make(chan error, 1)
	err := client.AddAsyncTask(func() {
		defer close(responseChan)
		defer close(errChan)
		response, err := client.CloseIntentionForPartner(request)
		if err != nil {
			errChan <- err
		} else {
			responseChan <- response
		}
	})
	if err != nil {
		errChan <- err
		close(responseChan)
		close(errChan)
	}
	return responseChan, errChan
}

// CloseIntentionForPartnerWithCallback invokes the companyreg.CloseIntentionForPartner API asynchronously
func (client *Client) CloseIntentionForPartnerWithCallback(request *CloseIntentionForPartnerRequest, callback func(response *CloseIntentionForPartnerResponse, err error)) <-chan int {
	result := make(chan int, 1)
	err := client.AddAsyncTask(func() {
		var response *CloseIntentionForPartnerResponse
		var err error
		defer close(result)
		response, err = client.CloseIntentionForPartner(request)
		callback(response, err)
		result <- 1
	})
	if err != nil {
		defer close(result)
		callback(nil, err)
		result <- 0
	}
	return result
}

// CloseIntentionForPartnerRequest is the request struct for api CloseIntentionForPartner
type CloseIntentionForPartnerRequest struct {
	*requests.RpcRequest
	BizType        string `position:"Query" name:"BizType"`
	Note           string `position:"Query" name:"Note"`
	IntentionBizId string `position:"Query" name:"IntentionBizId"`
}

// CloseIntentionForPartnerResponse is the response struct for api CloseIntentionForPartner
type CloseIntentionForPartnerResponse struct {
	*responses.BaseResponse
	ErrorMsg  string `json:"ErrorMsg" xml:"ErrorMsg"`
	RequestId string `json:"RequestId" xml:"RequestId"`
	Success   bool   `json:"Success" xml:"Success"`
	ErrorCode string `json:"ErrorCode" xml:"ErrorCode"`
}

// CreateCloseIntentionForPartnerRequest creates a request to invoke CloseIntentionForPartner API
func CreateCloseIntentionForPartnerRequest() (request *CloseIntentionForPartnerRequest) {
	request = &CloseIntentionForPartnerRequest{
		RpcRequest: &requests.RpcRequest{},
	}
	request.InitWithApiInfo("companyreg", "2020-03-06", "CloseIntentionForPartner", "companyreg", "openAPI")
	request.Method = requests.POST
	return
}

// CreateCloseIntentionForPartnerResponse creates a response to parse from CloseIntentionForPartner response
func CreateCloseIntentionForPartnerResponse() (response *CloseIntentionForPartnerResponse) {
	response = &CloseIntentionForPartnerResponse{
		BaseResponse: &responses.BaseResponse{},
	}
	return
}


text:
// Copyright 2014 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.

/*!

# Documentation for the trans module

This module contains high-level summaries of how the various modules
in trans work. It is a work in progress. For detailed comments,
naturally, you can refer to the individual modules themselves.

## The Expr module

The expr module handles translation of expressions. The most general
translation routine is `trans()`, which will translate an expression
into a datum. `trans_into()` is also available, which will translate
an expression and write the result directly into memory, sometimes
avoiding the need for a temporary stack slot. Finally,
`trans_to_lvalue()` is available if you'd like to ensure that the
result has cleanup scheduled.

Internally, each of these functions dispatches to various other
expression functions depending on the kind of expression. We divide
up expressions into:

- **Datum expressions:** Those that most naturally yield values.
  Examples would be `22`, `box x`, or `a + b` (when not overloaded).
- **DPS expressions:** Those that most naturally write into a location
  in memory. Examples would be `foo()` or `Point { x: 3, y: 4 }`.
- **Statement expressions:** That that do not generate a meaningful
  result. Examples would be `while { ... }` or `return 44`.

## The Datum module

A `Datum` encapsulates the result of evaluating a Rust expression.  It
contains a `ValueRef` indicating the result, a `Ty` describing
the Rust type, but also a *kind*. The kind indicates whether the datum
has cleanup scheduled (lvalue) or not (rvalue) and -- in the case of
rvalues -- whether or not the value is "by ref" or "by value".

The datum API is designed to try and help you avoid memory errors like
forgetting to arrange cleanup or duplicating a value. The type of the
datum incorporates the kind, and thus reflects whether it has cleanup
scheduled:

- `Datum<Lvalue>` -- by ref, cleanup scheduled
- `Datum<Rvalue>` -- by value or by ref, no cleanup scheduled
- `Datum<Expr>` -- either `Datum<Lvalue>` or `Datum<Rvalue>`

Rvalue and expr datums are noncopyable, and most of the methods on
datums consume the datum itself (with some notable exceptions). This
reflects the fact that datums may represent affine values which ought
to be consumed exactly once, and if you were to try to (for example)
store an affine value multiple times, you would be duplicating it,
which would certainly be a bug.

Some of the datum methods, however, are designed to work only on
copyable values such as ints or pointers. Those methods may borrow the
datum (`&self`) rather than consume it, but they always include
assertions on the type of the value represented to check that this
makes sense. An example is `shallow_copy()`, which duplicates
a datum value.

Translating an expression always yields a `Datum<Expr>` result, but
the methods `to_[lr]value_datum()` can be used to coerce a
`Datum<Expr>` into a `Datum<Lvalue>` or `Datum<Rvalue>` as
needed. Coercing to an lvalue is fairly common, and generally occurs
whenever it is necessary to inspect a value and pull out its
subcomponents (for example, a match, or indexing expression). Coercing
to an rvalue is more unusual; it occurs when moving values from place
to place, such as in an assignment expression or parameter passing.

### Lvalues in detail

An lvalue datum is one for which cleanup has been scheduled. Lvalue
datums are always located in memory, and thus the `ValueRef` for an
LLVM value is always a pointer to the actual Rust value. This means
that if the Datum has a Rust type of `int`, then the LLVM type of the
`ValueRef` will be `int*` (pointer to int).

Because lvalues already have cleanups scheduled, the memory must be
zeroed to prevent the cleanup from taking place (presuming that the
Rust type needs drop in the first place, otherwise it doesn't
matter). The Datum code automatically performs this zeroing when the
value is stored to a new location, for example.

Lvalues usually result from evaluating lvalue expressions. For
example, evaluating a local variable `x` yields an lvalue, as does a
reference to a field like `x.f` or an index `x[i]`.

Lvalue datums can also arise by *converting* an rvalue into an lvalue.
This is done with the `to_lvalue_datum` method defined on
`Datum<Expr>`. Basically this method just schedules cleanup if the
datum is an rvalue, possibly storing the value into a stack slot first
if needed. Converting rvalues into lvalues occurs in constructs like
`&foo()` or `match foo() { ref x => ... }`, where the user is
implicitly requesting a temporary.

Somewhat surprisingly, not all lvalue expressions yield lvalue datums
when trans'd. Ultimately the reason for this is to micro-optimize
the resulting LLVM. For example, consider the following code:

    fn foo() -> Box<int> { ... }
    let x = *foo();

The expression `*foo()` is an lvalue, but if you invoke `expr::trans`,
it will return an rvalue datum. See `deref_once` in expr.rs for
more details.

### Rvalues in detail

Rvalues datums are values with no cleanup scheduled. One must be
careful with rvalue datums to ensure that cleanup is properly
arranged, usually by converting to an lvalue datum or by invoking the
`add_clean` method.

### Scratch datums

Sometimes you need some temporary scratch space.  The functions
`[lr]value_scratch_datum()` can be used to get temporary stack
space. As their name suggests, they yield lvalues and rvalues
respectively. That is, the slot from `lvalue_scratch_datum` will have
cleanup arranged, and the slot from `rvalue_scratch_datum` does not.

## The Cleanup module

The cleanup module tracks what values need to be cleaned up as scopes
are exited, either via panic or just normal control flow. The basic
idea is that the function context maintains a stack of cleanup scopes
that are pushed/popped as we traverse the AST tree. There is typically
at least one cleanup scope per AST node; some AST nodes may introduce
additional temporary scopes.

Cleanup items can be scheduled into any of the scopes on the stack.
Typically, when a scope is popped, we will also generate the code for
each of its cleanups at that time. This corresponds to a normal exit
from a block (for example, an expression completing evaluation
successfully without panic). However, it is also possible to pop a
block *without* executing its cleanups; this is typically used to
guard intermediate values that must be cleaned up on panic, but not
if everything goes right. See the section on custom scopes below for
more details.

Cleanup scopes come in three kinds:
- **AST scopes:** each AST node in a function body has a corresponding
  AST scope. We push the AST scope when we start generate code for an AST
  node and pop it once the AST node has been fully generated.
- **Loop scopes:** loops have an additional cleanup scope. Cleanups are
  never scheduled into loop scopes; instead, they are used to record the
  basic blocks that we should branch to when a `continue` or `break` statement
  is encountered.
- **Custom scopes:** custom scopes are typically used to ensure cleanup
  of intermediate values.

### When to schedule cleanup

Although the cleanup system is intended to *feel* fairly declarative,
it's still important to time calls to `schedule_clean()` correctly.
Basically, you should not schedule cleanup for memory until it has
been initialized, because if an unwind should occur before the memory
is fully initialized, then the cleanup will run and try to free or
drop uninitialized memory. If the initialization itself produces
byproducts that need to be freed, then you should use temporary custom
scopes to ensure that those byproducts will get freed on unwind.  For
example, an expression like `box foo()` will first allocate a box in the
heap and then call `foo()` -- if `foo()` should panic, this box needs
to be *shallowly* freed.

### Long-distance jumps

In addition to popping a scope, which corresponds to normal control
flow exiting the scope, we may also *jump out* of a scope into some
earlier scope on the stack. This can occur in response to a `return`,
`break`, or `continue` statement, but also in response to panic. In
any of these cases, we will generate a series of cleanup blocks for
each of the scopes that is exited. So, if the stack contains scopes A
... Z, and we break out of a loop whose corresponding cleanup scope is
X, we would generate cleanup blocks for the cleanups in X, Y, and Z.
After cleanup is done we would branch to the exit point for scope X.
But if panic should occur, we would generate cleanups for all the
scopes from A to Z and then resume the unwind process afterwards.

To avoid generating tons of code, we cache the cleanup blocks that we
create for breaks, returns, unwinds, and other jumps. Whenever a new
cleanup is scheduled, though, we must clear these cached blocks. A
possible improvement would be to keep the cached blocks but simply
generate a new block which performs the additional cleanup and then
branches to the existing cached blocks.

### AST and loop cleanup scopes

AST cleanup scopes are pushed when we begin and end processing an AST
node. They are used to house cleanups related to rvalue temporary that
get referenced (e.g., due to an expression like `&Foo()`). Whenever an
AST scope is popped, we always trans all the cleanups, adding the cleanup
code after the postdominator of the AST node.

AST nodes that represent breakable loops also push a loop scope; the
loop scope never has any actual cleanups, it's just used to point to
the basic blocks where control should flow after a "continue" or
"break" statement. Popping a loop scope never generates code.

### Custom cleanup scopes

Custom cleanup scopes are used for a variety of purposes. The most
common though is to handle temporary byproducts, where cleanup only
needs to occur on panic. The general strategy is to push a custom
cleanup scope, schedule *shallow* cleanups into the custom scope, and
then pop the custom scope (without transing the cleanups) when
execution succeeds normally. This way the cleanups are only trans'd on
unwind, and only up until the point where execution succeeded, at
which time the complete value should be stored in an lvalue or some
other place where normal cleanup applies.

To spell it out, here is an example. Imagine an expression `box expr`.
We would basically:

1. Push a custom cleanup scope C.
2. Allocate the box.
3. Schedule a shallow free in the scope C.
4. Trans `expr` into the box.
5. Pop the scope C.
6. Return the box as an rvalue.

This way, if a panic occurs while transing `expr`, the custom
cleanup scope C is pushed and hence the box will be freed. The trans
code for `expr` itself is responsible for freeing any other byproducts
that may be in play.

*/