text:
using System.Collections.Generic;
using System.Linq;
using BoardGamesNook.Model;
using BoardGamesNook.Repository.Interfaces;
using BoardGamesNook.Services;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using Moq;

namespace BoardGamesNook.Tests
{
    [TestClass]
    public class BoardGameServiceTest
    {
        private readonly Mock<IBoardGameRepository> _boardGameRepositoryMock;

        private readonly BoardGame _testBoardGame = new BoardGame
        {
            Id = 1,
            Name = "test"
        };

        public BoardGameServiceTest()
        {
            _boardGameRepositoryMock = new Mock<IBoardGameRepository>();
        }

        [TestMethod]
        public void GetBoardGameList()
        {
            //Arrange
            _boardGameRepositoryMock.Setup(mock => mock.GetAll()).Returns(new List<BoardGame> {new BoardGame()});
            var boardGameService = new BoardGameService(_boardGameRepositoryMock.Object);

            //Act
            var boardGames = boardGameService.GetAll();

            //Assert
            Assert.AreEqual(1, boardGames.Count());
            _boardGameRepositoryMock.Verify(mock => mock.GetAll(), Times.Once());
        }

        [TestMethod]
        public void AddBoardGameToBoardGamesList()
        {
            //Arrange
            _boardGameRepositoryMock.Setup(mock => mock.Add(It.IsAny<BoardGame>()));
            var boardGameService = new BoardGameService(_boardGameRepositoryMock.Object);
            //Act
            boardGameService.Add(_testBoardGame);
            //Assert
            _boardGameRepositoryMock.Verify(mock => mock.Add(It.Is<BoardGame>(i => i.Equals(_testBoardGame))),
                Times.Once);
        }

        [TestMethod]
        public void GetBoardGame()
        {
            //Arrange
            _boardGameRepositoryMock.Setup(mock => mock.Get(It.IsAny<int>()));
            var boardGameService = new BoardGameService(_boardGameRepositoryMock.Object);
            //Act
            boardGameService.Get(_testBoardGame.Id);
            //Assert
            _boardGameRepositoryMock.Verify(mock => mock.Get(_testBoardGame.Id), Times.Once());
        }

        [TestMethod]
        public void EditBoardGame()
        {
            //Arrange
            _boardGameRepositoryMock.Setup(mock => mock.Edit(It.IsAny<BoardGame>()));
            var boardGameService = new BoardGameService(_boardGameRepositoryMock.Object);

            //Act
            boardGameService.Edit(_testBoardGame);
            //Assert
            _boardGameRepositoryMock.Verify(mock => mock.Edit(It.Is<BoardGame>(x => x.Equals(_testBoardGame))),
                Times.Once());
        }

        [TestMethod]
        public void DeactivateBoardGame()
        {
            //Arrange
            _boardGameRepositoryMock.Setup(mock => mock.Deactivate(It.IsAny<int>()));
            var boardGameService = new BoardGameService(_boardGameRepositoryMock.Object);
            //Act
            boardGameService.DeactivateBoardGame(_testBoardGame.Id);
            //Assert
            _boardGameRepositoryMock.Verify(mock => mock.Deactivate(It.Is<int>(x => x.Equals(_testBoardGame.Id))),
                Times.Once());
        }
    }
}


text:
#include "SkCanvas.h"
#include "SkDrawLooper.h"
#include "Test.h"

/*
 *  Subclass of looper that just draws once, with an offset in X.
 */
class TestLooper : public SkDrawLooper {
public:
    bool fOnce;

    virtual void init(SkCanvas*) SK_OVERRIDE {
        fOnce = true;
    }

    virtual bool next(SkCanvas* canvas, SkPaint*) SK_OVERRIDE {
        if (fOnce) {
            fOnce = false;
            canvas->translate(SkIntToScalar(10), 0);
            return true;
        }
        return false;
    }

    SK_DECLARE_UNFLATTENABLE_OBJECT()
};

static void test_drawBitmap(skiatest::Reporter* reporter) {
    SkBitmap src;
    src.setConfig(SkBitmap::kARGB_8888_Config, 10, 10);
    src.allocPixels();
    src.eraseColor(SK_ColorWHITE);

    SkBitmap dst;
    dst.setConfig(SkBitmap::kARGB_8888_Config, 10, 10);
    dst.allocPixels();
    dst.eraseColor(SK_ColorTRANSPARENT);

    SkCanvas canvas(dst);
    SkPaint  paint;

    // we are initially transparent
    REPORTER_ASSERT(reporter, 0 == *dst.getAddr32(5, 5));

    // we see the bitmap drawn
    canvas.drawBitmap(src, 0, 0, &paint);
    REPORTER_ASSERT(reporter, 0xFFFFFFFF == *dst.getAddr32(5, 5));

    // reverify we are clear again
    dst.eraseColor(SK_ColorTRANSPARENT);
    REPORTER_ASSERT(reporter, 0 == *dst.getAddr32(5, 5));

    // if the bitmap is clipped out, we don't draw it
    canvas.drawBitmap(src, SkIntToScalar(-10), 0, &paint);
    REPORTER_ASSERT(reporter, 0 == *dst.getAddr32(5, 5));

    // now install our looper, which will draw, since it internally translates
    // to the left. The test is to ensure that canvas' quickReject machinary
    // allows us through, even though sans-looper we would look like we should
    // be clipped out.
    paint.setLooper(new TestLooper)->unref();
    canvas.drawBitmap(src, SkIntToScalar(-10), 0, &paint);
    REPORTER_ASSERT(reporter, 0xFFFFFFFF == *dst.getAddr32(5, 5));
}

static void test(skiatest::Reporter* reporter) {
    test_drawBitmap(reporter);
}

#include "TestClassDef.h"
DEFINE_TESTCLASS("QuickReject", QuickRejectClass, test)

redpajama_set_name: RedPajamaGithub


text:
package io.quarkus.it.rest.client;

import org.junit.jupiter.api.Order;
import org.junit.jupiter.api.Test;

import io.quarkus.test.junit.QuarkusTest;
import io.restassured.RestAssured;

@QuarkusTest
@Order(200) // used in order to make sure this is run after InjectMockTest
public class ShouldNotUseMockTest {

    @Test
    void shouldMockClientInTheApp() {
        RestAssured.with().post("/call-cdi-client-with-exception-mapper")
                .then()
                .statusCode(200);
    }
}


text:
"""
MySQL database backend for Django.

Requires MySQLdb: http://sourceforge.net/projects/mysql-python
"""

from django.db.backends import BaseDatabaseWrapper, BaseDatabaseFeatures, BaseDatabaseOperations, util
from django.utils.encoding import force_unicode
try:
    import MySQLdb as Database
except ImportError, e:
    from django.core.exceptions import ImproperlyConfigured
    raise ImproperlyConfigured("Error loading MySQLdb module: %s" % e)
from MySQLdb.converters import conversions
from MySQLdb.constants import FIELD_TYPE
import types
import re

DatabaseError = Database.DatabaseError
IntegrityError = Database.IntegrityError

django_conversions = conversions.copy()
django_conversions.update({
    types.BooleanType: util.rev_typecast_boolean,
    FIELD_TYPE.DATETIME: util.typecast_timestamp,
    FIELD_TYPE.DATE: util.typecast_date,
    FIELD_TYPE.TIME: util.typecast_time,
    FIELD_TYPE.DECIMAL: util.typecast_decimal,
    FIELD_TYPE.STRING: force_unicode,
    FIELD_TYPE.VAR_STRING: force_unicode,
    # Note: We don't add a convertor for BLOB here. Doesn't seem to be required.
})

# This should match the numerical portion of the version numbers (we can treat
# versions like 5.0.24 and 5.0.24a as the same). Based on the list of version
# at http://dev.mysql.com/doc/refman/4.1/en/news.html and
# http://dev.mysql.com/doc/refman/5.0/en/news.html .
server_version_re = re.compile(r'(\d{1,2})\.(\d{1,2})\.(\d{1,2})')

# This is an extra debug layer over MySQL queries, to display warnings.
# It's only used when DEBUG=True.
class MysqlDebugWrapper:
    def __init__(self, cursor):
        self.cursor = cursor

    def execute(self, sql, params=()):
        try:
            return self.cursor.execute(sql, params)
        except Database.Warning, w:
            self.cursor.execute("SHOW WARNINGS")
            raise Database.Warning("%s: %s" % (w, self.cursor.fetchall()))

    def executemany(self, sql, param_list):
        try:
            return self.cursor.executemany(sql, param_list)
        except Database.Warning, w:
            self.cursor.execute("SHOW WARNINGS")
            raise Database.Warning("%s: %s" % (w, self.cursor.fetchall()))

    def __getattr__(self, attr):
        if attr in self.__dict__:
            return self.__dict__[attr]
        else:
            return getattr(self.cursor, attr)

class DatabaseFeatures(BaseDatabaseFeatures):
    autoindexes_primary_keys = False
    inline_fk_references = False
    empty_fetchmany_value = ()
    update_can_self_select = False

class DatabaseOperations(BaseDatabaseOperations):
    def date_extract_sql(self, lookup_type, field_name):
        # http://dev.mysql.com/doc/mysql/en/date-and-time-functions.html
        return "EXTRACT(%s FROM %s)" % (lookup_type.upper(), field_name)

    def date_trunc_sql(self, lookup_type, field_name):
        fields = ['year', 'month', 'day', 'hour', 'minute', 'second']
        format = ('%%Y-', '%%m', '-%%d', ' %%H:', '%%i', ':%%s') # Use double percents to escape.
        format_def = ('0000-', '01', '-01', ' 00:', '00', ':00')
        try:
            i = fields.index(lookup_type) + 1
        except ValueError:
            sql = field_name
        else:
            format_str = ''.join([f for f in format[:i]] + [f for f in format_def[i:]])
            sql = "CAST(DATE_FORMAT(%s, '%s') AS DATETIME)" % (field_name, format_str)
        return sql

    def drop_foreignkey_sql(self):
        return "DROP FOREIGN KEY"

    def fulltext_search_sql(self, field_name):
        return 'MATCH (%s) AGAINST (%%s IN BOOLEAN MODE)' % field_name

    def limit_offset_sql(self, limit, offset=None):
        # 'LIMIT 20,40'
        sql = "LIMIT "
        if offset and offset != 0:
            sql += "%s," % offset
        return sql + str(limit)

    def no_limit_value(self):
        # 2**64 - 1, as recommended by the MySQL documentation
        return 18446744073709551615L

    def quote_name(self, name):
        if name.startswith("`") and name.endswith("`"):
            return name # Quoting once is enough.
        return "`%s`" % name

    def random_function_sql(self):
        return 'RAND()'

    def sql_flush(self, style, tables, sequences):
        # NB: The generated SQL below is specific to MySQL
        # 'TRUNCATE x;', 'TRUNCATE y;', 'TRUNCATE z;'... style SQL statements
        # to clear all tables of all data
        if tables:
            sql = ['SET FOREIGN_KEY_CHECKS = 0;']
            for table in tables:
                sql.append('%s %s;' % (style.SQL_KEYWORD('TRUNCATE'), style.SQL_FIELD(self.quote_name(table))))
            sql.append('SET FOREIGN_KEY_CHECKS = 1;')

            # 'ALTER TABLE table AUTO_INCREMENT = 1;'... style SQL statements
            # to reset sequence indices
            sql.extend(["%s %s %s %s %s;" % \
                (style.SQL_KEYWORD('ALTER'),
                 style.SQL_KEYWORD('TABLE'),
                 style.SQL_TABLE(self.quote_name(sequence['table'])),
                 style.SQL_KEYWORD('AUTO_INCREMENT'),
                 style.SQL_FIELD('= 1'),
                ) for sequence in sequences])
            return sql
        else:
            return []

