text:
using namespace llvm;

STATISTIC(NumRemoved, "Number of invokes removed");
STATISTIC(NumUnreach, "Number of noreturn calls optimized");

namespace {
  struct PruneEH : public CallGraphSCCPass {
    static char ID; // Pass identification, replacement for typeid
    PruneEH() : CallGraphSCCPass(ID) {
      initializePruneEHPass(*PassRegistry::getPassRegistry());
    }

    // runOnSCC - Analyze the SCC, performing the transformation if possible.
    bool runOnSCC(CallGraphSCC &SCC);

    bool SimplifyFunction(Function *F);
    void DeleteBasicBlock(BasicBlock *BB);
  };
}

char PruneEH::ID = 0;
INITIALIZE_PASS_BEGIN(PruneEH, "prune-eh",
                "Remove unused exception handling info", false, false)
INITIALIZE_AG_DEPENDENCY(CallGraph)
INITIALIZE_PASS_END(PruneEH, "prune-eh",
                "Remove unused exception handling info", false, false)

Pass *llvm::createPruneEHPass() { return new PruneEH(); }

bool PruneEH::runOnSCC(CallGraphSCC &SCC) {
  SmallPtrSet<CallGraphNode *, 8> SCCNodes;
  CallGraph &CG = getAnalysis<CallGraph>();
  bool MadeChange = false;

  // Fill SCCNodes with the elements of the SCC.  Used for quickly
  // looking up whether a given CallGraphNode is in this SCC.
  for (CallGraphSCC::iterator I = SCC.begin(), E = SCC.end(); I != E; ++I)
    SCCNodes.insert(*I);

  // First pass, scan all of the functions in the SCC, simplifying them
  // according to what we know.
  for (CallGraphSCC::iterator I = SCC.begin(), E = SCC.end(); I != E; ++I)
    if (Function *F = (*I)->getFunction())
      MadeChange |= SimplifyFunction(F);

  // Next, check to see if any callees might throw or if there are any external
  // functions in this SCC: if so, we cannot prune any functions in this SCC.
  // Definitions that are weak and not declared non-throwing might be
  // overridden at linktime with something that throws, so assume that.
  // If this SCC includes the unwind instruction, we KNOW it throws, so
  // obviously the SCC might throw.
  //
  bool SCCMightUnwind = false, SCCMightReturn = false;
  for (CallGraphSCC::iterator I = SCC.begin(), E = SCC.end();
       (!SCCMightUnwind || !SCCMightReturn) && I != E; ++I) {
    Function *F = (*I)->getFunction();
    if (F == 0) {
      SCCMightUnwind = true;
      SCCMightReturn = true;
    } else if (F->isDeclaration() || F->mayBeOverridden()) {
      SCCMightUnwind |= !F->doesNotThrow();
      SCCMightReturn |= !F->doesNotReturn();
    } else {
      bool CheckUnwind = !SCCMightUnwind && !F->doesNotThrow();
      bool CheckReturn = !SCCMightReturn && !F->doesNotReturn();

      if (!CheckUnwind && !CheckReturn)
        continue;

      // Check to see if this function performs an unwind or calls an
      // unwinding function.
      for (Function::iterator BB = F->begin(), E = F->end(); BB != E; ++BB) {
        if (CheckUnwind && isa<ResumeInst>(BB->getTerminator())) {
          // Uses unwind / resume!
          SCCMightUnwind = true;
        } else if (CheckReturn && isa<ReturnInst>(BB->getTerminator())) {
          SCCMightReturn = true;
        }

        // Invoke instructions don't allow unwinding to continue, so we are
        // only interested in call instructions.
        if (CheckUnwind && !SCCMightUnwind)
          for (BasicBlock::iterator I = BB->begin(), E = BB->end(); I != E; ++I)
            if (CallInst *CI = dyn_cast<CallInst>(I)) {
              if (CI->doesNotThrow()) {
                // This call cannot throw.
              } else if (Function *Callee = CI->getCalledFunction()) {
                CallGraphNode *CalleeNode = CG[Callee];
                // If the callee is outside our current SCC then we may
                // throw because it might.
                if (!SCCNodes.count(CalleeNode)) {
                  SCCMightUnwind = true;
                  break;
                }
              } else {
                // Indirect call, it might throw.
                SCCMightUnwind = true;
                break;
              }
            }
        if (SCCMightUnwind && SCCMightReturn) break;
      }
    }
  }

  // If the SCC doesn't unwind or doesn't throw, note this fact.
  if (!SCCMightUnwind || !SCCMightReturn)
    for (CallGraphSCC::iterator I = SCC.begin(), E = SCC.end(); I != E; ++I) {
      AttrBuilder NewAttributes;

      if (!SCCMightUnwind)
        NewAttributes.addAttribute(Attribute::NoUnwind);
      if (!SCCMightReturn)
        NewAttributes.addAttribute(Attribute::NoReturn);

      Function *F = (*I)->getFunction();
      const AttributeSet &PAL = F->getAttributes();
      const AttributeSet &NPAL =
        PAL.addAttributes(F->getContext(), AttributeSet::FunctionIndex,
                          AttributeSet::get(F->getContext(),
                                            AttributeSet::FunctionIndex,
                                            NewAttributes));
      if (PAL != NPAL) {
        MadeChange = true;
        F->setAttributes(NPAL);
      }
    }

  for (CallGraphSCC::iterator I = SCC.begin(), E = SCC.end(); I != E; ++I) {
    // Convert any invoke instructions to non-throwing functions in this node
    // into call instructions with a branch.  This makes the exception blocks
    // dead.
    if (Function *F = (*I)->getFunction())
      MadeChange |= SimplifyFunction(F);
  }

  return MadeChange;
}

// SimplifyFunction - Given information about callees, simplify the specified
// function if we have invokes to non-unwinding functions or code after calls to
// no-return functions.
bool PruneEH::SimplifyFunction(Function *F) {
  bool MadeChange = false;
  for (Function::iterator BB = F->begin(), E = F->end(); BB != E; ++BB) {
    if (InvokeInst *II = dyn_cast<InvokeInst>(BB->getTerminator()))
      if (II->doesNotThrow()) {
        SmallVector<Value*, 8> Args(II->op_begin(), II->op_end() - 3);
        // Insert a call instruction before the invoke.
        CallInst *Call = CallInst::Create(II->getCalledValue(), Args, "", II);
        Call->takeName(II);
        Call->setCallingConv(II->getCallingConv());
        Call->setAttributes(II->getAttributes());
        Call->setDebugLoc(II->getDebugLoc());

        // Anything that used the value produced by the invoke instruction
        // now uses the value produced by the call instruction.  Note that we
        // do this even for void functions and calls with no uses so that the
        // callgraph edge is updated.
        II->replaceAllUsesWith(Call);
        BasicBlock *UnwindBlock = II->getUnwindDest();
        UnwindBlock->removePredecessor(II->getParent());

        // Insert a branch to the normal destination right before the
        // invoke.
        BranchInst::Create(II->getNormalDest(), II);

        // Finally, delete the invoke instruction!
        BB->getInstList().pop_back();

        // If the unwind block is now dead, nuke it.
        if (pred_begin(UnwindBlock) == pred_end(UnwindBlock))
          DeleteBasicBlock(UnwindBlock);  // Delete the new BB.

        ++NumRemoved;
        MadeChange = true;
      }

    for (BasicBlock::iterator I = BB->begin(), E = BB->end(); I != E; )
      if (CallInst *CI = dyn_cast<CallInst>(I++))
        if (CI->doesNotReturn() && !isa<UnreachableInst>(I)) {
          // This call calls a function that cannot return.  Insert an
          // unreachable instruction after it and simplify the code.  Do this
          // by splitting the BB, adding the unreachable, then deleting the
          // new BB.
          BasicBlock *New = BB->splitBasicBlock(I);

          // Remove the uncond branch and add an unreachable.
          BB->getInstList().pop_back();
          new UnreachableInst(BB->getContext(), BB);

          DeleteBasicBlock(New);  // Delete the new BB.
          MadeChange = true;
          ++NumUnreach;
          break;
        }
  }

  return MadeChange;
}

