text:
// Copyright 2018 Google LLC
//
// 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.

package com.google.location.suplclient.asn1.supl2.supl_triggered_start;

// Copyright 2008 Google Inc. All Rights Reserved.
/*
 * This class is AUTOMATICALLY GENERATED. Do NOT EDIT.
 */

//
//
import com.google.location.suplclient.asn1.base.Asn1SequenceOf;
import com.google.location.suplclient.asn1.base.Asn1Tag;
import com.google.location.suplclient.asn1.base.BitStream;
import com.google.location.suplclient.asn1.base.BitStreamReader;
import com.google.common.collect.ImmutableList;
import java.util.Collection;
import javax.annotation.Nullable;

/**
 *
 */
public  class AreaIdSet
    extends Asn1SequenceOf<AreaId> {
  //

  private static final Asn1Tag TAG_AreaIdSet
      = Asn1Tag.fromClassAndNumber(-1, -1);

  public AreaIdSet() {
    super();
    setMinSize(1);
setMaxSize(256);

  }

  @Override
  @Nullable
  protected Asn1Tag getTag() {
    return TAG_AreaIdSet;
  }

  @Override
  protected boolean isTagImplicit() {
    return true;
  }

  public static Collection<Asn1Tag> getPossibleFirstTags() {
    if (TAG_AreaIdSet != null) {
      return ImmutableList.of(TAG_AreaIdSet);
    } else {
      return Asn1SequenceOf.getPossibleFirstTags();
    }
  }

  /**
   * Creates a new AreaIdSet from encoded stream.
   */
  public static AreaIdSet fromPerUnaligned(byte[] encodedBytes) {
    AreaIdSet result = new AreaIdSet();
    result.decodePerUnaligned(new BitStreamReader(encodedBytes));
    return result;
  }

  /**
   * Creates a new AreaIdSet from encoded stream.
   */
  public static AreaIdSet fromPerAligned(byte[] encodedBytes) {
    AreaIdSet result = new AreaIdSet();
    result.decodePerAligned(new BitStreamReader(encodedBytes));
    return result;
  }

  @Override public AreaId createAndAddValue() {
    AreaId value = new AreaId();
    add(value);
    return value;
  }

  @Override public Iterable<BitStream> encodePerUnaligned() {
    return super.encodePerUnaligned();
  }

  @Override public Iterable<BitStream> encodePerAligned() {
    return super.encodePerAligned();
  }

  @Override public void decodePerUnaligned(BitStreamReader reader) {
    super.decodePerUnaligned(reader);
  }

  @Override public void decodePerAligned(BitStreamReader reader) {
    super.decodePerAligned(reader);
  }

  @Override public String toString() {
    return toIndentedString("");
  }

  public String toIndentedString(String indent) {
    StringBuilder builder = new StringBuilder();
    builder.append("AreaIdSet = [\n");
    final String internalIndent = indent + "  ";
    for (AreaId value : getValues()) {
      builder.append(internalIndent)
          .append(value.toIndentedString(internalIndent));
    }
    builder.append(indent).append("];\n");
    return builder.toString();
  }
}