class DatabaseWrapper(BaseDatabaseWrapper):
    features = DatabaseFeatures()
    ops = DatabaseOperations()
    operators = {
        'exact': '= %s',
        'iexact': 'LIKE %s',
        'contains': 'LIKE BINARY %s',
        'icontains': 'LIKE %s',
        'regex': 'REGEXP BINARY %s',
        'iregex': 'REGEXP %s',
        'gt': '> %s',
        'gte': '>= %s',
        'lt': '< %s',
        'lte': '<= %s',
        'startswith': 'LIKE BINARY %s',
        'endswith': 'LIKE BINARY %s',
        'istartswith': 'LIKE %s',
        'iendswith': 'LIKE %s',
    }

    def __init__(self, **kwargs):
        super(DatabaseWrapper, self).__init__(**kwargs)
        self.server_version = None

    def _valid_connection(self):
        if self.connection is not None:
            try:
                self.connection.ping()
                return True
            except DatabaseError:
                self.connection.close()
                self.connection = None
        return False

    def _cursor(self, settings):
        if not self._valid_connection():
            kwargs = {
                # Note: use_unicode intentonally not set to work around some
                # backwards-compat issues. We do it manually.
                'user': settings.DATABASE_USER,
                'db': settings.DATABASE_NAME,
                'passwd': settings.DATABASE_PASSWORD,
                'conv': django_conversions,
            }
            if settings.DATABASE_HOST.startswith('/'):
                kwargs['unix_socket'] = settings.DATABASE_HOST
            else:
                kwargs['host'] = settings.DATABASE_HOST
            if settings.DATABASE_PORT:
                kwargs['port'] = int(settings.DATABASE_PORT)
            kwargs.update(self.options)
            self.connection = Database.connect(**kwargs)
            cursor = self.connection.cursor()
            if self.connection.get_server_info() >= '4.1' and not self.connection.character_set_name().startswith('utf8'):
                if hasattr(self.connection, 'charset'):
                    # MySQLdb < 1.2.1 backwards-compat hacks.
                    conn = self.connection
                    cursor.execute("SET NAMES 'utf8'")
                    cursor.execute("SET CHARACTER SET 'utf8'")
                    to_str = lambda u, dummy=None, c=conn: c.literal(u.encode('utf-8'))
                    conn.converter[unicode] = to_str
                else:
                    self.connection.set_character_set('utf8')
        else:
            cursor = self.connection.cursor()
        return cursor

    def make_debug_cursor(self, cursor):
        return BaseDatabaseWrapper.make_debug_cursor(self, MysqlDebugWrapper(cursor))

    def _rollback(self):
        try:
            BaseDatabaseWrapper._rollback(self)
        except Database.NotSupportedError:
            pass

    def get_server_version(self):
        if not self.server_version:
            if not self._valid_connection():
                self.cursor()
            m = server_version_re.match(self.connection.get_server_info())
            if not m:
                raise Exception('Unable to determine MySQL version from version string %r' % self.connection.get_server_info())
            self.server_version = tuple([int(x) for x in m.groups()])
        return self.server_version


text:
package ch.sama.sql.dialect.tsql.query;

import ch.sama.sql.dbo.IType;
import ch.sama.sql.dialect.tsql.TSqlQueryRenderer;
import ch.sama.sql.query.base.IQuery;
import ch.sama.sql.query.base.check.Identifier;
import ch.sama.sql.query.exception.IllegalIdentifierException;
import ch.sama.sql.query.helper.Value;

public class TSqlDeclareQuery extends MainQuery {
    private IQuery parent;
    private String variable;
    private IType type;
    private Value value;

    public TSqlDeclareQuery(TSqlQueryRenderer renderer, IQuery parent, String variable, IType type, Value value) {
        super(renderer);

        if (!Identifier.test(variable)) {
            throw new IllegalIdentifierException(variable);
        }

        this.parent = parent;
        this.variable = variable;
        this.type = type;
        this.value = value;
    }

    @Override
    public IQuery getParent() {
        return parent;
    }

    @Override
    public String getSql() {
        return getRenderer().render(this);
    }

    @Override
    public IQuery chainTo(IQuery query) {
        this.parent = query;
        return query;
    }

    public String getVariable() {
        return variable;
    }

    public IType getType() {
        return type;
    }

    public Value getValue() {
        return value;
    }

    public TSqlDeclareQuery declare(String variable, IType type, Value value) {
        return new TSqlDeclareQuery(getRenderer(), this, variable, type, value);
    }
}


text:
package e2e

import (
	"os"
	"strings"
	"testing"
	"time"

	"github.com/coreos/etcd/pkg/expect"
)

func TestCtlV3Elect(t *testing.T) { testCtl(t, testElect) }

func testElect(cx ctlCtx) {
	name := "a"

	holder, ch, err := ctlV3Elect(cx, name, "p1")
	if err != nil {
		cx.t.Fatal(err)
	}

	l1 := ""
	select {
	case <-time.After(2 * time.Second):
		cx.t.Fatalf("timed out electing")
	case l1 = <-ch:
		if !strings.HasPrefix(l1, name) {
			cx.t.Errorf("got %q, expected %q prefix", l1, name)
		}
	}

	// blocked process that won't win the election
	blocked, ch, err := ctlV3Elect(cx, name, "p2")
	if err != nil {
		cx.t.Fatal(err)
	}
	select {
	case <-time.After(100 * time.Millisecond):
	case <-ch:
		cx.t.Fatalf("should block")
	}

	// overlap with a blocker that will win the election
	blockAcquire, ch, err := ctlV3Elect(cx, name, "p2")
	if err != nil {
		cx.t.Fatal(err)
	}
	defer blockAcquire.Stop()
	select {
	case <-time.After(100 * time.Millisecond):
	case <-ch:
		cx.t.Fatalf("should block")
	}

	// kill blocked process with clean shutdown
	if err = blocked.Signal(os.Interrupt); err != nil {
		cx.t.Fatal(err)
	}
	if err = blocked.Close(); err != nil {
		cx.t.Fatal(err)
	}

	// kill the holder with clean shutdown
	if err = holder.Signal(os.Interrupt); err != nil {
		cx.t.Fatal(err)
	}
	if err = holder.Close(); err != nil {
		cx.t.Fatal(err)
	}

	// blockAcquire should win the election
	select {
	case <-time.After(time.Second):
		cx.t.Fatalf("timed out from waiting to holding")
	case l2 := <-ch:
		if l1 == l2 || !strings.HasPrefix(l2, name) {
			cx.t.Fatalf("expected different elect name, got l1=%q, l2=%q", l1, l2)
		}
	}
}

// ctlV3Elect creates a elect process with a channel listening for when it wins the election.
func ctlV3Elect(cx ctlCtx, name, proposal string) (*expect.ExpectProcess, <-chan string, error) {
	cmdArgs := append(cx.PrefixArgs(), "elect", name, proposal)
	proc, err := spawnCmd(cmdArgs)
	outc := make(chan string, 1)
	if err != nil {
		close(outc)
		return proc, outc, err
	}
	go func() {
		s, xerr := proc.ExpectFunc(func(string) bool { return true })
		if xerr != nil {
			cx.t.Errorf("expect failed (%v)", xerr)
		}
		outc <- s
	}()
	return proc, outc, err
}


text:
mkdir -p m4 # Needed in OSX
for f in AUTHORS ChangeLog COPYING README NEWS; do
  test -f "$f" || touch "$f"
done
autoreconf --force --install


text:
using System.Collections.Generic;
using System.Net;
using System.Text.Json;
using Azure.Core;

namespace Azure.ResourceManager.TrafficManager.Models
{
    public partial class TrafficManagerHeatMapTrafficFlow : IUtf8JsonSerializable
    {
        void IUtf8JsonSerializable.Write(Utf8JsonWriter writer)
        {
            writer.WriteStartObject();
            if (Optional.IsDefined(SourceIP))
            {
                writer.WritePropertyName("sourceIp");
                writer.WriteStringValue(SourceIP.ToString());
            }
            if (Optional.IsDefined(Latitude))
            {
                writer.WritePropertyName("latitude");
                writer.WriteNumberValue(Latitude.Value);
            }
            if (Optional.IsDefined(Longitude))
            {
                writer.WritePropertyName("longitude");
                writer.WriteNumberValue(Longitude.Value);
            }
            if (Optional.IsCollectionDefined(QueryExperiences))
            {
                writer.WritePropertyName("queryExperiences");
                writer.WriteStartArray();
                foreach (var item in QueryExperiences)
                {
                    writer.WriteObjectValue(item);
                }
                writer.WriteEndArray();
            }
            writer.WriteEndObject();
        }

        internal static TrafficManagerHeatMapTrafficFlow DeserializeTrafficManagerHeatMapTrafficFlow(JsonElement element)
        {
            Optional<IPAddress> sourceIP = default;
            Optional<double> latitude = default;
            Optional<double> longitude = default;
            Optional<IList<TrafficManagerHeatMapQueryExperience>> queryExperiences = default;
            foreach (var property in element.EnumerateObject())
            {
                if (property.NameEquals("sourceIp"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        property.ThrowNonNullablePropertyIsNull();
                        continue;
                    }
                    sourceIP = IPAddress.Parse(property.Value.GetString());
                    continue;
                }
                if (property.NameEquals("latitude"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        property.ThrowNonNullablePropertyIsNull();
                        continue;
                    }
                    latitude = property.Value.GetDouble();
                    continue;
                }
                if (property.NameEquals("longitude"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        property.ThrowNonNullablePropertyIsNull();
                        continue;
                    }
                    longitude = property.Value.GetDouble();
                    continue;
                }
                if (property.NameEquals("queryExperiences"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        property.ThrowNonNullablePropertyIsNull();
                        continue;
                    }
                    List<TrafficManagerHeatMapQueryExperience> array = new List<TrafficManagerHeatMapQueryExperience>();
                    foreach (var item in property.Value.EnumerateArray())
                    {
                        array.Add(TrafficManagerHeatMapQueryExperience.DeserializeTrafficManagerHeatMapQueryExperience(item));
                    }
                    queryExperiences = array;
                    continue;
                }
            }
            return new TrafficManagerHeatMapTrafficFlow(sourceIP.Value, Optional.ToNullable(latitude), Optional.ToNullable(longitude), Optional.ToList(queryExperiences));
        }
    }
}


text:
Uredi skupinu

Obavijesti

naziv: preimenuj skupinu (nestvarno preimenovanje u slučaju stvarne skupine).

opis: prikažite uopćeni opis sadržaja, ovaj tekst će se prikazati ispod stranice poveznih sličica.

Premjesti

Ako je skupina nestvarna, možete je premjestiti. Premještanje skupine znači promjenu njene nadređene skupine.

Mogućnosti

Vrsta pristupa: Upravljanje dozvolama. Ako postavite skupinu kao osobnu, sve njoj podređene skupine postaju osobne. Ako postavite
  skupinu kao javnu, sve njoj nadređene skupine postaju javne.

Zaključavanje: Skupina i njene podskupine postaju nedostupne zbog poslova održavanja.

Komentari: Dozvoli korisnicima da mogu komentirati stavke ove skupine.

Dozvoli prebacivanje: Dozvoli korisnicima da mogu prebacivati zapise na poslužitelj. Ova mogućnost je dostupna samo za stvarne skupine (ne i za nestvarne skupine).

Ovim mogućnostima možete upravljati i preko "Svojstva" upravnog prozora
 (prozori Prebaci, Komentari, Zaključaj,
Javno/Osobno, Predstavnik dostupnih preko Uprava, Skupine, Svojstva).

Redoslijed slaganja

Odaberite ako će se koristiti pretpostavljeni redoslijed slaganja.

Označite ako će se taj redoslijed primjeniti i na podskupine.

Odaberite posebno slaganje po stupcima za korištenje kod ove skupine.

Nadnevak izrade: Nadnevak stvaranja slike

Nadnevak postavljanja: Nadnevak usklađivanja

Prosječna ocjena (*): Prosječna ocjena se može mijenjati od strane posjetitelja

Najposjećenije (*): Trenutna posjeta mijenja redoslijed najposjećenijih

Naziv zapisa: Dano ime u obavijesnim poljima