/// DeleteBasicBlock - remove the specified basic block from the program,
/// updating the callgraph to reflect any now-obsolete edges due to calls that
/// exist in the BB.
void PruneEH::DeleteBasicBlock(BasicBlock *BB) {
  assert(pred_begin(BB) == pred_end(BB) && "BB is not dead!");
  CallGraph &CG = getAnalysis<CallGraph>();

  CallGraphNode *CGN = CG[BB->getParent()];
  for (BasicBlock::iterator I = BB->end(), E = BB->begin(); I != E; ) {
    --I;
    if (CallInst *CI = dyn_cast<CallInst>(I)) {
      if (!isa<IntrinsicInst>(I))
        CGN->removeCallEdgeFor(CI);
    } else if (InvokeInst *II = dyn_cast<InvokeInst>(I))
      CGN->removeCallEdgeFor(II);
    if (!I->use_empty())
      I->replaceAllUsesWith(UndefValue::get(I->getType()));
  }

  // Get the list of successors of this block.
  std::vector<BasicBlock*> Succs(succ_begin(BB), succ_end(BB));

  for (unsigned i = 0, e = Succs.size(); i != e; ++i)
    Succs[i]->removePredecessor(BB);

  BB->eraseFromParent();
}


text:
package reactivestreams.tour;

import com.mongodb.client.result.DeleteResult;
import com.mongodb.client.result.InsertManyResult;
import com.mongodb.client.result.InsertOneResult;
import com.mongodb.client.result.UpdateResult;
import com.mongodb.reactivestreams.client.MongoClient;
import com.mongodb.reactivestreams.client.MongoClients;
import com.mongodb.reactivestreams.client.MongoCollection;
import com.mongodb.reactivestreams.client.MongoDatabase;
import org.bson.codecs.configuration.CodecRegistry;
import org.bson.codecs.pojo.PojoCodecProvider;
import reactivestreams.helpers.SubscriberHelpers.ObservableSubscriber;
import reactivestreams.helpers.SubscriberHelpers.OperationSubscriber;
import reactivestreams.helpers.SubscriberHelpers.PrintToStringSubscriber;

import java.util.List;

import static com.mongodb.client.model.Filters.eq;
import static com.mongodb.client.model.Filters.gt;
import static com.mongodb.client.model.Filters.not;
import static com.mongodb.client.model.Updates.combine;
import static com.mongodb.client.model.Updates.set;
import static java.util.Arrays.asList;
import static org.bson.codecs.configuration.CodecRegistries.fromProviders;
import static org.bson.codecs.configuration.CodecRegistries.fromRegistries;

/**
 * The POJO QuickTour code example
 */
public class PojoQuickTour {
    /**
     * Run this main method to see the output of this quick example.
     *
     * @param args takes an optional single argument for the connection string
     */
    public static void main(final String[] args) {
        MongoClient mongoClient;

        if (args.length == 0) {
            // connect to the local database server
            mongoClient = MongoClients.create();
        } else {
            mongoClient = MongoClients.create(args[0]);
        }

        // create codec registry for POJOs
        CodecRegistry pojoCodecRegistry = fromRegistries(MongoClients.getDefaultCodecRegistry(),
                fromProviders(PojoCodecProvider.builder().automatic(true).build()));

        // get handle to "mydb" database
        MongoDatabase database = mongoClient.getDatabase("mydb").withCodecRegistry(pojoCodecRegistry);

        // get a handle to the "people" collection
        MongoCollection<Person> collection = database.getCollection("people", Person.class);

        // drop all the data in it
        ObservableSubscriber<Void> successSubscriber = new OperationSubscriber<>();
        collection.drop().subscribe(successSubscriber);
        successSubscriber.await();

        // make a document and insert it
        Person ada = new Person("Ada Byron", 20, new Address("St James Square", "London", "W1"));
        System.out.println("Original Person Model: " + ada);

        ObservableSubscriber<InsertOneResult> insertOneSubscriber = new OperationSubscriber<>();
        collection.insertOne(ada).subscribe(insertOneSubscriber);
        insertOneSubscriber.await();

        // get it (since it's the only one in there since we dropped the rest earlier on)
        ObservableSubscriber<Person> personSubscriber = new PrintToStringSubscriber<>();
        collection.find().first().subscribe(personSubscriber);
        personSubscriber.await();

        // now, lets add some more people so we can explore queries and cursors
        List<Person> people = asList(
                new Person("Charles Babbage", 45, new Address("5 Devonshire Street", "London", "W11")),
                new Person("Alan Turing", 28, new Address("Bletchley Hall", "Bletchley Park", "MK12")),
                new Person("Timothy Berners-Lee", 61, new Address("Colehill", "Wimborne", null))
        );

        ObservableSubscriber<InsertManyResult> insertManySubscriber = new OperationSubscriber<>();
        collection.insertMany(people).subscribe(insertManySubscriber);
        insertManySubscriber.await();

        // get all the documents in the collection and print them out
        personSubscriber = new PrintToStringSubscriber<>();
        collection.find().subscribe(personSubscriber);
        personSubscriber.await();

        // now use a query to get 1 document out
        personSubscriber = new PrintToStringSubscriber<>();
        collection.find(eq("address.city", "Wimborne")).first().subscribe(personSubscriber);
        personSubscriber.await();

        // now lets find every over 30
        personSubscriber = new PrintToStringSubscriber<>();
        collection.find(gt("age", 30)).subscribe(personSubscriber);
        personSubscriber.await();

        // Update One
        ObservableSubscriber<UpdateResult> updateSubscriber = new OperationSubscriber<>();
        collection.updateOne(eq("name", "Ada Byron"), combine(set("age", 23), set("name", "Ada Lovelace")))
                .subscribe(updateSubscriber);
        updateSubscriber.await();

        // Update Many
        updateSubscriber = new OperationSubscriber<>();
        collection.updateMany(not(eq("zip", null)), set("zip", null))
                .subscribe(updateSubscriber);
        updateSubscriber.await();

        // Replace One
        updateSubscriber = new OperationSubscriber<>();
        collection.replaceOne(eq("name", "Ada Lovelace"), ada).subscribe(updateSubscriber);
        updateSubscriber.await();

        // Delete One
        ObservableSubscriber<DeleteResult> deleteSubscriber = new OperationSubscriber<>();
        collection.deleteOne(eq("address.city", "Wimborne")).subscribe(deleteSubscriber);
        deleteSubscriber.await();

        // Delete Many
        deleteSubscriber = new OperationSubscriber<>();
        collection.deleteMany(eq("address.city", "London")).subscribe(deleteSubscriber);
        deleteSubscriber.await();

        // Clean up
        successSubscriber = new OperationSubscriber<>();
        database.drop().subscribe(successSubscriber);
        successSubscriber.await();

        // release resources
        mongoClient.close();
    }
}

redpajama_set_name: RedPajamaGithub


text:
'use strict';

/**
 * Servico de notificacao do dispositivo.
*/
app.factory('notificationService', [function () {

    return {

        /**
         * Mostra uma mensagem para o usuario.
         * @message(Object)
         *      + message(String): a mensagem a ser exibida para o usuário.
         *      + onClose(Function): uma função a ser executada quando fechar a mensagem.
         *      + title(String): o titulo da mensagem.
         *      + btnText(String): o texto do botão.
        */
        alert: function(params) {

            var _params = {
                message: "",
                onClose: null,
                title: "Aviso",
                btnText: "Ok"
            };

            $.extend(_params, params);

            if(navigator.notification && navigator.notification.alert) {
                navigator.notification.alert(
                    _params.message,
                    _params.onClose,
                    _params.title,
                    _params.btnText
                );
            }
            else {
                window.alert(_params.message);

                if(_params.onClose) {
                    _params.onClose();
                }
            }

        },

        /**
         * Mostra uma questão para o usuario.
         * @params(Object)
         *      + message(String): a mensagem a ser exibida para o usuário.
         *      + onConfirm(Function): uma função a ser executada quando confirmar.
         *      + title(String): o titulo da mensagem.
         *      + buttonLabels(Array): ["NomeBotaoOk", "NomeBotaoCancelar"].
        */
        confirm: function(params) {

            var _params = {
                message: "",
                //@result(Number): o numero do botao pressionado (começa em 1)
                onConfirm: function(result){},
                title: "Pergunta",
                buttonLabels: ["Ok", "Cancelar"]
            };

            $.extend(_params, params);

            if(navigator.notification && navigator.notification.confirm) {
                navigator.notification.confirm(
                    _params.message,
                    _params.onConfirm,
                    _params.title,
                    _params.buttonLabels
                );
            }
            else {
                var c = window.confirm(_params.message);

                if(c && _params.onConfirm) {
                    _params.onConfirm();
                }
            }
        }

    };
}]);