text:
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace WinformClicker
{
    static class Program
    {
        /// <summary>
        /// The main entry point for the application.
        /// </summary>
        [STAThread]
        static void Main(string[] args)
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            #region Var Settings
            Variables.IsDebug = args.Contains("-debug");
            Variables.Workers.Add("clicker", 0);
            Variables.Workers.Add("worker", 0);
            Variables.Workers.Add("factory", 0);
            Variables.Workers.Add("slavecountry", 0);
            Variables.Workers.Add("world", 0);
            Variables.Workers.Add("planet", 0);
            Variables.Workers.Add("universe", 0);
            Variables.Workers.Add("reality", 0);
            Variables.WorkerCosts.Add("clicker", 15);
            Variables.WorkerCosts.Add("worker", 200);
            Variables.WorkerCosts.Add("factory", 5000);
            Variables.WorkerCosts.Add("slavecountry", 20000);
            Variables.WorkerCosts.Add("world", 100000);
            Variables.WorkerCosts.Add("planet", 500000);
            Variables.WorkerCosts.Add("universe", 4000000);
            Variables.WorkerCosts.Add("reality", 10000000);
            Variables.OriginalWorkerCosts = new Dictionary<string, int>(Variables.WorkerCosts);
            // ^ Copies all values
            Variables.WorkerGains.Add("clicker", 1);
            Variables.WorkerGains.Add("worker", 5);
            Variables.WorkerGains.Add("factory", 20);
            Variables.WorkerGains.Add("slavecountry", 100);
            Variables.WorkerGains.Add("world", 500);
            Variables.WorkerGains.Add("planet", 2000);
            Variables.WorkerGains.Add("universe", 10000);
            Variables.WorkerGains.Add("reality", 50000);
            Variables.Upgrades.Add(new List<string>
            {
                "doubleClick", "Double Click", "200", "Mouse and Clickers get +1 CpS.", "false", "cps-1-mouse-clicker", "10-clicker:1-worker:upgrade-roboMouse"
            });
            Variables.Upgrades.Add(new List<string>
            {
                "roboMouse", "Robotic Mouse", "100", "Mouse gets +1 CpS.", "false", "cps-1-mouse", "5-clicker"
            });
            Variables.Upgrades.Add(new List<string>
            {
                "workerWhip", "Worker Whip", "150", "Worker gets +2 CpS.", "false", "cps-2-worker", "2-worker"
            });
            Variables.Upgrades.Add(new List<string>
            {
                "goldenCookieEnable", "Golden Cookie", "1000", "Enable golden cookie drops!\r\nGolden cookies will make your mouse and workers make 7x more cookies!", "false"
            });
            Variables.Upgrades.Add(new List<string>
            {
                "extraSlaves", "More Slaves", "1500", "Slave Country gets +20 CpS", "false", "cps-20-slavecountry", "5-clicker:upgrade-roboMouse"
            });
            Variables.Upgrades.Add(new List<string>
            {
                "outsourcedWork", "Outsourced Work", "3000", "Factories gain +5 CpS", "false", "cps-5-factory", "upgrade-goldenCookieEnable:2-factory"
            });
            Variables.Upgrades.Add(new List<string>
            {
                "nuclearCookies", "Nuclear Cookies", "5000", "Factories gain +20 CpS", "false", "cps-20-factory", "5-factory"
            });
            Variables.Upgrades.Add(new List<string>
            {
                "bionicMice", "Bionic Mice", "1500", "Clickers and Mouse gain +3 CpS", "false", "cps-3-mouse-clicker", "2-factory:5-clicker:upgrade-goldenCookieEnable"
            });
            Variables.Achievements.Add(new List<string>
            {
                "firstTime", "First Time Playing", "This is your first time playing!", "false", "first-time"
            });
            Variables.Achievements.Add(new List<string>
            {
                "tenSecondsPlayed", "Amateur Player", "You played for 10 seconds!", "false", "timePlayed-10"
            });
            #endregion
            {
                var temp = Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData);
                temp = Path.Combine(temp, ".ilan");
                if (!Directory.Exists(temp)) Directory.CreateDirectory(temp);
                temp = Path.Combine(temp, "WinformClicker");
                if (!Directory.Exists(temp)) Directory.CreateDirectory(temp);
                //MessageBox.Show(temp);
                Variables.SavesDir = temp;
            }
            for (int i = 0; i < 6; i++)
            {
                Variables.AchievementFiles[i] = Path.Combine(Variables.SavesDir, String.Format("WinformAchieves{0}.ach", i+1));
            }
            Processing.CalculateWorkerPrices();
            Application.Run(new WinformClicker());
        }
    }
}

redpajama_set_name: RedPajamaGithub