Id: Unutarnja Id oznaka (novije skupine imaju veći id nego starije.

(*)Budite oprezni i prethodno isprobajte jer možete dobiti neočekivane ishode.

Predstavnik

Predstavnik skupine je povezna sličica postavljena da predstavlja
skupinu na glavnoj stranici (category.php) kada skupina
sadrži samo podskupine (kao korijenska skupina).

Postoje 4 načina za postavljanje slike predstavnika skupine :

Stranica Slika: dugmad na traci postupaka,
  jedan od njih omogućava postavljanje prikazane slike kao predstavnika skupine. ovo dugme je dostupno samo upravnicima.

Izmjena podataka o slici u upravnom dijelu. Ovaj prozor dostupan preko picture.php ili Slijedna obrada  u pojedinačnom načinu. Pogledajte sustav pomoći u ovom prozoru za pojedinosti.

Uprava, Skupine, Svojstva, Predstavnik. Pogledajte sustav pomoći u ovom prozoru za pojedinosti.

Uredi skupinu (ovaj prozor).

Predstavljanje ovisi o postavkama stavke allow_random_representative (vidi include/config_default.inc.php).

U pretpostavljenom načinu (allow_random_representative postavljen na false)
svaka skupina koja sadrži najmanje jednu stavku je predstavljena određenim predstavnikom. Jednom postavljen (pri stvaranju skupine), predstavnik se mijenja jedino
kada upravnik to zatraži. Ako predstavnik nije odgovarajući možete zatražiti Odabir novog predstavnika slučajnim pristupom.

Ako je postavka allow_random_representative postavljena na true, skupina koja ima sadržaj ne može imati prepostavljenog prestavnika.
Jednostavno upotrijebite Izbriši predstavnika dugme.

Ako skupina nema stavki (nego samo podskupine) može biti predstavljena bilo kojom
stavkom podskupina zahvaljujući prozoru  Promijeni podatke o slici. Jedina mogućnost na trenutnom prozou je
 Izbriši predstavnika dugme, a nakon birisanja, odabir predstavnika nije više dostupan.

Poveži sve stavke skupine u novu skupinu

Naziv nestvarne skupine: Novi naziv skupine će se odrediti,
sve slike trenutne skupine će se povezati sa novonastalom.

Nadređena skupina: Gdje će se nova skupina nalaziti, ostavi prazno za postavu iz polazišta.

Poveži sve stavke skupine sa nekim postojećim skupinama

Skupine: Odaberite odredišnu skupinu.

Pošalji e-mail obavijest članovima grupe

Grupa: adrese grupe

Sadržaj e-mail poruke: sadržaj po volji koji će se poslati.


text:
<meta name="generator" content="groff -Thtml, see www.gnu.org">
<meta name="Content-Style" content="text/css">
<title>TEXTDOMAIN</title>

TEXTDOMAIN

NAME

SYNOPSIS

DESCRIPTION

RETURN VALUE

ERRORS

BUGS

SEE ALSO

NAME

textdomain - set domain for future gettext() calls

SYNOPSIS

#include <libintl.h>

char * textdomain (const char * domainname);

DESCRIPTION

The textdomain function sets or retrieves the current
message domain.

A message domain is a set of translatable msgid
messages. Usually, every software package has its own
message domain. The domain name is used to determine the
message catalog where a translation is looked up; it must be
a non-empty string.

The current message domain is used by the gettext,
ngettext functions, and by the dgettext,
dcgettext, dngettext and dcngettext
functions when called with a NULL domainname
argument.

If domainname is not NULL, the current message domain
is set to domainname. The string the function stores
internally is a copy of the domainname
argument.

If domainname is NULL, the function returns the
current message domain.

RETURN VALUE

If successful, the textdomain function returns the
current message domain, after possibly changing it. The
resulting string is valid until the next textdomain
call and must not be modified or freed. If a memory
allocation failure occurs, it sets errno to
ENOMEM and returns NULL.

ERRORS

The following error can occur, among others:

ENOMEM

Not enough memory available.

BUGS

The return type ought to be const char *, but is
char * to avoid warnings in C code predating ANSI
C.

SEE ALSO

gettext(3), ngettext(3),
bindtextdomain(3),
bind_textdomain_codeset(3)


text:
/*
 * @(#)TLogger.java	1.2 06/02/11
 */

package com.sun.ts.tests.ejb30.common.helper;

/**
 * A convenience class to use different logging, e.g., cts TestUtil.log, or
 * System.out.println.
 */
public class TLogger {
    public static final String NL = System.getProperty("line.separator");
    private TLogger() {}

    public static void log(String... args) {
        String msg = null;
        if(args.length == 0) {
            return;
        } else if(args.length == 1) {
            msg = args[0];
            if(msg == null) {
                return;
            }
        } else {
            StringBuffer sb = new StringBuffer();
            for(String s : args) {
                sb.append(s).append(' ');
            }
            msg = sb.toString();
        }
        System.out.println(msg);
    }

    public static void log(String arg, Throwable thr) {
        if(arg != null) {
            System.out.println(arg);
        }
        if(thr != null) {
            thr.printStackTrace();
        }
    }

    public static void log(boolean status, String arg) {
        if(arg != null) {
            String s = status ? "PASSED: " : "FAILED: ";
            System.out.println(s + arg);
        }
    }

    public static void logMsg(String s) {
        log(s);
    }

    public static void logErr(String s) {
        log(s);
    }

    public static void logTrace(String s) {
        log(s);
    }

    public static void printStackTrace(Throwable th) {
        th.printStackTrace();
    }

    public static void main(String[] args) {
        TLogger.log("####");
    }
}


text:
package model

type ChannelId interface {
	ChannelId() string
}

type ChannelIdIterator interface {
	ChannelIdIterator() (chan ChannelId, chan bool)
}

type ChannelGroupInterface interface {
	ChannelIdIterator
	Name() string
	GroupId() string
	Description() string
}


text:
from libcloud.compute.types import Provider
from libcloud.compute.providers import get_driver

cls = get_driver(Provider.SCALEWAY)
driver = cls("SCALEWAY_ACCESS_KEY", "SCALEWAY_SECRET_TOKEN")

nodes = driver.list_nodes()
for node in nodes:
    print(node)


text:
package io.reflectoring.coderadar.useradministration.service.teams;

import io.reflectoring.coderadar.domain.ProjectRole;
import io.reflectoring.coderadar.projectadministration.ProjectNotFoundException;
import io.reflectoring.coderadar.projectadministration.port.driven.project.GetProjectPort;
import io.reflectoring.coderadar.useradministration.TeamNotFoundException;
import io.reflectoring.coderadar.useradministration.port.driven.AddTeamToProjectPort;
import io.reflectoring.coderadar.useradministration.port.driven.GetTeamPort;
import io.reflectoring.coderadar.useradministration.port.driver.teams.AddTeamToProjectUseCase;
import lombok.RequiredArgsConstructor;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Service;

@Service
@RequiredArgsConstructor
public class AddTeamToProjectService implements AddTeamToProjectUseCase {

  private final GetProjectPort getProjectPort;
  private final AddTeamToProjectPort addTeamToProjectPort;
  private final GetTeamPort getTeamPort;

  private static final Logger logger = LoggerFactory.getLogger(AddTeamToProjectService.class);

  @Override
  public void addTeamToProject(long projectId, long teamId, ProjectRole role) {
    if (!getProjectPort.existsById(projectId)) {
      throw new ProjectNotFoundException(projectId);
    }
    if (!getTeamPort.existsById(teamId)) {
      throw new TeamNotFoundException(teamId);
    }
    addTeamToProjectPort.addTeamToProject(projectId, teamId, role);
    logger.info(
        "Assigned team with id: {} to project with id: {} with the role: {}",
        teamId,
        projectId,
        role.getValue());
  }
}


text:
package com.sixsq.slipstream.run;

import com.sixsq.slipstream.persistence.RuntimeParameter;
import com.sixsq.slipstream.persistence.VmRuntimeParameterMapping;
import com.sixsq.slipstream.persistence.RuntimeParameter.SpecialValues;

public class RuntimeParameterMediator {

	public static void processSpecialValue(RuntimeParameter rp) {
		String name = rp.getName();
		SpecialValues sp;
		try {
			sp = SpecialValues.valueOf(name);
		} catch(IllegalArgumentException ex) {
			// no there
			return;
		}

		switch(sp) {
			case instanceid:
				setVmInstanceMapping(rp);
				break;
		}
	}

	private static void setVmInstanceMapping(RuntimeParameter rp) {
		VmRuntimeParameterMapping.insertVmInstanceMapping(rp);
	}

}


text:
module Codebreaker
  class Game
    MAX_NUMBER_OF_ATTEMPTS=5
    STRING_SIZE = 4
    attr_reader :number, :number_of_attempts, :count_of_hints , :player, :guess_checker

    def initialize(player)
      @number_of_attempts=0;
      @count_of_hints =0;
      @number=""
      @player=player
      generate
    end

    def string_for(guess)
      result = ""
      num_of_minuses=0;
      STRING_SIZE.times do |i|
         if number[i]==guess.value[i]
           result<<"+"
         elsif number.include? guess.value[i]
            num_of_minuses+=1
         end
      end
      num_of_minuses.times {result<<"-"}
      result
    end

    def result_of(guess)
         @number_of_attempts+=1
         string=string_for(guess)
         if string=="++++"
           win(string)   #win
         elsif @number_of_attempts<MAX_NUMBER_OF_ATTEMPTS
           continue(string) #continue
         elsif @number_of_attempts==MAX_NUMBER_OF_ATTEMPTS
           loose(string) #loose
          end
    end

    def checker_for_win(string)
      GuessChecker.new(:message=>"Congratulations! You are winner",
                       :number_of_attempts=>@number_of_attempts,
                       :string=>string)
    end

    def checker_for_continue(string)
      GuessChecker.new(:message=>"Game is continue",
                       :number_of_attempts=>@number_of_attempts,
                       :string=>string)
    end

    def checker_for_loose(string)
      GuessChecker.new(:message=>"Game is over",
                       :number_of_attempts=>@number_of_attempts,
                       :string=>string)
    end

    def win(string)
      write_results_to_file(:status=>"win")
      checker_for_win(string)
    end

    def loose (string)
      write_results_to_file(:status=>"lost")
      checker_for_loose(string)
    end

    def continue(string)
      checker_for_continue(string)
    end

    def write_results_to_file (options={})
      f_name = "/tmp/new_file.txt"
     # File.delete(f_name) if File.exist?(f_name)
      File.open(f_name, 'w') { |file| file.write(" Player: #{@player.name} finished game.\n Status: #{options[:status]}.\n Number of attempts: #{@number_of_attempts}") }
    end

    def can_use_hint?
      @count_of_hints<1? true : false
    end

    def take_hint
      if can_use_hint?
        position = rand(3)
        @count_of_hints+=1
        "There is #{take_digit(position).chr} digit in the secret number"
      else
        "You have not hints"
      end
    end

    def take_digit(position)
      number[position]
    end

    private
    def generate
      STRING_SIZE.times do
        @number << (rand(5)+1).to_s
      end
    end
  end
end


text:
<?php

namespace app\modules\Admin\Homework;
use app\modules\AppBase\base\appbase\BaseModule;
class Homework extends BaseModule
{
    public $controllerNamespace = 'app\modules\Admin\Homework\controllers';
    public function init()
    {
        parent::init();
    }
}


text:
#pragma once

#include "il2cpp-config.h"

#ifndef _MSC_VER
# include <alloca.h>
#else
# include <malloc.h>
#endif

#include <stdint.h>

// System.UInt16[]
struct UInt16U5BU5D_t801649474;
// System.String
struct String_t;
// System.Text.RegularExpressions.QuickSearch
struct QuickSearch_t2109051075;
// System.Text.RegularExpressions.Interpreter/RepeatContext
struct RepeatContext_t1764265010;
// System.Text.RegularExpressions.Mark[]
struct MarkU5BU5D_t581716920;
// System.Int32[]
struct Int32U5BU5D_t3230847821;

#include "System_System_Text_RegularExpressions_BaseMachine768653060.h"
#include "System_System_Text_RegularExpressions_Interpreter_3630763131.h"

#ifdef __clang__
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Winvalid-offsetof"
#pragma clang diagnostic ignored "-Wunused-variable"
#endif

// System.Text.RegularExpressions.Interpreter
struct  Interpreter_t4223808840  : public BaseMachine_t768653060
{
public:
	// System.UInt16[] System.Text.RegularExpressions.Interpreter::program
	UInt16U5BU5D_t801649474* ___program_1;
	// System.Int32 System.Text.RegularExpressions.Interpreter::program_start
	int32_t ___program_start_2;
	// System.String System.Text.RegularExpressions.Interpreter::text
	String_t* ___text_3;
	// System.Int32 System.Text.RegularExpressions.Interpreter::text_end
	int32_t ___text_end_4;
	// System.Int32 System.Text.RegularExpressions.Interpreter::group_count
	int32_t ___group_count_5;
	// System.Int32 System.Text.RegularExpressions.Interpreter::match_min
	int32_t ___match_min_6;
	// System.Text.RegularExpressions.QuickSearch System.Text.RegularExpressions.Interpreter::qs
	QuickSearch_t2109051075 * ___qs_7;
	// System.Int32 System.Text.RegularExpressions.Interpreter::scan_ptr
	int32_t ___scan_ptr_8;
	// System.Text.RegularExpressions.Interpreter/RepeatContext System.Text.RegularExpressions.Interpreter::repeat
	RepeatContext_t1764265010 * ___repeat_9;
	// System.Text.RegularExpressions.Interpreter/RepeatContext System.Text.RegularExpressions.Interpreter::fast
	RepeatContext_t1764265010 * ___fast_10;
	// System.Text.RegularExpressions.Interpreter/IntStack System.Text.RegularExpressions.Interpreter::stack
	IntStack_t3630763131  ___stack_11;
	// System.Text.RegularExpressions.Interpreter/RepeatContext System.Text.RegularExpressions.Interpreter::deep
	RepeatContext_t1764265010 * ___deep_12;
	// System.Text.RegularExpressions.Mark[] System.Text.RegularExpressions.Interpreter::marks
	MarkU5BU5D_t581716920* ___marks_13;
	// System.Int32 System.Text.RegularExpressions.Interpreter::mark_start
	int32_t ___mark_start_14;
	// System.Int32 System.Text.RegularExpressions.Interpreter::mark_end
	int32_t ___mark_end_15;
	// System.Int32[] System.Text.RegularExpressions.Interpreter::groups
	Int32U5BU5D_t3230847821* ___groups_16;

public:
	inline static int32_t get_offset_of_program_1() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___program_1)); }
	inline UInt16U5BU5D_t801649474* get_program_1() const { return ___program_1; }
	inline UInt16U5BU5D_t801649474** get_address_of_program_1() { return &___program_1; }
	inline void set_program_1(UInt16U5BU5D_t801649474* value)
	{
		___program_1 = value;
		Il2CppCodeGenWriteBarrier(&___program_1, value);
	}

	inline static int32_t get_offset_of_program_start_2() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___program_start_2)); }
	inline int32_t get_program_start_2() const { return ___program_start_2; }
	inline int32_t* get_address_of_program_start_2() { return &___program_start_2; }
	inline void set_program_start_2(int32_t value)
	{
		___program_start_2 = value;
	}

	inline static int32_t get_offset_of_text_3() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___text_3)); }
	inline String_t* get_text_3() const { return ___text_3; }
	inline String_t** get_address_of_text_3() { return &___text_3; }
	inline void set_text_3(String_t* value)
	{
		___text_3 = value;
		Il2CppCodeGenWriteBarrier(&___text_3, value);
	}

	inline static int32_t get_offset_of_text_end_4() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___text_end_4)); }
	inline int32_t get_text_end_4() const { return ___text_end_4; }
	inline int32_t* get_address_of_text_end_4() { return &___text_end_4; }
	inline void set_text_end_4(int32_t value)
	{
		___text_end_4 = value;
	}

	inline static int32_t get_offset_of_group_count_5() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___group_count_5)); }
	inline int32_t get_group_count_5() const { return ___group_count_5; }
	inline int32_t* get_address_of_group_count_5() { return &___group_count_5; }
	inline void set_group_count_5(int32_t value)
	{
		___group_count_5 = value;
	}

	inline static int32_t get_offset_of_match_min_6() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___match_min_6)); }
	inline int32_t get_match_min_6() const { return ___match_min_6; }
	inline int32_t* get_address_of_match_min_6() { return &___match_min_6; }
	inline void set_match_min_6(int32_t value)
	{
		___match_min_6 = value;
	}

	inline static int32_t get_offset_of_qs_7() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___qs_7)); }
	inline QuickSearch_t2109051075 * get_qs_7() const { return ___qs_7; }
	inline QuickSearch_t2109051075 ** get_address_of_qs_7() { return &___qs_7; }
	inline void set_qs_7(QuickSearch_t2109051075 * value)
	{
		___qs_7 = value;
		Il2CppCodeGenWriteBarrier(&___qs_7, value);
	}

	inline static int32_t get_offset_of_scan_ptr_8() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___scan_ptr_8)); }
	inline int32_t get_scan_ptr_8() const { return ___scan_ptr_8; }
	inline int32_t* get_address_of_scan_ptr_8() { return &___scan_ptr_8; }
	inline void set_scan_ptr_8(int32_t value)
	{
		___scan_ptr_8 = value;
	}

	inline static int32_t get_offset_of_repeat_9() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___repeat_9)); }
	inline RepeatContext_t1764265010 * get_repeat_9() const { return ___repeat_9; }
	inline RepeatContext_t1764265010 ** get_address_of_repeat_9() { return &___repeat_9; }
	inline void set_repeat_9(RepeatContext_t1764265010 * value)
	{
		___repeat_9 = value;
		Il2CppCodeGenWriteBarrier(&___repeat_9, value);
	}

	inline static int32_t get_offset_of_fast_10() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___fast_10)); }
	inline RepeatContext_t1764265010 * get_fast_10() const { return ___fast_10; }
	inline RepeatContext_t1764265010 ** get_address_of_fast_10() { return &___fast_10; }
	inline void set_fast_10(RepeatContext_t1764265010 * value)
	{
		___fast_10 = value;
		Il2CppCodeGenWriteBarrier(&___fast_10, value);
	}

	inline static int32_t get_offset_of_stack_11() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___stack_11)); }
	inline IntStack_t3630763131  get_stack_11() const { return ___stack_11; }
	inline IntStack_t3630763131 * get_address_of_stack_11() { return &___stack_11; }
	inline void set_stack_11(IntStack_t3630763131  value)
	{
		___stack_11 = value;
	}

	inline static int32_t get_offset_of_deep_12() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___deep_12)); }
	inline RepeatContext_t1764265010 * get_deep_12() const { return ___deep_12; }
	inline RepeatContext_t1764265010 ** get_address_of_deep_12() { return &___deep_12; }
	inline void set_deep_12(RepeatContext_t1764265010 * value)
	{
		___deep_12 = value;
		Il2CppCodeGenWriteBarrier(&___deep_12, value);
	}

	inline static int32_t get_offset_of_marks_13() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___marks_13)); }
	inline MarkU5BU5D_t581716920* get_marks_13() const { return ___marks_13; }
	inline MarkU5BU5D_t581716920** get_address_of_marks_13() { return &___marks_13; }
	inline void set_marks_13(MarkU5BU5D_t581716920* value)
	{
		___marks_13 = value;
		Il2CppCodeGenWriteBarrier(&___marks_13, value);
	}

	inline static int32_t get_offset_of_mark_start_14() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___mark_start_14)); }
	inline int32_t get_mark_start_14() const { return ___mark_start_14; }
	inline int32_t* get_address_of_mark_start_14() { return &___mark_start_14; }
	inline void set_mark_start_14(int32_t value)
	{
		___mark_start_14 = value;
	}

	inline static int32_t get_offset_of_mark_end_15() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___mark_end_15)); }
	inline int32_t get_mark_end_15() const { return ___mark_end_15; }
	inline int32_t* get_address_of_mark_end_15() { return &___mark_end_15; }
	inline void set_mark_end_15(int32_t value)
	{
		___mark_end_15 = value;
	}

	inline static int32_t get_offset_of_groups_16() { return static_cast<int32_t>(offsetof(Interpreter_t4223808840, ___groups_16)); }
	inline Int32U5BU5D_t3230847821* get_groups_16() const { return ___groups_16; }
	inline Int32U5BU5D_t3230847821** get_address_of_groups_16() { return &___groups_16; }
	inline void set_groups_16(Int32U5BU5D_t3230847821* value)
	{
		___groups_16 = value;
		Il2CppCodeGenWriteBarrier(&___groups_16, value);
	}
};