text:
package joshie.harvest.api.crops;

import com.google.common.collect.ImmutableList;
import joshie.harvest.api.HFApi;
import net.minecraft.block.properties.PropertyInteger;
import net.minecraft.block.state.BlockStateContainer;
import net.minecraft.block.state.IBlockState;
import net.minecraft.util.math.AxisAlignedBB;
import net.minecraft.util.math.BlockPos;
import net.minecraft.world.IBlockAccess;

public class StateHandlerDefault<C extends Crop> implements IStateHandler<C> {
    public static final AxisAlignedBB CROP_AABB = new AxisAlignedBB(0.0D, 0.0D, 0.0D, 1.0D, 0.5D, 1.0D);
    protected BlockStateContainer stateContainer;
    protected PropertyInteger stages;
    protected IBlockState defaultState;

    protected final int maximum;

    public StateHandlerDefault(int maximum) {
        this.maximum = maximum;
        this.stages = PropertyInteger.create("stage", 1, maximum);
        this.stateContainer = HFApi.crops.getStateContainer(stages);
        this.defaultState = stateContainer.getBaseState().withProperty(stages, 1);
    }

    public StateHandlerDefault(Crop crop) {
        this(crop.getStages());
    }

    @Override
    public ImmutableList<IBlockState> getValidStates() {
        return stateContainer.getValidStates();
    }

    @Override
    public AxisAlignedBB getBoundingBox(IBlockAccess world, BlockPos pos, PlantSection section, C crop, int stage, boolean withered) {
        return CROP_AABB;
    }

    @Override
    public IBlockState getState(IBlockAccess world, BlockPos pos, PlantSection section, C crop, int stage, boolean withered) {
        return getState(Math.min(maximum, stage));
    }

    protected IBlockState getState(int stage) {
        return defaultState.withProperty(stages, Math.max(1, stage));
    }
}


text:
package condition

import (
	proto "github.com/golang/protobuf/proto"
	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
	reflect "reflect"
	sync "sync"
)

const (
	// Verify that this generated code is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
	// Verify that runtime/protoimpl is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)

// This is a compile-time assertion that a sufficiently up-to-date version
// of the legacy proto package is being used.
const _ = proto.ProtoPackageIsVersion4

type CIName struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields
}

func (x *CIName) Reset() {
	*x = CIName{}
	if protoimpl.UnsafeEnabled {
		mi := &file_pkg_condition_ci_condition_proto_msgTypes[0]
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		ms.StoreMessageInfo(mi)
	}
}

func (x *CIName) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*CIName) ProtoMessage() {}

func (x *CIName) ProtoReflect() protoreflect.Message {
	mi := &file_pkg_condition_ci_condition_proto_msgTypes[0]
	if protoimpl.UnsafeEnabled && x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use CIName.ProtoReflect.Descriptor instead.
func (*CIName) Descriptor() ([]byte, []int) {
	return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{0}
}

type CIVersion struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields
}

func (x *CIVersion) Reset() {
	*x = CIVersion{}
	if protoimpl.UnsafeEnabled {
		mi := &file_pkg_condition_ci_condition_proto_msgTypes[1]
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		ms.StoreMessageInfo(mi)
	}
}

func (x *CIVersion) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*CIVersion) ProtoMessage() {}

func (x *CIVersion) ProtoReflect() protoreflect.Message {
	mi := &file_pkg_condition_ci_condition_proto_msgTypes[1]
	if protoimpl.UnsafeEnabled && x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use CIVersion.ProtoReflect.Descriptor instead.
func (*CIVersion) Descriptor() ([]byte, []int) {
	return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{1}
}

type RunCondition struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields
}

func (x *RunCondition) Reset() {
	*x = RunCondition{}
	if protoimpl.UnsafeEnabled {
		mi := &file_pkg_condition_ci_condition_proto_msgTypes[2]
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		ms.StoreMessageInfo(mi)
	}
}

func (x *RunCondition) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*RunCondition) ProtoMessage() {}

func (x *RunCondition) ProtoReflect() protoreflect.Message {
	mi := &file_pkg_condition_ci_condition_proto_msgTypes[2]
	if protoimpl.UnsafeEnabled && x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use RunCondition.ProtoReflect.Descriptor instead.
func (*RunCondition) Descriptor() ([]byte, []int) {
	return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{2}
}

type GetCurrentBranch struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields
}

func (x *GetCurrentBranch) Reset() {
	*x = GetCurrentBranch{}
	if protoimpl.UnsafeEnabled {
		mi := &file_pkg_condition_ci_condition_proto_msgTypes[3]
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		ms.StoreMessageInfo(mi)
	}
}

func (x *GetCurrentBranch) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*GetCurrentBranch) ProtoMessage() {}

func (x *GetCurrentBranch) ProtoReflect() protoreflect.Message {
	mi := &file_pkg_condition_ci_condition_proto_msgTypes[3]
	if protoimpl.UnsafeEnabled && x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use GetCurrentBranch.ProtoReflect.Descriptor instead.
func (*GetCurrentBranch) Descriptor() ([]byte, []int) {
	return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{3}
}

type GetCurrentSHA struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields
}

func (x *GetCurrentSHA) Reset() {
	*x = GetCurrentSHA{}
	if protoimpl.UnsafeEnabled {
		mi := &file_pkg_condition_ci_condition_proto_msgTypes[4]
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		ms.StoreMessageInfo(mi)
	}
}

func (x *GetCurrentSHA) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*GetCurrentSHA) ProtoMessage() {}

func (x *GetCurrentSHA) ProtoReflect() protoreflect.Message {
	mi := &file_pkg_condition_ci_condition_proto_msgTypes[4]
	if protoimpl.UnsafeEnabled && x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use GetCurrentSHA.ProtoReflect.Descriptor instead.
func (*GetCurrentSHA) Descriptor() ([]byte, []int) {
	return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{4}
}

type CIName_Request struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields
}

func (x *CIName_Request) Reset() {
	*x = CIName_Request{}
	if protoimpl.UnsafeEnabled {
		mi := &file_pkg_condition_ci_condition_proto_msgTypes[5]
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		ms.StoreMessageInfo(mi)
	}
}

func (x *CIName_Request) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*CIName_Request) ProtoMessage() {}

func (x *CIName_Request) ProtoReflect() protoreflect.Message {
	mi := &file_pkg_condition_ci_condition_proto_msgTypes[5]
	if protoimpl.UnsafeEnabled && x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use CIName_Request.ProtoReflect.Descriptor instead.
func (*CIName_Request) Descriptor() ([]byte, []int) {
	return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{0, 0}
}

type CIName_Response struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields

	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
}

func (x *CIName_Response) Reset() {
	*x = CIName_Response{}
	if protoimpl.UnsafeEnabled {
		mi := &file_pkg_condition_ci_condition_proto_msgTypes[6]
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		ms.StoreMessageInfo(mi)
	}
}

func (x *CIName_Response) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*CIName_Response) ProtoMessage() {}

func (x *CIName_Response) ProtoReflect() protoreflect.Message {
	mi := &file_pkg_condition_ci_condition_proto_msgTypes[6]
	if protoimpl.UnsafeEnabled && x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use CIName_Response.ProtoReflect.Descriptor instead.
func (*CIName_Response) Descriptor() ([]byte, []int) {
	return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{0, 1}
}

func (x *CIName_Response) GetName() string {
	if x != nil {
		return x.Name
	}
	return ""
}

type CIVersion_Request struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields
}

func (x *CIVersion_Request) Reset() {
	*x = CIVersion_Request{}
	if protoimpl.UnsafeEnabled {
		mi := &file_pkg_condition_ci_condition_proto_msgTypes[7]
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		ms.StoreMessageInfo(mi)
	}
}

func (x *CIVersion_Request) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*CIVersion_Request) ProtoMessage() {}

func (x *CIVersion_Request) ProtoReflect() protoreflect.Message {
	mi := &file_pkg_condition_ci_condition_proto_msgTypes[7]
	if protoimpl.UnsafeEnabled && x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use CIVersion_Request.ProtoReflect.Descriptor instead.
func (*CIVersion_Request) Descriptor() ([]byte, []int) {
	return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{1, 0}
}

type CIVersion_Response struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields

	Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"`
}