text:
/*
 * 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.
 */

package com.github.ipaas.ifw.mq;

import org.junit.runner.RunWith;
import org.junit.runners.Suite;
import org.junit.runners.Suite.SuiteClasses;

import com.github.ipaas.ifw.mq.activemq.FwAmqMqServiceTest;
import com.github.ipaas.ifw.mq.activemq.usability.MqHealthCheckTest;

@RunWith(Suite.class)
@SuiteClasses({ FwAmqMqServiceTest.class, MqHealthCheckTest.class })
public class AllTestSuite {
}


text:
<?php
	/***********************************************\
	* Author: Joey Grasso                           *
	* URL: www.JoeyGrasso.com                       *
	* Purpose: Easily make database connections     *
	*          with PHP to a MySQL server.          *
	\***********************************************/

	// Require the DB_Connect Class
	require_once('DB_Connect.php');

	// Example Usage To Create New DB Object:
		// Create The DB_Connect Object
		$db = new DB_Connect;
		// Run the DB() Function
		$db->DB();

	// Test By Querying For Information
	$result = mysql_query("SELECT * FROM Customers;");

	// Fill An Array With Information From Customer Table
	$Arr = array();
		// Populate Array With Query Result
		while($row = mysql_fetch_array($result)){
			$Arr[] = $row;
		}

	// Take A Dump To Prove Yourself
	var_dump($Arr);

?>


text:
#import "NSNull.h"

@interface NSNull (NSNullPortCoding)
- (id)replacementObjectForPortCoder:(id)arg1;
@end


text:
#import "DVTiPhoneSimulatorRemoteClient.h"

/** Device family constants  */
typedef enum {
    /** iPhone/iPod Devices. */
    DTiPhoneSimulatoriPhoneFamily = 1,

    /** iPad Devices */
    DTiPhoneSimulatoriPadFamily = 2
} DTiPhoneSimulatorFamily;

/** Platform API */
@interface DVTPlatform : NSObject

/** Load all platform SDKs */
+ (BOOL)loadAllPlatformsReturningError:(id*)arg1;

@end


text:
package nodetasks

import (
	"fmt"
	"os"
	"os/exec"
	"path"
	"path/filepath"
	"strings"

	"k8s.io/klog/v2"
	"k8s.io/kops/pkg/backoff"
	"k8s.io/kops/upup/pkg/fi"
	"k8s.io/kops/upup/pkg/fi/nodeup/cloudinit"
	"k8s.io/kops/upup/pkg/fi/nodeup/local"
	"k8s.io/kops/upup/pkg/fi/utils"
	"k8s.io/kops/util/pkg/hashing"
)

// LoadImageTask is responsible for downloading a docker image
type LoadImageTask struct {
	Name    string
	Sources []string
	Hash    string
	Runtime string
}

var (
	_ fi.Task            = &LoadImageTask{}
	_ fi.HasDependencies = &LoadImageTask{}
)

func (t *LoadImageTask) GetDependencies(tasks map[string]fi.Task) []fi.Task {
	// LoadImageTask depends on the docker service to ensure we
	// sideload images after docker is completely updated and
	// configured.
	var deps []fi.Task
	for _, v := range tasks {
		if svc, ok := v.(*Service); ok && svc.Name == containerdService {
			deps = append(deps, v)
		}
		if svc, ok := v.(*Service); ok && svc.Name == dockerService {
			deps = append(deps, v)
		}
	}
	return deps
}

var _ fi.HasName = &LoadImageTask{}

func (t *LoadImageTask) GetName() *string {
	if t.Name == "" {
		return nil
	}
	return &t.Name
}

func (t *LoadImageTask) String() string {
	return fmt.Sprintf("LoadImageTask: %v", t.Sources)
}

func (e *LoadImageTask) Find(c *fi.Context) (*LoadImageTask, error) {
	klog.Warningf("LoadImageTask checking if image present not yet implemented")
	return nil, nil
}