#ifdef __clang__
#pragma clang diagnostic pop
#endif


text:
package org.rsna.ctp.objects;

import org.apache.log4j.Logger;
import org.rsna.util.FileUtil;
import org.rsna.util.XmlUtil;
import org.w3c.dom.Document;
import org.w3c.dom.Element;

import java.io.BufferedInputStream;
import java.io.BufferedOutputStream;
import java.io.BufferedReader;
import java.io.File;
import java.io.FileOutputStream;
import java.io.InputStreamReader;
import java.io.StringWriter;
import java.nio.charset.Charset;
import java.util.ArrayList;
import java.util.Enumeration;
import java.util.zip.ZipEntry;
import java.util.zip.ZipFile;

/**
 * A generic Zip object for collections of clinical trials data, providing
 * parsing and access to the files. This object supports a manifest, the primary
 * purpose of which is to provide a unique identifier along the same lines as the
 * DICOM SOP Instance UID. The manifest is an XML file named "manifest.xml" stored
 * in the root of the zip directory structure. The root element of the manifest can
 * have any element name, but the UID must be an attribute of the root element and
 * have the name "uid".
 *

 * This object can be used to access zip files not having a manifest, but in that
 * case, all the manifest access methods return either null Strings or null XML
 * documents (depending on the method).
 *

 * The schema of the manifest is:
 *
 *

 * <manifest
 *        uid="UID of the ZipObject instance"
 *        study-uid="UID of the study instance"
 *        date="YYYYMMDD"
 *        version="manifest version identifier"
 *        type="type of ZipObject"
 *        description="description of the ZipObject"
 *        pt-name="Last^First^Middle"
 *        pt-id="...">
 *    ...child elements as required for the usage of the ZipObject...
 * </manifest>
 *

 *
 */
public class ZipObject extends FileObject {

	public static final String manifestName = "manifest.xml";
	String manifest = "";
	Document manifestXML = null;

	static Charset latin1 = Charset.forName("iso-8859-1");
	static Charset utf8 = Charset.forName("utf-8");

	static final Logger logger = Logger.getLogger(ZipObject.class);

	/**
	 * Class constructor; opens the zip file.
	 * @param file the zip file.
	 * @throws Exception if the zip file does not parse.
	 */
	public ZipObject(File file) throws Exception {
		super(file);
		ZipFile zipFile = null;
		//Get the manifest text and DOM document.
		try {
			zipFile = new ZipFile(file);
			ZipEntry manifestEntry = zipFile.getEntry(manifestName);
			if (manifestEntry != null) manifest = extractFileText(manifestEntry);
			if (!manifest.equals("")) {
				try { manifestXML = XmlUtil.getDocument(manifest); }
				catch (Exception ex) { manifestXML = null; }
			}
			zipFile.close();
		}
		catch (Exception ex) {
			if (zipFile != null) zipFile.close();
			throw ex;
		}
	}

	/**
	 * Get the standard extension for a ZipObject (".zip").
	 * @return ".zip"
	 */
	@Override
  public String getStandardExtension() {
		return ".zip";
	}

	/**
	 * Get a prefix for a ZipObject ("ZIP-").
	 * @return a prefix for a ZipObject.
	 */
	@Override
  public String getTypePrefix() {
		return "ZIP-";
	}

	/**
	 * Get the text of the manifest for this object. The manifest is
	 * a text file named "manifest.xml" in the zip file.
	 * @return the text of the manifest file or the empty string if
	 * the manifest cannot be obtained.
	 */
	public String getManifestText() {
		if (manifest == null) return "";
		return manifest;
	}

	/**
	 * Get the manifest XML DOM document for this object.
	 * @return the XML DOM document for the parsed manifest file or null if
	 * the manifest cannot be obtained and parsed.
	 */
	public Document getManifestDocument() {
		return manifestXML;
	}

	/**
	 * Get the document element name (the root element) of the
	 * manifest for this object.
	 * @return the document element name of the manifest.
	 */
	public String getManifestDocumentElementName() {
		if (manifestXML == null) return "";
		return manifestXML.getDocumentElement().getTagName();
	}

	/**
	 * Get the UID for this object from the manifest. This requires that the
	 * "uid" attribute of the root element be present in the XML file named
	 * "manifest.xml" in the zip file.
	 * @return the UID or the empty string if the uid cannot be obtained.
	 */
	@Override
  public String getUID() {
		if (manifestXML == null) return "";
		return manifestXML.getDocumentElement().getAttribute("uid").replaceAll("\\s","");
	}

	/**
	 * Get the description element text from the manifest. The description element
	 * must be a first-generation child of the root element and be named "description".
	 * The text returned is the sum of the text nodes of the first description
	 * element found under the root.
	 * @return the value of the description element in the manifest,
	 * or the file name if the element cannot be obtained.
	 */
	@Override
  public String getDescription() {
		if (manifestXML == null) return file.getName();
		Element root = manifestXML.getDocumentElement();
		String rootName = root.getTagName();
		String desc = XmlUtil.getValueViaPath(root,rootName+"/description");
		if (!desc.trim().equals("")) return desc;
		return file.getName();
	}