func (x *CIVersion_Response) Reset() {
	*x = CIVersion_Response{}
	if protoimpl.UnsafeEnabled {
		mi := &file_pkg_condition_ci_condition_proto_msgTypes[8]
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		ms.StoreMessageInfo(mi)
	}
}

func (x *CIVersion_Response) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*CIVersion_Response) ProtoMessage() {}

func (x *CIVersion_Response) ProtoReflect() protoreflect.Message {
	mi := &file_pkg_condition_ci_condition_proto_msgTypes[8]
	if protoimpl.UnsafeEnabled && x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use CIVersion_Response.ProtoReflect.Descriptor instead.
func (*CIVersion_Response) Descriptor() ([]byte, []int) {
	return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{1, 1}
}

func (x *CIVersion_Response) GetVersion() string {
	if x != nil {
		return x.Version
	}
	return ""
}

type RunCondition_Request struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields

	Value map[string]string `protobuf:"bytes,1,rep,name=value,proto3" json:"value,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
}

func (x *RunCondition_Request) Reset() {
	*x = RunCondition_Request{}
	if protoimpl.UnsafeEnabled {
		mi := &file_pkg_condition_ci_condition_proto_msgTypes[9]
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		ms.StoreMessageInfo(mi)
	}
}

func (x *RunCondition_Request) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*RunCondition_Request) ProtoMessage() {}

func (x *RunCondition_Request) ProtoReflect() protoreflect.Message {
	mi := &file_pkg_condition_ci_condition_proto_msgTypes[9]
	if protoimpl.UnsafeEnabled && x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use RunCondition_Request.ProtoReflect.Descriptor instead.
func (*RunCondition_Request) Descriptor() ([]byte, []int) {
	return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{2, 0}
}

func (x *RunCondition_Request) GetValue() map[string]string {
	if x != nil {
		return x.Value
	}
	return nil
}

type RunCondition_Response struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields

	Error string `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"`
}

func (x *RunCondition_Response) Reset() {
	*x = RunCondition_Response{}
	if protoimpl.UnsafeEnabled {
		mi := &file_pkg_condition_ci_condition_proto_msgTypes[10]
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		ms.StoreMessageInfo(mi)
	}
}

func (x *RunCondition_Response) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*RunCondition_Response) ProtoMessage() {}

func (x *RunCondition_Response) ProtoReflect() protoreflect.Message {
	mi := &file_pkg_condition_ci_condition_proto_msgTypes[10]
	if protoimpl.UnsafeEnabled && x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use RunCondition_Response.ProtoReflect.Descriptor instead.
func (*RunCondition_Response) Descriptor() ([]byte, []int) {
	return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{2, 1}
}

func (x *RunCondition_Response) GetError() string {
	if x != nil {
		return x.Error
	}
	return ""
}

type GetCurrentBranch_Request struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields
}

func (x *GetCurrentBranch_Request) Reset() {
	*x = GetCurrentBranch_Request{}
	if protoimpl.UnsafeEnabled {
		mi := &file_pkg_condition_ci_condition_proto_msgTypes[12]
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		ms.StoreMessageInfo(mi)
	}
}

func (x *GetCurrentBranch_Request) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*GetCurrentBranch_Request) ProtoMessage() {}

func (x *GetCurrentBranch_Request) ProtoReflect() protoreflect.Message {
	mi := &file_pkg_condition_ci_condition_proto_msgTypes[12]
	if protoimpl.UnsafeEnabled && x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use GetCurrentBranch_Request.ProtoReflect.Descriptor instead.
func (*GetCurrentBranch_Request) Descriptor() ([]byte, []int) {
	return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{3, 0}
}

type GetCurrentBranch_Response struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields

	Value string `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"`
}

func (x *GetCurrentBranch_Response) Reset() {
	*x = GetCurrentBranch_Response{}
	if protoimpl.UnsafeEnabled {
		mi := &file_pkg_condition_ci_condition_proto_msgTypes[13]
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		ms.StoreMessageInfo(mi)
	}
}

func (x *GetCurrentBranch_Response) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*GetCurrentBranch_Response) ProtoMessage() {}

func (x *GetCurrentBranch_Response) ProtoReflect() protoreflect.Message {
	mi := &file_pkg_condition_ci_condition_proto_msgTypes[13]
	if protoimpl.UnsafeEnabled && x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use GetCurrentBranch_Response.ProtoReflect.Descriptor instead.
func (*GetCurrentBranch_Response) Descriptor() ([]byte, []int) {
	return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{3, 1}
}

func (x *GetCurrentBranch_Response) GetValue() string {
	if x != nil {
		return x.Value
	}
	return ""
}

type GetCurrentSHA_Request struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields
}

func (x *GetCurrentSHA_Request) Reset() {
	*x = GetCurrentSHA_Request{}
	if protoimpl.UnsafeEnabled {
		mi := &file_pkg_condition_ci_condition_proto_msgTypes[14]
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		ms.StoreMessageInfo(mi)
	}
}

func (x *GetCurrentSHA_Request) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*GetCurrentSHA_Request) ProtoMessage() {}

func (x *GetCurrentSHA_Request) ProtoReflect() protoreflect.Message {
	mi := &file_pkg_condition_ci_condition_proto_msgTypes[14]
	if protoimpl.UnsafeEnabled && x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use GetCurrentSHA_Request.ProtoReflect.Descriptor instead.
func (*GetCurrentSHA_Request) Descriptor() ([]byte, []int) {
	return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{4, 0}
}

type GetCurrentSHA_Response struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields

	Value string `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"`
}

func (x *GetCurrentSHA_Response) Reset() {
	*x = GetCurrentSHA_Response{}
	if protoimpl.UnsafeEnabled {
		mi := &file_pkg_condition_ci_condition_proto_msgTypes[15]
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		ms.StoreMessageInfo(mi)
	}
}

func (x *GetCurrentSHA_Response) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*GetCurrentSHA_Response) ProtoMessage() {}

