text:
package com.pizidea.imagepicker.ui.activity;

import android.app.Activity;
import android.content.Intent;
import android.graphics.Bitmap;
import android.os.Bundle;
import android.support.v4.app.FragmentActivity;
import android.util.Log;
import android.view.View;
import android.widget.AdapterView;
import android.widget.TextView;

import com.pizidea.imagepicker.AndroidImagePicker;
import com.pizidea.imagepicker.R;
import com.pizidea.imagepicker.bean.ImageItem;
import com.pizidea.imagepicker.ui.ImagesGridFragment;

public class ImagesGridActivity extends FragmentActivity implements View.OnClickListener,AndroidImagePicker.OnImageSelectedChangeListener {
    private static final String TAG = ImagesGridActivity.class.getSimpleName();

    private TextView mBtnOk;

    ImagesGridFragment mFragment;
    AndroidImagePicker androidImagePicker;
    String imagePath;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_images_grid);

        androidImagePicker = AndroidImagePicker.getInstance();
        androidImagePicker.clearSelectedImages();//most of the time you need to clear the last selected images or you can comment out this line

        mBtnOk = (TextView) findViewById(R.id.btn_ok);
        mBtnOk.setOnClickListener(this);

        if(androidImagePicker.getSelectMode() == AndroidImagePicker.Select_Mode.MODE_SINGLE){
            mBtnOk.setVisibility(View.GONE);
        }else{
            mBtnOk.setVisibility(View.VISIBLE);
        }

        findViewById(R.id.btn_backpress).setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                finish();
            }
        });

        //final boolean isCrop = getIntent().getBooleanExtra("isCrop",false);
        final boolean isCrop = androidImagePicker.cropMode;
        imagePath = getIntent().getStringExtra(AndroidImagePicker.KEY_PIC_PATH);
        mFragment = new ImagesGridFragment();
        /*Bundle data = new Bundle();
        data.putString(AndroidImagePicker.KEY_PIC_PATH,imagePath);
        mFragment.setArguments(data);*/

        mFragment.setOnImageItemClickListener(new AdapterView.OnItemClickListener() {
            @Override
            public void onItemClick(AdapterView<?> parent, View view, int position, long id) {

                position = androidImagePicker.isShouldShowCamera() ? position-1 : position;

                if(androidImagePicker.getSelectMode() == AndroidImagePicker.Select_Mode.MODE_MULTI){
                    go2Preview(position);
                }else if(androidImagePicker.getSelectMode() == AndroidImagePicker.Select_Mode.MODE_SINGLE){
                    if(isCrop){
                        Intent intent = new Intent();
                        intent.setClass(ImagesGridActivity.this,ImageCropActivity.class);
                        intent.putExtra(AndroidImagePicker.KEY_PIC_PATH,androidImagePicker.getImageItemsOfCurrentImageSet().get(position).path);
                        startActivity(intent);
                    }else{
                        androidImagePicker.clearSelectedImages();
                        androidImagePicker.addSelectedImageItem(position, androidImagePicker.getImageItemsOfCurrentImageSet().get(position));
                        setResult(RESULT_OK);

                        finish();
                        androidImagePicker.notifyOnImagePickComplete();
                    }

                }

            }
        });

        getSupportFragmentManager().beginTransaction().replace(R.id.container, mFragment).commit();

        androidImagePicker.addOnImageSelectedChangeListener(this);

        int selectedCount = androidImagePicker.getSelectImageCount();
        onImageSelectChange(0, null, selectedCount, androidImagePicker.getSelectLimit());

    }

    /**
     * 预览页面
     * @param position
     */
    private void go2Preview(int position) {
        Intent intent = new Intent();
        intent.putExtra(AndroidImagePicker.KEY_PIC_SELECTED_POSITION, position);
        intent.setClass(ImagesGridActivity.this, ImagePreviewActivity.class);
        startActivityForResult(intent, AndroidImagePicker.REQ_PREVIEW);
    }

    @Override
    public void onClick(View v) {

        if(v.getId() == R.id.btn_ok){
            finish();
            androidImagePicker.notifyOnImagePickComplete();
        }else if(v.getId() == R.id.btn_pic_rechoose){
            finish();
        }

    }

    @Override
    public void onImageSelectChange(int position, ImageItem item, int selectedItemsCount, int maxSelectLimit) {
        if(selectedItemsCount > 0){
            mBtnOk.setEnabled(true);
            //mBtnOk.setText("完成("+selectedItemsCount+"/"+maxSelectLimit+")");
            mBtnOk.setText(getResources().getString(R.string.select_complete,selectedItemsCount,maxSelectLimit));
        }else{
            mBtnOk.setText(getResources().getString(R.string.complete));
            mBtnOk.setEnabled(false);
        }
        Log.i(TAG, "=====EVENT:onImageSelectChange");
    }

    @Override
    protected void onDestroy() {
        androidImagePicker.removeOnImageItemSelectedChangeListener(this);
        androidImagePicker.clearImageSets();
        Log.i(TAG, "=====removeOnImageItemSelectedChangeListener");
        super.onDestroy();
    }

    @Override
    protected void onActivityResult(int requestCode, int resultCode, Intent data) {
        super.onActivityResult(requestCode,resultCode,data);

        if(resultCode == Activity.RESULT_OK){

           if(requestCode == AndroidImagePicker.REQ_PREVIEW){
                setResult(RESULT_OK);
                finish();
                androidImagePicker.notifyOnImagePickComplete();
            }

        }

    }

}


text:
module EPI::ChapterTen
  module One
    # Design an algorithm that takes a set of files containing stock trades
    # sorted by increasing trade times, and writes a single file containing
    # the trades appearing in the individual files sorted in the same order.
    # The algorithm should use very little RAM, ideally of the order of a few
    # kilobytes.
    #
    # This can be accomplished with an n-way merge or with a heap.
    # In either case, we would keep the memory usage low by not reading
    # the entire files into memory.
    #
    # In the case of the n-way merge, we would use a buffered read from
    # each file (the size of the buffer would depend on the amount of files
    # we would need to have open), pick the minimum at each merge, and perform
    # a buffered write for every minimum found. The main inefficiency would
    # come from potentially having too many files to compare from. For example,
    # if there are 500 files, then we are performing a 500-way merge. Once we
    # find the minimum for that merge we would then backfill from the file from
    # which that minimum came to prepare for the next merge. However, the next
    # merge would then be comparing the same 499 entries from the previous merge.
    #
    # In the case of a heap, we would still use buffered reads and buffered writes
    # instead of reading entire files at a time, but we could also avoid
    # the redundant comparisons inherent to the n-way merge. We would read an entry
    # from each file into the heap, pop the minimum into a file, then backfill into
    # the heap another entry from the file in which a minimum just came. The
    # advantage here is that once we go to find the minimum again, we aren't
    # redundantly comparing every element to each other element because the constructed
    # heap has already ordered the previous elements in a nearly-sorted manner.
  end
end

redpajama_set_name: RedPajamaGithub


text:
    <meta http-equiv="content-type" content="text/html; charset=UTF-8"><title>CreateMail</title>

CreateMail()

语法