	/**
	 * Get the study's unique identifier from the manifest. This requires that the
	 * "study-uid" attribute of the root element be present in the XML file named
	 * "manifest.xml" in the zip file.
	 * @return the study's unique identifier, if available; otherwise the empty string.
	 */
	@Override
  public String getStudyUID() {
		if (manifestXML == null) return "";
		return manifestXML.getDocumentElement().getAttribute("study-uid");
	}

	/**
	 * Get the patient name from the manifest. This requires that the
	 * "pt-name" attribute of the root element be present in the XML file named
	 * "manifest.xml" in the zip file.
	 * @return the patient name, if available; otherwise the empty string.
	 */
	@Override
  public String getPatientName() {
		if (manifestXML == null) return "";
		return manifestXML.getDocumentElement().getAttribute("pt-name");
	}

	/**
	 * Get the patient ID from the manifest. This requires that the
	 * "pt-id" attribute of the root element be present in the XML file named
	 * "manifest.xml" in the zip file.
	 * @return the patient ID, if available; otherwise the empty string.
	 */
	@Override
  public String getPatientID() {
		if (manifestXML == null) return "";
		return manifestXML.getDocumentElement().getAttribute("pt-id");
	}

	/**
	 * Get the version identifier from the manifest. This requires that the
	 * "version" attribute of the root element be present in the XML file named
	 * "manifest.xml" in the zip file.
	 * @return the manifest version identifier, if available; otherwise the empty string.
	 */
	public String getVersion() {
		if (manifestXML == null) return "";
		return manifestXML.getDocumentElement().getAttribute("version");
	}

	/**
	 * Get the type identifier from the manifest. This requires that the
	 * "type" attribute of the root element be present in the XML file named
	 * "manifest.xml" in the zip file.
	 * @return the manifest type identifier, if available; otherwise the empty string.
	 */
	@Override
  public String getType() {
		if (manifestXML == null) return "";
		return manifestXML.getDocumentElement().getAttribute("type");
	}

	/**
	 * Get the date from the manifest. This requires that the
	 * "date" attribute of the root element be present in the XML file named
	 * "manifest.xml" in the zip file.
	 * @return the manifest date, if available; otherwise the empty string.
	 */
	@Override
  public String getStudyDate() {
		if (manifestXML == null) return "";
		return manifestXML.getDocumentElement().getAttribute("date").replaceAll("\\D","");
	}

	/**
	 * Get the value of the node identified by a path in the manifest. This method
	 * is a convenience method that can only be relied on if the path to the
	 * node can be found by taking the first element matching each step of
	 * the path.
	 * @param path the path from the root element to the node. Note that this
	 * method uses the XmlUtil.getValueViaPath(String) method, and the path
	 * syntax is slightly different from that of XPath. Specifically,
	 * attributes are identified as "node@attribute" rather than "node/@attribute".
	 * @return the value, or the empty string if the node identified by the path is missing.
	 */
	public String getValue(String path) {
		if (manifestXML == null) return "";
		return XmlUtil.getValueViaPath(manifestXML.getDocumentElement(),path);
	}

	/**
	 * Get an array of ZipEntry objects corresponding to the files
	 * in the ZipObject. This method does not return ZipEntry objects
	 * which correspond to directories.
	 * @return the array of ZipEntry objects corresponding to the files
	 * in the ZipObject, or null if the ZipObject cannot be read.
	 */
	public ZipEntry[] getEntries() {
		try {
			ZipEntry[] entries = null;
			ZipFile zipFile = new ZipFile(file);
			ZipEntry ze;
			Enumeration<? extends ZipEntry> e = zipFile.entries();
			//Get the ZipEntries corresponding to files (not directories).
			ArrayList<ZipEntry> list = new ArrayList<ZipEntry>();
			for (int i=0; e.hasMoreElements(); i++) {
				ze = e.nextElement();
				if (!ze.isDirectory()) list.add(ze);
			}
			entries = new ZipEntry[list.size()];
			entries = list.toArray(entries);
			return entries;
		}
		catch (Exception ex) { return null; }
	}

	/**
	 * Unpack the ZipObject using the directory structure of the zip file.
	 * @param dir the directory into which to unpack the zip file. This becomes
	 * root directory of the file tree of the object. Files with no path information
	 * are placed in this directory; files with path information are placed in child
	 * directories with this directory as the root. Directories are created when necessary.
	 * @return true if the operation succeeded; false otherwise.
	 */
	public boolean extractAll(File dir) {
		BufferedOutputStream out = null;
		BufferedInputStream in = null;
		ZipFile zipFile = null;
		if (!file.exists()) return false;
		if (!dir.isDirectory()) return false;
		String path = dir.getAbsolutePath();
		if (!path.endsWith(File.separator)) path += File.separator;
		try {
			zipFile = new ZipFile(file);
			Enumeration<? extends ZipEntry> zipEntries = zipFile.entries();
			while (zipEntries.hasMoreElements()) {
				ZipEntry entry = zipEntries.nextElement();
				String name = entry.getName().replace('/',File.separatorChar);
				File outFile = new File(path + name);
				if (!entry.isDirectory()) {
					outFile.getParentFile().mkdirs();
					out = new BufferedOutputStream(new FileOutputStream(outFile));
					in = new BufferedInputStream(zipFile.getInputStream(entry));
					FileUtil.copy(in, out, -1);
				}
				else outFile.mkdirs();
			}
			zipFile.close();
			return true;
		}
		catch (Exception e) {
			try {
				if (zipFile != null) zipFile.close();
				if (in != null) in.close();
				if (out != null) out.close();
			}
			catch (Exception ignore) { logger.warn("Unable to close zipFile."); }
			return false;
		}
	}

	/**
	 * Unpack the file corresponding to a ZipEntry and place it in a specified directory.
	 * If the directory does not exist, it is created.
	 * @param entry the entry pointing to the desired file in the zip file. This can be
	 * one of the entries in the array returned by getEntries().
	 * @param dir the directory into which to unpack the zip file. This becomes
	 * root directory of the file tree of the object. Files with no path information
	 * are placed in this directory; files with path information are placed in child
	 * directories with this directory as the root. Directories are created when necessary.
	 * @return true if the operation succeeded; false otherwise.
	 */
	public boolean extractFile(ZipEntry entry, File dir) {
		BufferedOutputStream out = null;
		BufferedInputStream in = null;
		ZipFile zipFile = null;
		if (!file.exists()) return false;
		if (!dir.exists()) dir.mkdirs();
		try {
			zipFile = new ZipFile(file);
			File outFile = new File(entry.getName().replace('/',File.separatorChar));
			outFile = new File(dir,outFile.getName());
			if (!entry.isDirectory()) {
				outFile.getParentFile().mkdirs();
				out = new BufferedOutputStream(new FileOutputStream(outFile));
				in = new BufferedInputStream(zipFile.getInputStream(entry));
				FileUtil.copy(in, out, -1);
				zipFile.close();
				return true;
			}
		}
		catch (Exception e) { }
		FileUtil.close(in);
		FileUtil.close(out);
		FileUtil.close(zipFile);
		return false;
	}

	/**
	 * Unpack the file corresponding to a ZipEntry and place it in a specified directory
	 * with a specified file name. No path information from the Zip Entry is used.
	 * If the directory does not exist, it is created. If the ZipEntry is a directory,
	 * nothing is done and false is returned.
	 * @param entry the entry pointing to the desired file in the zip file. This can be
	 * one of the entries in the array returned by getEntries().
	 * @param dir the directory into which to unpack the zip file.
	 * @param name the file name for the unpacked file.
	 * @return true if the operation succeeded; false otherwise.
	 */
	public boolean extractFile(ZipEntry entry, File dir, String name) {
		BufferedOutputStream out = null;
		BufferedInputStream in = null;
		ZipFile zipFile = null;
		if (!file.exists()) return false;
		if (!dir.exists()) dir.mkdirs();
		try {
			zipFile = new ZipFile(file);
			File outFile = new File(dir, name);
			if (!entry.isDirectory()) {
				outFile.getParentFile().mkdirs();
				out = new BufferedOutputStream(new FileOutputStream(outFile));
				in = new BufferedInputStream(zipFile.getInputStream(entry));
				FileUtil.copy(in, out, -1);
				zipFile.close();
				return true;
			}
		}
		catch (Exception e) { }
			FileUtil.close(in);
			FileUtil.close(out);
			FileUtil.close(zipFile);
		return false;
	}

	/**
	 * Unpack the file corresponding to a ZipEntry and return its contents as a String,
	 * using the iso-8859-1 character set (Latin-1).
	 * Care should be taken to use this method only on known text files.
	 * @param entry the entry pointing to the desired file in the zip file. This can be
	 * one of the entries in the array returned by getEntries().
	 * @return the text of the file if the operation succeeded, or the empty string if it failed.
	 */
	public String extractFileText(ZipEntry entry) {
		return extractFileText(entry, latin1);
	}

	/**
	 * Unpack the file corresponding to a ZipEntry and return its contents as a String,
	 * using the specified character set.
	 * Care should be taken to use this method only on known text files.
	 * @param entry the entry pointing to the desired file in the zip file. This can be
	 * one of the entries in the array returned by getEntries().
	 * @param charset the character encoding to be used for the bytes in the file.
	 * @return the text of the file if the operation succeeded, or the empty string if it failed.
	 */
	public String extractFileText(ZipEntry entry, Charset charset) {
		StringWriter sw = new StringWriter();
		BufferedReader in = null;
		ZipFile zipFile = null;
		if (!file.exists()) return "";
		try {
			zipFile = new ZipFile(file);
			if (!entry.isDirectory()) {
				in = new BufferedReader(
							new InputStreamReader(zipFile.getInputStream(entry),charset));
				int size = 1024;
				int n = 0;
				char[] c = new char[size];
				while ((n = in.read(c,0,size)) != -1) sw.write(c,0,n);
				in.close();
			}
			zipFile.close();
			return sw.toString();
		}
		catch (Exception e) {
			try {
				if (zipFile != null) zipFile.close();
				if (in != null) in.close();
			}
			catch (Exception ignore) { logger.warn("Unable to close zipFile."); }
			return "";
		}
	}

	/**
	 * Evaluate a boolean script for the manifest of this ZipObject.
	 * See the RSNA CTP wiki article (The CTP XmlFilter) for information
	 * on the script language.
	 * @param scriptFile the text file containing the expression to
	 * compute based on the values in this ZipObject.
	 * @return the computed boolean value of the script, or false if
	 * the object does not contain a manifest.
	 */
	public boolean matches(File scriptFile) {
		String script = FileUtil.getText(scriptFile);
		if (manifestXML != null) XmlUtil.matches(manifestXML, script);
		return false;
	}

	/**
	 * Evaluate a boolean script for the manifest of this ZipObject.
	 * See the RSNA CTP wiki article (The CTP XmlFilter) for information
	 * on the script language.
	 * @param script the expression to compute based on the values
	 * in this ZipObject.
	 * @return the computed boolean value of the script, or false if
	 * the object does not contain a manifest.
	 */
	public boolean matches(String script) {
		if (manifestXML != null) XmlUtil.matches(manifestXML, script);
		return false;
	}

}


text:
@interface Menu : CCLayer<GameKitHelperProtocol>{
	CCParticleSystemQuad *emitter;
	CCSprite *company;
	CGSize winSize;
	float gravityValue;
}
+(id) scene;

@end


text:
@interface QYSearchTextView : QYBasicTextFiled

@end


text:
using System;
using System.Xml.Serialization;
using Aop.Api.Domain;

namespace Aop.Api.Response
{
    /// <summary>
    /// AlipayEcoMycarParkingConfigQueryResponse.
    /// </summary>
    public class AlipayEcoMycarParkingConfigQueryResponse : AopResponse
    {
        /// <summary>
        /// 签约支付宝账号,开发者通过ISV系统配置信息注册接口(alipay.eco.mycar.parking.config.set)传入的参数值
        /// </summary>
        [XmlElement("account_no")]
        public string AccountNo { get; set; }

        /// <summary>
        /// 业务接口列表数据  Json格式数据
        /// </summary>
        [XmlElement("interface_info_list")]
        public InterfaceInfoList InterfaceInfoList { get; set; }

        /// <summary>
        /// 商户在停车平台首页露出的LOGO链接地址,开发者通过ISV系统配置信息注册接口(alipay.eco.mycar.parking.config.set)调用自动生成该链接
        /// </summary>
        [XmlElement("merchant_logo")]
        public string MerchantLogo { get; set; }

        /// <summary>
        /// 商户简称,开发者通过ISV系统配置信息注册接口(alipay.eco.mycar.parking.config.set)传入的参数值
        /// </summary>
        [XmlElement("merchant_name")]
        public string MerchantName { get; set; }