func (x *GetCurrentSHA_Response) ProtoReflect() protoreflect.Message {
	mi := &file_pkg_condition_ci_condition_proto_msgTypes[15]
	if protoimpl.UnsafeEnabled && x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use GetCurrentSHA_Response.ProtoReflect.Descriptor instead.
func (*GetCurrentSHA_Response) Descriptor() ([]byte, []int) {
	return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{4, 1}
}

func (x *GetCurrentSHA_Response) GetValue() string {
	if x != nil {
		return x.Value
	}
	return ""
}

var File_pkg_condition_ci_condition_proto protoreflect.FileDescriptor

var file_pkg_condition_ci_condition_proto_rawDesc = []byte{
	0x0a, 0x20, 0x70, 0x6b, 0x67, 0x2f, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x2f,
	0x63, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f,
	0x74, 0x6f, 0x22, 0x33, 0x0a, 0x06, 0x43, 0x49, 0x4e, 0x61, 0x6d, 0x65, 0x1a, 0x09, 0x0a, 0x07,
	0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f,
	0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28,
	0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x3c, 0x0a, 0x09, 0x43, 0x49, 0x56, 0x65, 0x72,
	0x73, 0x69, 0x6f, 0x6e, 0x1a, 0x09, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a,
	0x24, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x76,
	0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x76, 0x65,
	0x72, 0x73, 0x69, 0x6f, 0x6e, 0x22, 0xad, 0x01, 0x0a, 0x0c, 0x52, 0x75, 0x6e, 0x43, 0x6f, 0x6e,
	0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x1a, 0x7b, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,
	0x74, 0x12, 0x36, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b,
	0x32, 0x20, 0x2e, 0x52, 0x75, 0x6e, 0x43, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x2e,
	0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x2e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x45, 0x6e, 0x74,
	0x72, 0x79, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x1a, 0x38, 0x0a, 0x0a, 0x56, 0x61, 0x6c,
	0x75, 0x65, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01,
	0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c,
	0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a,
	0x02, 0x38, 0x01, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12,
	0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05,
	0x65, 0x72, 0x72, 0x6f, 0x72, 0x22, 0x3f, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x43, 0x75, 0x72, 0x72,
	0x65, 0x6e, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x63, 0x68, 0x1a, 0x09, 0x0a, 0x07, 0x52, 0x65, 0x71,
	0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65,
	0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
	0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x43, 0x75, 0x72,
	0x72, 0x65, 0x6e, 0x74, 0x53, 0x48, 0x41, 0x1a, 0x09, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65,
	0x73, 0x74, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14,
	0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76,
	0x61, 0x6c, 0x75, 0x65, 0x32, 0xbe, 0x02, 0x0a, 0x11, 0x43, 0x49, 0x43, 0x6f, 0x6e, 0x64, 0x69,
	0x74, 0x69, 0x6f, 0x6e, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x12, 0x29, 0x0a, 0x04, 0x4e, 0x61,
	0x6d, 0x65, 0x12, 0x0f, 0x2e, 0x43, 0x49, 0x4e, 0x61, 0x6d, 0x65, 0x2e, 0x52, 0x65, 0x71, 0x75,
	0x65, 0x73, 0x74, 0x1a, 0x10, 0x2e, 0x43, 0x49, 0x4e, 0x61, 0x6d, 0x65, 0x2e, 0x52, 0x65, 0x73,
	0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x32, 0x0a, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e,
	0x12, 0x12, 0x2e, 0x43, 0x49, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x71,
	0x75, 0x65, 0x73, 0x74, 0x1a, 0x13, 0x2e, 0x43, 0x49, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e,
	0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3d, 0x0a, 0x0c, 0x52, 0x75, 0x6e,
	0x43, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x15, 0x2e, 0x52, 0x75, 0x6e, 0x43,
	0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
	0x1a, 0x16, 0x2e, 0x52, 0x75, 0x6e, 0x43, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x2e,
	0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x49, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x43,
	0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x63, 0x68, 0x12, 0x19, 0x2e, 0x47,
	0x65, 0x74, 0x43, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x63, 0x68, 0x2e,
	0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x75, 0x72,
	0x72, 0x65, 0x6e, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x63, 0x68, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f,
	0x6e, 0x73, 0x65, 0x12, 0x40, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x43, 0x75, 0x72, 0x72, 0x65, 0x6e,
	0x74, 0x53, 0x48, 0x41, 0x12, 0x16, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x75, 0x72, 0x72, 0x65, 0x6e,
	0x74, 0x53, 0x48, 0x41, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x17, 0x2e, 0x47,
	0x65, 0x74, 0x43, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x53, 0x48, 0x41, 0x2e, 0x52, 0x65, 0x73,
	0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x42, 0x5a, 0x40, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e,
	0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x6f, 0x2d, 0x73, 0x65, 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63, 0x2d,
	0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2f, 0x73, 0x65, 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63,
	0x2d, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2f, 0x76, 0x32, 0x2f, 0x70, 0x6b, 0x67, 0x2f,
	0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f,
	0x33,
}

var (
	file_pkg_condition_ci_condition_proto_rawDescOnce sync.Once
	file_pkg_condition_ci_condition_proto_rawDescData = file_pkg_condition_ci_condition_proto_rawDesc
)

func file_pkg_condition_ci_condition_proto_rawDescGZIP() []byte {
	file_pkg_condition_ci_condition_proto_rawDescOnce.Do(func() {
		file_pkg_condition_ci_condition_proto_rawDescData = protoimpl.X.CompressGZIP(file_pkg_condition_ci_condition_proto_rawDescData)
	})
	return file_pkg_condition_ci_condition_proto_rawDescData
}

var file_pkg_condition_ci_condition_proto_msgTypes = make([]protoimpl.MessageInfo, 16)
var file_pkg_condition_ci_condition_proto_goTypes = []interface{}{
	(*CIName)(nil),                    // 0: CIName
	(*CIVersion)(nil),                 // 1: CIVersion
	(*RunCondition)(nil),              // 2: RunCondition
	(*GetCurrentBranch)(nil),          // 3: GetCurrentBranch
	(*GetCurrentSHA)(nil),             // 4: GetCurrentSHA
	(*CIName_Request)(nil),            // 5: CIName.Request
	(*CIName_Response)(nil),           // 6: CIName.Response
	(*CIVersion_Request)(nil),         // 7: CIVersion.Request
	(*CIVersion_Response)(nil),        // 8: CIVersion.Response
	(*RunCondition_Request)(nil),      // 9: RunCondition.Request
	(*RunCondition_Response)(nil),     // 10: RunCondition.Response
	nil,                               // 11: RunCondition.Request.ValueEntry
	(*GetCurrentBranch_Request)(nil),  // 12: GetCurrentBranch.Request
	(*GetCurrentBranch_Response)(nil), // 13: GetCurrentBranch.Response
	(*GetCurrentSHA_Request)(nil),     // 14: GetCurrentSHA.Request
	(*GetCurrentSHA_Response)(nil),    // 15: GetCurrentSHA.Response
}
var file_pkg_condition_ci_condition_proto_depIdxs = []int32{
	11, // 0: RunCondition.Request.value:type_name -> RunCondition.Request.ValueEntry
	5,  // 1: CIConditionPlugin.Name:input_type -> CIName.Request
	7,  // 2: CIConditionPlugin.Version:input_type -> CIVersion.Request
	9,  // 3: CIConditionPlugin.RunCondition:input_type -> RunCondition.Request
	12, // 4: CIConditionPlugin.GetCurrentBranch:input_type -> GetCurrentBranch.Request
	14, // 5: CIConditionPlugin.GetCurrentSHA:input_type -> GetCurrentSHA.Request
	6,  // 6: CIConditionPlugin.Name:output_type -> CIName.Response
	8,  // 7: CIConditionPlugin.Version:output_type -> CIVersion.Response
	10, // 8: CIConditionPlugin.RunCondition:output_type -> RunCondition.Response
	13, // 9: CIConditionPlugin.GetCurrentBranch:output_type -> GetCurrentBranch.Response
	15, // 10: CIConditionPlugin.GetCurrentSHA:output_type -> GetCurrentSHA.Response
	6,  // [6:11] is the sub-list for method output_type
	1,  // [1:6] is the sub-list for method input_type
	1,  // [1:1] is the sub-list for extension type_name
	1,  // [1:1] is the sub-list for extension extendee
	0,  // [0:1] is the sub-list for field type_name
}

func init() { file_pkg_condition_ci_condition_proto_init() }
func file_pkg_condition_ci_condition_proto_init() {
	if File_pkg_condition_ci_condition_proto != nil {
		return
	}
	if !protoimpl.UnsafeEnabled {
		file_pkg_condition_ci_condition_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
			switch v := v.(*CIName); i {
			case 0:
				return &v.state
			case 1:
				return &v.sizeCache
			case 2:
				return &v.unknownFields
			default:
				return nil
			}
		}
		file_pkg_condition_ci_condition_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
			switch v := v.(*CIVersion); i {
			case 0:
				return &v.state
			case 1:
				return &v.sizeCache
			case 2:
				return &v.unknownFields
			default:
				return nil
			}
		}
		file_pkg_condition_ci_condition_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
			switch v := v.(*RunCondition); i {
			case 0:
				return &v.state
			case 1:
				return &v.sizeCache
			case 2:
				return &v.unknownFields
			default:
				return nil
			}
		}
		file_pkg_condition_ci_condition_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
			switch v := v.(*GetCurrentBranch); i {
			case 0:
				return &v.state
			case 1:
				return &v.sizeCache
			case 2:
				return &v.unknownFields
			default:
				return nil
			}
		}
		file_pkg_condition_ci_condition_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
			switch v := v.(*GetCurrentSHA); i {
			case 0:
				return &v.state
			case 1:
				return &v.sizeCache
			case 2:
				return &v.unknownFields
			default:
				return nil
			}
		}
		file_pkg_condition_ci_condition_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
			switch v := v.(*CIName_Request); i {
			case 0:
				return &v.state
			case 1:
				return &v.sizeCache
			case 2:
				return &v.unknownFields
			default:
				return nil
			}
		}
		file_pkg_condition_ci_condition_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
			switch v := v.(*CIName_Response); i {
			case 0:
				return &v.state
			case 1:
				return &v.sizeCache
			case 2:
				return &v.unknownFields
			default:
				return nil
			}
		}
		file_pkg_condition_ci_condition_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
			switch v := v.(*CIVersion_Request); i {
			case 0:
				return &v.state
			case 1:
				return &v.sizeCache
			case 2:
				return &v.unknownFields
			default:
				return nil
			}
		}
		file_pkg_condition_ci_condition_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
			switch v := v.(*CIVersion_Response); i {
			case 0:
				return &v.state
			case 1:
				return &v.sizeCache
			case 2:
				return &v.unknownFields
			default:
				return nil
			}
		}
		file_pkg_condition_ci_condition_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
			switch v := v.(*RunCondition_Request); i {
			case 0:
				return &v.state
			case 1:
				return &v.sizeCache
			case 2:
				return &v.unknownFields
			default:
				return nil
			}
		}
		file_pkg_condition_ci_condition_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
			switch v := v.(*RunCondition_Response); i {
			case 0:
				return &v.state
			case 1:
				return &v.sizeCache
			case 2:
				return &v.unknownFields
			default:
				return nil
			}
		}
		file_pkg_condition_ci_condition_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} {
			switch v := v.(*GetCurrentBranch_Request); i {
			case 0:
				return &v.state
			case 1:
				return &v.sizeCache
			case 2:
				return &v.unknownFields
			default:
				return nil
			}
		}
		file_pkg_condition_ci_condition_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} {
			switch v := v.(*GetCurrentBranch_Response); i {
			case 0:
				return &v.state
			case 1:
				return &v.sizeCache
			case 2:
				return &v.unknownFields
			default:
				return nil
			}
		}
		file_pkg_condition_ci_condition_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} {
			switch v := v.(*GetCurrentSHA_Request); i {
			case 0:
				return &v.state
			case 1:
				return &v.sizeCache
			case 2:
				return &v.unknownFields
			default:
				return nil
			}
		}
		file_pkg_condition_ci_condition_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} {
			switch v := v.(*GetCurrentSHA_Response); i {
			case 0:
				return &v.state
			case 1:
				return &v.sizeCache
			case 2:
				return &v.unknownFields
			default:
				return nil
			}
		}
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: file_pkg_condition_ci_condition_proto_rawDesc,
			NumEnums:      0,
			NumMessages:   16,
			NumExtensions: 0,
			NumServices:   1,
		},
		GoTypes:           file_pkg_condition_ci_condition_proto_goTypes,
		DependencyIndexes: file_pkg_condition_ci_condition_proto_depIdxs,
		MessageInfos:      file_pkg_condition_ci_condition_proto_msgTypes,
	}.Build()
	File_pkg_condition_ci_condition_proto = out.File
	file_pkg_condition_ci_condition_proto_rawDesc = nil
	file_pkg_condition_ci_condition_proto_goTypes = nil
	file_pkg_condition_ci_condition_proto_depIdxs = nil
}