func (e *LoadImageTask) Run(c *fi.Context) error {
	return fi.DefaultDeltaRunMethod(e, c)
}

func (_ *LoadImageTask) CheckChanges(a, e, changes *LoadImageTask) error {
	return nil
}

func (_ *LoadImageTask) RenderLocal(t *local.LocalTarget, a, e, changes *LoadImageTask) error {
	runtime := e.Runtime
	if runtime != "docker" && runtime != "containerd" {
		return fmt.Errorf("no runtime specified")
	}

	hash, err := hashing.FromString(e.Hash)
	if err != nil {
		return err
	}

	urls := e.Sources
	if len(urls) == 0 {
		return fmt.Errorf("no sources specified: %v", err)
	}

	// We assume the first url is the "main" url, and download to a local file based on that _name_, wherever we get it from
	primaryURL := urls[0]
	key := path.Base(primaryURL)
	localFile := filepath.Join(t.CacheDir, hash.String()+"_"+utils.SanitizeString(key))

	for _, url := range urls {
		_, err = fi.DownloadURL(url, localFile, hash)
		if err != nil {
			klog.Warningf("error downloading url %q: %v", url, err)
			continue
		} else {
			break
		}
	}
	if err != nil {
		// Hack to try to avoid failed downloads causing massive bandwidth bills
		backoff.DoGlobalBackoff(fmt.Errorf("failed to download image %s: %v", primaryURL, err))
		return err
	}

	// containerd can't import gzipped container images, if the image is gzipped extract it to tmp dir
	// TODO: Improve the naive gzip format detection by checking the content type bytes "\x1F\x8B\x08"
	var tarFile string
	if strings.HasSuffix(localFile, "gz") {
		tmpDir, err := os.MkdirTemp("", "loadimage")
		if err != nil {
			return fmt.Errorf("error creating temp dir: %v", err)
		}
		defer func() {
			if err := os.RemoveAll(tmpDir); err != nil {
				klog.Warningf("error deleting temp dir %q: %v", tmpDir, err)
			}
		}()
		tarFile = path.Join(tmpDir, utils.SanitizeString(primaryURL))
		err = utils.UngzipFile(localFile, tarFile)
		if err != nil {
			return fmt.Errorf("error ungzipping container image: %v", err)
		}
	} else {
		// Assume container image is tar file alerady
		tarFile = localFile
	}

	// Load the container image
	var args []string
	switch runtime {
	case "docker":
		args = []string{"docker", "load", "-i", tarFile}
	case "containerd":
		args = []string{"ctr", "--namespace", "k8s.io", "images", "import", tarFile}
	default:
		return fmt.Errorf("unknown container runtime: %s", runtime)
	}
	human := strings.Join(args, " ")

	klog.Infof("running command %s", human)
	cmd := exec.Command(args[0], args[1:]...)
	output, err := cmd.CombinedOutput()
	if err != nil {
		return fmt.Errorf("error loading docker image with '%s': %v: %s", human, err, string(output))
	}

	return nil
}

func (_ *LoadImageTask) RenderCloudInit(t *cloudinit.CloudInitTarget, a, e, changes *LoadImageTask) error {
	return fmt.Errorf("LoadImageTask::RenderCloudInit not implemented")
}


text:
@interface WRBaseNavigationController ()

@end

@implementation WRBaseNavigationController

- (void)viewDidLoad {
    [super viewDidLoad];
    [self setNavigationBarImage];
    // Do any additional setup after loading the view.
}

- (UIStatusBarStyle)preferredStatusBarStyle
{
    return UIStatusBarStyleLightContent;
}

- (BOOL)prefersStatusBarHidden
{
    return NO;
}