        /// <summary>
        /// 商户客服电话,开发者通过ISV系统配置信息注册接口(alipay.eco.mycar.parking.config.set)传入的参数值
        /// </summary>
        [XmlElement("merchant_service_phone")]
        public string MerchantServicePhone { get; set; }
    }
}


text:
import os

module = None
for module in os.listdir(os.path.dirname(__file__)):
    if module == '__init__.py' or module[-3:] != '.py':
        continue
    __import__(module[:-3], locals(), globals())
del module


text:
package com.jade.customervisit.util;

import com.jade.customervisit.network.IAsyncListener;
import com.jade.customervisit.network.IAsyncListener.ResultParser;

import android.os.Handler;

/**
 * 解析器抽象类
 *
 * @author zhoushujie
 *
 * @param <T>
 */
public abstract class AbsBaseParser<T> implements ResultParser<T> {

    protected Handler handler = new Handler();

    protected IAsyncListener<T> listener = new IAsyncListener<T>() {

        @Override
        public void onSuccess(T result) {
            // TODO Auto-generated method stub

        }

        @Override
        public void onSuccess(int stateCode, T result) {
            // TODO Auto-generated method stub

        }

        @Override
        public void onFailure(Exception error, String content) {
            // TODO Auto-generated method stub

        }

        @Override
        public void onStart() {
            // TODO Auto-generated method stub

        }

        @Override
        public void onStopped() {
            // TODO Auto-generated method stub

        }

        @Override
        public void onStopped(T result) {
            // TODO Auto-generated method stub

        }

        @Override
        public void onLoading(Object... values) {
            // TODO Auto-generated method stub

        }

        @Override
        public T parseResult(String response) {
            // TODO Auto-generated method stub
            return null;
        }

    };

    public AbsBaseParser() {
    }

    public AbsBaseParser(IAsyncListener<T> listener) {
        if (listener != null) {
            this.listener = listener;
        }
    }

    public void onFailure(final Exception e) {
        if (listener != null) {
            handler.post(new Runnable() {

                @Override
                public void run() {
                    listener.onFailure(e, "解析异常");
                }
            });
        }
    }
}


text:
<?php

namespace apisnetworks\Beacon;

class Client {
	const ENDPOINT = 'http://localhost:2082/soap';
	const WSDL = '/apnscp.wsdl';

	/**
	 * @var \SoapClient
	 */
	protected $client;

	protected $key;

	public function __construct($key, $endpoint, array $options = []) {
		$this->setKey($key);
		$options['location'] = $endpoint . '?authkey=' . $this->key;
		$this->client = new \SoapClient(
			static::makeWSDL($endpoint),
			$options
		);
	}

	protected static function makeWSDL($endpoint) {
		return dirname($endpoint) . static::WSDL;
	}

	public function __call($method, $args = null) {
		if (empty($this->key)) {
			throw new \RuntimeException("no API key set");
		}
		try {
			$response = $this->client->__soapCall($method, $args);
		} catch (\SoapFault $e) {
			if (strstr($e->getMessage(), "is not a valid method for this service")) {
				// WSDL determines whether method may be invoked before sending
				throw $e;
			}
			if ($this->client->trace) {
				print ">>> REQUEST HEADERS: ";
				print $this->client->__getLastRequestHeaders();
				print PHP_EOL . PHP_EOL;
				print "<<< RESPONSE BODY: ";
				print $this->client->__getLastResponse();
			}
			throw $e;
		}
		return $response;

	}

	public function setKey($key) {
		$this->key = preg_replace('/[\s-]+/', '', $key);
	}

	public function getKey() {
		return $this->key;
	}
}


text:
package dst.lib.io

import play.api.Play.current
import play.Logger

import play.api.libs.ws._
import com.ning.http.client.Realm.AuthScheme

import scala.concurrent._
import scala.concurrent.duration._

import java.nio.file.Files;
import java.nio.file.{Path, Paths};
import java.util.zip.GZIPInputStream

import org.apache.commons.io.IOUtils

import scala.concurrent._
import scala.concurrent.duration._
import scala.concurrent.ExecutionContext

object HttpDownloader {
  def download(url: String, localDirectory: Path, headers: Option[Map[String, String]] = None, credentials: Option[(String, String)] = None)(implicit timeout: Duration, context: ExecutionContext): Future[Path] = {
    val remoteName = Paths.get(url).getFileName.toString
    val outputPath = localDirectory.resolve(remoteName).normalize

    Files.createDirectories(localDirectory)

    Logger.info(s"Downloading $url to $outputPath")

    def withHeaders(request: WS.WSRequestHolder): WS.WSRequestHolder = headers.foldLeft(request) { (request, headers) => request.withHeaders((headers + ("Accept-Encoding" -> "gzip")).toSeq:_*) }
    def withCredentials(request: WS.WSRequestHolder): WS.WSRequestHolder = credentials.foldLeft(request) { (request, credentials) => request.withAuth(credentials._1, credentials._2, AuthScheme.BASIC) }

    val request = withCredentials(withHeaders(WS.url(url)))

    val promise = request.withRequestTimeout(timeout.toMillis.toInt).get() map { response =>
      val outputStream = Files.newOutputStream(outputPath);
      try {
        val inputStream = response .header("Content-Encoding") match {
          case Some("gzip") => new GZIPInputStream(response.getAHCResponse.getResponseBodyAsStream)
          case _ => response.getAHCResponse.getResponseBodyAsStream
        }

        IOUtils.copy(inputStream, outputStream);
        outputStream.flush();
        inputStream.close()

        outputPath
      } finally {
        outputStream.close()
      }
    }

    promise.onFailure { case t: Throwable => Logger.info(t.toString) }
    promise
  }
}


text:
namespace fsm { namespace aux {

namespace mpl = boost::mpl;
using namespace mpl::placeholders;

template< typename Transition >
struct STT_void_row_impl
{
    typedef typename Transition::from_state_t   state_t;
    typedef typename Transition::fsm_t          fsm_t;
    typedef typename Transition::base_event_t   base_event_t;

    static long do_process_event(fsm_t&, long state, base_event_t const&)
    {
        assert(false);
        return state;
    }

    static long do_transition(fsm_t&, long state, base_event_t const&)
    {
        assert(false);
        return state;
    }
};

template<
      typename PrevRowImpl
    , typename Transition
    >
struct STT_event_row_impl
    : PrevRowImpl
{
    typedef typename Transition::from_state_t   state_t;
    typedef typename Transition::fsm_t          fsm_t;
    typedef typename Transition::base_event_t   base_event_t;

    static long do_process_event(fsm_t& fsm, long state, base_event_t const& evt)
    {
        if (typeid(typename Transition::event_t) == typeid(evt))
        {
            // typedefs are here to make GCC happy
            typedef typename Transition::to_state_t to_state_;
            typedef typename Transition::from_state_t from_state_;

            return Transition::do_transition(fsm, evt)
                ? to_state_::do_check_invariant(fsm)
                : from_state_::do_check_invariant(fsm)
                ;
        }

        return PrevRowImpl::do_process_event(fsm, state, evt);
    }
};

template<
      typename PrevRowImpl
    , typename StateType
    >
struct STT_state_row_impl
    : PrevRowImpl
{
    typedef typename PrevRowImpl::fsm_t         fsm_t;
    typedef typename PrevRowImpl::base_event_t  base_event_t;

    static long do_transition(fsm_t& fsm, long state, base_event_t const& evt)
    {
        return state == StateType::value
            ? PrevRowImpl::do_process_event(fsm, state, evt)
            : PrevRowImpl::do_transition(fsm, state, evt)
            ;
    }

    static long do_process_event(fsm_t&, long state, base_event_t const&)
    {
        assert(false);
        return state;
    }
};

template<
      typename PrevRowImpl
    , typename Transition
    >
struct STT_row_impl
{
    typedef typename mpl::if_<
          boost::is_same<
              typename PrevRowImpl::state_t
            , typename Transition::from_state_t
            >
        , STT_event_row_impl< PrevRowImpl,Transition >
        , STT_event_row_impl<
              STT_state_row_impl< PrevRowImpl,typename PrevRowImpl::state_t >
            , Transition
            >
        >::type type;
};

template< typename Transitions >
struct STT_impl_gen
{
 private:
    typedef typename mpl::front<Transitions>::type first_;
    typedef typename mpl::fold<
          Transitions
        , STT_void_row_impl<first_>
        , STT_row_impl<_,_>
        >::type STT_impl_;

 public:
    typedef STT_state_row_impl<
          STT_impl_
        , typename STT_impl_::state_t
        > type;
};

}}

#endif // BOOST_FSM_HANDLER_INCLUDED


text:
import pygame
from pygame.locals import *
from sys import exit
from random import randint

pygame.init()
screen = pygame.display.set_mode((640, 480), 0, 32)

while True:

    for event in pygame.event.get():
        if event.type == QUIT:
            pygame.quit()
            exit()

    rand_col = (randint(0, 255), randint(0, 255), randint(0, 255))
    for _ in range(100):
        rand_pos = (randint(0, 639), randint(0, 479))
        screen.set_at(rand_pos, rand_col)

    pygame.display.update()


text:
require 'quick_travel/adapter'

module QuickTravel
  class Product < Adapter
    attr_reader :error_message

    self.api_base = '/api/products'

    # Find product details for a given product
    #
    # Options are::tabnew
    #   passenger_types: {<passenger_type_id> => <num_pax>, ...},
    #   date_range: {start_date: <date>, end_date: <date>}
    def self.find(id, params = {})
      if params[:passenger_type_numbers].blank?
        fail ArgumentError, 'Product#find requires passenger_type_numbers'
      end
      if params[:date_range].blank?
        fail ArgumentError, 'Product#find requires date_range'
      end
      super
    end

    def self.bulk_availability(resource_ids, date_from, date_to, units)
      request_params = {
        resource_ids: resource_ids,
        date_from:    date_from,
        date_to:      date_to,
        units:        units
      }
      get_and_validate('/api/availability/bulk.json', request_params)
    end

    def self.unavailable_dates(resource_ids, date_from, date_to)
      request_params = {
        resource_ids: resource_ids,
        date_from:    date_from,
        date_to:      date_to
      }
      get_and_validate('/api/availability/unavailable_dates.json', request_params)
    end

    # Returns minified mega structure:
    #
    # products_by_resource_id_and_date
    # {
    #   <resource-id> => {<date> => <product-instance>, ...},
    #   ...
    # }
    def self.fetch_and_arrange_by_resource_id_and_date(resource_ids, options = {})
      request_params = options.clone
      request_params[:resource_ids] = resource_ids

      # Returned call mega-structure is:
      # [
      #   {
      #     "resource" => {"id" => <resource-id>, "name" => <resource-name>},
      #     "bookability" => {
      #       <date-as-string>  => {<product-attrs}
      #       ...
      #     }
      #   },
      #   ...
      # ]
      complex_data = get_and_validate('/api/products/date_range_bookability.json', request_params)
      complex_data ||= {}

      products_by_resource_id_and_date = {}

      # Go through shitty complex_grid_data
      complex_data.each do |resource_and_bookability_hash|
        resource_id = resource_and_bookability_hash.fetch('resource', {}).fetch('id', nil)
        product_attrs_by_date = resource_and_bookability_hash.fetch('bookability', {})

        products_by_resource_id_and_date[resource_id] = {}
        product_attrs_by_date.each do |date, product_attrs|
          products_by_resource_id_and_date[resource_id][date] = new(product_attrs)
        end
      end

      products_by_resource_id_and_date
    end

    # needed as captain cook grid cell exepcts them to be defined
    attr_reader :pricing_details_for_rack_rate,
                :pricing_details_without_rules

    def id
      @reservation_attributes['resource_id']
    end

    def name
      @selection_name
    end

    def available?
      !!@available
    end

    def extras=(extra_attrs)
      @extras = extra_attrs.map do |extra_attr|
        QuickTravel::Product.new(extra_attr)
      end
    end

    def select_extras_by_id(selected_ids)
      @extras.select { |extra| selected_ids.include? extra.id }
    end

    def resource=(resource_hash)
      @resource = QuickTravel::Resource.new(resource_hash)
    end

    def availability_details=(availability_details)
      @availability_details = AvailabilityDetails.new(availability_details)
    end

    def pricing_details=(pricing_details)
      @pricing_details = PricingDetails.new(pricing_details)
    end

    def pricing_details_for_rack_rate=(pricing_details_for_rack_rate)
      @pricing_details_for_rack_rate = PricingDetails.new(pricing_details_for_rack_rate)
    end

    def pricing_details_without_rules=(pricing_details_without_rules)
      @pricing_details_without_rules = PricingDetails.new(pricing_details_without_rules)
    end
  end

  class PricingDetails < Adapter
    # define to avoid auto definition as money getter
    # due to _in_cents postfix
    def adjustments_to_apply_in_cents
      @adjustments_to_apply_in_cents
    end

    def price_per_pax_type=(pax_type_hash)
      @price_per_pax_type = convert_pax_type_hash(pax_type_hash)
    end

    def convert_pax_type_hash(pax_type_hash)
      pax_type_hash.each.with_object({}) { |(type, cents), hash| hash[type.to_i] = Money.new(cents.to_i) }
    end
  end

  class AvailabilityDetails < Adapter
  end

  class PricePerPaxType < Adapter
  end