text:
'use strict'

var createScene = require('../scene')
var createMesh = require('gl-mesh3d')
var bunny = require('bunny')

var scene = createScene()
var mesh = createMesh({
  gl:         scene.gl,
  cells:      bunny.cells,
  positions:  bunny.positions,
  colormap:   'jet'
})

scene.add(mesh)


text:
package net.ontopia.topicmaps.nav2.taglibs.TMvalue;

import java.io.IOException;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Collections;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import javax.servlet.ServletContext;
import javax.servlet.jsp.JspException;
import net.ontopia.topicmaps.core.TopicMapIF;
import net.ontopia.topicmaps.nav2.core.ContextManagerIF;
import net.ontopia.topicmaps.nav2.core.NavigatorCompileException;
import net.ontopia.topicmaps.nav2.core.NavigatorRuntimeException;
import net.ontopia.topicmaps.nav2.core.VariableNotSetException;
import net.ontopia.topicmaps.nav2.impl.basic.JSPEngineWrapper;
import net.ontopia.topicmaps.nav2.taglibs.logic.ContextTag;
import net.ontopia.topicmaps.nav2.taglibs.value.BaseValueProducingTag;
import net.ontopia.topicmaps.nav2.utils.FrameworkUtils;
import net.ontopia.topicmaps.query.core.InvalidQueryException;
import net.ontopia.topicmaps.query.core.QueryProcessorIF;
import net.ontopia.topicmaps.query.core.QueryResultIF;
import net.ontopia.topicmaps.query.utils.QueryResultIterator;
import net.ontopia.topicmaps.query.utils.QueryUtils;
import net.ontopia.utils.CollectionUtils;
import org.apache.commons.collections4.IteratorUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 * INTERNAL: TologQueryTag evalutes a tolog query and returns a
 * collection of maps.
 */
public class TologQueryTag extends BaseValueProducingTag {
  private static final Logger log = LoggerFactory.getLogger(TologQueryTag.class.getName());

  // tag attributes
  private String query;
  private String select;
  private String implementation;
  private String rulesfile;

  @Override
  public Collection process(Collection tmObjects) throws JspException {
    if (query == null) {
      throw new NavigatorCompileException("TologQueryTag: Ambiguous attribute " +
                                          "settings.");
    }

    // try to retrieve default value from ContextManager
    ContextTag contextTag = FrameworkUtils.getContextTag(pageContext);

    // Get the ContextManager
    ContextManagerIF ctxtMgr = contextTag.getContextManager();

    // Create a map for the context
    Map argmap = new ContextManagerMapWrapper(ctxtMgr);

    // get topicmap object on which we should compute
    TopicMapIF topicmap = contextTag.getTopicMap();
    if (topicmap == null) {
      throw new NavigatorRuntimeException("TologQueryTag found no topic map.");
    }

    // Get the result from the QueryProcessor
    QueryProcessorIF q_processor = (implementation == null ?
				    QueryUtils.createQueryProcessor(topicmap) :
				    QueryUtils.createQueryProcessor(topicmap, Collections.singletonMap("net.ontopia.topicmaps.query.core.QueryProcessorIF", implementation)));

    if (rulesfile != null) {
      ServletContext ctxt = pageContext.getServletContext();
      try {
        q_processor.load(new InputStreamReader(ctxt.getResourceAsStream(rulesfile)));
      } catch (IOException e) {
        throw JSPEngineWrapper.getJspException("Problem loading tolog rules file: " +
                                               rulesfile, e);
      } catch (InvalidQueryException e) {
        throw JSPEngineWrapper.getJspException("Problem loading tolog rules file: " +
                                               rulesfile, e);
      }
    }

    try {
      // produce list of maps
      return getMapCollection(q_processor.execute(query, argmap));
    } catch (InvalidQueryException e) {
      log.debug("Parsing of query '" + query + "' failed with message: " + e);
      throw new NavigatorRuntimeException(e);
    }
  }

  /**
   * INTERNAL: Wraps a QueryResultIF instance in a suitable
   * MapCollection implementation.
   */
  protected Collection getMapCollection(QueryResultIF result) {

    if (select != null) {
      int index = result.getIndex(select);
      if (index < 0) {
        throw new IndexOutOfBoundsException("No query result column named '" + select + "'");
      }

      List list = new ArrayList();
      while (result.next()) {
        list.add(result.getValue(index));
      }
      result.close();
      return list;
    }

    if (result instanceof net.ontopia.topicmaps.query.impl.basic.QueryResult) {
      // BASIC
      return net.ontopia.topicmaps.query.impl.basic.QueryResultWrappers.getWrapper(result);
    } else {
      // FIXME: Should pass collection size if available.
      return IteratorUtils.toList(new QueryResultIterator(result));
    }
  }

  // -----------------------------------------------------------------
  // Set methods for tag attributes
  // -----------------------------------------------------------------

  public void setQuery(String query) {
    this.query = query;
  }

  public void setSelect(String select) {
    this.select = select;
  }

  public void setRulesfile(String rulesfile) {
    this.rulesfile = rulesfile;
  }

  public void setImplementation(String implementation) {
    this.implementation = implementation;
  }

  // --- Helper class

  class ContextManagerMapWrapper extends HashMap {

    private ContextManagerIF ctxtMgr;

    public ContextManagerMapWrapper(ContextManagerIF ctxtMgr) {
      this.ctxtMgr = ctxtMgr;
    }

    @Override
    public Object get(Object key) {
      Collection coll = ctxtMgr.getValue((String) key);
      if (coll.isEmpty()) {
        throw new VariableNotSetException((String) key);
      }

      return CollectionUtils.getFirstElement(coll);
    }

    @Override
    public boolean containsKey(Object key) {
      return ctxtMgr.getValue((String)key) != null;
    }
  }
}


text:
package collector

import (
	linuxproc "github.com/c9s/goprocinfo/linux"
)