Result = CreateMail(#Mail, From$, Subject$ [, Encoding])

概要

Create a new, empty mail.

参数

#Mail

A number to identify the new mail. #PB_Any 可以用来自动生成这个编码.

From$

The sender address for the mail.

Subject$

The subject line for the mail.

Encoding (optional)

The encoding for the mail. 它可以是下列值之一︰

  #PB_Ascii : The mail body will be in ascii (default)
  #PB_UTF8  : The mail body will be in UTF-8

返回值

Returns nonzero if the mail was created successfully and zero if not.
If #PB_Any was used as the #Mail parameter, then the auto-generated number is returned in case of success.

备注

SetMailBody(), SetMailAttribute(), AddMailAttachment() and
AddMailAttachmentData() can be used to change the content of the  #Mail.

Note: According to the RFC 2822 standard
a line break in an e-mail need to be done always using the CRLF chars.

示例

  InitNetwork()

  If CreateMail(0, "test@purebasic.com", "Hello")
    SetMailBody(0, "This is a body !" + #CRLF$ + "Second line")
    Debug "Mail created"
  Else
    Debug "Can't create the mail"
  EndIf

参阅

InitNetwork(), SetMailBody(), SetMailAttribute(), AddMailAttachment(), AddMailAttachmentData(), SendMail(), FreeMail()

已支持操作系统
所有

<- AddMailRecipient() - Mail Index - FreeMail() ->


text:
namespace aprilui
{
	namespace Animators
	{
		BlueChanger::BlueChanger(chstr name) : Animator(name)
		{
		}

		BlueChanger::~BlueChanger()
		{
		}

		Animator* BlueChanger::createInstance(chstr name)
		{
			return new BlueChanger(name);
		}

		float BlueChanger::_getObjectValue()
		{
			return (float)this->parent->getBlue();
		}

		void BlueChanger::_setObjectValue(float value)
		{
			this->parent->setBlue((unsigned char)value);
		}

		void BlueChanger::update(float k)
		{
			this->_valueUpdateUChar(k);
		}

	}
}


text:
package org.eclipse.bpel.ui.util;

import org.eclipse.bpel.common.ui.editmodel.EditModel;
import org.eclipse.bpel.ui.IBPELUIConstants;
import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.IResource;
import org.eclipse.core.resources.ResourcesPlugin;
import org.eclipse.core.runtime.IPath;
import org.eclipse.emf.ecore.resource.ResourceSet;

/**
 * Sharable EditModel, customized for the BPELEditor.
 */
public class BPELEditModel extends EditModel {

	protected IFile extensionsFile;
	protected IFile artifactsFile;

	/*
	 * Protected constructor. Use the static factory methods.
	 */
	protected BPELEditModel(ResourceSet resourceSet,IResource primaryFile) {
		super(resourceSet, primaryFile);
	}

	static class BPELEditModelFactory extends EditModel.Factory {
		@Override
		protected EditModel createEditModel(ResourceSet resourceSet,IResource primaryFile) {
			return new BPELEditModel(resourceSet, primaryFile);
		}
	}

	public static EditModel getEditModel(IResource primaryFile) {
		return getEditModel(primaryFile, new BPELEditModelFactory());
	}

	/**
	 * Returns an IFile representing the Extensions file (the .bpelex file).
	 */
	public IFile getExtensionsFile() {
		if (extensionsFile == null) {
			IPath extensionsPath = getPrimaryFile().getFullPath().removeFileExtension().addFileExtension(IBPELUIConstants.EXTENSION_MODEL_EXTENSIONS);
			extensionsFile = ResourcesPlugin.getWorkspace().getRoot().getFile(extensionsPath);
		}
		return extensionsFile;
	}

	/**
	 * Returns an IFile representing the Artifacts WSDL for the primaryFile (BPEL file).
	 */
	public IFile getArtifactsFile() {
		if (artifactsFile == null) {
			// TODO: there might be a simpler way to do this.
			IPath artifactsPath = getPrimaryFile().getFullPath().removeFileExtension();
			String shortName = artifactsPath.lastSegment()+"Artifacts"; //$NON-NLS-1$
			artifactsPath = artifactsPath.removeLastSegments(1).append(shortName).addFileExtension(IBPELUIConstants.EXTENSION_WSDL);
			artifactsFile = ResourcesPlugin.getWorkspace().getRoot().getFile(artifactsPath);
		}
		return artifactsFile;
	}
}


text:
// <copyright company="Aspose Pty Ltd">
//   Copyright (C) 2011-2021 GroupDocs. All Rights Reserved.
// </copyright>

namespace GroupDocs.Metadata.Examples.CSharp.AdvancedUsage.ManagingMetadataForSpecificFormats.Video.Avi
{
    using System;
    using Formats.Video;

    /// <summary>
    /// This code sample shows how to extract INFO chunk metadata from an AVI file.
    /// </summary>
    public static class AviReadInfoMetadata
    {
        public static void Run()
        {
            using (Metadata metadata = new Metadata(Constants.InputAvi))
            {
                var root = metadata.GetRootPackage<AviRootPackage>();
                if (root.RiffInfoPackage != null)
                {
                    Console.WriteLine(root.RiffInfoPackage.Artist);
                    Console.WriteLine(root.RiffInfoPackage.Comment);
                    Console.WriteLine(root.RiffInfoPackage.Copyright);
                    Console.WriteLine(root.RiffInfoPackage.CreationDate);
                    Console.WriteLine(root.RiffInfoPackage.Software);
                    Console.WriteLine(root.RiffInfoPackage.Engineer);
                    Console.WriteLine(root.RiffInfoPackage.Genre);

                    // ...
                }
            }
        }
    }
}


text:
import sys

PY3 = sys.version_info >= (3,)

if PY3:
    string_type = str
else:
    string_type = basestring


text:
package org.apache.karaf.http.core;

import javax.management.openmbean.TabularData;

/**
 * HTTP MBean.
 */
public interface HttpMBean {

    /**
     * List details for servlets.
     *
     * @return a tabular view of the servlets information.
     * @throws Exception
     */
    TabularData getServlets();

}


text:
  #include "mraa.h"
  #include "spi.h"
  #include "gpio.h"
  #include "compatibility.h"

  #include <stdint.h>
  #include <stdio.h>
  #include <time.h>
  #include <string.h>
  #include <sys/time.h>
  #include <stddef.h>
  #include <iostream>
  #include <unistd.h>
  #include <stdlib.h>

  //#include <UtilTime.h> // Precompiled arduino x86 based utiltime for timing functions

  // GCC a Arduino Missing
  #define HIGH	1
  #define LOW	0
  #define _BV(x) (1<<(x))
  #define pgm_read_word(p) (*(p))
  #define pgm_read_byte(p) (*(p))
  #define pgm_read_ptr(p) (*(p))
  #define _SPI spi

  #define RF24_LINUX
  //typedef uint16_t prog_uint16_t;
  #define PSTR(x) (x)
  #define printf_P printf
  #define sprintf_P sprintf
  #define strlen_P strlen
  #define PROGMEM
  #define PRIPSTR "%s"

  #ifdef SERIAL_DEBUG
	#define IF_SERIAL_DEBUG(x) ({x;})
  #else
	#define IF_SERIAL_DEBUG(x)
  #endif

  #define digitalWrite(pin, value) gpio.write(pin, value)
  #define digitalRead(pin) GPIO::read(pin)
  #define pinMode(pin, direction) gpio.open(pin, direction)

  #ifndef __TIME_H__
    // Prophet: Redefine time functions only if precompiled arduino time is not included
	#define delay(milisec) __msleep(milisec)
	#define delayMicroseconds(usec) __usleep(usec)
	#define millis() __millis()
  #endif

  #define INPUT mraa::DIR_IN
  #define OUTPUT mraa::DIR_OUT

  // SPI defines for ARDUINO API
  #define MSBFIRST 1
  #define SPI_MODE0 mraa::SPI_MODE0
  #define SPI_CLOCK_DIV2 8000000

#endif


text:
package model;

import java.io.File;
import java.io.IOException;
import java.util.Vector;

import org.jaudiotagger.audio.AudioFile;
import org.jaudiotagger.audio.AudioFileIO;
import org.jaudiotagger.audio.exceptions.CannotReadException;
import org.jaudiotagger.audio.exceptions.CannotWriteException;
import org.jaudiotagger.audio.exceptions.InvalidAudioFrameException;
import org.jaudiotagger.audio.exceptions.ReadOnlyFileException;
import org.jaudiotagger.tag.FieldKey;
import org.jaudiotagger.tag.Tag;
import org.jaudiotagger.tag.TagException;

public class MP3TagHandler {
	public static Vector<String> getTags(File mp3) {
		try {
			//System.out.println("Getting tags for file " + mp3.getAbsolutePath());
			AudioFile f = AudioFileIO.read(mp3);
			Tag tag = f.getTag();
			Vector<String> song = new Vector<String>();
			song.add(tag.getFirst(FieldKey.ARTIST));
			song.add(tag.getFirst(FieldKey.TITLE));
			song.add(tag.getFirst(FieldKey.LYRICS));
			return song;
		} catch (CannotReadException e1) {
			// TODO Auto-generated catch block
			 //e1.printStackTrace();
		} catch (IOException e1) {
			// TODO Auto-generated catch block
			 //e1.printStackTrace();
		} catch (TagException e1) {
			// TODO Auto-generated catch block
			 //e1.printStackTrace();
		} catch (ReadOnlyFileException e1) {
			// TODO Auto-generated catch block
			//e1.printStackTrace();
		} catch (InvalidAudioFrameException e1) {
			// TODO Auto-generated catch block
			//e1.printStackTrace();
		}
		return null;
	}

	public static int saveLyrics(String lyrics, String fileLocation) {
		try {
			File mp3 = new File(fileLocation);
			AudioFile f = AudioFileIO.read(mp3);
			Tag tag = f.getTag();
			tag.setField(FieldKey.LYRICS, lyrics);
			f.commit();
			return 1;
		} catch (CannotReadException e1) {
			// TODO Auto-generated catch block
			// e1.printStackTrace();
		} catch (CannotWriteException e1) {
			// TODO Auto-generated catch block
			// e1.printStackTrace();
		} catch (IOException e1) {
			// TODO Auto-generated catch block
			// e1.printStackTrace();
		} catch (TagException e1) {
			// TODO Auto-generated catch block
			// e1.printStackTrace();
		} catch (ReadOnlyFileException e1) {
			// TODO Auto-generated catch block
			// e1.printStackTrace();
		} catch (InvalidAudioFrameException e1) {
			// TODO Auto-generated catch block
			// e1.printStackTrace();
		}
		return 0;
	}
}


text:
{{ $freelancing := ($.Site.Taxonomies.categories.freelancing).Pages }}

I've had {{ len $freelancing}} freelance clients so far

  {{ range $freelancing }} {{ if .Date.Local.Before now }}

    {{ partial "card.html" . }}

  {{ end }} {{ end }}


text:
from django import forms
from django.contrib.auth.models import User, Group
from django.contrib.auth.forms import UserCreationForm, forms
from .models import C_Owner

C_OWNER_GROUP = 'Contest Owner'
APPLICANT_GROUP = 'Applicant'

class COwnerCreationForm(UserCreationForm):
	website = forms.CharField(label='Website', max_length=200)
	company_name = forms.CharField(label='Company Name', max_length=200,)
	company_address = forms.CharField(label='Company Address', widget=forms.Textarea(attrs={'rows': 3}))

	class Meta:
		model = User
		fields=("username","email")

	def save(self, commit=True):
		if not commit:
			raise NotImplementedError("Database Save Error")
		user = super(COwnerCreationForm, self).save(commit=True)
		c_owner = C_Owner(profile_model_referance=user, website=self.cleaned_data['website'],
			company_name=self.cleaned_data['company_name'], company_address=self.cleaned_data['company_address'])
		c_owner.save()
		user.groups.add(Group.objects.get(name=C_OWNER_GROUP))
		return user, c_owner

class ApplicantCreationForm(UserCreationForm):
	class Meta:
		model = User
		fields=("username","email")

	def save(self, commit=True):
		if not commit:
			raise NotImplementedError("Database Save Error")
		user = super(ApplicantCreationForm, self).save(commit=True)
		Group.objects.get(name=APPLICANT_GROUP).user_set.add(user)
		return user

class COwnerChangeForm(forms.ModelForm):
	website = forms.CharField(label='Website', max_length=200)
	company_name = forms.CharField(label='Company Name', max_length=200,)
	company_address = forms.CharField(label='Company Address', widget=forms.Textarea(attrs={'rows': 3}))

	class Meta:
		model = User
		fields= {"username","email"}

	def save(self,user,commit=True):
		if not commit:
			raise NotImplementedError("Database Save Error")
		user.username = self.cleaned_data['username']
		user.email = self.cleaned_data['email']
		cowner = C_Owner.objects.get(profile_model_referance__exact = user.id)
		cowner.website = self.cleaned_data['website']
		cowner.company_name = self.cleaned_data['company_name']
		cowner.company_address = self.cleaned_data['company_address']
		user.save()
		cowner.save()

class ApplicantChangeForm(forms.ModelForm):
	class Meta:
		model = User
		fields = {"username","email"}

	def save(self,user,commit=True):
		if not commit:
			raise NotImplementedError("Database Save Error")
		user.username = self.cleaned_data['username']
		user.email = self.cleaned_data['email']
		user.save()

class LoginForm(forms.Form):
	username = forms.CharField(label='Username')
	password = forms.CharField(label='Password', widget=forms.PasswordInput)

class ContactForm(forms.Form):
	email = forms.EmailField(label='E-Mail Address')
	subject = forms.CharField(label='Subject')
	text = forms.CharField(label='Message', widget=forms.Textarea(attrs={'rows':5}))


text:
Featured lists are common marketing components used for associating visual icons with a list of topics.

{% example html %}

Save things

            Use dropbox to save things in the "cloud" because throwing things away is stressful and this way you don't have to.

Fork things

            Use github to share things on the internet then change them. Make things better. Free software? But not as in beer.

Write things

            Use Medium to write things down and sound smart. Also when you write, your writings looks pretty and that is cool.

Tweet things

            Use twitter to share 140 characters worth of anything you want. Pictures, videos, etc. It doesn't really matter.

{% endexample %}


text:
========================
 EUCALYPTUS LOG TRACKER
========================

## WIKI
See why LogTracker is useful: https://github.com/eucalyptus/logtrackers/wiki

## WHAT IS THIS?

Since Eucalyptus is a distributed Cloud platform, it is often challenging to
track and troubleshoot distributed computations that is the result of an
end-user's request. For example, "RunInstances" result in database transaction
at CLC, VM scheduling at CC, and VM allocation at NC. If any of the sub-operations
fail, debugging the distributed systems can be a challenging task to cloud administrators.

To ease the pain, Eucalyptus 4.1 introduces a core support and tools for tracking
distributed computations that is the result of a Cloud user's request.

## EXAMPLE USAGE

`euca-req-history eucalyptus`

 *Print out the history of requests by account "eucalyptus". From the history, request-id is used below.*

`euca-req-track --ssh 95e9933e`

 *Ssh into the distributed Eucalyptus services and gather all the logs related to the request-id.*

`euca-req-track -d /var/log/eucalyptus -t rsyslog 95e9933e`

 *If the log files are being aggregated with rsyslog, the tool gathers the logs from the directory.*

## DEPENDENCIES

  tabulate
  dnspython

  For Centos, run `yum install python-pip`, followed by `pip install tabulate dnspython`


text:
package nanocad.minimize.uff;

import java.lang.Math;
import java.util.Vector;
import nanocad.*;

public class aterm extends term
{
	private static final double convert = pi / 180; // degrees to radians
	double k,k0,k1,k2, th0;	// force constants, and standard bond angle.  It would be preferable
				// to use just one force constant, and have it calculated and assigned
				// during setCalculationValues, but k depends on theta, which is not
				// available until the calculation begins.  Therefore, k is broken
				// into 3 separate constants.
	int n;			// constant multiplier; 1,3,4,or 4 for linear, trigonal-planar,
				// square-planar, or octahedral respectively.  Not used for
				// general non-linear cases (where geometry is with respect to
				// the central atom in the term).
	double rij, rjk;	// natural bond lengths, as explained in lterm.java.  These should
				// probably be moved to be member variables of bond.java, if possible.

	/**
	 * Calculates forces and potential for the angle term.
	 * For linear or planar geometries (wrt the central atom),
	 *  E = k/n^2*(1-cos(n*theta);
	 *  n depends on the orientation, see below where n is assigned
	 * For general non-linear,
	 *  E = k*(c0 + c1*cos(theta) + c2*cos(2*theta))
	 *  c2 = 1/(4*sin^2(th0));
	 *  c1 = -4*c2*cos(th0);
	 *  c0 = c2*(2*cos^2(2*th0) + 1);
	 * k = 664.12/(rij*rjk)*zi*zk/(rik^5)*rij*rjk*(3*rij*rjk*(1-cos^2(th0)) - rik^2*cos(th0));
	 *
	 * Creation date: (6/08/02 jstrutz)
	 */
	public aterm() {}
	public aterm(atom a1, atom a2, atom a3) {
		myAtoms = new atom[3];
		myAtoms[0] = a1;
		myAtoms[1] = a2;
		myAtoms[2] = a3;
		setCalculationValues();
	}

	protected void buildTerm (Vector v, Vector termList)
    {
		myGroup = ((atom)v.elementAt(0)).getGroup();
		if(myGroup.needsToGetTypes()) myGroup.setTypes();
		int atom1 = ((atom)v.elementAt(0)).getUFFTypeNum();
		int atom2 = ((atom)v.elementAt(1)).getUFFTypeNum();
		int atom3 = ((atom)v.elementAt(2)).getUFFTypeNum();

		if ((atom1 < atom3) || ((atom1 == atom3)&&(((atom)v.elementAt(0)).x[0] < ((atom)v.elementAt(2)).x[0])))
		{
		    aterm t = new aterm ((atom) v.elementAt(0),
			   (atom) v.elementAt(1),
			   (atom) v.elementAt(2));
			termList.addElement(t);
		}
    }

	public double computeForces() {
		int i;
		// compute forces on each atom, add it to the atom's force vector
		double[] ab = new double[3];
		double[] bc = new double[3];
		double abdotab = 0.0, abdotbc = 0.0, bcdotbc = 0.0, th, duDth = 0.0;
		for (i = 0; i < 3; i++) {
			ab[i] = myAtoms[0].x[i] - myAtoms[1].x[i];
			bc[i] = myAtoms[2].x[i] - myAtoms[1].x[i]; // isn't this cb?
		}
		abdotab = dotProduct(ab,ab);
		abdotbc = dotProduct(ab,bc);
		bcdotbc = dotProduct(bc,bc);
		if(abdotab <= 0) abdotab = uffMinimizeAlgorythm.TINY;
		if(bcdotbc <= 0) bcdotbc = uffMinimizeAlgorythm.TINY;

//		if (abdotab > 3.0 || bcdotbc > 3.0) return 0.0; // Why?

		double jtemp1 = abdotbc/Math.sqrt(abdotab * bcdotbc);
		if(jtemp1 < -1) jtemp1 = -1;
		if(jtemp1 > 1) jtemp1 = 1;
		th = Math.acos(jtemp1);

		// now we can finish computing k
		double jtemp3 = rij*rij + rjk*rjk - 2*rij*rjk*Math.cos(th);
		if(jtemp3 <= 0) jtemp3 = uffMinimizeAlgorythm.TINY;
		double rik = Math.sqrt(jtemp3);
		k = k0/(jtemp3*jtemp3*rik)*(k1 - k2*jtemp3); // Keep in mind jtemp3 = rik^2.

		// potential and force depend on the angle, different
		// expressions are used depending on the geometry.
		potential = computePotential(th);
		duDth = computePotentialDerivative(th);

		double[] dthda = new double[3];
		double[] dthdc = new double[3];

		double jtemp2 = abdotab * bcdotbc - abdotbc*abdotbc;
		if(jtemp2 <= 0) jtemp2 = uffMinimizeAlgorythm.TINY;
		double denominator = Math.sqrt(jtemp2);
		for (i = 0; i < 3; i++)
		{
		    dthda[i] = -(ab[i] * abdotbc / abdotab - bc[i]) / denominator;
		    dthdc[i] = -(bc[i] * abdotbc / bcdotbc - ab[i]) / denominator;
		    myAtoms[0].f[i] += duDth * dthda[i];
		    myAtoms[1].f[i] += duDth * (-dthda[i] - dthdc[i]);
		    myAtoms[2].f[i] += duDth * dthdc[i];
		}
		return duDth * dthda[0];
	}

	/**
	 * Insert the method's description here.
	 * Creation date: (6/15/00 12:53:22 PM)
	 * @return double
	 * @param deltaTheta double
	 */
	protected double computePotentialDerivative(double theta) {
		if(computePotential(theta) < 0.00001) return 0;
		if(n == 0){ // general non-linear case
			double c2 = 0.25/(Math.sin(th0)*Math.sin(th0));
			double c1 = -4*c2*Math.cos(th0);
			return (-k*(c1*Math.sin(theta) + 2*c2*Math.sin(2*theta)));
		}
		// specific linear case, simplified 2 term fourier expansion
		return (k/n*(Math.sin(n*theta) - 2/n*(1 - Math.cos(n*theta))));
	}

	protected double computePotential(double theta){
	        if(n == 0){ // general non-linear case
			double c2 = 0.25/(Math.sin(th0)*Math.sin(th0));
			double c1 = -4*c2*Math.cos(th0);
			double c0 = c2*(2*Math.cos(th0)*Math.cos(th0) + 1);
			return (k*(c0 + c1*Math.cos(theta) + c2*Math.cos(2*theta)));
		}
		// specific linear case, simplified 2 term fourier expansion
		return (k/n/n*(1 - Math.cos(n*theta)));
	}

    protected String repr2()
	{
		return " angle " +
		(new Double(k)).toString() + " " +
		(new Double(th0)).toString()+ " " +
		(new Double(n)).toString();
	}

	/**
	 * Insert the method's description here.
	 * Creation date: (6/15/00 12:41:20 PM)
	 */
	protected void setCalculationValues() {
		System.out.println("Creating aterm");
		double ri=0, rj=0, rk=0;	// natural bond distance
		double xi=0, xj=0, xk=0;	// natural non-bond distance
		double zi=0, zj=0, zk=0;	// effective charge
		myGroup = myAtoms[0].getGroup();
		if(myGroup.needsToGetTypes()) myGroup.setTypes();
		int atomOneType = myAtoms[0].getUFFTypeNum();
		int atomTwoType = myAtoms[1].getUFFTypeNum();
		int atomThreeType = myAtoms[2].getUFFTypeNum();
		if ((atomOneType < 0) || (atomTwoType < 0) || (atomThreeType < 0)) {
			// Should never happen; uff has types for all atoms.
			System.out.println("ERROR: Atom types not found "+myAtoms[0].repr()+", "+myAtoms[1].repr()+", "+myAtoms[2].repr());
			return;
		}

		try {
			AtomDataFile dataFile = new AtomDataFile(newNanocad.txtDir +
					newNanocad.fileSeparator + "uffdata.txt");
			//AtomDataFile dataFile = new AtomDataFile("uffdata.txt");
			if (dataFile.findData(atomTwoType, 1)) {
				th0 = dataFile.parseDouble(3)*convert;
				rj = dataFile.parseDouble(2);
				xj = dataFile.parseDouble(4);
				zj = dataFile.parseDouble(7);
				n = dataFile.parseInt(8);
				System.out.println("th0:rj:xj:zj");
				System.out.println(th0/convert+" : "+rj+" : "+xj+" : "+zj);
			}
			else {
				// Should never happen; uff has parameters for all atoms.
				System.out.println("ERROR: Angle parameters not found for "+myAtoms[1].repr());
				return;
			}

			dataFile = new AtomDataFile(newNanocad.txtDir +
					newNanocad.fileSeparator + "uffdata.txt");
			//dataFile = new AtomDataFile("uffdata.txt");
			if (dataFile.findData(atomOneType, 1)) {
				ri = dataFile.parseDouble(2);
				xi = dataFile.parseDouble(4);
				zi = dataFile.parseDouble(7);
				System.out.println("ri:xi:zi");
				System.out.println(ri+" : "+xi+" : "+zi);
			}
			else{
				// should never happen; uff has parameters for all atoms.
				System.out.println("ERROR: Angle parameters not found for "+myAtoms[0].repr());
				return;
			}

			dataFile = new AtomDataFile(newNanocad.txtDir +
					newNanocad.fileSeparator + "uffdata.txt");
			//dataFile = new AtomDataFile("uffdata.txt");
			if (dataFile.findData(atomThreeType, 1)) {
				rk = dataFile.parseDouble(2);
				xk = dataFile.parseDouble(4);
				zk = dataFile.parseDouble(7);
				System.out.println("rk:xk:zk");
				System.out.println(rk+" : "+xk+" : "+zk);
			}
			else{
				// should never happen; uff has parameters for all atoms.
				System.out.println("ERROR: Angle parameters not found for "+myAtoms[2].repr());
				return;
			}
		}
		catch (java.io.IOException e) {
			System.err.println("Angle data lookup error");
			e.printStackTrace();
		}

		// Change the value of n so it matches the required term.
		// Linear = 1
		// Trigonal = 3
		// Square-planar = 4
		// Octahedral = 4
		// General non-linear = 0
		// Basically, these terms ensure that the energy falls to 0 when
		// theta approaches theta0 (th0 = 180, 120, 90, 90/180, respectively).
		// The general non-linear is 0 because a more descriptive, 3 term cosine
		// fourier expansion is used.
		switch(n){
			// NOTE!! This has been changed to 2, because the expression is
			// E = k/n^2 * (1 - cos(n*th)), which leads to a maximum at th = 180.
			case 1: n = 2;
				break;
			case 2: n = 3;
				break;
			case 3: n = 0;
				break;
		//	case 4: n = 4;
		//		break;
			case 5: n = 0;
				break;
			case 6: n = 4;
				break;
			default: n = 0;
				break;
		}

		// Find the ij bond order
		bond myBond1 = myAtoms[0].getBond(myAtoms[1]);
		double rbo1 = -0.1332*(ri + rj)*Math.log(myBond1.apporder());

		// Note here that x,r are > 0 for all atoms
		double temp1 = Math.sqrt(xi) - Math.sqrt(xj);
		double ren1 = ri*rj*temp1*temp1 / (xi*ri + xj*rj);
		rij = ri + rj + rbo1 + ren1;

		// Find the jk bond order
		bond myBond2 = myAtoms[2].getBond(myAtoms[1]);
		double rbo2 = -0.1332*(rk + rj)*Math.log(myBond2.apporder());

		// Note here that x,r are > 0 for all atoms
		double temp2 = Math.sqrt(xk) - Math.sqrt(xj);
		double ren2 = rk*rj*temp2*temp2 / (xk*rk + xj*rj);
		rjk = rk + rj + rbo2 + ren2;

		k0 = 664.12*zi*zk/rij/rjk;
		k1 = 3*rij*rjk*(1-Math.cos(th0)*Math.cos(th0));
		k2 = Math.cos(th0);
		//System.out.println("*************************");
		//System.out.println("Angle rij = "+rij);
		//System.out.println("Angle rjk = "+rjk);
		//System.out.println("Angle k0 = "+k0);
		//System.out.println("Angle k1 = "+k1);
		//System.out.println("Angle k2 = "+k2);
		//System.out.println("*************************");
	}

	public int termLength() { return 3; }

	public String name()
	{
		return "Angle";
	}
}


text:
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  <parent>
    <groupId>com.google.cloud</groupId>
    <artifactId>native-image-samples</artifactId>
    <version>0.14.2-SNAPSHOT</version>
  </parent>

  <modelVersion>4.0.0</modelVersion>
  <packaging>pom</packaging>

  <name>Google Cloud Native Image - Quarkus Samples</name>
  <artifactId>native-image-samples-quarkus</artifactId>

  <properties>
    <quarkus.platform.version>2.8.2.Final</quarkus.platform.version>
    <assertj-core.version>3.22.0</assertj-core.version>
  </properties>

  <modules>
    <module>quarkus-pubsub-sample</module>
    <module>quarkus-integration-test</module>
  </modules>

  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>com.google.cloud</groupId>
        <artifactId>libraries-bom</artifactId>
        <version>${libraries.bom.version}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
      <dependency>
        <groupId>io.quarkus</groupId>
        <artifactId>quarkus-universe-bom</artifactId>
        <version>${quarkus.platform.version}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
    </dependencies>
  </dependencyManagement>

</project>


text: Simple to use input class, built by Vundo


text:
import time
import random

def mergesort(mylist):
    mergehelper(mylist, 0, len(mylist))
    return mylist

def mergehelper(mylist, start, end):
    if end-start <= 1:
        return mylist

    halfway = start + (end-start)/2
    mergehelper(mylist, start, halfway)
    mergehelper(mylist, halfway, end)

    while start < halfway and halfway < end:
        if mylist[start] <= mylist[halfway]:
            start += 1
        else:
            insertpartial(mylist, mylist[halfway], start, halfway)
            start += 1
            halfway += 1

    return mylist

def insertpartial(mylist, value, index, end):
    #similar to list.insert() but works over only part of a list
    #list.insert is O(n) where n is the length of the WHOLE list
    #this only inserts over part of the list, so it's O(n) over
    #this part of the list, averaging out to O(log n) for the function
    #i think
    tempval = mylist[index]
    mylist[index] = value
    for i in range(index+1, end+1):
        value = tempval
        tempval = mylist[i]
        mylist[i] = value

if __name__ == "__main__":
    a = range(10000)
    #worst part of the algorithm is insertpartial
    #so if you never have to call that (it's in order)
    #it goes faster
    start = time.time()
    mergesort(a)
    stop = time.time()
    print "fastest: " + str(stop-start)
    #and it will be the worst when it insertpartials every time
    #so reverse order
    a.reverse()
    start = time.time()
    mergesort(a)
    stop = time.time()
    print "slowest: " + str(stop-start)


text:
import strawman.collection.mutable._

object Test {
  def main(args: Array[String]): Unit = {
    // FIXME issue loading class inheriting a type parameter
//    val sb2 = new StringBuilder2
//    println(sb2.result())
  }
}


text:
/** Coerces a data-bound value (typically a string) to a boolean. */
export function coerceBooleanProperty(value) {
    return value != null && "" + value !== 'false';
}
//# sourceMappingURL=boolean-property.js.map


text:
@implementation AppDelegate

- (BOOL)application:(UIApplication *)application
    didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {

  UITabBarController *bar = [[UITabBarController alloc] init];
  [bar setViewControllers:
      @[[[UrlGetViewController alloc] init]]];
  bar.selectedIndex = 0;
  self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
  self.window.rootViewController = bar;
  [self.window makeKeyAndVisible];
  return YES;
}

- (void)applicationWillResignActive:(UIApplication *)application {}

- (void)applicationDidEnterBackground:(UIApplication *)application {}

- (void)applicationWillEnterForeground:(UIApplication *)application {}

- (void)applicationDidBecomeActive:(UIApplication *)application {}

- (void)applicationWillTerminate:(UIApplication *)application {}

@end


text: java -cp target/lib/*:target/classes DataLocalityMember


text:
export type CustomFlagPropsType = {|
  code: String,
  size: String,
  children?: React$Element<*>
|}

export type FlagBlockPropsType = CountryType

export type AppFactoryOptionsType = {|
  useCssModules: boolean
|}

export type AppPropsType = {|
  headingText: String,
  subHeadingText: String,
  moduleVersionReactFlagIconCss: String
|}

export type KeyType = string | number

export type ObjectType = { [key: KeyType]: T }

export type GetRandomElementsReturnType = string | number | Array<string | number>


text:
module JasmineRails
  class SpecRunnerController < JasmineRails::ApplicationController
    def index
      JasmineRails.reload_jasmine_config
    end
  end
end


text:
<?php
namespace PHPAPILibrary\Core\Data;

/**
 * Interface DataInterface
 * @package PHPAPILibrary\Core\Data
 */
interface DataInterface extends \Serializable
{
    //Marker interface
}


text:
//
//  Test-MBMessageDigest.m
//  MockingbirdTests
//
//  Created by Evan Coyne Maloney on 4/14/14.
//  Copyright (c) 2014 Gilt Groupe. All rights reserved.
//

#import <XCTest/XCTest.h>

#import "MBMessageDigest.h"
#import "NSData+MBMessageDigest.h"
#import "NSString+MBMessageDigest.h"

/******************************************************************************/
#pragma mark -
#pragma mark Tests
/******************************************************************************/

@interface MBMessageDigestTests : XCTestCase
@end

@implementation MBMessageDigestTests

- (void) _testMD5String:(NSString*)toHash expectingString:(NSString*)expectedHash
{
    NSString* testOne = [toHash MD5];
    XCTAssertEqualObjects(testOne, expectedHash, @"unexpected message hash");

    NSString* testTwo = [MBMessageDigest MD5ForString:toHash];
    XCTAssertEqualObjects(testOne, testTwo, @"hashes don't match");
}

- (void) _testMD5Data:(NSData*)toHash expectingString:(NSString*)expectedHash
{
    NSString* testOne = [toHash MD5];
    XCTAssertEqualObjects(testOne, expectedHash, @"unexpected message hash");

    NSString* testTwo = [MBMessageDigest MD5ForData:toHash];
    XCTAssertEqualObjects(testOne, testTwo, @"hashes don't match");
}

- (void) _testSHA1String:(NSString*)toHash expectingString:(NSString*)expectedHash
{
    NSString* testOne = [toHash SHA1];
    XCTAssertEqualObjects(testOne, expectedHash, @"unexpected message hash");

    NSString* testTwo = [MBMessageDigest SHA1ForString:toHash];
    XCTAssertEqualObjects(testOne, testTwo, @"hashes don't match");
}

- (void) _testSHA1Data:(NSData*)toHash expectingString:(NSString*)expectedHash
{
    NSString* testOne = [toHash SHA1];
    XCTAssertEqualObjects(testOne, expectedHash, @"unexpected message hash");

    NSString* testTwo = [MBMessageDigest SHA1ForData:toHash];
    XCTAssertEqualObjects(testOne, testTwo, @"hashes don't match");
}

- (void) _testMD5String:(NSString*)toHash expectingData:(NSData*)expectedHash
{
    NSData* testHash = [MBMessageDigest MD5DataForString:toHash];
    XCTAssertEqualObjects(expectedHash, testHash, @"unexpected message hash");
}

- (void) _testSHA1String:(NSString*)toHash expectingData:(NSData*)expectedHash
{
    NSData* testHash = [MBMessageDigest SHA1DataForString:toHash];
    XCTAssertEqualObjects(expectedHash, testHash, @"unexpected message hash");
}

- (void) testHashStringToString
{
    [self _testMD5String:@"this is a test"
         expectingString:@"54b0c58c7ce9f2a8b551351102ee0938"];

    [self _testMD5String:@"this is a not a test\nbut maybe it should be\n"
         expectingString:@"a752ea5c60926f1f18419ac806969e4b"];

    [self _testSHA1String:@"this is a test"
          expectingString:@"fa26be19de6bff93f70bc2308434e4a440bbad02"];

    [self _testSHA1String:@"this is a not a test\nbut maybe it should be\n"
          expectingString:@"8d2f164edadeadace439d9069bcd4bfd69897f6d"];
}

- (void) testHashDataToString
{
    // the base64 encoding of the string "this is a test" is dGhpcyBpcyBhIHRlc3Q=
    NSData* testData1 = [[NSData alloc] initWithBase64EncodedString:@"dGhpcyBpcyBhIHRlc3Q=" options:0];

    // the base64 encoding of the string "this is a not a test\nbut maybe it should be\n"
    // is dGhpcyBpcyBhIG5vdCBhIHRlc3QKYnV0IG1heWJlIGl0IHNob3VsZCBiZQo=
    NSData* testData2 = [[NSData alloc] initWithBase64EncodedString:@"dGhpcyBpcyBhIG5vdCBhIHRlc3QKYnV0IG1heWJlIGl0IHNob3VsZCBiZQo=" options:0];

    [self _testMD5Data:testData1
       expectingString:@"54b0c58c7ce9f2a8b551351102ee0938"];

    [self _testMD5Data:testData2
       expectingString:@"a752ea5c60926f1f18419ac806969e4b"];

    [self _testSHA1Data:testData1
        expectingString:@"fa26be19de6bff93f70bc2308434e4a440bbad02"];

    [self _testSHA1Data:testData2
        expectingString:@"8d2f164edadeadace439d9069bcd4bfd69897f6d"];
}

- (void) testHashDataToData
{
    NSData* md5Data1 = [[NSData alloc] initWithBase64EncodedString:@"VLDFjHzp8qi1UTURAu4JOA==" options:0];

    NSData* md5Data2 = [[NSData alloc] initWithBase64EncodedString:@"p1LqXGCSbx8YQZrIBpaeSw==" options:0];

    NSData* sha1Data1 = [[NSData alloc] initWithBase64EncodedString:@"+ia+Gd5r/5P3C8IwhDTkpEC7rQI=" options:0];

    NSData* sha1Data2 = [[NSData alloc] initWithBase64EncodedString:@"jS8WTtrerazkOdkGm81L/WmJf20=" options:0];

    [self _testMD5String:@"this is a test"
           expectingData:md5Data1];

    [self _testMD5String:@"this is a not a test\nbut maybe it should be\n"
           expectingData:md5Data2];

    [self _testSHA1String:@"this is a test"
            expectingData:sha1Data1];

    [self _testSHA1String:@"this is a not a test\nbut maybe it should be\n"
            expectingData:sha1Data2];
}

@end


text:
module Cantina
  module Client
    VERSION = "0.0.1"
  end
end


text: This program is written according to https://brennan.io/2015/01/16/write-a-shell-in-c/.


text: Course Catalog Analytics & Visualization


text:
/* eslint-disable camelcase */
import React from 'react';
import { shallow, mount } from 'enzyme';
import { render } from 'react-dom';

import TransitionGroupWrapper from '../TransitionGroupWrapper.tsx';
import Node from '../../Node/index.tsx';
import Link from '../../Link/index.tsx';
import Tree from '../index.tsx';
import { mockData, mockData2, mockData4, mockTree_D1N2_D2N2 } from './mockData';

describe('<Tree />', () => {
  jest.spyOn(Tree.prototype, 'generateTree');
  jest.spyOn(Tree, 'assignInternalProperties');
  jest.spyOn(Tree, 'collapseNode');
  jest.spyOn(Tree, 'expandNode');
  jest.spyOn(Tree.prototype, 'setInitialTreeDepth');
  jest.spyOn(Tree.prototype, 'bindZoomListener');
  jest.spyOn(Tree.prototype, 'collapseNeighborNodes');

  // Clear method spies on prototype after each test
  afterEach(() => jest.clearAllMocks());

  it('builds a tree on each render', () => {
    const renderedComponent = shallow(<Tree data={mockData} />);
    expect(renderedComponent.instance().generateTree).toHaveBeenCalled();
  });

  it('maps every node onto a <Node />', () => {
    const nodeCount = 5; // root + 2 nodes + 2 child nodes
    const renderedComponent = shallow(<Tree data={mockData} />);

    expect(renderedComponent.find(Node).length).toBe(nodeCount);
  });

  it('maps every parent-child relation onto a <Link />', () => {
    const linkCount = 4;
    const renderedComponent = shallow(<Tree data={mockData} />);

    expect(renderedComponent.find(Link).length).toBe(linkCount);
  });

  it('maps every parent-child relation onto a <Link /> with expected siblings', () => {
    const linkCount = 5; // 1 top level node + 2 child nodes (1 child, 2 children) in mockData
    const renderedComponent = shallow(<Tree data={mockData4} />);

    expect(renderedComponent.find(Link).length).toBe(linkCount);
  });

  // Ensures D3's pan & zoom listeners can bind to multiple trees in a single view (https://github.com/bkrem/react-d3-tree/issues/100).
  it("assigns unique ref classNames to each Tree instance's `svg` and primary `g` tag", () => {
    const tree1 = shallow(<Tree data={mockData} />);
    const tree2 = shallow(<Tree data={mockData} />);
    expect(tree1.find('.rd3t-svg').prop('className')).not.toBe(
      tree2.find('.rd3t-svg').prop('className')
    );
    expect(tree1.find('.rd3t-g').prop('className')).not.toBe(
      tree2.find('.rd3t-g').prop('className')
    );
  });

  it('reassigns internal props if `props.data` changes', () => {
    // `assignInternalProperties` recurses by depth: 1 level -> 1 call
    const mockDataDepth = 3;
    const mockData2Depth = 2;
    const nextProps = {
      data: mockData2,
    };
    const renderedComponent = mount(<Tree data={mockData} />);
    expect(Tree.assignInternalProperties).toHaveBeenCalledTimes(mockDataDepth);
    renderedComponent.setProps(nextProps);
    expect(Tree.assignInternalProperties).toHaveBeenCalledTimes(mockDataDepth + mockData2Depth);
  });

  it("reassigns internal props if `props.data`'s array reference changes", () => {
    // `assignInternalProperties` recurses by depth: 1 level -> 1 call
    const mockDataDepth = 3;
    const nextDataDepth = 3;
    const nextData = [...mockData];
    nextData[0].children.push({ name: `${nextData[0].children.length}` });
    const renderedComponent = mount(<Tree data={mockData} />);
    expect(Tree.assignInternalProperties).toHaveBeenCalledTimes(mockDataDepth);
    renderedComponent.setProps({ data: nextData });
    expect(Tree.assignInternalProperties).toHaveBeenCalledTimes(mockDataDepth + nextDataDepth);
  });

  describe('translate', () => {
    it('applies the `translate` prop when specified', () => {
      const fixture = { x: 123, y: 321 };
      const expected = `translate(${fixture.x},${fixture.y})`;
      const renderedComponent = shallow(<Tree data={mockData} translate={fixture} />);
      expect(renderedComponent.find(TransitionGroupWrapper).prop('transform')).toContain(expected);
    });
  });

  describe('depthFactor', () => {
    it("mutates each node's `y` prop according to `depthFactor` when specified", () => {
      const depthFactor = 100;
      const renderedComponent = shallow(
        <Tree data={mockData} orientation="vertical" depthFactor={depthFactor} />
      );

      const { nodes } = renderedComponent.instance().generateTree(mockData);
      nodes.forEach(node => {
        expect(node.y).toBe(node.depth * depthFactor);
      });
    });
  });

  describe('orientation', () => {
    it('passes `props.orientation` to its <Node /> and <Link /> children', () => {
      const fixture = 'vertical';
      const renderedComponent = shallow(<Tree data={mockData} orientation={fixture} />);

      expect(renderedComponent.find(Node).everyWhere(n => n.prop('orientation') === fixture)).toBe(
        true
      );
      expect(renderedComponent.find(Link).everyWhere(n => n.prop('orientation') === fixture)).toBe(
        true
      );
    });
  });

  describe('collapsible', () => {
    it("collapses a node's children when it is clicked in an expanded state", () => {
      const renderedComponent = mount(<Tree data={mockData4} />);
      const nodeCount = renderedComponent.find(Node).length;
      renderedComponent
        .find(Node)
        .first()
        .find('circle')
        .simulate('click'); // collapse

      expect(Tree.collapseNode).toHaveBeenCalledTimes(nodeCount);
    });

    it("expands a node's children when it is clicked in a collapsed state", () => {
      const renderedComponent = mount(<Tree data={mockData} />);
      const nodeCount = renderedComponent.find(Node).length;
      renderedComponent
        .find(Node)
        .first()
        .find('circle')
        .simulate('click'); // collapse

      renderedComponent
        .find(Node)
        .first()
        .find('circle')
        .simulate('click'); // re-expand

      expect(Tree.collapseNode).toHaveBeenCalledTimes(nodeCount);
      expect(Tree.expandNode).toHaveBeenCalledTimes(1);
    });

    it('does not collapse a node if `props.collapsible` is false', () => {
      const renderedComponent = mount(<Tree data={mockData} collapsible={false} />);
      renderedComponent
        .find(Node)
        .first()
        .find('circle')
        .simulate('click');

      expect(Tree.collapseNode).toHaveBeenCalledTimes(0);
    });

    describe('with `props.enableLegacyTransitions`', () => {
      it('does not toggle any nodes again until `transitionDuration` has completed', () => {
        const renderedComponent = mount(<Tree data={mockData} enableLegacyTransitions />);
        const nodeCount = renderedComponent.find(Node).length;
        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('click');

        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('click');

        expect(Tree.collapseNode).toHaveBeenCalledTimes(nodeCount);
        expect(Tree.expandNode).not.toHaveBeenCalled();
      });

      it('allows toggling nodes again after `transitionDuration` + 10ms has expired', () => {
        jest.useFakeTimers();
        const renderedComponent = mount(<Tree data={mockData} enableLegacyTransitions />);
        const nodeCount = renderedComponent.find(Node).length;
        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('click');

        jest.runAllTimers();

        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('click');

        expect(Tree.collapseNode).toHaveBeenCalledTimes(nodeCount);
        expect(Tree.expandNode).toHaveBeenCalledTimes(1);
      });
    });
  });

  describe('shouldCollapseNeighborNodes', () => {
    it('is inactive by default', () => {
      const renderedComponent = mount(<Tree data={mockData} />);
      renderedComponent
        .find(Node)
        .first()
        .simulate('click'); // collapse

      renderedComponent
        .find(Node)
        .first()
        .simulate('click'); // re-expand

      expect(Tree.prototype.collapseNeighborNodes).toHaveBeenCalledTimes(0);
    });

    it('collapses all neighbor nodes of the targetNode if it is about to be expanded', () => {
      const renderedComponent = mount(<Tree data={mockData} shouldCollapseNeighborNodes />);
      renderedComponent
        .find(Node)
        .first()
        .find('circle')
        .simulate('click'); // collapse

      renderedComponent
        .find(Node)
        .first()
        .find('circle')
        .simulate('click'); // re-expand

      expect(Tree.prototype.collapseNeighborNodes).toHaveBeenCalledTimes(1);
    });
  });

  describe('initialDepth', () => {
    it('expands tree to full depth by default', () => {
      const renderedComponent = shallow(<Tree data={mockTree_D1N2_D2N2} />);
      expect(renderedComponent.find(Node).length).toBe(5);
    });

    it('expands tree to `props.initialDepth` if specified', () => {
      const renderedComponent = shallow(<Tree data={mockTree_D1N2_D2N2} initialDepth={1} />);
      expect(renderedComponent.find(Node).length).toBe(3);
    });

    it('renders only the root node if `initialDepth === 0`', () => {
      const renderedComponent = shallow(<Tree data={mockTree_D1N2_D2N2} initialDepth={0} />);
      expect(renderedComponent.find(Node).length).toBe(1);
    });

    it('increases tree depth by no more than 1 level when a node is expanded after initialising to `initialDepth`', () => {
      const renderedComponent = mount(<Tree data={mockTree_D1N2_D2N2} initialDepth={0} />);
      expect(renderedComponent.find(Node).length).toBe(1);
      renderedComponent
        .find(Node)
        .first()
        .find('circle')
        .simulate('click');
      expect(renderedComponent.find(Node).length).toBe(3);
    });
  });

  describe('zoom', () => {
    it('applies the `zoom` prop when specified', () => {
      const zoomLevel = 0.3;
      const expected = `scale(${zoomLevel})`;
      const renderedComponent = shallow(<Tree data={mockData} zoom={zoomLevel} />);
      expect(renderedComponent.find(TransitionGroupWrapper).prop('transform')).toContain(expected);
    });

    it('applies default zoom level when `zoom` is not specified', () => {
      const renderedComponent = shallow(<Tree data={mockData} />);
      expect(renderedComponent.find(TransitionGroupWrapper).prop('transform')).toContain(
        `scale(1)`
      );
    });

    it('respects `scaleExtent` constraints on initial display', () => {
      const scaleExtent = { min: 0.2, max: 0.8 };

      let renderedComponent = shallow(
        <Tree data={mockData} scaleExtent={scaleExtent} zoom={0.9} />
      );
      expect(renderedComponent.find(TransitionGroupWrapper).prop('transform')).toContain(
        `scale(${scaleExtent.max})`
      );

      renderedComponent = shallow(<Tree data={mockData} scaleExtent={scaleExtent} zoom={0.1} />);
      expect(renderedComponent.find(TransitionGroupWrapper).prop('transform')).toContain(
        `scale(${scaleExtent.min})`
      );
    });

    it('rebinds zoom handler on zoom-related props update', () => {
      const zoomProps = [
        { translate: { x: 1, y: 1 } },
        { scaleExtent: { min: 0.3, max: 0.4 } },
        { zoom: 3.1415 },
      ];
      const renderedComponent = mount(<Tree data={mockData} />);

      expect(renderedComponent.instance().bindZoomListener).toHaveBeenCalledTimes(1);

      zoomProps.forEach(nextProps => renderedComponent.setProps(nextProps));
      expect(renderedComponent.instance().bindZoomListener).toHaveBeenCalledTimes(4);
    });

    it('rebinds on `props.enableLegacyTransitions` change to handle switched DOM nodes from TransitionGroupWrapper', () => {
      const renderedComponent = mount(<Tree data={mockData} />);
      expect(renderedComponent.instance().bindZoomListener).toHaveBeenCalledTimes(1);
      renderedComponent.setProps({ enableLegacyTransitions: true });
      expect(renderedComponent.instance().bindZoomListener).toHaveBeenCalledTimes(2);
    });
  });

  describe('Event handlers', () => {
    describe('onNodeClick', () => {
      it('calls the onNodeClick callback when a node is toggled', () => {
        const onClickSpy = jest.fn();
        const renderedComponent = mount(<Tree data={mockData} onNodeClick={onClickSpy} />);

        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('click');

        expect(onClickSpy).toHaveBeenCalledTimes(1);
      });

      it('calls the onNodeClick callback even when `props.collapsible` is false', () => {
        const onClickSpy = jest.fn();
        const renderedComponent = mount(
          <Tree data={mockData} collapsible={false} onNodeClick={onClickSpy} />
        );

        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('click');

        expect(onClickSpy).toHaveBeenCalledTimes(1);
      });

      it('clones the `hierarchyPointNode` representation & passes it to the onNodeClick callback if defined', () => {
        const onClickSpy = jest.fn();
        const mockEvt = { mock: 'event' };

        const renderedComponent = mount(
          // Disable `collapsible` here to avoid side-effects on the underlying tree structure,
          // i.e. node's expanding/collapsing onClick.
          <Tree data={mockData} onNodeClick={onClickSpy} collapsible={false} />
        );

        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('click', mockEvt);

        expect(onClickSpy).toHaveBeenCalledWith(
          renderedComponent
            .find(Node)
            .first()
            .prop('hierarchyPointNode'),
          expect.objectContaining(mockEvt)
        );
      });

      it('persists the SynthethicEvent for downstream processing', () => {
        const persistSpy = jest.fn();
        const mockEvt = { mock: 'event', persist: persistSpy };
        const renderedComponent = mount(<Tree data={mockData} onNodeClick={() => {}} />);

        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('click', mockEvt);

        expect(persistSpy).toHaveBeenCalledTimes(1);
      });
    });

    describe('onNodeMouseOver', () => {
      it('calls the onNodeMouseOver callback when a node is hovered over', () => {
        const onMouseOverSpy = jest.fn();
        const renderedComponent = mount(<Tree data={mockData} onNodeMouseOver={onMouseOverSpy} />);

        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('mouseover');

        expect(onMouseOverSpy).toHaveBeenCalledTimes(1);
      });

      it('does not call the onNodeMouseOver callback if it is not a function', () => {
        const onMouseOverSpy = jest.fn();
        const renderedComponent = mount(<Tree data={mockData} onNodeMouseOver />);

        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('mouseover');

        expect(onMouseOverSpy).toHaveBeenCalledTimes(0);
      });

      it('clones the `hierarchyPointNode` representation & passes it to the onNodeMouseOver callback if defined', () => {
        const onMouseOverSpy = jest.fn();
        const mockEvt = { mock: 'event' };
        const renderedComponent = mount(<Tree data={mockData} onNodeMouseOver={onMouseOverSpy} />);

        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('mouseover', mockEvt);

        expect(onMouseOverSpy).toHaveBeenCalledWith(
          renderedComponent
            .find(Node)
            .first()
            .prop('hierarchyPointNode'),
          expect.objectContaining(mockEvt)
        );
      });

      it('persists the SynthethicEvent for downstream processing if handler is defined', () => {
        const persistSpy = jest.fn();
        const mockEvt = { mock: 'event', persist: persistSpy };
        const renderedComponent = mount(<Tree data={mockData} onNodeMouseOver={() => {}} />);

        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('mouseover', mockEvt);

        expect(persistSpy).toHaveBeenCalledTimes(1);
      });
    });

    describe('onNodeMouseOut', () => {
      it('calls the onNodeMouseOut callback when a node is hovered over', () => {
        const onMouseOutSpy = jest.fn();
        const renderedComponent = mount(<Tree data={mockData} onNodeMouseOut={onMouseOutSpy} />);

        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('mouseout');

        expect(onMouseOutSpy).toHaveBeenCalledTimes(1);
      });

      it('does not call the onNodeMouseOut callback if it is not a function', () => {
        const onMouseOutSpy = jest.fn();
        const renderedComponent = mount(<Tree data={mockData} onNodeMouseOut />);

        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('mouseout');

        expect(onMouseOutSpy).toHaveBeenCalledTimes(0);
      });

      it('clones the `hierarchyPointNode` representation & passes it to the onNodeMouseOut callback if defined', () => {
        const onMouseOutSpy = jest.fn();
        const mockEvt = { mock: 'event' };
        const renderedComponent = mount(<Tree data={mockData} onNodeMouseOut={onMouseOutSpy} />);

        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('mouseout', mockEvt);

        expect(onMouseOutSpy).toHaveBeenCalledWith(
          renderedComponent
            .find(Node)
            .first()
            .prop('hierarchyPointNode'),
          expect.objectContaining(mockEvt)
        );
      });

      it('persists the SynthethicEvent for downstream processing if handler is defined', () => {
        const persistSpy = jest.fn();
        const mockEvt = { mock: 'event', persist: persistSpy };
        const renderedComponent = mount(<Tree data={mockData} onNodeMouseOut={() => {}} />);

        renderedComponent
          .find(Node)
          .first()
          .find('circle')
          .simulate('mouseout', mockEvt);

        expect(persistSpy).toHaveBeenCalledTimes(1);
      });
    });

    describe('onLinkClick', () => {
      it('calls the onLinkClick callback when a node is toggled', () => {
        const onLinkClickSpy = jest.fn();
        const renderedComponent = mount(<Tree data={mockData2} onLinkClick={onLinkClickSpy} />);

        renderedComponent
          .find(Link)
          .first()
          .simulate('click');

        expect(onLinkClickSpy).toHaveBeenCalledTimes(1);
      });

      it('does not call the onLinkClick callback if it is not a function', () => {
        const onClickSpy = jest.fn();
        const renderedComponent = mount(<Tree data={mockData} onLinkClick />);

        renderedComponent
          .find(Link)
          .first()
          .simulate('click');

        expect(onClickSpy).toHaveBeenCalledTimes(0);
      });

      it('calls the onLinkClick callback even when `props.collapsible` is false', () => {
        const onLinkClickSpy = jest.fn();
        const renderedComponent = mount(
          <Tree data={mockData} collapsible={false} onLinkClick={onLinkClickSpy} />
        );

        renderedComponent
          .find(Link)
          .first()
          .simulate('click');

        expect(onLinkClickSpy).toHaveBeenCalledTimes(1);
      });

      it("clones the clicked link's data & passes it to the onLinkClick callback if defined", () => {
        const onLinkClickSpy = jest.fn();
        const mockEvt = { mock: 'event' };
        const renderedComponent = mount(<Tree data={mockData2} onLinkClick={onLinkClickSpy} />);

        renderedComponent
          .find(Link)
          .first()
          .simulate('click', mockEvt);

        expect(onLinkClickSpy).toHaveBeenCalledWith(
          renderedComponent
            .find(Link)
            .first()
            .prop('linkData').source,
          renderedComponent
            .find(Link)
            .first()
            .prop('linkData').target,
          expect.objectContaining(mockEvt)
        );
      });

      it('persists the SyntheticEvent for downstream processing', () => {
        const persistSpy = jest.fn();
        const mockEvt = { mock: 'event', persist: persistSpy };
        const renderedComponent = mount(<Tree data={mockData2} onLinkClick={() => {}} />);

        renderedComponent
          .find(Link)
          .first()
          .simulate('click', mockEvt);

        expect(persistSpy).toHaveBeenCalledTimes(1);
      });
    });

    describe('onLinkMouseOver', () => {
      it('calls the onLinkMouseOver callback when a node is hovered over', () => {
        const onLinkMouseOverOverSpy = jest.fn();
        const renderedComponent = mount(
          <Tree data={mockData} onLinkMouseOver={onLinkMouseOverOverSpy} />
        );

        renderedComponent
          .find(Link)
          .first()
          .simulate('mouseover');

        expect(onLinkMouseOverOverSpy).toHaveBeenCalledTimes(1);
      });

      it('does not call the onLinkMouseOver callback if it is not a function', () => {
        const onLinkMouseOverSpy = jest.fn();
        const renderedComponent = mount(<Tree data={mockData} onLinkMouseOver />);

        renderedComponent
          .find(Link)
          .first()
          .simulate('mouseover');

        expect(onLinkMouseOverSpy).toHaveBeenCalledTimes(0);
      });

      it("clones the hovered node's data & passes it to the onLinkMouseOver callback if defined", () => {
        const onLinkMouseOverOverSpy = jest.fn();
        const mockEvt = { mock: 'event' };
        const renderedComponent = mount(
          <Tree data={mockData} onLinkMouseOver={onLinkMouseOverOverSpy} />
        );

        renderedComponent
          .find(Link)
          .first()
          .simulate('mouseover', mockEvt);

        expect(onLinkMouseOverOverSpy).toHaveBeenCalledWith(
          renderedComponent
            .find(Link)
            .first()
            .prop('linkData').source,
          renderedComponent
            .find(Link)
            .first()
            .prop('linkData').target,
          expect.objectContaining(mockEvt)
        );
      });

      it('persists the SynthethicEvent for downstream processing if handler is defined', () => {
        const persistSpy = jest.fn();
        const mockEvt = { mock: 'event', persist: persistSpy };
        const renderedComponent = mount(<Tree data={mockData} onLinkMouseOver={() => {}} />);

        renderedComponent
          .find(Link)
          .first()
          .simulate('mouseover', mockEvt);

        expect(persistSpy).toHaveBeenCalledTimes(1);
      });
    });

    describe('onLinkMouseOut', () => {
      it('calls the onLinkMouseOut callback when a node is hovered over', () => {
        const onLinkMouseOutSpy = jest.fn();
        const renderedComponent = mount(
          <Tree data={mockData} onLinkMouseOut={onLinkMouseOutSpy} />
        );

        renderedComponent
          .find(Link)
          .first()
          .simulate('mouseout');

        expect(onLinkMouseOutSpy).toHaveBeenCalledTimes(1);
      });

      it('does not call the onLinkMouseOut callback if it is not a function', () => {
        const onLinkMouseOutSpy = jest.fn();
        const renderedComponent = mount(<Tree data={mockData} onLinkMouseOut />);

        renderedComponent
          .find(Link)
          .first()
          .simulate('mouseout');

        expect(onLinkMouseOutSpy).toHaveBeenCalledTimes(0);
      });

      it("clones the hovered node's data & passes it to the onNodeMouseOut callback if defined", () => {
        const onLinkMouseOutSpy = jest.fn();
        const mockEvt = { mock: 'event' };
        const renderedComponent = mount(
          <Tree data={mockData} onLinkMouseOut={onLinkMouseOutSpy} />
        );

        renderedComponent
          .find(Link)
          .first()
          .simulate('mouseout', mockEvt);

        expect(onLinkMouseOutSpy).toHaveBeenCalledWith(
          renderedComponent
            .find(Link)
            .first()
            .prop('linkData').source,
          renderedComponent
            .find(Link)
            .first()
            .prop('linkData').target,
          expect.objectContaining(mockEvt)
        );
      });

      it('persists the SynthethicEvent for downstream processing if handler is defined', () => {
        const persistSpy = jest.fn();
        const mockEvt = { mock: 'event', persist: persistSpy };
        const renderedComponent = mount(<Tree data={mockData} onLinkMouseOut={() => {}} />);

        renderedComponent
          .find(Link)
          .first()
          .simulate('mouseout', mockEvt);

        expect(persistSpy).toHaveBeenCalledTimes(1);
      });
    });

    describe('onUpdate', () => {
      it('calls `onUpdate` on node toggle', () => {
        const onUpdateSpy = jest.fn();

        const renderedComponent = mount(<Tree data={mockData} onUpdate={onUpdateSpy} />);
        renderedComponent
          .find(Node)
          .first()
          .simulate('click'); // collapse

        expect(onUpdateSpy).toHaveBeenCalledWith({
          node: expect.any(Object),
          zoom: 1,
          translate: { x: 0, y: 0 },
        });
      });

      // FIXME: cannot read property 'baseVal' of undefined.
      it.skip('calls `onUpdate` on zoom', () => {
        const onUpdateSpy = jest.fn();

        document.body.innerHTML += '<div id="reactContainer"></div>';
        render(
          <Tree
            data={mockData}
            onUpdate={onUpdateSpy}
            scaleExtent={{ min: 0.1, max: 10 }}
            zoom={1}
          />,
          document.querySelector('#reactContainer')
        );
        const scrollableComponent = document.querySelector('.rd3t-tree-container > svg');
        scrollableComponent.dispatchEvent(new Event('wheel'));
        expect(onUpdateSpy).toHaveBeenCalledTimes(1);
        expect(onUpdateSpy).toHaveBeenCalledWith({
          node: null,
          translate: { x: expect.any(Number), y: expect.any(Number) },
          zoom: expect.any(Number),
        });
      });

      it.skip('does not call `onUpdate` if not a function', () => {
        const onUpdateSpy = jest.fn();

        document.body.innerHTML += '<div id="reactContainer"></div>';
        render(
          <Tree data={mockData} onUpdate scaleExtent={{ min: 0.1, max: 10 }} />,
          document.querySelector('#reactContainer')
        );
        const scrollableComponent = document.querySelector('.rd3t-tree-container > svg');
        scrollableComponent.dispatchEvent(new Event('wheel'));
        expect(onUpdateSpy).toHaveBeenCalledTimes(0);
      });

      it('passes the specified (not default) `zoom` and `translate` when a node is clicked for the 1st time', () => {
        const onUpdateSpy = jest.fn();
        const zoom = 0.7;
        const translate = { x: 10, y: 5 };

        const renderedComponent = mount(
          <Tree data={mockData} zoom={zoom} translate={translate} onUpdate={onUpdateSpy} />
        );
        renderedComponent
          .find(Node)
          .first()
          .simulate('click');

        expect(onUpdateSpy).toHaveBeenCalledWith({
          node: expect.any(Object),
          translate,
          zoom,
        });
      });
    });
  });
});


text:
@interface TableViewSwitchItem : TableViewItem
// The filename for the leading icon.  If empty, no icon will be shown.
@property(nonatomic, copy) NSString* iconImageName;

// The text to display.
@property(nonatomic, copy) NSString* text;

// The detail text string.
@property(nonatomic, copy) NSString* detailText;

// The current state of the switch.
@property(nonatomic, assign, getter=isOn) BOOL on;

// Whether or not the switch is enabled.  Disabled switches are automatically
// drawn as in the "off" state, with dimmed text.
@property(nonatomic, assign, getter=isEnabled) BOOL enabled;

@end

#endif  // IOS_CHROME_BROWSER_UI_TABLE_VIEW_CELLS_TABLE_VIEW_SWITCH_ITEM_H_


text:
import { Injectable } from '@angular/core';
import { Resolve, ActivatedRouteSnapshot, RouterStateSnapshot, Router } from '@angular/router';

import { Observable } from 'rxjs/Observable';
import 'rxjs/add/operator/catch';
import 'rxjs/add/operator/map';
import 'rxjs/add/observable/of';

import { SriVidyaService } from './srividya.service';
import { SvcAnswer } from './svcanswer';

@Injectable()
export class SriVidyaResolver implements Resolve<SvcAnswer>
{
    constructor(private srividyaService: SriVidyaService,
        private router: Router) {}
    resolve(route: ActivatedRouteSnapshot, state: RouterStateSnapshot): Observable<SvcAnswer>
    {
        let id = route.params['id'];
        if (isNaN(+id)) {
            console.log(`Product id was not a number: ${id}`);
            this.router.navigate(['/products']);
            return Observable.of(null);
        }
        return this.srividyaService.getProduct(+id)
            .map(product => {
                if (product) {
                    return product;
                }
                console.log(`Product was not found: ${id}`);
                this.router.navigate(['/products']);
                return null;
            })
            .catch(error => {
                console.log(`Retrieval error: ${error}`);
                this.router.navigate(['/products']);
                return Observable.of(null);
            });
    }
}


text:
Serwer baz danych PostgreSQL

PostgreSQL jest prostym serwerem baz danych dla systemów uniksowych.
<<<<<<< HEAD
Obs³uguje on wiele baz danych, wiele typów danych, wiêkszo¶æ standardowej
sk³adni jêzyka SQL i posiada potê¿n± kontrolê dostêpu. Ka¿da
z zarz±dzanych przez serwer baz danych mo¿e zawieraæ wiele tabel,
a ka¿da tabela wiele wierszy danych.

W górnej czê¶ci strony g³ownej znajduje siê lista ikon odpowiadaj±cych
poszczególnym bazom danych, a pod ni± odsy³acz do dodania nowej bazy.
Ka¿dy serwer PostgreSQLa bêdzie posiada³ przynajmniej jedn± wzorcow± bazê
danych, zazwyczaj o nazwie <tt>template1</tt>. Pod bazami danych
znajduj± siê ikony do konfiguracji kontroli dostêpu i uprawnieñ, za¶ na
samym dole umieszczony jest przycisk zatrzymuj±cy b±d¼ uruchamiaj±cy serwer
=======
Obsługuje on wiele baz danych, wiele typów danych, większość standardowej
składni języka SQL i posiada potężną kontrolę dostępu. Każda
z zarządzanych przez serwer baz danych może zawierać wiele tabel,
a każda tabela wiele wierszy danych.

W górnej części strony głownej znajduje się lista ikon odpowiadających
poszczególnym bazom danych, a pod nią odsyłacz do dodania nowej bazy.
Każdy serwer PostgreSQLa będzie posiadał przynajmniej jedną wzorcową bazę
danych, zazwyczaj o nazwie <tt>template1</tt>. Pod bazami danych
znajdują się ikony do konfiguracji kontroli dostępu i uprawnień, zaś na
samym dole umieszczony jest przycisk zatrzymujący bądź uruchamiający serwer
>>>>>>> upstream/master
baz danych.


text:
jQuery( document ).ready( function () {

	//process tooltip actions
	jQuery( '#itsec_go_to_logs, #itsec_dismiss_file_change_warning' ).click( function ( event ) {

		event.preventDefault();

		var button = this.value;

		var data = {
			action: 'itsec_file_change_warning_ajax',
			nonce: itsec_file_change_warning.nonce
		};

		//call the ajax
		jQuery.post( ajaxurl, data, function () {

			jQuery( '#itsec_file_change_warning_dialog' ).remove();

			if ( button == 'View Logs' ) {
				window.location.replace( itsec_file_change_warning.url )
			}

		} );

	} );

} );


text:
<?php

namespace Google\Service\Monitoring;

class ListGroupMembersResponse extends \Google\Collection
{
  protected $collection_key = 'members';
  protected $membersType = MonitoredResource::class;
  protected $membersDataType = 'array';
  /**
   * @var string
   */
  public $nextPageToken;
  /**
   * @var int
   */
  public $totalSize;

  /**
   * @param MonitoredResource[]
   */
  public function setMembers($members)
  {
    $this->members = $members;
  }
  /**
   * @return MonitoredResource[]
   */
  public function getMembers()
  {
    return $this->members;
  }
  /**
   * @param string
   */
  public function setNextPageToken($nextPageToken)
  {
    $this->nextPageToken = $nextPageToken;
  }
  /**
   * @return string
   */
  public function getNextPageToken()
  {
    return $this->nextPageToken;
  }
  /**
   * @param int
   */
  public function setTotalSize($totalSize)
  {
    $this->totalSize = $totalSize;
  }
  /**
   * @return int
   */
  public function getTotalSize()
  {
    return $this->totalSize;
  }
}

// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListGroupMembersResponse::class, 'Google_Service_Monitoring_ListGroupMembersResponse');


text:
@interface YHCollectionViewCell()
@property (weak, nonatomic) IBOutlet UIImageView *imageView;
@property (weak, nonatomic) IBOutlet UILabel *title;

@end
@implementation YHCollectionViewCell

- (void)awakeFromNib {
    [super awakeFromNib];

}
-(void)setPhoto:(YHPhoto *)photo{
    _photo = photo;
    UIImage *image = [[SDImageCache sharedImageCache] imageFromDiskCacheForKey:photo.small_url];
    if (image) {
        [_imageView setImage:image];
    }else{
        NSURL *url = [NSURL URLWithString:photo.small_url];
        [_imageView sd_setImageWithURL:url placeholderImage:[UIImage imageNamed:@"placeholder.jpg"]];
    }
    _title.text = photo.title;
    [_title sizeToFit];
}
@end


text:
class DataBase
{
public:
    DataBase();
    bool openDataBase(const QString &name, const QString &type,
                      const QString &connectionName = "defaultConnection");

    virtual void createTable();
    void closeDataBase();

private:
    QSqlDatabase db;
};

#endif // DATABASE1_H


text:
class SyncRel
  attr_reader :rel_key
  attr_reader :props

  def initialize(node, sync_props)
    @node = node
    @sp = sync_props
    @rel_key = nil
    @props = {}
  end

  def add_row(row)
    @rel_key = row[@sp.rel_index]
    @sp.rel_props.each do |prop|
      new_val = row[@sp.rel_prop_index[prop]]
      check_for_conflict(prop, new_val)
      @props[prop] = new_val
    end
  end

  def check_for_conflict(prop, new_val)
    return unless @props.key?(prop)
    return if @props[prop] == new_val

    raise SyncDataConflictError.rel_prop_mismatch(@node,
                                                  self,
                                                  prop,
                                                  @props[prop],
                                                  new_val)
  end

  # Look for properties that differ between this relationship and a serialized
  # relationship we are trying to match. If we find any, return true, and set
  # last_synced if necessary.
  def flag_prop_changes(ser_rel)
    changes = ''
    @sp.rel_props.each do |prop|
      next unless @props[prop] != ser_rel[prop.to_s]

      changes += "#{@node.klass_name} '#{@node.id}': #{prop} of " \
                 "relationship to #{rel_node_klass} '#{rel_key}' changed " \
                 "from '#{@props[prop]}' to '#{ser_rel[prop.to_s]}'"
      ser_rel['last_synced'] = @sp.timestamp if @sp.timestamp_rel
    end
    changes
  end

  # Create a serialized version of this relationship. If auto_timestamp is true,
  # and the relationship has a last_synced property, it gets timestamped (used
  # when creating new nodes).
  def serialize(auto_timestamp)
    ser = {}
    ser['last_synced'] = @sp.timestamp if auto_timestamp && @sp.timestamp_rel
    @sp.rel_props.each do |prop|
      ser[prop.to_s] = @props[prop]
    end
    ser
  end

  # Convenience method.
  def rel_node_klass; @sp.rel_node_klass.name.downcase; end
end


text:
PLEASE NOTE: This document applies to the HEAD of the source tree

If you are using a released version of Kubernetes, you should
refer to the docs that go with that version.

The latest release of this document can be found
[here](http://releases.k8s.io/release-1.1/docs/getting-started-guides/docker-multinode/master.md).

Documentation for other releases can be found at
[releases.k8s.io](http://releases.k8s.io).

--

## Installing a Kubernetes Master Node via Docker

We'll begin by setting up the master node.  For the purposes of illustration, we'll assume that the IP of this machine
is `${MASTER_IP}`.  We'll need to run several versioned Kubernetes components, so we'll assume that the version we want
to run is `${K8S_VERSION}`, which should hold a released version of Kubernetes >= "1.2.0-alpha.6"

Enviroinment variables used:

```sh
export MASTER_IP=<the_master_ip_here>
export K8S_VERSION=<your_k8s_version (e.g. 1.2.0-alpha.6)>
export ETCD_VERSION=<your_etcd_version (e.g. 2.2.1)>
export FLANNEL_VERSION=<your_flannel_version (e.g. 0.5.5)>
export FLANNEL_IFACE=<flannel_interface (defaults to eth0)>
```

There are two main phases to installing the master:
   * [Setting up `flanneld` and `etcd`](#setting-up-flanneld-and-etcd)
   * [Starting the Kubernetes master components](#starting-the-kubernetes-master)

## Setting up flanneld and etcd

_Note_:
This guide expects **Docker 1.7.1 or higher**.

### Setup Docker Bootstrap

We're going to use `flannel` to set up networking between Docker daemons.  Flannel itself (and etcd on which it relies) will run inside of
Docker containers themselves.  To achieve this, we need a separate "bootstrap" instance of the Docker daemon.  This daemon will be started with
`--iptables=false` so that it can only run containers with `--net=host`.  That's sufficient to bootstrap our system.

Run:

```sh
sudo sh -c 'docker -d -H unix:///var/run/docker-bootstrap.sock -p /var/run/docker-bootstrap.pid --iptables=false --ip-masq=false --bridge=none --graph=/var/lib/docker-bootstrap 2> /var/log/docker-bootstrap.log 1> /dev/null &'
```

_Important Note_:
If you are running this on a long running system, rather than experimenting, you should run the bootstrap Docker instance under something like SysV init, upstart or systemd so that it is restarted
across reboots and failures.

### Startup etcd for flannel and the API server to use

Run:

```sh
sudo docker -H unix:///var/run/docker-bootstrap.sock run -d \
    --net=host \
    gcr.io/google_containers/etcd:${ETCD_VERSION} \
    /usr/local/bin/etcd \
        --listen-client-urls=http://127.0.0.1:4001,http://${MASTER_IP}:4001 \
        --advertise-client-urls=http://${MASTER_IP}:4001 \
        --data-dir=/var/etcd/data
```

Next, you need to set a CIDR range for flannel.  This CIDR should be chosen to be non-overlapping with any existing network you are using:

```sh
sudo docker -H unix:///var/run/docker-bootstrap.sock run \
    --net=host \
    gcr.io/google_containers/etcd:${ETCD_VERSION} \
    etcdctl set /coreos.com/network/config '{ "Network": "10.1.0.0/16" }'
```

### Set up Flannel on the master node

Flannel is a network abstraction layer build by CoreOS, we will use it to provide simplified networking between our Pods of containers.

Flannel re-configures the bridge that Docker uses for networking.  As a result we need to stop Docker, reconfigure its networking, and then restart Docker.

#### Bring down Docker

To re-configure Docker to use flannel, we need to take docker down, run flannel and then restart Docker.

Turning down Docker is system dependent, it may be:

```sh
sudo /etc/init.d/docker stop
```

or

```sh
sudo systemctl stop docker
```

or

```sh
sudo service docker stop
```

or it may be something else.

#### Run flannel

Now run flanneld itself:

```sh
sudo docker -H unix:///var/run/docker-bootstrap.sock run -d \
    --net=host \
    --privileged \
    -v /dev/net:/dev/net \
    quay.io/coreos/flannel:${FLANNEL_VERSION} \
        --ip-masq \
        --iface=${FLANNEL_IFACE}
```

The previous command should have printed a really long hash, the container id, copy this hash.

Now get the subnet settings from flannel:

```sh
sudo docker -H unix:///var/run/docker-bootstrap.sock exec <really-long-hash-from-above-here> cat /run/flannel/subnet.env
```

#### Edit the docker configuration

You now need to edit the docker configuration to activate new flags.  Again, this is system specific.

This may be in `/etc/default/docker` or `/etc/systemd/service/docker.service` or it may be elsewhere.

Regardless, you need to add the following to the docker command line:

```sh
--bip=${FLANNEL_SUBNET} --mtu=${FLANNEL_MTU}
```

#### Remove the existing Docker bridge

Docker creates a bridge named `docker0` by default.  You need to remove this:

```sh
sudo /sbin/ifconfig docker0 down
sudo brctl delbr docker0
```

You may need to install the `bridge-utils` package for the `brctl` binary.

#### Restart Docker

Again this is system dependent, it may be:

```sh
sudo /etc/init.d/docker start
```

it may be:

```sh
systemctl start docker
```

## Starting the Kubernetes Master

Ok, now that your networking is set up, you can startup Kubernetes, this is the same as the single-node case, we will use the "main" instance of the Docker daemon for the Kubernetes components.

```sh
sudo docker run \
    --volume=/:/rootfs:ro \
    --volume=/sys:/sys:ro \
    --volume=/dev:/dev \
    --volume=/var/lib/docker/:/var/lib/docker:rw \
    --volume=/var/lib/kubelet/:/var/lib/kubelet:rw \
    --volume=/var/run:/var/run:rw \
    --net=host \
    --privileged=true \
    --pid=host \
    -d \
    gcr.io/google_containers/hyperkube-amd64:v${K8S_VERSION} \
    /hyperkube kubelet \
        --allow-privileged=true \
        --api-servers=http://localhost:8080 \
        --v=2 \
        --address=0.0.0.0 \
        --enable-server \
        --hostname-override=127.0.0.1 \
        --config=/etc/kubernetes/manifests-multi \
        --containerized \
        --cluster-dns=10.0.0.10 \
        --cluster-domain=cluster.local
```

> Note that `--cluster-dns` and `--cluster-domain` is used to deploy dns, feel free to discard them if dns is not needed.

### Test it out

At this point, you should have a functioning 1-node cluster.  Let's test it out!

Download the kubectl binary for `${K8S_VERSION}` (look at the URL in the following links) and make it available by editing your PATH environment variable.
([OS X/amd64](http://storage.googleapis.com/kubernetes-release/release/v1.2.0-alpha.6/bin/darwin/amd64/kubectl))
([OS X/386](http://storage.googleapis.com/kubernetes-release/release/v1.2.0-alpha.6/bin/darwin/386/kubectl))
([linux/amd64](http://storage.googleapis.com/kubernetes-release/release/v1.2.0-alpha.6/bin/linux/amd64/kubectl))
([linux/386](http://storage.googleapis.com/kubernetes-release/release/v1.2.0-alpha.6/bin/linux/386/kubectl))
([linux/arm](http://storage.googleapis.com/kubernetes-release/release/v1.2.0-alpha.6/bin/linux/arm/kubectl))

For example, OS X:

```console
$ wget http://storage.googleapis.com/kubernetes-release/release/v${K8S_VERSION}/bin/darwin/amd64/kubectl
$ chmod 755 kubectl
$ PATH=$PATH:`pwd`
```

Linux:

```console
$ wget http://storage.googleapis.com/kubernetes-release/release/v${K8S_VERSION}/bin/linux/amd64/kubectl
$ chmod 755 kubectl
$ PATH=$PATH:`pwd`
```

Now you can list the nodes:

```sh
kubectl get nodes
```

This should print something like:

```console
NAME        LABELS                             STATUS
127.0.0.1   kubernetes.io/hostname=127.0.0.1   Ready
```

If the status of the node is `NotReady` or `Unknown` please check that all of the containers you created are successfully running.
If all else fails, ask questions on [Slack](../../troubleshooting.md#slack).

### Next steps

Move on to [adding one or more workers](worker.md) or [deploy a dns](deployDNS.md)

[![Analytics](https://kubernetes-site.appspot.com/UA-36037335-10/GitHub/docs/getting-started-guides/docker-multinode/master.md?pixel)]()


text:
//------------------------------------------------------------------------------
// <auto-generated>
//     This code was generated by a tool.
//     Runtime Version:2.0.50727.5446
//
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------

namespace ConsultaAmbulatoria.UserControls {

    public partial class Medicamento {

        /// <summary>
        /// txtAutomed control.
        /// </summary>
        /// <remarks>
        /// Auto-generated field.
        /// To modify move field declaration from designer file to code-behind file.
        /// </remarks>
        protected global::System.Web.UI.WebControls.TextBox txtAutomed;

        /// <summary>
        /// idMedicamento control.
        /// </summary>
        /// <remarks>
        /// Auto-generated field.
        /// To modify move field declaration from designer file to code-behind file.
        /// </remarks>
        protected global::System.Web.UI.WebControls.HiddenField idMedicamento;

        /// <summary>
        /// lblDescripcion control.
        /// </summary>
        /// <remarks>
        /// Auto-generated field.
        /// To modify move field declaration from designer file to code-behind file.
        /// </remarks>
        protected global::System.Web.UI.WebControls.Label lblDescripcion;

        /// <summary>
        /// lblRubro control.
        /// </summary>
        /// <remarks>
        /// Auto-generated field.
        /// To modify move field declaration from designer file to code-behind file.
        /// </remarks>
        protected global::System.Web.UI.WebControls.Label lblRubro;

        /// <summary>
        /// idMedicamentos control.
        /// </summary>
        /// <remarks>
        /// Auto-generated field.
        /// To modify move field declaration from designer file to code-behind file.
        /// </remarks>
        protected global::System.Web.UI.WebControls.HiddenField idMedicamentos;
    }
}


text:
Meteor.methods({
    addConference: function(code) {
        if (Conferences.findOne({code: code})) {
            return Conferences.findOne({
                code: code
            })["_id"];
        } else {
            return Conferences.insert({
                code: code,
                created: new Date()
            });
        }
    },

    addPost: function(post, code) {
        return Posts.insert({
            content: post,
            code: code,
            created: new Date(),
            votes: 0
        });
    },

    upvote: function(post) {
        Posts.update(post, {$inc: {votes: 1}});
    },

    downvote: function(post) {
        Posts.update(post, {$inc: {votes: -1}});
    }
});


text:
using System;
using MonoTouch.Foundation;
using MonoTouch.UIKit;
using Xamarin.QuickUI;
using QuickDemo;

[assembly: ExportCell (typeof (StarCell), typeof (StarCellRenderer))]

namespace QuickDemo {

	[Register ("AppDelegate")]
	public partial class AppDelegate : UIApplicationDelegate {

		public override UIWindow Window { get; set; }

		public override bool FinishedLaunching (UIApplication application, NSDictionary launchOptions)
		{
			Window = new UIWindow (UIScreen.MainScreen.Bounds);
			QuickUI.Init ();
			Window.RootViewController = CatalogPage.GetMainPage ().GetViewController ();
			Window.MakeKeyAndVisible ();
			return true;
		}

		static void Main (string[] args)
		{
			UIApplication.Main (args, null, "AppDelegate");
		}
	}
}


text:
ACCEPTED

#### According to
The Catalogue of Life, 3rd January 2011

#### Published in
Parasit. Alg. Pilze Java's (Jakarta) 2: (1900)

#### Original name
Balladyna gardeniae Racib., 1900

### Remarks
null


text:
class jfTextBoxController {
	/* @ngInject */
    constructor($scope, $element, $timeout, $interval, $compile, $q, JfFullTextService) {
        this.$scope = $scope;
        this.$compile = $compile;
        this.$timeout = $timeout;
        this.$interval = $interval;
        this.$element = $element;
        this.fullTextModal = JfFullTextService;
        this.$q = $q;
    }

    $onInit() {

        this.seeAllText = this.seeAllText || '(Show All ...)';

        this.fullTextElement.text(this.text)
        this.registerResize();
        this.$timeout(() => this.refreshText());

        this.$scope.$on('$destroy', () => {
            this.deregisterResize();
        })
    }

    registerResize() {

        let appliedRefresh = () => {
            this.$scope.$apply(() => {
                this.refreshText();
            })
        }
        let debouncedRefresh = _.debounce(appliedRefresh, 0, {leading: true});
//        let throttledRefresh = _.throttle(appliedRefresh, 150, {/*leading: false*/})

        this.onResize = debouncedRefresh;

        $(window).on('resize', this.onResize)
    }

    deregisterResize() {
        $(window).off('resize', this.onResize)
    }

    get containerElement() {
        if (!this.cachedContainerElement) {
            this.cachedContainerElement = $(this.$element).find('.jf-text-box-container');
        }
        return this.cachedContainerElement;
    }

    get fullTextElement() {
        if (!this.cachedFullTextElement) {
            this.cachedFullTextElement = $(this.$element).find('.jf-text-box-content-full')
        }
        return this.cachedFullTextElement;
    }

    get currentTextElement() {
        if (!this.cachedCurrentTextElement) {
            this.cachedCurrentTextElement = $(this.$element).find('.jf-text-box-content-current')
        }
        return this.cachedCurrentTextElement;
    }

    get stageElement() {
        if (!this.cachedStageElement) {
            this.cachedStageElement = $(this.$element).find('.jf-text-box-content-stage')
        }
        return this.cachedStageElement;
    }

    get containerHeight() {
        return this.containerElement.height();
    }

    get containerWidth() {
        return this.containerElement.width();
    }

    get numOfWholeRows() {
        let auto = Math.floor(this.containerHeight / this.lineHeight + 0.1);
        return this.maxLines ? Math.min(parseInt(this.maxLines), auto) : auto;
    }

    get numOfActualRows() {
        let contentHeight = this.fullTextElement.height();
        return Math.ceil(contentHeight / this.lineHeight - 0.1);
    }

    get numOfVisibleRows() {
        let contentHeight = this.currentTextElement.height();
        return Math.ceil(contentHeight / this.lineHeight - 0.1);
    }

    get numOfStageRows() {
        let contentHeight = this.stageElement.height();
        return Math.ceil(contentHeight / this.lineHeight - 0.1);
    }

    get isOverflowing() {
        return this.numOfActualRows > this.numOfWholeRows;
    }

    setStageText(text) {
        this.stageElement.text(text);
    }

    refreshText() {
        this.measureLineHeight();

        if (!this.isOverflowing) {
            this.content = this.text;
        }
        else {
            this.stageElement.html('');
            let words = this.splitText(this.text);
            let i = 1;
            let getNumOfLinesUntil = (index, withSeeAll = true) => {
                this.setStageText(_.trimRight(words.slice(0, index).join('')) + (withSeeAll ? ' ' : ''))
                if (withSeeAll) this.stageElement.append($(`  <div class="jf-text-box-show-all">${this.seeAllText}</div>`));
                return this.numOfStageRows;
            }
            while (getNumOfLinesUntil(i) <= this.numOfWholeRows && i <= words.length) {
                i++;
            }

            if (getNumOfLinesUntil(i, false) !== getNumOfLinesUntil(i)) {
                this.wrapSeeAll = true;
            }
            else this.wrapSeeAll = false;
            /*
                        let saved = i;
                        i--;
                        while (getNumOfLinesUntil(i, false) !== getNumOfLinesUntil(i) && i > 0) {
                            console.log('?');
                            i--;
                        }

                        if  (i === 0) {
                            i = saved;
                            this.wrapSeeAll = true;
                        }
                        else this.wrapSeeAll = false;
            */

            let fit = words.slice(0, i);

            this.setStageText(_.trimRight(fit.join('')) + (this.isOverflowing ? ' ' : ''));
            if (this.isOverflowing) this.stageElement.append($(`<div class="jf-text-box-show-all">${this.seeAllText}</div>`));

            let m = 0;
            while (this.numOfStageRows > this.numOfWholeRows && i > m) {
                m++;

                fit = words.slice(0, i - m);
                this.setStageText(_.trimRight(fit.join('')) + (this.isOverflowing ? ' ' : ''));
                if (this.isOverflowing) this.stageElement.append($(`<div class="jf-text-box-show-all">${this.seeAllText}</div>`));
            }
            this.content = _.trimRight(fit.join(''));

        }
        this.ready = true;
    }

    splitText(text) {

        if (this.splitCache) return this.splitCache;
        else {
            let regex = /\s+/g;
            let parts = [];
            let match = regex.exec(text);
            let lastIndex = 0;
            while (match) {
                parts.push(text.substr(lastIndex, match.index - lastIndex) + match[0]);
                lastIndex = match.index + match[0].length;
                match = regex.exec(text);
            }
            parts.push(text.substr(lastIndex, text.length - lastIndex));

            parts = _.map(parts, part => {
                if (part.length > 16) return part.split('');
                else return part;
            })

            parts = _.flatten(parts);

            this.splitCache = parts;
            return parts;
        }

    }

    measureLineHeight() {
        this.stageElement.text('*');
        this.lineHeight = this.stageElement.height();
        if (this.maxLines) {
            this.containerElement.height(parseInt(this.maxLines) * this.lineHeight);
        }
    }

    seeAll() {
        if (this.noAction) return;
        let text = this.text;
        if (this.customAction) {
            this.customAction({text})
        }
        else {
            this.fullTextModal.showFullTextModal(text, this.modalTitle || 'Full Text', 500, false, null, 'text-box-show-all-modal');
            this.deregisterResize();
            this.fullTextModal.modalInstance.result.finally(() => {
                this.$timeout(() => this.registerResize());
            })
        }
    }

}

export function jfTextBox() {
    return {
        restrict: 'E',
        scope: {
            text: '=',
            numOfLines: '@',
            modalTitle: '@?',
            seeAllText: '@?',
            maxLines: '@?',
            customAction: '&?',
            noAction: '@?'
        },
        controller: jfTextBoxController,
        controllerAs: 'jfTextBox',
        bindToController: true,
        templateUrl: 'directives/jf_text_box/jf_text_box.html'
    }
}


text:
FOUNDATION_EXPORT double Pods_DZAUnsafeMutableArray_TestsVersionNumber;
FOUNDATION_EXPORT const unsigned char Pods_DZAUnsafeMutableArray_TestsVersionString[];


text:
import * as application from "tns-core-modules/application";

application.run({moduleName: "main-page"});