end


text:
package com.mopub.mobileads;

import android.app.Activity;
import android.content.Context;
import android.graphics.drawable.Drawable;
import android.view.View;
import android.widget.TextView;

import com.mopub.mobileads.resource.TextDrawable;
import com.mopub.common.test.support.SdkTestRunner;

import org.junit.Before;
import org.junit.Test;
import org.junit.runner.RunWith;

import static org.fest.assertions.api.Assertions.assertThat;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.spy;
import static org.mockito.Mockito.verify;
import static org.robolectric.Robolectric.shadowOf;

@RunWith(SdkTestRunner.class)
public class VastVideoToolbarTest {
    private Context context;
    private VastVideoToolbar subject;
    private View.OnTouchListener onTouchListener;

    @Before
    public void setUp() throws Exception {
        context = new Activity();
        subject = new VastVideoToolbar(context);

        onTouchListener = mock(View.OnTouchListener.class);
    }

    @Test
    public void constructor_shouldSetOnTouchListenerThatConsumesAllTouchEvents() throws Exception {
        final View.OnTouchListener onTouchListener = shadowOf(subject).getOnTouchListener();

        assertThat(onTouchListener).isNotNull();
        assertThat(onTouchListener.onTouch(null, null)).isTrue();
    }

    @Test
    public void constructor_shouldAddWidgetsToToolbar() throws Exception {
        assertThat(subject.getChildCount()).isEqualTo(4);

        assertThat(subject.getDurationWidget().getParent()).isEqualTo(subject);
        assertThat(subject.getLearnMoreWidget().getParent()).isEqualTo(subject);
        assertThat(subject.getCountdownWidget().getParent()).isEqualTo(subject);
        assertThat(subject.getCloseButtonWidget().getParent()).isEqualTo(subject);
    }

    @Test
    public void constructor_shouldOnlyStartWithDurationWidgetsVisible() throws Exception {
        assertThat(subject.getDurationWidget().getVisibility()).isEqualTo(View.VISIBLE);
        assertThat(subject.getLearnMoreWidget().getVisibility()).isEqualTo(View.INVISIBLE);
        assertThat(subject.getCountdownWidget().getVisibility()).isEqualTo(View.INVISIBLE);
        assertThat(subject.getCloseButtonWidget().getVisibility()).isEqualTo(View.GONE);
    }

    @Test
    public void makeInteractable_shouldHideCountdownWidgetAndShowLearnMoreAndCloseButtonWidgets() throws Exception {
        subject.makeInteractable();

        assertThat(subject.getDurationWidget().getVisibility()).isEqualTo(View.VISIBLE);
        assertThat(subject.getLearnMoreWidget().getVisibility()).isEqualTo(View.VISIBLE);
        assertThat(subject.getCountdownWidget().getVisibility()).isEqualTo(View.GONE);
        assertThat(subject.getCloseButtonWidget().getVisibility()).isEqualTo(View.VISIBLE);
    }

    @Test
    public void setCloseButtonOnTouchListener_shouldPropagateToCloseButtonWidget() throws Exception {
        subject.setCloseButtonOnTouchListener(onTouchListener);

        assertThat(shadowOf(subject.getCloseButtonWidget()).getOnTouchListener()).isEqualTo(onTouchListener);
    }

    @Test
    public void setLearnButtonOnTouchListener_shouldPropagateToLearnButtonWidget() throws Exception {
        subject.setLearnMoreButtonOnTouchListener(onTouchListener);

        assertThat(shadowOf(subject.getLearnMoreWidget()).getOnTouchListener()).isEqualTo(onTouchListener);
    }

    @Test
    public void convertMillisecondsToSecondsRoundedUp_shouldReturnLongMillisecondsAsRoundedUpLongSeconds() throws Exception {
        assertThat(subject.convertMillisecondsToSecondsRoundedUp(0)).isEqualTo(0);

        assertThat(subject.convertMillisecondsToSecondsRoundedUp(1)).isEqualTo(1);
        assertThat(subject.convertMillisecondsToSecondsRoundedUp(999)).isEqualTo(1);
        assertThat(subject.convertMillisecondsToSecondsRoundedUp(1000)).isEqualTo(1);

        assertThat(subject.convertMillisecondsToSecondsRoundedUp(1001)).isEqualTo(2);
        assertThat(subject.convertMillisecondsToSecondsRoundedUp(100000)).isEqualTo(100);
    }

    @Test
    public void formatTime_shouldReturnLongMillisecondsAsFormattedString() {
        assertThat(subject.formatTime(-8999)).isEqualTo("-8 seconds");
        assertThat(subject.formatTime(-9000)).isEqualTo("-9 seconds");
        assertThat(subject.formatTime(-9001)).isEqualTo("-9 seconds");
        assertThat(subject.formatTime(0)).isEqualTo("0 seconds");

        assertThat(subject.formatTime(1)).isEqualTo("1 second");
        assertThat(subject.formatTime(1000)).isEqualTo("1 second");
        assertThat(subject.formatTime(1005)).isEqualTo("2 seconds");

        assertThat(subject.formatTime(59999)).isEqualTo("60 seconds");
        assertThat(subject.formatTime(60000)).isEqualTo("60 seconds");
        assertThat(subject.formatTime(60001)).isEqualTo("61 seconds");
        assertThat(subject.formatTime(853437)).isEqualTo("854 seconds");

        assertThat(subject.formatTime(3599999)).isEqualTo("3600 seconds");
        assertThat(subject.formatTime(3600000)).isEqualTo("3600 seconds");
        assertThat(subject.formatTime(3600001)).isEqualTo("3601 seconds");
        assertThat(subject.formatTime(3660001)).isEqualTo("3661 seconds");
        assertThat(subject.formatTime(65784693)).isEqualTo("65785 seconds");
    }

    @Test
    public void updateCountdownWidget_shouldUpdateTextDrawablesDisplayNumber() throws Exception {
        final TextDrawable countdownImageSpy = spy((TextDrawable) subject.getCountdownWidget().getImageViewDrawable());
        subject.getCountdownWidget().setImageViewDrawable((Drawable) countdownImageSpy);

        subject.updateCountdownWidget(1002);

        verify(countdownImageSpy).updateText("2");
    }

    @Test
    public void updateCountdownWidget_shouldHideCloseButtonAndShowCountdown() throws Exception {
        subject.getCloseButtonWidget().setVisibility(View.INVISIBLE);
        subject.getCountdownWidget().setVisibility(View.INVISIBLE);

        subject.updateCountdownWidget(1);

        assertThat(subject.getCloseButtonWidget().getVisibility()).isEqualTo(View.GONE);
        assertThat(subject.getCountdownWidget().getVisibility()).isEqualTo(View.VISIBLE);
    }

    @Test
    public void updateCountdownWidget_whenRemainingTimeIsNegative_shouldNotModifyWidgetVisibility() throws Exception {
        subject.getCloseButtonWidget().setVisibility(View.INVISIBLE);
        subject.getCountdownWidget().setVisibility(View.INVISIBLE);

        subject.updateCountdownWidget(-1);

        assertThat(subject.getCloseButtonWidget().getVisibility()).isEqualTo(View.INVISIBLE);
        assertThat(subject.getCountdownWidget().getVisibility()).isEqualTo(View.INVISIBLE);
    }

    @Test
    public void updateDurationWidget_shouldShowWhenVideoEnds() throws Exception {
        final TextView durationWidgetTextView = getDurationWidgetTextView();

        assertThat(durationWidgetTextView.getText()).isEqualTo("");

        subject.updateDurationWidget(100000);

        assertThat(durationWidgetTextView.getText()).isEqualTo("Ends in 100 seconds");

        subject.updateDurationWidget(99000);

        assertThat(durationWidgetTextView.getText()).isEqualTo("Ends in 99 seconds");
    }

    @Test
    public void updateDurationWidget_whenBelowThresholdForHidingVideoDuration_shouldShowThanksForWatching() throws Exception {
        final TextView durationWidgetTextView = getDurationWidgetTextView();

        assertThat(durationWidgetTextView.getText()).isEqualTo("");

        subject.updateDurationWidget(50000);

        assertThat(durationWidgetTextView.getText()).isEqualTo("Ends in 50 seconds");

        // 200ms of remaining video is the cut off for switching to "Thanks for watching"
        subject.updateDurationWidget(200);

        assertThat(durationWidgetTextView.getText()).isEqualTo("Ends in 1 second");

        subject.updateDurationWidget(199);

        assertThat(durationWidgetTextView.getText()).isEqualTo("Thanks for watching");
    }

    @Test
    public void updateDurationWidget_whenRemainingTimeIsNegative_shouldDoNothing() throws Exception {
        final TextView durationWidgetTextView = getDurationWidgetTextView();

        assertThat(durationWidgetTextView.getText()).isEqualTo("");

        subject.updateDurationWidget(-1);

        assertThat(durationWidgetTextView.getText()).isEqualTo("");
    }

    private TextView getDurationWidgetTextView() {
        final ToolbarWidget durationWidget = subject.getDurationWidget();
        final int childCount = durationWidget.getChildCount();
        for (int i = 0; i < childCount; i++) {
            final View child = durationWidget.getChildAt(i);
            if (child instanceof TextView) {
                return (TextView) child;
            }
        }
        return null;
    }
}


text:
require_relative 'auditable'

module StudioGame

  class Die
    include Auditable

    attr_accessor :number

    def initialize
      @number = roll
    end

    def roll
      @number = rand 1..6
      audit
      return @number
    end
  end

end


text:
function MasterView() {
	//create object instance, parasitic subclass of Observable
	var self = Ti.UI.createView({
		backgroundColor:'white'
	});

	//some dummy data for our table view
	var tableData = [
		{title: "Ruso Negro", receta:"Receta de Ruso Negro", imagen: "images/8316_20130705204436.jpeg" },
        {title: "Cosmopolitan", receta:"Como preparar la Cosmopolitan", imagen: "images/1.jpg"},
        {title: "Shoot", receta:"Así se prepara el tequila shot", imagen: "images/tequila_shot-263x300.png"},
        {title: "Piñada", receta:"Las  infalibles piñadas", imagen: "images/Pinacolada.jpg"},
        {title: "Ron", receta:"Este es el ron.", imagen: "images/conRon.jpg"}
	];

	var searchbar = Ti.UI.createSearchBar({
    	barcolor: '#385292',
		showCancel: false
	});

	var table = Ti.UI.createTableView({
		data:tableData,
		search: searchbar,
    	hideSearchOnSelection: true,
    	hasChild: true
	});
	self.add(table);

	//add behavior
	table.addEventListener('click', function(e) {
		self.fireEvent('itemSelected', {
			name:e.rowData.title,
			receta:e.rowData.receta,
			imagen: e.rowData.imagen
		});
	});

	return self;
};

module.exports = MasterView;