var sysMemTotal = getSysMemTotal()

const (
	clockTicksPerSecond  uint64 = 100
	nanoSecondsPerSecond        = 1e9
)

func getSysMemTotal() int64 {
	stat, err := linuxproc.ReadMemInfo("/proc/meminfo")
	if err != nil {
		log.Errorf("error reading system stats: %s", err)
		return 0
	}
	return int64(stat.MemTotal * 1024)
}

// return cumulative system cpu usage in nanoseconds
func getSysCPUUsage() uint64 {
	stat, err := linuxproc.ReadStat("/proc/stat")
	if err != nil {
		log.Errorf("error reading system stats: %s", err)
		return 0
	}

	sum := stat.CPUStatAll.User +
		stat.CPUStatAll.Nice +
		stat.CPUStatAll.System +
		stat.CPUStatAll.Idle +
		stat.CPUStatAll.IOWait +
		stat.CPUStatAll.IRQ +
		stat.CPUStatAll.SoftIRQ +
		stat.CPUStatAll.Steal +
		stat.CPUStatAll.Guest +
		stat.CPUStatAll.GuestNice

	return (sum * nanoSecondsPerSecond) / clockTicksPerSecond
}


text:
(function($){

var Vgnr = {

    decrypt: function(key, emailToDecrypt) {
        var alphabet = "!$%'&*#+-./0123456789=?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~";
        //var alphabet = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";
        var alphabetLen = alphabet.length;
        var emailLen = emailToDecrypt.length;
        var letter = "";
        var Result = "";
        var alphabetMatrix = new Array(alphabet.length);

        for(i=0; i < alphabet.length; i++) {
            alphabetMatrix[i] = alphabet.substr(i) + alphabet.substr(0, i);
        }
        var j = -1;
        var result = '';
        for(i=0; i < emailToDecrypt.length; i++) {
            j++;
            letter = emailToDecrypt.charAt(i);
            if (alphabet.indexOf(letter) == -1) {
                j--;
                result += letter;
            } else {
                result += alphabet.charAt(alphabetMatrix[alphabet.indexOf(key.charAt(j))].indexOf(letter));
            }
            if(j == key.length-1) {
                j = -1;
            }
        }
        return result;
    }

};

/*
 * Read the comments in the PHP Ciphering Library to understand what is going on here
 * The only comment I can make is that I gave the file a name of vgnr instead of
 * vigenere, once again for paranoiac reasons. I know, it is extremely weak.
 */
$.fn.deobfuscateEmailLink = function() {
    $(this).each(function() {
        if ($(this).hasClass("obfuscated-link")) {
            var href = $(this).attr("href");
            if (href.indexOf("#KEEP-LOOKING-") > -1) {
                var mail = href.substring(14).split("]#[");
                var key = mail[0];
                var cipheredEmail = mail[1];

                var finalEmail = Vgnr.decrypt(key, cipheredEmail);

                $(this).attr("href", "mailto:" + finalEmail);
            }
        } else {
            var mail = $(this).text().split("]#[");
            var key = mail[0];
            var cipheredEmail = mail[1];

            var finalEmail = Vgnr.decrypt(key, cipheredEmail);

            $(this).text(finalEmail);
        }
    });
};

$(document).ready(function() {
    $("a.obfuscated-link").deobfuscateEmailLink();
    $("span.obfuscated-link-text").deobfuscateEmailLink();
});

})(jQuery);


text:
package org.apache.flink.streaming.runtime.tasks;

import org.apache.flink.annotation.Internal;
import org.apache.flink.api.common.typeutils.TypeSerializer;
import org.apache.flink.runtime.execution.Environment;
import org.apache.flink.runtime.io.network.partition.consumer.InputGate;
import org.apache.flink.streaming.api.operators.TwoInputStreamOperator;
import org.apache.flink.streaming.runtime.io.StreamTwoInputSelectableProcessor;

import java.io.IOException;
import java.util.Collection;

/**
 * A {@link StreamTask} for executing a {@link TwoInputStreamOperator} and supporting
 * the {@link TwoInputStreamOperator} to select input for reading.
 */
@Internal
public class TwoInputSelectableStreamTask<IN1, IN2, OUT> extends AbstractTwoInputStreamTask<IN1, IN2, OUT> {

	public TwoInputSelectableStreamTask(Environment env) {
		super(env);
	}

	@Override
	protected void createInputProcessor(
		Collection<InputGate> inputGates1,
		Collection<InputGate> inputGates2,
		TypeSerializer<IN1> inputDeserializer1,
		TypeSerializer<IN2> inputDeserializer2) throws IOException {

		this.inputProcessor = new StreamTwoInputSelectableProcessor<>(
			inputGates1, inputGates2,
			inputDeserializer1, inputDeserializer2,
			this,
			getConfiguration().getCheckpointMode(),
			getCheckpointLock(),
			getEnvironment().getIOManager(),
			getEnvironment().getTaskManagerInfo().getConfiguration(),
			getStreamStatusMaintainer(),
			this.headOperator,
			input1WatermarkGauge,
			input2WatermarkGauge,
			getTaskNameWithSubtaskAndId(),
			operatorChain);
	}
}


text:
<!DOCTYPE html>

	<title>Chatty Help</title>
        <link rel="stylesheet" type="text/css" href="style.css" />

Back to main help page

Guide: Run more than one instance of Chatty