//设置导航图片
-(void)setNavigationBarImage
{
    if (GJCFSystemIsOver7) {
        UIImage *syncBgImg = [GJCFAssetsPickerConstans imageForColor:[WRGuideStyle navigationBarBackColor] withSize:CGSizeMake(320, 64)];
        [self.navigationBar setBackgroundImage:syncBgImg forBarPosition:UIBarPositionAny barMetrics:UIBarMetricsDefault];
    }
    else if (GJCFSystemIsOver6)
    {
        UIImage *syncBgImg = [GJCFAssetsPickerConstans imageForColor:[WRGuideStyle navigationBarBackColor] withSize:CGSizeMake(320, 44)];
        [self.navigationBar setBackgroundImage:syncBgImg forBarMetrics:UIBarMetricsDefault];
    }
    else
    {
        [self.navigationBar setBackgroundImage:[GJCFAssetsPickerConstans imageForColor:[WRGuideStyle navigationBarBackColor] withSize:CGSizeMake(320, 44)] forBarMetrics:UIBarMetricsDefault];
    }
}

@end


text:
import string
import os
from collections import namedtuple

generate_for_languages = os.environ.get(
    'THEMIS_TEST_LANGUAGES', 'ruby,python,js,node,go,php,rust')
generate_for_languages = generate_for_languages.split(',')

LanguageSetting = namedtuple(
    'LanguageSetting', ['name', 'command', 'script_path', 'extension'])

languages = [
    LanguageSetting(name='ruby', command='ruby', script_path='./tools/ruby', extension='rb'),
    LanguageSetting(name='python', command='python3', script_path='./tools/python', extension='py'),
    LanguageSetting(name='js', command='node', script_path='./tools/js/wasm-themis', extension='js'),
    LanguageSetting(name='node', command='node', script_path='./tools/js/jsthemis', extension='js'),
    LanguageSetting(name='go', command='env', script_path='./tools/go', extension='go.compiled'),
    LanguageSetting(name='php', command='php -f', script_path='./tools/php', extension='php'),
    LanguageSetting(name='rust', command='env', script_path='./tools/rust', extension='rust'),
]

templates = {
    'smessage_signing': './tests/_integration/integration_smessage_signing.template',
    'smessage_encryption': './tests/_integration/integration_smessage_encryption.template',
    'scell_token_protect': './tests/_integration/integration_scell_token_protect.template',
    'scell_seal': './tests/_integration/integration_scell_seal.template',
    'scell_seal_pw': './tests/_integration/integration_scell_seal_pw.template',
    'scell_context_imprint': './tests/_integration/integration_scell_context_imprint.template',
}

def render_snippet(template, setting1, setting2):
    return template.safe_substitute(
        language_name1=setting1.name, language_name2=setting2.name,
        command1=setting1.command, command2=setting2.command,
        script_path1=setting1.script_path, script_path2=setting2.script_path,
        script1_extension=setting1.extension, script2_extension=setting2.extension)

base_template_path = './tests/_integration/base.template'
with open(base_template_path) as f:
    base_template = string.Template(f.read())

with open('./tests/_integration/integration_total.template') as f:
    script_runner_template = string.Template(f.read())

scripts_runners = []
# generate scripts for each operation
for snippet_name in templates:
    snippets = []
    with open(templates[snippet_name]) as f:
        snippet_template = string.Template(f.read())
    for setting1 in languages:
        for setting2 in languages:
            if (setting1.name not in generate_for_languages or
                    setting2.name not in generate_for_languages):
                continue
            snippet = render_snippet(snippet_template, setting1, setting2)
            snippets.append(snippet)

    script = base_template.substitute(commands='\n'.join(snippets))

    script_path = './tests/_integration/integration_{}.sh'.format(snippet_name)
    with open(script_path, 'w') as f:
        f.write(script)
    scripts_runners.append(script_runner_template.safe_substitute(
        script_path=script_path, test_name=snippet_name))

with open('./tests/_integration/integration_total.sh', 'w') as f:
    f.write(base_template.safe_substitute(commands='\n'.join(scripts_runners)))

print('done')