text:
<!DOCTYPE html>
<html lang="en">
<head>

  <meta charset="UTF-8" />
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />

  <!-- Custom CSS -->
  <link href="<?php echo base_url(); ?>assets/matrix/css/custom.css" rel="stylesheet">

  <!-- CSS -->

  <link rel="stylesheet" href="<?php echo base_url(); ?>assets/css/animate.css" />
  <link rel="stylesheet" href="<?php echo base_url(); ?>assets/matrix/css/bootstrap.min.css" />
  <link rel="stylesheet" href="<?php echo base_url(); ?>assets/matrix/css/uniform.css" />
  <link rel="stylesheet" href="<?php echo base_url(); ?>assets/matrix/css/select2.css" />
  <link rel="stylesheet" href="<?php echo base_url(); ?>assets/matrix/css/bootstrap-responsive.min.css" />

  <!--!! <link rel="stylesheet" href="<?php echo base_url(); ?>assets/matrix/css/fullcalendar.css" /> -->

  <link rel="stylesheet" href="<?php echo base_url(); ?>assets/matrix/css/matrix-style.css" />
  <link rel="stylesheet" href="<?php echo base_url(); ?>assets/matrix/css/matrix-media.css" />
  <link href="<?php echo base_url(); ?>assets/matrix/font-awesome/css/font-awesome.css" rel="stylesheet" />
  <link href="<?php echo base_url(); ?>assets/css/font-awesome-4.7.0/css/font-awesome.min.css" rel="stylesheet" />

  <!--!! <link rel="stylesheet" href="<?php echo base_url(); ?>assets/matrix/css/jquery.gritter.css" /> -->

  <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,800' rel='stylesheet' type='text/css'>

  <!-- JAVASCRIPT -->

  <script src="<?php echo base_url(); ?>assets/matrix/js/excanvas.min.js"></script>
  <script src="<?php echo base_url(); ?>assets/matrix/js/jquery.min.js"></script>
  <!-- <script src="<?php echo base_url(); ?>assets/js/jquery.min.js"></script>  -->
  <script src="<?php echo base_url(); ?>assets/js/noty/packaged/jquery.noty.packaged.min.js"></script>
  <!-- <script src="<?php echo base_url(); ?>assets/js/noty/themes/relax.js"></script> -->

  <script src="<?php echo base_url(); ?>assets/js/dept-dashboard.js"></script>
  <script src="<?php echo base_url(); ?>assets/matrix/js/jquery.ui.custom.js"></script>
  <script src="<?php echo base_url(); ?>assets/matrix/js/bootstrap.min.js"></script>

  <!-- <script src="<?php echo base_url(); ?>assets/matrix/js/jquery.flot.min.js"></script>   -->
  <!-- <script src="<?php echo base_url(); ?>assets/matrix/js/jquery.flot.resize.min.js"></script>   -->

  <script src="<?php echo base_url(); ?>assets/matrix/js/jquery.peity.min.js"></script>
  <!-- <script src="<?php echo base_url(); ?>assets/matrix/js/fullcalendar.min.js"></script>  -->
  <script src="<?php echo base_url(); ?>assets/matrix/js/matrix.js"></script>

  <!--!! <script src="<?php echo base_url(); ?>assets/matrix/js/matrix.dashboard.js"></script>  -->
  <!--!! <script src="<?php echo base_url(); ?>assets/matrix/js/jquery.gritter.min.js"></script>  -->

  <script src="<?php echo base_url(); ?>assets/matrix/js/matrix.interface.js"></script>
  <!-- <script src="<?php echo base_url(); ?>assets/matrix/js/matrix.charts.js"></script>  -->

  <!--!! <script src="<?php echo base_url(); ?>assets/matrix/js/matrix.calendar.js"></script> -->

  <!-- <script src="<?php echo base_url(); ?>assets/matrix/js/jquery.validate.js"></script>  -->
  <!-- <script src="<?php echo base_url(); ?>assets/matrix/js/matrix.form_validation.js"></script>  -->
  <!-- <script src="<?php echo base_url(); ?>assets/matrix/js/jquery.wizard.js"></script>  -->
  <script src="<?php echo base_url(); ?>assets/matrix/js/jquery.uniform.js"></script>
  <script src="<?php echo base_url(); ?>assets/matrix/js/select2.min.js"></script>
  <!-- <script src="<?php echo base_url(); ?>assets/matrix/js/matrix.popover.js"></script>  -->
  <script src="<?php echo base_url(); ?>assets/matrix/js/jquery.dataTables.min.js"></script>
  <script src="<?php echo base_url(); ?>assets/matrix/js/matrix.tables.js"></script>
  <script src="<?php echo base_url(); ?>assets/js/jquery.canvasjs.min.js"></script>
  <!-- <script src="<?php echo base_url(); ?>assets/js/parsley.min.js"></script> -->

  <script type="text/javascript">
  // This function is called from the pop-up menus to transfer to
  // a different page. Ignore if the value returned is a null string:
  function goPage (newURL) {

      // if url is empty, skip the menu dividers and reset the menu selection to default
      if (newURL != "") {

          // if url is "-", it is this page -- reset the menu:
          if (newURL == "-" ) {
            resetMenu();
          }
          // else, send page to designated URL
          else {
            document.location.href = newURL;
          }
        }
      }

// resets the menu selection upon entry to this page:
function resetMenu() {
 document.gomenu.selector.selectedIndex = 2;
}
</script>
</head>


text:
package ca.mahram.demo.picasso;

import android.app.Activity;
import android.net.Uri;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ImageView;
import android.widget.ListView;
import android.widget.TextView;

import com.squareup.picasso.Picasso;

public class ListDemo
  extends Activity {

    private LayoutInflater inflater;
    private Picasso        picasso;

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

        getActionBar ().setDisplayHomeAsUpEnabled (true);

        picasso = DemoConstants.picasso (this);
        inflater = LayoutInflater.from (this);

        final ListView list = (ListView) findViewById (android.R.id.list);
        list.setAdapter (new DemoListAdapter ());
    }

    @Override
    public boolean onCreateOptionsMenu (Menu menu) {
        return false;
    }

    private class DemoListAdapter
      extends AbstractDemoAdapter {

        @Override protected void bindView (final View row, final Uri item) {
            final ListRowTag tag = (ListRowTag) row.getTag ();

            picasso.load (item)
                   .error (R.drawable.error)
                   .into (tag.image);
            tag.title.setText (item.toString ());
        }

        @Override protected View newView (final ViewGroup parent) {
            final View view = inflater.inflate (R.layout.item_list, parent, false);
            view.setTag (new ListRowTag (view));
            return view;
        }
    }
}


text:
package com.java110.po.propertyRightRegistrationDetail;

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

/**
 * 类表述: Po 数据模型实体对象 基本保持与数据库模型一直 用于 增加修改删除 等时的数据载体
 * add by 吴学文 at 2021-10-11 09:15:52 mail: 928255095@qq.com
 * open source address: https://gitee.com/wuxw7/MicroCommunity
 * 官网:http://www.homecommunity.cn
 * 温馨提示:如果您对此文件进行修改 请不要删除原有作者及注释信息,请补充您的 修改的原因以及联系邮箱如下
 * // modify by 张三 at 2021-09-12 第10行在某种场景下存在某种bug 需要修复,注释10至20行 加入 20行至30行
 */
public class PropertyRightRegistrationDetailPo implements Serializable {

    private String prrId;
    private String prrdId;
    private String createUser;
    private String statusCd = "0";
    private String isTrue;
    private String state;
    private String securities;
    private String createTime;
    private List<String> idCardPhotos;
    private List<String> housePurchasePhotos;
    private List<String> repairPhotos;
    private List<String> deedTaxPhotos;

    public String getPrrId() {
        return prrId;
    }

    public void setPrrId(String prrId) {
        this.prrId = prrId;
    }

    public String getPrrdId() {
        return prrdId;
    }

    public void setPrrdId(String prrdId) {
        this.prrdId = prrdId;
    }

    public String getCreateUser() {
        return createUser;
    }

    public void setCreateUser(String createUser) {
        this.createUser = createUser;
    }

    public String getStatusCd() {
        return statusCd;
    }

    public void setStatusCd(String statusCd) {
        this.statusCd = statusCd;
    }

    public String getState() {
        return state;
    }

    public void setState(String state) {
        this.state = state;
    }

    public String getSecurities() {
        return securities;
    }

    public void setSecurities(String securities) {
        this.securities = securities;
    }

    public String getIsTrue() {
        return isTrue;
    }

    public void setIsTrue(String isTrue) {
        this.isTrue = isTrue;
    }

    public String getCreateTime() {
        return createTime;
    }

    public void setCreateTime(String createTime) {
        this.createTime = createTime;
    }

    public List<String> getIdCardPhotos() {
        return idCardPhotos;
    }

    public void setIdCardPhotos(List<String> idCardPhotos) {
        this.idCardPhotos = idCardPhotos;
    }

    public List<String> getHousePurchasePhotos() {
        return housePurchasePhotos;
    }

    public void setHousePurchasePhotos(List<String> housePurchasePhotos) {
        this.housePurchasePhotos = housePurchasePhotos;
    }

    public List<String> getRepairPhotos() {
        return repairPhotos;
    }

    public void setRepairPhotos(List<String> repairPhotos) {
        this.repairPhotos = repairPhotos;
    }

    public List<String> getDeedTaxPhotos() {
        return deedTaxPhotos;
    }

    public void setDeedTaxPhotos(List<String> deedTaxPhotos) {
        this.deedTaxPhotos = deedTaxPhotos;
    }
}


text:
#include "../stdafx.h"
#include "phidget_jni.h"
#include "com_phidgets_TextLEDPhidget.h"
#include "../cphidgettextled.h"

JNI_LOAD(led, TextLED)
}

JNI_CREATE(TextLED)
JNI_GETFUNC(TextLED, Brightness, Brightness, jint)
JNI_SETFUNC(TextLED, Brightness, Brightness, jint)
JNI_GETFUNC(TextLED, RowCount, RowCount, jint)
JNI_GETFUNC(TextLED, ColumnCount, ColumnCount, jint)

JNIEXPORT void JNICALL
Java_com_phidgets_TextLEDPhidget_setDisplayString(JNIEnv *env, jobject obj, jint index, jstring v)
{
	CPhidgetTextLEDHandle h = (CPhidgetTextLEDHandle)(uintptr_t)
	    (*env)->GetLongField(env, obj, handle_fid);
	int error;
    jboolean iscopy;
    const char *textString = (*env)->GetStringUTFChars(
                env, v, &iscopy);

	if ((error = CPhidgetTextLED_setDisplayString(h, index, (char *)textString)))
		PH_THROW(error);

	(*env)->ReleaseStringUTFChars(env, v, textString);
}


text:
namespace DetectorGraphConfig
{

enum DetectorGraphConfigEnum
{

    // This enum contains the hardcoded config/sizing parameters for a particular
    // graph. This header must be provided by the application. Ideally you'd want
    // this numbers as small as possible. If the numbers are too small an init-time
    // assert will fail pointing you to bump the one that is too small.
    // This numbers DO NOT change for a running graph, so if it starts it's good
    // forever.
    //
    // One can tie this numbers to kNumberOfTopicStateIds & NumberOfDetectors
    // for ideal sizing:
    // kMaxNumberOfVertices = TopicStateId::kNumberOfTopicStateIds + NumberOfDetectors,
    //
    // For the below sizes, using kNumberOfTopicStateIds is the conservative
    // option as it is a theoretical upper bound for those sizes.
    // kMaxNumberOfOutEdges = TopicStateId::kNumberOfTopicStateIds,
    // kMaxNumberOfInEdges = TopicStateId::kNumberOfTopicStateIds,
    // kMaxNumberOfTopics = TopicStateId::kNumberOfTopicStateIds,
    //
    // For the purposes of this example we can also hardcode them to sensible
    // numbers:
    kMaxNumberOfVertices = 3,
    kMaxNumberOfOutEdges = 1,
    kMaxNumberOfInEdges = 1,
    kMaxNumberOfTopicStates = 1,
    // TODO(DGRAPH-57): Using 0 for the two configs below causes a warning.
    kMaxNumberOfTimeouts = 1,
    kMaxNumberOfPeriodicTimers = 1,
};

}

#endif // DETECTORGRAPHCONFIG_H


text:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="vertical">

    <include layout="@layout/include_toolbar" />

    <FrameLayout
        android:id="@+id/fragment_container"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        tools:context="app.settings.SettingsActivity" />
</LinearLayout>


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

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>M-Index</title>
<meta name="date" content="2016-01-25">
<link rel="stylesheet" type="text/css" href="../stylesheet.css" title="Style">

JavaScript is disabled on your browser.

Overview

Package

Class

Use

Tree

Deprecated

Index

Help

Prev Letter

Next Letter

Frames

No Frames

All Classes

A B C D E F G H I L M N O P R S T U V

M

main(String[]) - Static method in class BEncoding.BencodingTest

main(String[]) - Static method in class Bittorrent

main(String[]) - Static method in class TorrentMetadata.TorrentFileTest

Manager - package Manager

Manager - Class in Manager

Manager() - Constructor for class Manager.Manager

A B C D E F G H I L M N O P R S T U V

Overview

Package

Class

Use

Tree

Deprecated

Index

Help

Prev Letter

Next Letter

Frames

No Frames

All Classes