If you want to run Chatty more than once at the same time, you may need
    to know how it saves it's settings. By default the settings are saved
    in your user-directory in the subfolder .chatty (where it is
    exactly is system-dependant, enter /dir in Chatty to show it's location). When you run the program, it loads the settings
    and when you exit the program, it saves them, overwriting the file with
    no regard to possible changes (to the file) that may have occured in the meantime.

This means that when you run more than one instance on the same computer,
    the last one you close always overwrites the settings.

Seperate settings

You can change the default settings directory by using the -cd
    commandline paramter, which changes the settings directory to the current
    working directory, meaning the settings are loaded and saved in the same
    location you specified as working directory.

This means you can easily run more than one instance on the same computer
    with completely different settings, just by using that commandline parameter
    and specifying different working directories (e.g. in Windows in the shortcut
    settings).

See also: Create Shortcut.

Sharing login data

When you want to run several instances with different settings, but want
    to use the same account, you run into problems.
    Everytime you request login
    data (token), the old login is invalidated, so you have to share the login data
    you already have between different instances.
    This may or may not be
        the case anymore.

You can do this by simply copying the login settings file
    which contains the login data. Make sure you closed the Chatty instance
    you requested the login data with at least once, so it's actually saved
    to the file.

You could also try to play around with symbolic links
        to point to a shared login file.

Using Chatty on different computers

If you want to run Chatty on different computers with the same account,
    you run into the same problem as mentioned under Sharing login data:
    You can't have more than one access token with the same account for the same
    app at the same time.

To use Chatty on more than one computer with the same account, you'll
        have to transfer the login data, either by copying the login
        file or by entering the access token manually
        (/get token displays the token,
        /changetoken <token> changes it).


text:
using System;

namespace HttpLight.Attributes
{
    /// <summary>
    /// Determines custom parameter binder
    /// </summary>
    [AttributeUsage(AttributeTargets.Parameter)]
    public class BinderAttribute : Attribute
    {
        internal Type Binder { get; }

        public BinderAttribute(Type binder)
        {
            if (!typeof(IActionParameterBinder).IsAssignableFrom(binder))
                throw new ArgumentException(binder.Name + " is not assignable to " + nameof(IActionParameterBinder), nameof(binder));
            Binder = binder;
        }
    }
}


text:
CREATE TABLE `configs` (
  `id` INT(11) NOT NULL AUTO_INCREMENT,
  `total_reward_threshold` DECIMAL(19, 8) NOT NULL COMMENT 'threshold count that determines reward_rate_type',
  `referer_reward_rate` DECIMAL(4, 4) NOT NULL COMMENT 'referer reward rate means the percentage get from reward of referee',
  `updated_at` DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  `created_at` DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

INSERT INTO `configs` (total_reward_threshold, referer_reward_rate) VALUES (10, 0.1);

-- +goose Down
-- SQL section 'Down' is executed when this migration is rolled back
DROP TABLE `configs`;


text:
__author__ = 'Eugene'

from model.contact import Contact
from random import randrange

def test_mod_contact(app):
    if app.contact.count() == 0:
        app.contact.create_contact(Contact(first_name="Eugene", last_name="Kuznetsov", nickname="eugene_smith",
                                    title="LLC", company_name="Lazada", address="Moscow, Presnenskaya, 10",
                                    home="84951112233", mobile="89001112233", work="80001122333", fax="88003332211",
                                    first="eugene.kuznetsov@lazada.com", second="second@lazada.com", third="third@lazada.com",
                                    homepage="www.homepage.com", birth_year="1980", an_year="1990",
                                    second_address="Second address", home_address="My home address",
                                    notes="Some note for this test"))
    old_contacts = app.contact.get_contact_list()
    index = randrange(len(old_contacts))
    contact = Contact(first_name="Max", last_name="Green", nickname="eugene_smith",
                                    title="LLC", company_name="Lazada", address="Moscow, Presnenskaya, 10",
                                    home="84951112233", mobile="89001112233", work="80001122333", fax="88003332211",
                                    first="eugene.kuznetsov@lazada.com", second="second@lazada.com", third="third@lazada.com",
                                    homepage="www.homepage.com", birth_year="1999", an_year="1907",
                                    second_address="Second address", home_address="My home address",
                                    notes="Another note for this test")
    contact.id = old_contacts[index].id
    app.contact.modify_contact_by_index(index, contact)
    new_contacts = app.contact.get_contact_list()
    assert len(old_contacts) == app.contact.count()
    old_contacts[index] = contact
    assert sorted(old_contacts, key=Contact.id_or_max) == sorted(new_contacts, key=Contact.id_or_max)


text:
package tests

import (
	"testing"

	"github.com/stretchr/testify/assert"

	"github.com/netapp/trident/storage_drivers/ontap/api/rest/models"
)

func TestInitFunctions(t *testing.T) {
	// the "github.com/netapp/trident/storage_drivers/ontap/api/rest/models" uses a lot of init()
	// the way they are generated within go-swagger, they can fail and cause our other unit tests
	// to fail as a side effect. this test exists as a quick sanity test to make sure those init
	// functions can be executed without generating panics.

	// this could be any class from the models package, it will still cause all of the init
	// functions within the package to be executed.  choosing this one as it has been a root
	// cause of failures.
	assert.NotNil(t, new(models.StorageBridge))
}


text:
(:
 :	Copyright 2008-2010 Mark Logic Corporation
 :
 :	Licensed under the Apache License, Version 2.0 (the "License");
 :	you may not use this file except in compliance with the License.
 :	You may obtain a copy of the License at
 :
 :	    http://www.apache.org/licenses/LICENSE-2.0
 :
 :	Unless required by applicable law or agreed to in writing, software
 :	distributed under the License is distributed on an "AS IS" BASIS,
 :	WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 :	See the License for the specific language governing permissions and
 :	limitations under the License.
 :
 :	@author Justin Makeig <jmakeig@marklogic.com>
 :
 :)
xquery version "1.0-ml";
import module namespace mvc="http://marklogic.com/mvc" at "/lib/mvc.xqy";
import module namespace s="http://marklogic.com/socrates" at "/lib/socrates.xqy";
declare option xdmp:mapping "false";

declare variable $mvc:model as map:map? external;
declare variable $mvc:errors as map:map? external;

<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
		<title>{map:get($mvc:model, "title")}</title>
		<link href="/assets/browser.css" rel="stylesheet" type="text/css"/>
		<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js" type="text/javascript"/>
		{map:get($mvc:model, "head")}
	</head>
	<body>
		{mvc:get-view("header.html", $mvc:model, $mvc:errors)}
		{map:get($mvc:model, "guts")}
		{mvc:get-view("footer.html", $mvc:model, $mvc:errors)}
	</body>
</html>


text:
Because Colossus is pre 1.0 and under heavy development, there is lots of
room for improvement and we are not afraid to make large-scale breaking changes
if it makes sense.  All bug fixes and feature improvements are welcome, but if
you are planning on implementing a significant change, especially one that
changes an API or breaks backwards compatibility, you should verify with one of
the core contributors that your work won't conflict with any ongoing or planned
changes.

## Branches

+ `master` contains the latest published version.
+ `develop` contains the next version.
+ `feature/*` for large features needing multiple PRs.

We use the [GitFlow](https://datasift.github.io/gitflow/IntroducingGitFlow.html) model for dealing with branches and releases.

## Pull Requests

1. Make sure an issue exists in the issue tracker for the work you want to contribute.
2. Fork the repo and create a branch from `develop`.
    + If it is a small change that will go into the next release then it can be named anything.
    + If it is a large feature that will require multiple PRs, then prefix the name with `feature/`.
3. Write the change.
4. If necessary, add tests.
5. If necessary, update [documentation](#documentation).
6. If you've significantly changed low-level code, you must run [benchmarks](#benchmarking) and provide numbers.
7. If you haven't already, complete the [Contributor License Agreement (CLA)](#contributor-license-agreement).
8. Submit your PR against the `develop` branch. Include the text "Fixes #issue-number" so when the PR is merged, the issue is automatically closed.
9. Once approved by two core contributors, the PR can be merged into `develop`.

## Documentation

[Paradox](https://github.com/lightbend/paradox) is used to turn the markdown files in `colosuss-docs/src/main/paradox` into HTML. To generate:

```
sbt
> project colossus-docs
> paradox
```

Then open `colossus-docs/target/paradox/site/main/index.html` to see the site.

When a new version is released, the version should be added to the top of `docs.yml` and the rake task ran:

```bash
rake site:publish
```

The rake task checks out each tagged version of colossus, runs paradox and generates the scaladocs. Each version is copied to a folder with the version at the top of `docs.yml` used as the latest version. The resulting site is upload to `gh-pages` branch, which github serves at `tumblr.github.io/colossus`.

## Benchmarking

1. Start the main app in examples project:

    ```sbtshell
    sbt colossus-examples/run
    ```

2. Run `wrk` with 50 connections, across 2 threads, a pipeline size of 16, for 10 seconds:

    ```bash
    wrk -c 50 -t 2 -d 10 --latency -s pipeline.lua http://localhost:9007/plaintext -- 16
    ```

**Note**: You definitely want to run it several times to make sure you get a good average. First time is always slower.
Throughput is the best metric here, since it's a single number and in this benchmark correlates very well with latency.
Performance takes a hit if you are constantly compiling, running, and shutting down. Best to compile, kill SBT, restart,
then run. Very tedious, but the most accurate. Also when running on your mac be very aware of running other apps and it
is usually best to kill CPU heavy apps.

## Contributor License Agreement

In order to accept your pull request, we need you to submit a Contributor License Agreement (CLA). A CLA is a way of protecting intellectual property disputes from harming the project. Complete your CLA [here](http://static.tumblr.com/zyubucd/GaTngbrpr/tumblr_corporate_contributor_license_agreement_v1__10-7-14.pdf).

# Publish

1. Merge develop (or hot fix branch) into master.
2. Update version in `version.sbt` and add to `docs.yml` (append `RC{X}` for release candidates)

    ```bash
    git add version.sbt
    git add docs.yml
    git commit -m "v{VERSION NUMBER}"
    ```

3. Create tag using just the version.

    ```bash
    git tag -a v{VERSION NUMBER}
    ```

4. Push changes to remote; travis will build and automatically publish to [sonatype](https://oss.sonatype.org/).

    ```bash
    git push origin
    ```

5. Generate the docs.

    ```bash
    rake site:publish
    ```

6. Merge master into develop and update version in `version.sbt` to point to the next snapshot.

# Publishing Milestones

1. On develop update version (must end with `-M{milestone number}`) in `version.sbt`
    ```bash
    git add version.sbt
    git commit -m "v{VERSION NUMBER}"
    ```
2. Create tag using just the version (with `-M{X}`).
    ```bash
    git tag -a v{VERSION NUMBER}
    ```
3. Push changes to remote; travis will build and automatically publish to [sonatype](https://oss.sonatype.org/).
    ```bash
    git push --follow-tags
    ```

## License

By contributing to Colossus you agree that your contributions will be licensed under its Apache 2.0 license.


text:
using System.Collections.Generic;
using System.Linq;

namespace Nancy.Model
{
    public static class NextIdHelper
    {
        public static int NextId<T>(this IList<T> list) where T : IEntity
        {
            return list.Any() ? list.Max(x => x.Id) + 1 : 0;
        }
    }
}