text:
/*
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
 * in compliance with the License. You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software distributed under the License
 * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
 * or implied. See the License for the specific language governing permissions and limitations under
 * the License.
 */
/*
 * This code was generated by https://github.com/googleapis/google-api-java-client-services/
 * Modify at your own risk.
 */

package com.google.api.services.composer.v1beta1.model;

/**
 * The configuration information for configuring a Private IP Cloud Composer environment.
 *
 *
 This is the Java data model class that specifies how to parse/serialize into the JSON that is
 * transmitted over HTTP when working with the Cloud Composer API. For a detailed explanation see:
 * https://developers.google.com/api-client-library/java/google-http-java-client/json
 *

 *
 * @author Google, Inc.
 */
@SuppressWarnings("javadoc")
public final class PrivateEnvironmentConfig extends com.google.api.client.json.GenericJson {

  /**
   * Optional. The CIDR block from which IP range in tenant project will be reserved for Cloud SQL.
   * Needs to be disjoint from web_server_ipv4_cidr_block
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String cloudSqlIpv4CidrBlock;

  /**
   * Optional. If `true`, a Private IP Cloud Composer environment is created. If this field is set
   * to true, `IPAllocationPolicy.use_ip_aliases` must be set to true.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.Boolean enablePrivateEnvironment;

  /**
   * Optional. Configuration for the private GKE cluster for a Private IP Cloud Composer
   * environment.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private PrivateClusterConfig privateClusterConfig;

  /**
   * Optional. The CIDR block from which IP range for web server will be reserved. Needs to be
   * disjoint from private_cluster_config.master_ipv4_cidr_block and cloud_sql_ipv4_cidr_block.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String webServerIpv4CidrBlock;

  /**
   * Output only. The IP range reserved for the tenant project's App Engine VMs.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String webServerIpv4ReservedRange;

  /**
   * Optional. The CIDR block from which IP range in tenant project will be reserved for Cloud SQL.
   * Needs to be disjoint from web_server_ipv4_cidr_block
   * @return value or {@code null} for none
   */
  public java.lang.String getCloudSqlIpv4CidrBlock() {
    return cloudSqlIpv4CidrBlock;
  }

  /**
   * Optional. The CIDR block from which IP range in tenant project will be reserved for Cloud SQL.
   * Needs to be disjoint from web_server_ipv4_cidr_block
   * @param cloudSqlIpv4CidrBlock cloudSqlIpv4CidrBlock or {@code null} for none
   */
  public PrivateEnvironmentConfig setCloudSqlIpv4CidrBlock(java.lang.String cloudSqlIpv4CidrBlock) {
    this.cloudSqlIpv4CidrBlock = cloudSqlIpv4CidrBlock;
    return this;
  }

  /**
   * Optional. If `true`, a Private IP Cloud Composer environment is created. If this field is set
   * to true, `IPAllocationPolicy.use_ip_aliases` must be set to true.
   * @return value or {@code null} for none
   */
  public java.lang.Boolean getEnablePrivateEnvironment() {
    return enablePrivateEnvironment;
  }

  /**
   * Optional. If `true`, a Private IP Cloud Composer environment is created. If this field is set
   * to true, `IPAllocationPolicy.use_ip_aliases` must be set to true.
   * @param enablePrivateEnvironment enablePrivateEnvironment or {@code null} for none
   */
  public PrivateEnvironmentConfig setEnablePrivateEnvironment(java.lang.Boolean enablePrivateEnvironment) {
    this.enablePrivateEnvironment = enablePrivateEnvironment;
    return this;
  }

  /**
   * Optional. Configuration for the private GKE cluster for a Private IP Cloud Composer
   * environment.
   * @return value or {@code null} for none
   */
  public PrivateClusterConfig getPrivateClusterConfig() {
    return privateClusterConfig;
  }

  /**
   * Optional. Configuration for the private GKE cluster for a Private IP Cloud Composer
   * environment.
   * @param privateClusterConfig privateClusterConfig or {@code null} for none
   */
  public PrivateEnvironmentConfig setPrivateClusterConfig(PrivateClusterConfig privateClusterConfig) {
    this.privateClusterConfig = privateClusterConfig;
    return this;
  }

  /**
   * Optional. The CIDR block from which IP range for web server will be reserved. Needs to be
   * disjoint from private_cluster_config.master_ipv4_cidr_block and cloud_sql_ipv4_cidr_block.
   * @return value or {@code null} for none
   */
  public java.lang.String getWebServerIpv4CidrBlock() {
    return webServerIpv4CidrBlock;
  }

  /**
   * Optional. The CIDR block from which IP range for web server will be reserved. Needs to be
   * disjoint from private_cluster_config.master_ipv4_cidr_block and cloud_sql_ipv4_cidr_block.
   * @param webServerIpv4CidrBlock webServerIpv4CidrBlock or {@code null} for none
   */
  public PrivateEnvironmentConfig setWebServerIpv4CidrBlock(java.lang.String webServerIpv4CidrBlock) {
    this.webServerIpv4CidrBlock = webServerIpv4CidrBlock;
    return this;
  }

  /**
   * Output only. The IP range reserved for the tenant project's App Engine VMs.
   * @return value or {@code null} for none
   */
  public java.lang.String getWebServerIpv4ReservedRange() {
    return webServerIpv4ReservedRange;
  }

  /**
   * Output only. The IP range reserved for the tenant project's App Engine VMs.
   * @param webServerIpv4ReservedRange webServerIpv4ReservedRange or {@code null} for none
   */
  public PrivateEnvironmentConfig setWebServerIpv4ReservedRange(java.lang.String webServerIpv4ReservedRange) {
    this.webServerIpv4ReservedRange = webServerIpv4ReservedRange;
    return this;
  }

  @Override
  public PrivateEnvironmentConfig set(String fieldName, Object value) {
    return (PrivateEnvironmentConfig) super.set(fieldName, value);
  }

  @Override
  public PrivateEnvironmentConfig clone() {
    return (PrivateEnvironmentConfig) super.clone();
  }

}


text:
package models;

import javax.persistence.Id;

import play.db.ebean.Model;
import play.data.validation.*;

public class Version extends Model {

	private static final long serialVersionUID = 1L;

	@Id
	public Long id;

	@Constraints.Required
	public Project project;

	@Constraints.Required
	public String version;

}

redpajama_set_name: RedPajamaGithub


text:
<?php

namespace Cake\Chronos\Traits;

use Cake\Chronos\ChronosInterface;
use DateTime;

/**
 * Provides string formatting methods for datetime instances.
 *
 * Expects implementing classes to define static::$toStringFormat
 */
trait FormattingTrait
{
    /**
     * Reset the format used to the default when type juggling a ChronosInterface instance to a string
     *
     * @return void
     */
    public static function resetToStringFormat()
    {
        static::setToStringFormat(ChronosInterface::DEFAULT_TO_STRING_FORMAT);
    }

    /**
     * Set the default format used when type juggling a ChronosInterface instance to a string
     *
     * @param string $format The format to use in future __toString() calls.
     * @return void
     */
    public static function setToStringFormat($format)
    {
        static::$toStringFormat = $format;
    }

    /**
     * Format the instance as a string using the set format
     *
     * @return string
     */
    public function __toString()
    {
        return $this->format(static::$toStringFormat);
    }

    /**
     * Format the instance as date
     *
     * @return string
     */
    public function toDateString()
    {
        return $this->format('Y-m-d');
    }

    /**
     * Format the instance as a readable date
     *
     * @return string
     */
    public function toFormattedDateString()
    {
        return $this->format('M j, Y');
    }

    /**
     * Format the instance as time
     *
     * @return string
     */
    public function toTimeString()
    {
        return $this->format('H:i:s');
    }

    /**
     * Format the instance as date and time
     *
     * @return string
     */
    public function toDateTimeString()
    {
        return $this->format('Y-m-d H:i:s');
    }

    /**
     * Format the instance with day, date and time
     *
     * @return string
     */
    public function toDayDateTimeString()
    {
        return $this->format('D, M j, Y g:i A');
    }

    /**
     * Format the instance as ATOM
     *
     * @return string
     */
    public function toAtomString()
    {
        return $this->format(DateTime::ATOM);
    }

    /**
     * Format the instance as COOKIE
     *
     * @return string
     */
    public function toCookieString()
    {
        return $this->format(DateTime::COOKIE);
    }

    /**
     * Format the instance as ISO8601
     *
     * @return string
     */
    public function toIso8601String()
    {
        return $this->format(DateTime::ATOM);
    }

    /**
     * Format the instance as RFC822
     *
     * @return string
     */
    public function toRfc822String()
    {
        return $this->format(DateTime::RFC822);
    }

    /**
     * Format the instance as RFC850
     *
     * @return string
     */
    public function toRfc850String()
    {
        return $this->format(DateTime::RFC850);
    }

    /**
     * Format the instance as RFC1036
     *
     * @return string
     */
    public function toRfc1036String()
    {
        return $this->format(DateTime::RFC1036);
    }

    /**
     * Format the instance as RFC1123
     *
     * @return string
     */
    public function toRfc1123String()
    {
        return $this->format(DateTime::RFC1123);
    }

    /**
     * Format the instance as RFC2822
     *
     * @return string
     */
    public function toRfc2822String()
    {
        return $this->format(DateTime::RFC2822);
    }

    /**
     * Format the instance as RFC3339
     *
     * @return string
     */
    public function toRfc3339String()
    {
        return $this->format(DateTime::RFC3339);
    }

    /**
     * Format the instance as RSS
     *
     * @return string
     */
    public function toRssString()
    {
        return $this->format(DateTime::RSS);
    }

    /**
     * Format the instance as W3C
     *
     * @return string
     */
    public function toW3cString()
    {
        return $this->format(DateTime::W3C);
    }

    /**
     * Returns a UNIX timestamp.
     *
     * @return string UNIX timestamp
     */
    public function toUnixString()
    {
        return $this->format('U');
    }

    /**
     * Returns the quarter
     *
     * @param bool $range Range.
     * @return mixed 1, 2, 3, or 4 quarter of year or array if $range true
     */
    public function toQuarter($range = false)
    {
        $quarter = ceil($this->format('m') / 3);
        if ($range === false) {
            return $quarter;
        }

        $year = $this->format('Y');
        switch ($quarter) {
            case 1:
                return [$year . '-01-01', $year . '-03-31'];
            case 2:
                return [$year . '-04-01', $year . '-06-30'];
            case 3:
                return [$year . '-07-01', $year . '-09-30'];
            case 4:
                return [$year . '-10-01', $year . '-12-31'];
        }
    }

    /**
     * @return int
     */
    public function toWeek()
    {
        return (int)$this->format('W');
    }
}


text:
module MediaWiktory::Wikipedia
  module Actions
    # Access graph tag functionality.
    #
    # Usage:
    #
    # ```ruby
    # api.graph.hash(value).perform # returns string with raw output
    # # or
    # api.graph.hash(value).response # returns output parsed and wrapped into Response object
    # ```
    #
    # See {Base} for generic explanation of working with MediaWiki actions and
    # {MediaWiktory::Wikipedia::Response} for working with action responses.
    #
    # All action's parameters are documented as its public methods, see below.
    #
    class Graph < MediaWiktory::Wikipedia::Actions::Get

      # Hash value of the graph
      #
      # @param value [String]
      # @return [self]
      def hash(value)
        merge(hash: value.to_s)
      end

      # Title of the article with the graph
      #
      # @param value [String]
      # @return [self]
      def title(value)
        merge(title: value.to_s)
      end

      # Text of the graph to be converted to JSON. Must be posted and used without title and hash parameters
      #
      # @param value [String]
      # @return [self]
      def text(value)
        merge(text: value.to_s)
      end
    end
  end
end


text:
package traffic_class // TrafficClass
import "github.com/antlr/antlr4/runtime/Go/antlr"

// BaseTrafficClassListener is a complete listener for a parse tree produced by TrafficClassParser.
type BaseTrafficClassListener struct{}

var _ TrafficClassListener = &BaseTrafficClassListener{}

// VisitTerminal is called when a terminal node is visited.
func (s *BaseTrafficClassListener) VisitTerminal(node antlr.TerminalNode) {}

// VisitErrorNode is called when an error node is visited.
func (s *BaseTrafficClassListener) VisitErrorNode(node antlr.ErrorNode) {}

// EnterEveryRule is called when any rule is entered.
func (s *BaseTrafficClassListener) EnterEveryRule(ctx antlr.ParserRuleContext) {}

// ExitEveryRule is called when any rule is exited.
func (s *BaseTrafficClassListener) ExitEveryRule(ctx antlr.ParserRuleContext) {}

// EnterMatchSrc is called when production matchSrc is entered.
func (s *BaseTrafficClassListener) EnterMatchSrc(ctx *MatchSrcContext) {}

// ExitMatchSrc is called when production matchSrc is exited.
func (s *BaseTrafficClassListener) ExitMatchSrc(ctx *MatchSrcContext) {}

// EnterMatchDst is called when production matchDst is entered.
func (s *BaseTrafficClassListener) EnterMatchDst(ctx *MatchDstContext) {}

// ExitMatchDst is called when production matchDst is exited.
func (s *BaseTrafficClassListener) ExitMatchDst(ctx *MatchDstContext) {}

// EnterMatchDSCP is called when production matchDSCP is entered.
func (s *BaseTrafficClassListener) EnterMatchDSCP(ctx *MatchDSCPContext) {}

// ExitMatchDSCP is called when production matchDSCP is exited.
func (s *BaseTrafficClassListener) ExitMatchDSCP(ctx *MatchDSCPContext) {}

// EnterMatchTOS is called when production matchTOS is entered.
func (s *BaseTrafficClassListener) EnterMatchTOS(ctx *MatchTOSContext) {}

// ExitMatchTOS is called when production matchTOS is exited.
func (s *BaseTrafficClassListener) ExitMatchTOS(ctx *MatchTOSContext) {}

// EnterMatchProtocol is called when production matchProtocol is entered.
func (s *BaseTrafficClassListener) EnterMatchProtocol(ctx *MatchProtocolContext) {}

// ExitMatchProtocol is called when production matchProtocol is exited.
func (s *BaseTrafficClassListener) ExitMatchProtocol(ctx *MatchProtocolContext) {}

// EnterMatchSrcPort is called when production matchSrcPort is entered.
func (s *BaseTrafficClassListener) EnterMatchSrcPort(ctx *MatchSrcPortContext) {}

// ExitMatchSrcPort is called when production matchSrcPort is exited.
func (s *BaseTrafficClassListener) ExitMatchSrcPort(ctx *MatchSrcPortContext) {}

// EnterMatchSrcPortRange is called when production matchSrcPortRange is entered.
func (s *BaseTrafficClassListener) EnterMatchSrcPortRange(ctx *MatchSrcPortRangeContext) {}

// ExitMatchSrcPortRange is called when production matchSrcPortRange is exited.
func (s *BaseTrafficClassListener) ExitMatchSrcPortRange(ctx *MatchSrcPortRangeContext) {}

// EnterMatchDstPort is called when production matchDstPort is entered.
func (s *BaseTrafficClassListener) EnterMatchDstPort(ctx *MatchDstPortContext) {}

// ExitMatchDstPort is called when production matchDstPort is exited.
func (s *BaseTrafficClassListener) ExitMatchDstPort(ctx *MatchDstPortContext) {}

// EnterMatchDstPortRange is called when production matchDstPortRange is entered.
func (s *BaseTrafficClassListener) EnterMatchDstPortRange(ctx *MatchDstPortRangeContext) {}

// ExitMatchDstPortRange is called when production matchDstPortRange is exited.
func (s *BaseTrafficClassListener) ExitMatchDstPortRange(ctx *MatchDstPortRangeContext) {}

// EnterCondCls is called when production condCls is entered.
func (s *BaseTrafficClassListener) EnterCondCls(ctx *CondClsContext) {}

// ExitCondCls is called when production condCls is exited.
func (s *BaseTrafficClassListener) ExitCondCls(ctx *CondClsContext) {}

// EnterCondAny is called when production condAny is entered.
func (s *BaseTrafficClassListener) EnterCondAny(ctx *CondAnyContext) {}

// ExitCondAny is called when production condAny is exited.
func (s *BaseTrafficClassListener) ExitCondAny(ctx *CondAnyContext) {}

// EnterCondAll is called when production condAll is entered.
func (s *BaseTrafficClassListener) EnterCondAll(ctx *CondAllContext) {}

// ExitCondAll is called when production condAll is exited.
func (s *BaseTrafficClassListener) ExitCondAll(ctx *CondAllContext) {}

// EnterCondNot is called when production condNot is entered.
func (s *BaseTrafficClassListener) EnterCondNot(ctx *CondNotContext) {}

// ExitCondNot is called when production condNot is exited.
func (s *BaseTrafficClassListener) ExitCondNot(ctx *CondNotContext) {}

// EnterCondBool is called when production condBool is entered.
func (s *BaseTrafficClassListener) EnterCondBool(ctx *CondBoolContext) {}

// ExitCondBool is called when production condBool is exited.
func (s *BaseTrafficClassListener) ExitCondBool(ctx *CondBoolContext) {}

// EnterCondIPv4 is called when production condIPv4 is entered.
func (s *BaseTrafficClassListener) EnterCondIPv4(ctx *CondIPv4Context) {}

// ExitCondIPv4 is called when production condIPv4 is exited.
func (s *BaseTrafficClassListener) ExitCondIPv4(ctx *CondIPv4Context) {}

// EnterCondPort is called when production condPort is entered.
func (s *BaseTrafficClassListener) EnterCondPort(ctx *CondPortContext) {}

// ExitCondPort is called when production condPort is exited.
func (s *BaseTrafficClassListener) ExitCondPort(ctx *CondPortContext) {}

// EnterCond is called when production cond is entered.
func (s *BaseTrafficClassListener) EnterCond(ctx *CondContext) {}

// ExitCond is called when production cond is exited.
func (s *BaseTrafficClassListener) ExitCond(ctx *CondContext) {}

// EnterTrafficClass is called when production trafficClass is entered.
func (s *BaseTrafficClassListener) EnterTrafficClass(ctx *TrafficClassContext) {}

// ExitTrafficClass is called when production trafficClass is exited.
func (s *BaseTrafficClassListener) ExitTrafficClass(ctx *TrafficClassContext) {}


text:
package org.hibernate.test.annotations.idmanytoone.alphabetical;

import org.junit.Test;

import org.hibernate.testing.junit4.BaseCoreFunctionalTestCase;

/**
 * @author Emmanuel Bernard
 */
public class AlphabeticalManyToOneTest extends BaseCoreFunctionalTestCase {
	@Test
	public void testAlphabeticalTest() throws Exception {
		//test through deployment
	}

	@Override
	protected Class[] getAnnotatedClasses() {
		return new Class[] {
				Acces.class,
				Droitacces.class,
				Benefserv.class,
				Service.class
		};
	}
}


text:
FOUNDATION_EXPORT double HRFrameworkVersionNumber;

//! Project version string for HRFramework.
FOUNDATION_EXPORT const unsigned char HRFrameworkVersionString[];

// In this header, you should import all the public headers of your framework using statements like #import <HRFramework/PublicHeader.h>

#import <HRFramework/HRFrameworkMacro.h>

#import <HRFramework/UIActionSheet+Blocks.h>
#import <HRFramework/UIAlertController+Blocks.h>
#import <HRFramework/UIAlertView+Blocks.h>
#import <HRFramework/UIPickerView+Blocks.h>

#import <HRFramework/NSArray+HRExtensions.h>
#import <HRFramework/NSDate+HRExtensions.h>
#import <HRFramework/NSDictionary+HRExtensions.h>
#import <HRFramework/NSString+HRExtensions.h>
#import <HRFramework/NSURLRequest+HRExtensions.h>
#import <HRFramework/UIButton+HRExtensions.h>
#import <HRFramework/UIColor+HRExtensions.h>
#import <HRFramework/UIImage+HRExtensions.h>
#import <HRFramework/UILabel+HRExtensions.h>
#import <HRFramework/UITextField+HRExtensions.h>

#import <HRFramework/HRAlertViewStylePlainTextInput.h>
#import <HRFramework/HRCircleProgressView.h>
#import <HRFramework/HRCycleScrollView.h>
#import <HRFramework/HRImagePickerController.h>
#import <HRFramework/HRLabel.h>
#import <HRFramework/HRLazyScrollView.h>
#import <HRFramework/HRNavigationController.h>
#import <HRFramework/HROutputView.h>
#import <HRFramework/HRTabBarController.h>
#import <HRFramework/HRTableView.h>
#import <HRFramework/HRTextField.h>
#import <HRFramework/HRTextView.h>
#import <HRFramework/HRView.h>

#import <HRFramework/HRCache.h>
#import <HRFramework/HRNetworking.h>
#import <HRFramework/HRSkinManager.h>

#import <HRFramework/HRFileUtil.h>
#import <HRFramework/HRIdentityCardUtil.h>
#import <HRFramework/HRNullSafe.h>
#import <HRFramework/HRSysAuthorityUtil.h>
#import <HRFramework/HRUserDefaultsUtil.h>
#import <HRFramework/HRValidateUtil.h>
#import <HRFramework/HRVersionUtil.h>


text:
package org.keycloak.authentication;

import org.keycloak.models.utils.FormMessage;

import javax.ws.rs.core.MultivaluedMap;
import java.util.List;

/**
 * Interface that encapsulates the current validation that is being performed.  Calling success() or validationError()
 * sets the status of this current validation.
 *
 * @author Bill Burke
 * @version $Revision: 1 $
 */
public interface ValidationContext extends FormContext {
    /**
     * Mark this validation as having a validation error
     *
     * @param formData form data you want to display when the form is refreshed
     * @param errors error messages to display on the form
     */
    void validationError(MultivaluedMap<String, String> formData, List<FormMessage> errors);

    void error(String error);

    /**
     * Mark this validation as sucessful
     *
     */
    void success();

    /**
     * The error messages of this current validation will take precedence over any others. Other error messages will not
     * be shown. This is useful to prevent validation from leaking to an attacker. For example, the recaptcha validator
     * calls this method so that usernames cannot be phished
     */
    void excludeOtherErrors();
}


text:
package com.example.dbflute.jodatime.cbean.cq.bs;

import java.util.Map;

import org.seasar.dbflute.cbean.*;
import org.seasar.dbflute.cbean.cvalue.ConditionValue;
import org.seasar.dbflute.cbean.sqlclause.SqlClause;
import org.seasar.dbflute.exception.IllegalConditionBeanOperationException;
import com.example.dbflute.jodatime.cbean.cq.ciq.*;
import com.example.dbflute.jodatime.cbean.*;
import com.example.dbflute.jodatime.cbean.cq.*;

/**
 * The base condition-query of PURCHASE.
 * @author DBFlute(AutoGenerator)
 */
public class BsPurchaseCQ extends AbstractBsPurchaseCQ {

    // ===================================================================================
    //                                                                           Attribute
    //                                                                           =========
    protected PurchaseCIQ _inlineQuery;

    // ===================================================================================
    //                                                                         Constructor
    //                                                                         ===========
    public BsPurchaseCQ(ConditionQuery childQuery, SqlClause sqlClause, String aliasName, int nestLevel) {
        super(childQuery, sqlClause, aliasName, nestLevel);
    }

    // ===================================================================================
    //                                                                 InlineView/OrClause
    //                                                                 ===================
    /**
     * Prepare InlineView query.

     * {select ... from ... left outer join (select * from PURCHASE) where FOO = [value] ...}
     *

     * cb.query().queryMemberStatus().inline().setFoo...;
     *

     * @return The condition-query for InlineView query. (NotNull)
     */
    public PurchaseCIQ inline() {
        if (_inlineQuery == null) { _inlineQuery = xcreateCIQ(); }
        _inlineQuery.xsetOnClause(false); return _inlineQuery;
    }

    protected PurchaseCIQ xcreateCIQ() {
        PurchaseCIQ ciq = xnewCIQ();
        ciq.xsetBaseCB(_baseCB);
        return ciq;
    }

    protected PurchaseCIQ xnewCIQ() {
        return new PurchaseCIQ(xgetReferrerQuery(), xgetSqlClause(), xgetAliasName(), xgetNestLevel(), this);
    }

    /**
     * Prepare OnClause query.

     * {select ... from ... left outer join PURCHASE on ... and FOO = [value] ...}
     *

     * cb.query().queryMemberStatus().on().setFoo...;
     *

     * @return The condition-query for OnClause query. (NotNull)
     * @throws IllegalConditionBeanOperationException When this condition-query is base query.
     */
    public PurchaseCIQ on() {
        if (isBaseQuery()) { throw new IllegalConditionBeanOperationException("OnClause for local table is unavailable!"); }
        PurchaseCIQ inlineQuery = inline(); inlineQuery.xsetOnClause(true); return inlineQuery;
    }

    // ===================================================================================
    //                                                                               Query
    //                                                                               =====

    protected ConditionValue _purchaseId;
    public ConditionValue getPurchaseId() {
        if (_purchaseId == null) { _purchaseId = nCV(); }
        return _purchaseId;
    }
    protected ConditionValue getCValuePurchaseId() { return getPurchaseId(); }

    /**
     * Add order-by as ascend.

     * PURCHASE_ID: {PK, ID, NotNull, BIGINT(19)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_PurchaseId_Asc() { regOBA("PURCHASE_ID"); return this; }

    /**
     * Add order-by as descend.

     * PURCHASE_ID: {PK, ID, NotNull, BIGINT(19)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_PurchaseId_Desc() { regOBD("PURCHASE_ID"); return this; }

    protected ConditionValue _memberId;
    public ConditionValue getMemberId() {
        if (_memberId == null) { _memberId = nCV(); }
        return _memberId;
    }
    protected ConditionValue getCValueMemberId() { return getMemberId(); }

    protected Map<String, MemberCQ> _memberId_InScopeRelation_MemberMap;
    public Map<String, MemberCQ> getMemberId_InScopeRelation_Member() { return _memberId_InScopeRelation_MemberMap; }
    public String keepMemberId_InScopeRelation_Member(MemberCQ subQuery) {
        if (_memberId_InScopeRelation_MemberMap == null) { _memberId_InScopeRelation_MemberMap = newLinkedHashMapSized(4); }
        String key = "subQueryMapKey" + (_memberId_InScopeRelation_MemberMap.size() + 1);
        _memberId_InScopeRelation_MemberMap.put(key, subQuery); return "memberId_InScopeRelation_Member." + key;
    }

    protected Map<String, MemberCQ> _memberId_NotInScopeRelation_MemberMap;
    public Map<String, MemberCQ> getMemberId_NotInScopeRelation_Member() { return _memberId_NotInScopeRelation_MemberMap; }
    public String keepMemberId_NotInScopeRelation_Member(MemberCQ subQuery) {
        if (_memberId_NotInScopeRelation_MemberMap == null) { _memberId_NotInScopeRelation_MemberMap = newLinkedHashMapSized(4); }
        String key = "subQueryMapKey" + (_memberId_NotInScopeRelation_MemberMap.size() + 1);
        _memberId_NotInScopeRelation_MemberMap.put(key, subQuery); return "memberId_NotInScopeRelation_Member." + key;
    }

    /**
     * Add order-by as ascend.

     * MEMBER_ID: {UQ, IX, NotNull, INTEGER(10), FK to MEMBER}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_MemberId_Asc() { regOBA("MEMBER_ID"); return this; }

    /**
     * Add order-by as descend.

     * MEMBER_ID: {UQ, IX, NotNull, INTEGER(10), FK to MEMBER}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_MemberId_Desc() { regOBD("MEMBER_ID"); return this; }

    protected ConditionValue _productId;
    public ConditionValue getProductId() {
        if (_productId == null) { _productId = nCV(); }
        return _productId;
    }
    protected ConditionValue getCValueProductId() { return getProductId(); }

    protected Map<String, ProductCQ> _productId_InScopeRelation_ProductMap;
    public Map<String, ProductCQ> getProductId_InScopeRelation_Product() { return _productId_InScopeRelation_ProductMap; }
    public String keepProductId_InScopeRelation_Product(ProductCQ subQuery) {
        if (_productId_InScopeRelation_ProductMap == null) { _productId_InScopeRelation_ProductMap = newLinkedHashMapSized(4); }
        String key = "subQueryMapKey" + (_productId_InScopeRelation_ProductMap.size() + 1);
        _productId_InScopeRelation_ProductMap.put(key, subQuery); return "productId_InScopeRelation_Product." + key;
    }

    protected Map<String, ProductCQ> _productId_NotInScopeRelation_ProductMap;
    public Map<String, ProductCQ> getProductId_NotInScopeRelation_Product() { return _productId_NotInScopeRelation_ProductMap; }
    public String keepProductId_NotInScopeRelation_Product(ProductCQ subQuery) {
        if (_productId_NotInScopeRelation_ProductMap == null) { _productId_NotInScopeRelation_ProductMap = newLinkedHashMapSized(4); }
        String key = "subQueryMapKey" + (_productId_NotInScopeRelation_ProductMap.size() + 1);
        _productId_NotInScopeRelation_ProductMap.put(key, subQuery); return "productId_NotInScopeRelation_Product." + key;
    }

    /**
     * Add order-by as ascend.

     * PRODUCT_ID: {UQ+, IX, NotNull, INTEGER(10), FK to PRODUCT}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_ProductId_Asc() { regOBA("PRODUCT_ID"); return this; }

    /**
     * Add order-by as descend.

     * PRODUCT_ID: {UQ+, IX, NotNull, INTEGER(10), FK to PRODUCT}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_ProductId_Desc() { regOBD("PRODUCT_ID"); return this; }

    protected ConditionValue _purchaseDatetime;
    public ConditionValue getPurchaseDatetime() {
        if (_purchaseDatetime == null) { _purchaseDatetime = nCV(); }
        return _purchaseDatetime;
    }
    protected ConditionValue getCValuePurchaseDatetime() { return getPurchaseDatetime(); }

    /**
     * Add order-by as ascend.

     * PURCHASE_DATETIME: {UQ+, IX, NotNull, TIMESTAMP(23, 10)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_PurchaseDatetime_Asc() { regOBA("PURCHASE_DATETIME"); return this; }

    /**
     * Add order-by as descend.

     * PURCHASE_DATETIME: {UQ+, IX, NotNull, TIMESTAMP(23, 10)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_PurchaseDatetime_Desc() { regOBD("PURCHASE_DATETIME"); return this; }

    protected ConditionValue _purchaseCount;
    public ConditionValue getPurchaseCount() {
        if (_purchaseCount == null) { _purchaseCount = nCV(); }
        return _purchaseCount;
    }
    protected ConditionValue getCValuePurchaseCount() { return getPurchaseCount(); }

    /**
     * Add order-by as ascend.

     * PURCHASE_COUNT: {NotNull, INTEGER(10)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_PurchaseCount_Asc() { regOBA("PURCHASE_COUNT"); return this; }

    /**
     * Add order-by as descend.

     * PURCHASE_COUNT: {NotNull, INTEGER(10)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_PurchaseCount_Desc() { regOBD("PURCHASE_COUNT"); return this; }

    protected ConditionValue _purchasePrice;
    public ConditionValue getPurchasePrice() {
        if (_purchasePrice == null) { _purchasePrice = nCV(); }
        return _purchasePrice;
    }
    protected ConditionValue getCValuePurchasePrice() { return getPurchasePrice(); }

    /**
     * Add order-by as ascend.

     * PURCHASE_PRICE: {IX, NotNull, INTEGER(10)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_PurchasePrice_Asc() { regOBA("PURCHASE_PRICE"); return this; }

    /**
     * Add order-by as descend.

     * PURCHASE_PRICE: {IX, NotNull, INTEGER(10)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_PurchasePrice_Desc() { regOBD("PURCHASE_PRICE"); return this; }

    protected ConditionValue _paymentCompleteFlg;
    public ConditionValue getPaymentCompleteFlg() {
        if (_paymentCompleteFlg == null) { _paymentCompleteFlg = nCV(); }
        return _paymentCompleteFlg;
    }
    protected ConditionValue getCValuePaymentCompleteFlg() { return getPaymentCompleteFlg(); }

    /**
     * Add order-by as ascend.

     * PAYMENT_COMPLETE_FLG: {NotNull, INTEGER(10)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_PaymentCompleteFlg_Asc() { regOBA("PAYMENT_COMPLETE_FLG"); return this; }

    /**
     * Add order-by as descend.

     * PAYMENT_COMPLETE_FLG: {NotNull, INTEGER(10)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_PaymentCompleteFlg_Desc() { regOBD("PAYMENT_COMPLETE_FLG"); return this; }

    protected ConditionValue _registerDatetime;
    public ConditionValue getRegisterDatetime() {
        if (_registerDatetime == null) { _registerDatetime = nCV(); }
        return _registerDatetime;
    }
    protected ConditionValue getCValueRegisterDatetime() { return getRegisterDatetime(); }

    /**
     * Add order-by as ascend.

     * REGISTER_DATETIME: {NotNull, TIMESTAMP(23, 10)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_RegisterDatetime_Asc() { regOBA("REGISTER_DATETIME"); return this; }

    /**
     * Add order-by as descend.

     * REGISTER_DATETIME: {NotNull, TIMESTAMP(23, 10)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_RegisterDatetime_Desc() { regOBD("REGISTER_DATETIME"); return this; }

    protected ConditionValue _registerUser;
    public ConditionValue getRegisterUser() {
        if (_registerUser == null) { _registerUser = nCV(); }
        return _registerUser;
    }
    protected ConditionValue getCValueRegisterUser() { return getRegisterUser(); }

    /**
     * Add order-by as ascend.

     * REGISTER_USER: {NotNull, VARCHAR(200)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_RegisterUser_Asc() { regOBA("REGISTER_USER"); return this; }

    /**
     * Add order-by as descend.

     * REGISTER_USER: {NotNull, VARCHAR(200)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_RegisterUser_Desc() { regOBD("REGISTER_USER"); return this; }

    protected ConditionValue _updateDatetime;
    public ConditionValue getUpdateDatetime() {
        if (_updateDatetime == null) { _updateDatetime = nCV(); }
        return _updateDatetime;
    }
    protected ConditionValue getCValueUpdateDatetime() { return getUpdateDatetime(); }

    /**
     * Add order-by as ascend.

     * UPDATE_DATETIME: {NotNull, TIMESTAMP(23, 10)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_UpdateDatetime_Asc() { regOBA("UPDATE_DATETIME"); return this; }

    /**
     * Add order-by as descend.

     * UPDATE_DATETIME: {NotNull, TIMESTAMP(23, 10)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_UpdateDatetime_Desc() { regOBD("UPDATE_DATETIME"); return this; }

    protected ConditionValue _updateUser;
    public ConditionValue getUpdateUser() {
        if (_updateUser == null) { _updateUser = nCV(); }
        return _updateUser;
    }
    protected ConditionValue getCValueUpdateUser() { return getUpdateUser(); }

    /**
     * Add order-by as ascend.

     * UPDATE_USER: {NotNull, VARCHAR(200)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_UpdateUser_Asc() { regOBA("UPDATE_USER"); return this; }

    /**
     * Add order-by as descend.

     * UPDATE_USER: {NotNull, VARCHAR(200)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_UpdateUser_Desc() { regOBD("UPDATE_USER"); return this; }

    protected ConditionValue _versionNo;
    public ConditionValue getVersionNo() {
        if (_versionNo == null) { _versionNo = nCV(); }
        return _versionNo;
    }
    protected ConditionValue getCValueVersionNo() { return getVersionNo(); }

    /**
     * Add order-by as ascend.

     * VERSION_NO: {NotNull, BIGINT(19)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_VersionNo_Asc() { regOBA("VERSION_NO"); return this; }

    /**
     * Add order-by as descend.

     * VERSION_NO: {NotNull, BIGINT(19)}
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addOrderBy_VersionNo_Desc() { regOBD("VERSION_NO"); return this; }

    // ===================================================================================
    //                                                             SpecifiedDerivedOrderBy
    //                                                             =======================
    /**
     * Add order-by for specified derived column as ascend.
     *

     * cb.specify().derivedPurchaseList().max(new SubQuery<PurchaseCB>() {
     *     public void query(PurchaseCB subCB) {
     *         subCB.specify().columnPurchaseDatetime();
     *     }
     * }, aliasName);
     * // order by [alias-name] asc
     * cb.addSpecifiedDerivedOrderBy_Asc(aliasName);
     *

     * @param aliasName The alias name specified at (Specify)DerivedReferrer. (NotNull)
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addSpecifiedDerivedOrderBy_Asc(String aliasName)
    { registerSpecifiedDerivedOrderBy_Asc(aliasName); return this; }

    /**
     * Add order-by for specified derived column as descend.
     *

     * cb.specify().derivedPurchaseList().max(new SubQuery<PurchaseCB>() {
     *     public void query(PurchaseCB subCB) {
     *         subCB.specify().columnPurchaseDatetime();
     *     }
     * }, aliasName);
     * // order by [alias-name] desc
     * cb.addSpecifiedDerivedOrderBy_Desc(aliasName);
     *

     * @param aliasName The alias name specified at (Specify)DerivedReferrer. (NotNull)
     * @return this. (NotNull)
     */
    public BsPurchaseCQ addSpecifiedDerivedOrderBy_Desc(String aliasName)
    { registerSpecifiedDerivedOrderBy_Desc(aliasName); return this; }

    // ===================================================================================
    //                                                                         Union Query
    //                                                                         ===========
    protected void reflectRelationOnUnionQuery(ConditionQuery baseQueryAsSuper, ConditionQuery unionQueryAsSuper) {
        PurchaseCQ baseQuery = (PurchaseCQ)baseQueryAsSuper;
        PurchaseCQ unionQuery = (PurchaseCQ)unionQueryAsSuper;
        if (baseQuery.hasConditionQueryMember()) {
            unionQuery.queryMember().reflectRelationOnUnionQuery(baseQuery.queryMember(), unionQuery.queryMember());
        }
        if (baseQuery.hasConditionQueryProduct()) {
            unionQuery.queryProduct().reflectRelationOnUnionQuery(baseQuery.queryProduct(), unionQuery.queryProduct());
        }
    }

    // ===================================================================================
    //                                                                       Foreign Query
    //                                                                       =============
    /**
     * Get the condition-query for relation table.

     * MEMBER by my MEMBER_ID, named 'member'.
     * @return The instance of condition-query. (NotNull)
     */
    public MemberCQ queryMember() {
        return getConditionQueryMember();
    }
    protected MemberCQ _conditionQueryMember;
    public MemberCQ getConditionQueryMember() {
        if (_conditionQueryMember == null) {
            _conditionQueryMember = xcreateQueryMember();
            xsetupOuterJoinMember();
        }
        return _conditionQueryMember;
    }
    protected MemberCQ xcreateQueryMember() {
        String nrp = resolveNextRelationPath("PURCHASE", "member");
        String jan = resolveJoinAliasName(nrp, xgetNextNestLevel());
        MemberCQ cq = new MemberCQ(this, xgetSqlClause(), jan, xgetNextNestLevel());
        cq.xsetBaseCB(_baseCB);
        cq.xsetForeignPropertyName("member");
        cq.xsetRelationPath(nrp); return cq;
    }
    protected void xsetupOuterJoinMember() {
        MemberCQ cq = getConditionQueryMember();
        Map<String, String> joinOnMap = newLinkedHashMapSized(4);
        joinOnMap.put("MEMBER_ID", "MEMBER_ID");
        registerOuterJoin(cq, joinOnMap, "member");
    }
    public boolean hasConditionQueryMember() {
        return _conditionQueryMember != null;
    }

    /**
     * Get the condition-query for relation table.

     * PRODUCT by my PRODUCT_ID, named 'product'.
     * @return The instance of condition-query. (NotNull)
     */
    public ProductCQ queryProduct() {
        return getConditionQueryProduct();
    }
    protected ProductCQ _conditionQueryProduct;
    public ProductCQ getConditionQueryProduct() {
        if (_conditionQueryProduct == null) {
            _conditionQueryProduct = xcreateQueryProduct();
            xsetupOuterJoinProduct();
        }
        return _conditionQueryProduct;
    }
    protected ProductCQ xcreateQueryProduct() {
        String nrp = resolveNextRelationPath("PURCHASE", "product");
        String jan = resolveJoinAliasName(nrp, xgetNextNestLevel());
        ProductCQ cq = new ProductCQ(this, xgetSqlClause(), jan, xgetNextNestLevel());
        cq.xsetBaseCB(_baseCB);
        cq.xsetForeignPropertyName("product");
        cq.xsetRelationPath(nrp); return cq;
    }
    protected void xsetupOuterJoinProduct() {
        ProductCQ cq = getConditionQueryProduct();
        Map<String, String> joinOnMap = newLinkedHashMapSized(4);
        joinOnMap.put("PRODUCT_ID", "PRODUCT_ID");
        registerOuterJoin(cq, joinOnMap, "product");
    }
    public boolean hasConditionQueryProduct() {
        return _conditionQueryProduct != null;
    }

    protected Map<String, Object> xfindFixedConditionDynamicParameterMap(String property) {
        return null;
    }

    // ===================================================================================
    //                                                                     ScalarCondition
    //                                                                     ===============
    protected Map<String, PurchaseCQ> _scalarConditionMap;
    public Map<String, PurchaseCQ> getScalarCondition() { return _scalarConditionMap; }
    public String keepScalarCondition(PurchaseCQ subQuery) {
        if (_scalarConditionMap == null) { _scalarConditionMap = newLinkedHashMapSized(4); }
        String key = "subQueryMapKey" + (_scalarConditionMap.size() + 1);
        _scalarConditionMap.put(key, subQuery); return "scalarCondition." + key;
    }

    // ===================================================================================
    //                                                                       MyselfDerived
    //                                                                       =============
    protected Map<String, PurchaseCQ> _specifyMyselfDerivedMap;
    public Map<String, PurchaseCQ> getSpecifyMyselfDerived() { return _specifyMyselfDerivedMap; }
    public String keepSpecifyMyselfDerived(PurchaseCQ subQuery) {
        if (_specifyMyselfDerivedMap == null) { _specifyMyselfDerivedMap = newLinkedHashMapSized(4); }
        String key = "subQueryMapKey" + (_specifyMyselfDerivedMap.size() + 1);
        _specifyMyselfDerivedMap.put(key, subQuery); return "specifyMyselfDerived." + key;
    }

    protected Map<String, PurchaseCQ> _queryMyselfDerivedMap;
    public Map<String, PurchaseCQ> getQueryMyselfDerived() { return _queryMyselfDerivedMap; }
    public String keepQueryMyselfDerived(PurchaseCQ subQuery) {
        if (_queryMyselfDerivedMap == null) { _queryMyselfDerivedMap = newLinkedHashMapSized(4); }
        String key = "subQueryMapKey" + (_queryMyselfDerivedMap.size() + 1);
        _queryMyselfDerivedMap.put(key, subQuery); return "queryMyselfDerived." + key;
    }
    protected Map<String, Object> _qyeryMyselfDerivedParameterMap;
    public Map<String, Object> getQueryMyselfDerivedParameter() { return _qyeryMyselfDerivedParameterMap; }
    public String keepQueryMyselfDerivedParameter(Object parameterValue) {
        if (_qyeryMyselfDerivedParameterMap == null) { _qyeryMyselfDerivedParameterMap = newLinkedHashMapSized(4); }
        String key = "subQueryParameterKey" + (_qyeryMyselfDerivedParameterMap.size() + 1);
        _qyeryMyselfDerivedParameterMap.put(key, parameterValue); return "queryMyselfDerivedParameter." + key;
    }

    // ===================================================================================
    //                                                                        MyselfExists
    //                                                                        ============
    protected Map<String, PurchaseCQ> _myselfExistsMap;
    public Map<String, PurchaseCQ> getMyselfExists() { return _myselfExistsMap; }
    public String keepMyselfExists(PurchaseCQ subQuery) {
        if (_myselfExistsMap == null) { _myselfExistsMap = newLinkedHashMapSized(4); }
        String key = "subQueryMapKey" + (_myselfExistsMap.size() + 1);
        _myselfExistsMap.put(key, subQuery); return "myselfExists." + key;
    }

    // ===================================================================================
    //                                                                       MyselfInScope
    //                                                                       =============
    protected Map<String, PurchaseCQ> _myselfInScopeMap;
    public Map<String, PurchaseCQ> getMyselfInScope() { return _myselfInScopeMap; }
    public String keepMyselfInScope(PurchaseCQ subQuery) {
        if (_myselfInScopeMap == null) { _myselfInScopeMap = newLinkedHashMapSized(4); }
        String key = "subQueryMapKey" + (_myselfInScopeMap.size() + 1);
        _myselfInScopeMap.put(key, subQuery); return "myselfInScope." + key;
    }

    // ===================================================================================
    //                                                                       Very Internal
    //                                                                       =============
    // very internal (for suppressing warn about 'Not Use Import')
    protected String xCB() { return PurchaseCB.class.getName(); }
    protected String xCQ() { return PurchaseCQ.class.getName(); }
    protected String xMap() { return Map.class.getName(); }
}


text:
<!doctype html>

  <meta charset="UTF-8">
  <title>Estimated Cost Analysis</title>

These metrics are not meant to be used as law but are a relative measure of the quality
  and cost of a program

Back to Overview

    Metric
    Value
    Description

    Maintainability
    80.96
    This is the relative maintainability of the file on a scale of 0-100. Higher is better.

    Difficulty
    7.29
    This is a measure of how difficult it is to understand the code. Lower is better.

    Cyclomatic Complexity
    1
    This is how complex the code is based on the number of paths through the code. Lower is better

    Cyclomatic Density
    8.33
    This is a re-expression of the above metric as a percentage based on the lines of code. Lower is better.

    Effort
    2109.26
    This is the amount of effort needed to write the code based on it's difficulty and length

    Time
    0.03 Hours
    This is the estimated amount of time needed to write the file based on the effort required.

    Cost
    $1.52
    This is the estimated cost to develop the file based on the time needed to develop it.

    Bugs
    0.10
    This is the estimated number of bugs in the file.

    Logical SLOC
    12
    This is the number of lines of software that are considered logic.

    Physical SLOC
    33
    This is the total lines of source code including up to 25% whitespace, but ignoring excessive formatting.

Dependencies:

    Name
    Line #
    Type

    gulp-jscpd
    3
    CommonJS

Functions:

    setupJSCPD

    Metric
    Value
    Description

    Line #
    14
    The line the function appears on.

    Parameters
    2
    The number of parameters the function takes.

    Difficulty
    2.67
    This is a measure of how difficult the method is to understand. Lower is better.

    Cyclomatic Complexity
    1
    This is how complex the method is based on the number of paths through the code. Lower is better.

    Cyclomatic Density
    33.33
    This is a re-expression of the above metric as a percentage based on the lines of code. Lower is better.

    Effort
    167.75
    This is the amount of effort needed to write the code based on it's difficulty and length.

    Time
    0.16 Minutes
    This is the estimated amount of time needed to write the method based on the effort required.

    Cost
    $1.21
    This is the estimated cost to develop the file based on the time needed to develop it.

    Bugs
    0.02
    This is the estimated number of bugs in the method.

    Logical SLOC
    3
    This is the number of lines of software that are considered logic.

    Physical SLOC
    6
    This is the total lines of source code including up to 25% whitespace, but ignoring excessive formatting.

    jscpdTask

    Metric
    Value
    Description

    Line #
    26
    The line the function appears on.

    Parameters
    0
    The number of parameters the function takes.

    Difficulty
    2.81
    This is a measure of how difficult the method is to understand. Lower is better.

    Cyclomatic Complexity
    1
    This is how complex the method is based on the number of paths through the code. Lower is better.

    Cyclomatic Density
    50.00
    This is a re-expression of the above metric as a percentage based on the lines of code. Lower is better.

    Effort
    187.33
    This is the amount of effort needed to write the code based on it's difficulty and length.

    Time
    0.17 Minutes
    This is the estimated amount of time needed to write the method based on the effort required.

    Cost
    $1.35
    This is the estimated cost to develop the file based on the time needed to develop it.

    Bugs
    0.02
    This is the estimated number of bugs in the method.

    Logical SLOC
    2
    This is the number of lines of software that are considered logic.

    Physical SLOC
    6
    This is the total lines of source code including up to 25% whitespace, but ignoring excessive formatting.


text:
<?php
declare(strict_types=1);

/**
 * DO NOT EDIT THIS FILE as it will be overwritten by the Pbj compiler.
 * @link https://github.com/gdbots/pbjc-php
 *
 * Returns an array of curies using mixin "gdbots:ncr:mixin:mark-node-as-pending:v1"
 * @link http://schemas.gdbots.io/json-schema/gdbots/ncr/mixin/mark-node-as-pending/1-0-0.json#
 */

return [
];


text:
using System;
using System.Collections.Generic;
using ChatterBox.Core.Infrastructure.Facts;

namespace ChatterBox.Core.Infrastructure.Entities
{
    public interface IAggregateRoot
    {
        Guid Id { get; }
        IEnumerable<IFact> GetAndClearPendingFacts();
        Guid RevisionId { get; }
        void SetRevisionId(Guid revisionId);
    }
}


text:
using System;
using System.Diagnostics;
using Microsoft.VisualStudio;
using Microsoft.VisualStudio.Shell;
using Microsoft.VisualStudio.Shell.Interop;
using IServiceProvider = System.IServiceProvider;
using ShellConstants = Microsoft.VisualStudio.Shell.Interop.Constants;

namespace Microsoft.VisualStudio.Project
{

    [CLSCompliant(false)]
    public abstract class SolutionListener : IVsSolutionEvents3, IVsSolutionEvents4, IDisposable, IVsSolutionEvents5, IVsSolutionEvents6
    {

        #region fields
		private uint eventsCookie = (uint)ShellConstants.VSCOOKIE_NIL;
		private IVsSolution solution = null;
		private IServiceProvider serviceProvider = null;
		private bool isDisposed;
        /// <summary>
        /// Defines an object that will be a mutex for this object for synchronizing thread calls.
        /// </summary>
        private static volatile object Mutex = new object();
        #endregion

        #region ctors
        protected SolutionListener(IServiceProvider serviceProviderParameter)
        {
            if (serviceProviderParameter == null)
            {
                throw new ArgumentNullException("serviceProviderParameter");
            }
            this.serviceProvider = serviceProviderParameter;
            this.solution = null;
            ThreadHelper.JoinableTaskFactory.Run(async delegate
            {
                await ThreadHelper.JoinableTaskFactory.SwitchToMainThreadAsync();
                this.solution = this.serviceProvider.GetService(typeof(SVsSolution)) as IVsSolution;
            });

            if (this.solution == null)
            {
                throw new InvalidOperationException("Could not get the IVsSolution object from the services exposed by this project");
            }

            this.InteropSafeIVsSolutionEvents = Utilities.GetOuterAs<IVsSolutionEvents>(this);
        }
        #endregion

        #region properties

        public IVsSolutionEvents InteropSafeIVsSolutionEvents
        {
            get;
            protected set;
        }

        protected uint EventsCookie
        {
            get
            {
                return this.eventsCookie;
            }
        }

        protected IVsSolution Solution
        {
            get
            {
                return this.solution;
            }
        }

        protected IServiceProvider ServiceProvider
        {
            get
            {
                return this.serviceProvider;
            }
        }
        #endregion

        #region IVsSolutionEvents3, IVsSolutionEvents2, IVsSolutionEvents methods
        public virtual int OnAfterCloseSolution(object reserved)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnAfterClosingChildren(IVsHierarchy hierarchy)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnAfterLoadProject(IVsHierarchy stubHierarchy, IVsHierarchy realHierarchy)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnAfterMergeSolution(object pUnkReserved)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnAfterOpenProject(IVsHierarchy hierarchy, int added)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnAfterOpenSolution(object pUnkReserved, int fNewSolution)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnAfterOpeningChildren(IVsHierarchy hierarchy)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnBeforeCloseProject(IVsHierarchy hierarchy, int removed)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnBeforeCloseSolution(object pUnkReserved)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnBeforeClosingChildren(IVsHierarchy hierarchy)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnBeforeOpeningChildren(IVsHierarchy hierarchy)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnBeforeUnloadProject(IVsHierarchy realHierarchy, IVsHierarchy rtubHierarchy)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnQueryCloseProject(IVsHierarchy hierarchy, int removing, ref int cancel)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnQueryCloseSolution(object pUnkReserved, ref int cancel)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnQueryUnloadProject(IVsHierarchy pRealHierarchy, ref int cancel)
        {
            return VSConstants.E_NOTIMPL;
        }
        #endregion

        #region IVsSolutionEvents4 methods
        public virtual int OnAfterAsynchOpenProject(IVsHierarchy hierarchy, int added)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnAfterChangeProjectParent(IVsHierarchy hierarchy)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnAfterRenameProject(IVsHierarchy hierarchy)
        {
            return VSConstants.E_NOTIMPL;
        }

        /// <summary>
        /// Fired before a project is moved from one parent to another in the solution explorer
        /// </summary>
        public virtual int OnQueryChangeProjectParent(IVsHierarchy hierarchy, IVsHierarchy newParentHier, ref int cancel)
        {
            return VSConstants.E_NOTIMPL;
        }
        #endregion

        #region Dispose

        /// <summary>
        /// The IDispose interface Dispose method for disposing the object determinastically.
        /// </summary>
        public void Dispose()
        {
            ThreadHelper.ThrowIfNotOnUIThread();

            this.Dispose(true);
            GC.SuppressFinalize(this);
        }

        #endregion

        #region methods
        public void Init()
        {
            ThreadHelper.ThrowIfNotOnUIThread();

            if (this.solution != null)
            {
                this.solution.AdviseSolutionEvents(this.InteropSafeIVsSolutionEvents, out this.eventsCookie);
            }
        }

        /// <summary>
        /// The method that does the cleanup.
        /// </summary>
        /// <param name="disposing"></param>
        [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA1806:DoNotIgnoreMethodResults", MessageId = "Microsoft.VisualStudio.Shell.Interop.IVsSolution.UnadviseSolutionEvents(System.UInt32)")]
        protected virtual void Dispose(bool disposing)
        {
            // Everybody can go here.
            ThreadHelper.ThrowIfNotOnUIThread();

            if (!this.isDisposed)
            {
                // Synchronize calls to the Dispose simulteniously.
                lock(Mutex)
                {
                    if(disposing && this.eventsCookie != (uint)ShellConstants.VSCOOKIE_NIL && this.solution != null)
                    {
                        this.solution.UnadviseSolutionEvents((uint)this.eventsCookie);
                        this.eventsCookie = (uint)ShellConstants.VSCOOKIE_NIL;
                    }

                    this.isDisposed = true;
                }
            }
        }
        #endregion

        #region IVsSolutionEvents5
        public virtual void OnBeforeOpenProject(ref Guid guidProjectID, ref Guid guidProjectType, string pszFileName)
        {
            return;
        }
        #endregion
        #region IVsSolutionEvents6
        public virtual int OnBeforeProjectRegisteredInRunningDocumentTable(Guid projectID, string projectFullPath)
        {
            return VSConstants.E_NOTIMPL;
        }

        public virtual int OnAfterProjectRegisteredInRunningDocumentTable(Guid projectID, string projectFullPath, uint docCookie)
        {
            return VSConstants.E_NOTIMPL;
        }
        #endregion

    }
}


text:
DEFINE_string(dir,
              "/tmp",
              "Where to write test logs");

DEFINE_string(file_base,
              "teststate",
              "Write logs w/ this prefix");

DEFINE_int32(block_size,
             128,
             "We create state logs w/ this size");

DEFINE_int32(blocks_per_file,
             500,
             "We create state logs w/ this size");

DEFINE_int32(rand_seed,
             3274,
             "Seed the random number generator w/ this");

DEFINE_string(name_len,
              "3-150",
              "Interval: state names have a random length in this interval");

DEFINE_string(value_len,
              "1-1500",
              "Interval: state values have a random length in this interval");

DEFINE_int32(num_ops,
             5000,
             "Number of operation per step. An op is: add,del,modify,..");

DEFINE_int32(num_steps,
             7,
             "On each step: a StateKeeper is created, some values are "
             "added/deleted/modified, the StateKeeper is destroyed, state data "
             "is stored on disk.");

//////////////////////////////////////////////////////////////////////

struct Action {
  enum ID {
    CHECKPOINT,
    TRANSACTION,
    ADD,
    DEL_EXISTENT,
    DEL_NONEXISTENT,
    MODIFY,
  };
  ID id_;
  // The chance of taking an action is proportioned with this value.
  uint32 chance_;
  Action(ID id, int32 chance) : id_(id), chance_(chance) {}
} g_actions[] = {
    Action(Action::CHECKPOINT, 1),
    Action(Action::TRANSACTION, 5),
    Action(Action::ADD, 70),
    Action(Action::DEL_EXISTENT, 20),
    Action(Action::DEL_NONEXISTENT, 20),
    Action(Action::MODIFY, 200)
};

static unsigned int g_rand_seed = 0;
static util::Interval g_name_len(0,0);
static util::Interval g_value_len(0,0);

// generate a random string, with length: random in 'interval'
string RandomString(const util::Interval& interval) {
  static const char kLetters[] =
    "1234567890qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM_";
  const int len = interval.Rand(&g_rand_seed);
  char* tmp = new char[len+1];
  for ( int i = 0; i < len; ++i ) {
    tmp[i] = kLetters[rand_r(&g_rand_seed) % (sizeof(kLetters) - 1)];
  }
  tmp[len] = 0;
  string s(tmp);
  delete [] tmp;
  return s;
}

// print these many characters of each string value
static const uint32 kShortStringLen = 32;
inline ostream& operator<<(ostream& os, const string& s) {
  if ( s.size() < kShortStringLen ) {
    return os << s.c_str();
  }
  return os << s.substr(0, kShortStringLen).c_str() << "...";
}

// Choose a random action, based on each action chance.
Action::ID RandomAction() {
  static uint32 g_total_chances = 0;
  if ( g_total_chances == 0 ) {
    for ( uint32 i = 0; i < NUMBEROF(g_actions); i++ ) {
      g_total_chances += g_actions[i].chance_;
    }
  }
  int32 rnd = ::rand_r(&g_rand_seed) % g_total_chances;
  for ( uint32 i = 0; i < NUMBEROF(g_actions); i++ ) {
    rnd -= g_actions[i].chance_;
    if ( rnd <= 0 ) {
      return g_actions[i].id_;
    }
  }
  LOG_FATAL << "g_total_chances: " << g_total_chances << ", rnd: " << rnd;
  return Action::ADD;
}

// state: a duplicate of the StateKeeper
// names: contains all names that have ever been in state. (i.e. current names
//        in 'state' + old names that were deleted from state). Used to verify
//        that the old names were indeed deleted.
void PerformStep(map<string, string>& state, vector<string>& names) {
  io::StateKeeper sk(FLAGS_dir,
                     FLAGS_file_base,
                     FLAGS_block_size,
                     FLAGS_blocks_per_file);
  CHECK(sk.Initialize());

  // Verify the 'state' map is identical with the StateKeeper
  LOG_WARNING << "Initial verification: names.size(): " << names.size();
  for ( int i = 0; i < names.size(); ++i ) {
    if ( state.find(names[i]) != state.end() ) {
      string val;
      CHECK(sk.GetValue(names[i], &val)) << " key: " << names[i];
      CHECK(state[names[i]] == val) << "i: " << i
          << ", state[" << names[i] << "] = [" << state[names[i]]
          << "], found in keeper: [" << val << "]";
    } else {
      CHECK(!sk.HasValue(names[i])) << " key: " << names[i];
    }
  }
  // count modifications, just for log
  int32 records_added_since_checkpoint = 0;
  int32 records_modified_since_checkpoint = 0;
  bool in_transaction = false;
  for ( int i = 0; i < FLAGS_num_ops; ++i ) {
    const Action::ID op = RandomAction();
    switch ( op ) {
      case Action::CHECKPOINT:
        LOG_INFO << "OP Checkpointing " << names.size()
                 << " values, added since checkpoint: "
                 << records_added_since_checkpoint
                 << ", modified since checkpoint: "
                 << records_modified_since_checkpoint;
        if ( in_transaction ) {
          LOG_INFO << "CommitTransaction before checkpoint";
          sk.CommitTransaction();
          in_transaction = false;
        }
        CHECK(sk.Checkpoint());
        records_added_since_checkpoint = 0;
        records_modified_since_checkpoint = 0;
        break;
      case Action::TRANSACTION:
        if ( in_transaction ) {
          LOG_INFO << "OP CommitTransaction";
          sk.CommitTransaction();
          in_transaction = false;
        } else {
          LOG_INFO << "OP BeginTransaction";
          sk.BeginTransaction();
          in_transaction = true;
        }
        break;
      case Action::DEL_EXISTENT:
        if ( !names.empty() ) {
          int rand_ndx = ::rand_r(&g_rand_seed) % names.size();
          const string& key = names[rand_ndx];
          if ( state.find(key) == state.end() ) {
            CHECK(!sk.HasValue(key));
            continue;
          }
          LOG_DEBUG << "OP DeleteValue: [" << key << "]";
          sk.DeleteValue(key);
          int32 count = state.erase(key);
          CHECK_EQ(count, 1);
        }
        break;
      case Action::DEL_NONEXISTENT: {
          const string key = RandomString(g_name_len);
          if ( state.find(key) != state.end() ) {
            CHECK(sk.HasValue(key));
            LOG_ERROR << "Go play lottery: " << key;
            continue;
          }
          LOG_DEBUG << "OP DeleteValue: [" << key << "]";
          sk.DeleteValue(key);
          int32 count = state.erase(key);
          CHECK_EQ(count, 0);
        }
        break;
      case Action::ADD: {
          const string k = RandomString(g_name_len);
          if ( state.find(k) != state.end() ) {
            CHECK(sk.HasValue(k));
            LOG_ERROR << "Go play lottery: " << k;
            continue;
          }
          const string val = RandomString(g_value_len);
          LOG_DEBUG << "OP AddValue: [" << k << "] -> [" << val << "]";
          records_added_since_checkpoint++;
          CHECK(sk.SetValue(k, val));
          names.push_back(k);
          state[k] = val;
        }
        break;
      case Action::MODIFY: {
          if ( names.empty() ) {
            continue;
          }
          const string key = names[rand_r(&g_rand_seed) % names.size()];
          const string val = RandomString(g_value_len);
          records_modified_since_checkpoint++;
          LOG_DEBUG << "OP ModifyValue: [" << key << "] -> [" << val << "]";
          CHECK(sk.SetValue(key, val));
          state[key] = val;
        }
        break;
    }
  }
  // complete transaction before ending this step
  if ( in_transaction ) {
    LOG_INFO << "CommitTransaction before destroying StateKeeper";
    sk.CommitTransaction();
    in_transaction = false;
  }
  // Verify again that the 'state' map is identical with the StateKeeper
  LOG_WARNING << "Final verification: names.size(): " << names.size()
              << ", records_added_since_checkpoint: "
              << records_added_since_checkpoint
              << ", records_modified_since_checkpoint: "
              << records_modified_since_checkpoint;
  for ( size_t i = 0; i < names.size(); ++i ) {
    if ( state.find(names[i]) != state.end() ) {
      string val;
      CHECK(sk.GetValue(names[i], &val)) << " key: " << names[i];
      CHECK(state[names[i]] == val)
          << "state[" << names[i] << "]: " << state[names[i]]
          << ", expected: " << val;
    } else {
      CHECK(!sk.HasValue(names[i])) << " key: " << names[i];
    }
  }
}

void PerformTimingTest() {
  io::StateKeeper sk(FLAGS_dir.c_str(),
                     FLAGS_file_base.c_str(),
                     FLAGS_block_size,
                     FLAGS_blocks_per_file);
  CHECK(sk.Initialize());

  io::StateKeepUser sku1(&sk, "gigi_marga/", 5000);
  io::StateKeepUser sku2(&sk, "vasile_ionica/", 10000);
  sku1.SetValue("key", "10");
  sku2.SetValue("key", "11");
  string value;
  CHECK(sku1.GetValue("key", &value));
  CHECK_EQ(value, "10");
  CHECK(sku2.GetValue("key", &value));
  CHECK_EQ(value, "11");

  ::sleep(6);

  CHECK(sku1.GetValue("key", &value));
  CHECK_EQ(value, "10");
  CHECK_EQ(sk.ExpireTimeoutedKeys(), 1);
  CHECK(!sku1.GetValue("key", &value));
  CHECK(sku2.GetValue("key", &value));
  CHECK_EQ(value, "11");

  ::sleep(6);

  CHECK(sku2.GetValue("key", &value));
  CHECK_EQ(value, "11");
  CHECK_EQ(sk.ExpireTimeoutedKeys(), 1);
  CHECK(!sku1.GetValue("key", &value));
  CHECK(!sku2.GetValue("key", &value));

  CHECK(sk.data().empty());
}

void ClearAllFiles() {
  vector<string> files;
  re::RE re(strutil::StringPrintf("%s_.*", FLAGS_file_base.c_str()));
  io::DirList(FLAGS_dir, io::LIST_FILES, &re, &files);
  LOG_INFO << "Clearing " << files.size() << " old files..";
  for ( uint32 i = 0; i < files.size(); i++ ) {
    io::Rm(strutil::JoinPaths(FLAGS_dir, files[i]));
  }
}

int main(int argc, char* argv[]) {
  common::Init(argc, argv);
  g_rand_seed = FLAGS_rand_seed;
  srand(FLAGS_rand_seed);

  if ( !g_name_len.Read(FLAGS_name_len) ) {
    LOG_ERROR << "Invalid interval: FLAGS_name_len: [" << FLAGS_name_len << "]";
    common::Exit(1);
  }
  if ( !g_value_len.Read(FLAGS_value_len) ) {
    LOG_ERROR << "Invalid interval: FLAGS_value_len: [" << FLAGS_value_len << "]";
    common::Exit(1);
  }

  ClearAllFiles();

  LOG_INFO << "Starting timing test ";
  LOG_WARNING << "Timing test disabled!";
  //PerformTimingTest();
  LOG_INFO << "Ended  timing test ";

  ClearAllFiles();

  map<string, string> state;
  vector<string> names;
  for ( int i = 0; i < FLAGS_num_steps; ++i ) {
    LOG_INFO << "============= STEP : " << i;
    PerformStep(state, names);
  }
  LOG_INFO << "PASS";
}


text:
define(function (require, exports, module) {

  'use strict';

  var TR = require('gui/GuiTR');
  var Remesh = require('editing/Remesh');
  var ShaderBase = require('render/shaders/ShaderBase');

  var GuiScene = function (guiParent, ctrlGui) {
    this._main = ctrlGui._main; // main application
    this._hideMeshes = [];
    this._cbToggleShowHide = this.toggleShowHide.bind(this, true);
    this.init(guiParent);
  };

  GuiScene.prototype = {
    /** Initialize */
    init: function (guiParent) {
      var menu = guiParent.addMenu(TR('sceneTitle'));

      // scene
      menu.addButton(TR('sceneReset'), this._main, 'clearScene' /*, 'CTRL+ALT+N'*/ );
      menu.addButton(TR('sceneAddSphere'), this._main, 'addSphere');
      menu.addButton(TR('sceneAddCube'), this._main, 'addCube');
      menu.addButton(TR('sceneAddCylinder'), this._main, 'addCylinder');
      menu.addButton(TR('sceneAddTorus'), this._main, 'addTorus');

      // menu.addTitle(TR('Torus'));
      // menu.addSlider(TR('Arc'), this._main._torusRadius, this.updateTorusRadius.bind(this), 0.01, Math.PI * 2, 0.001);
      // this.ctrlWI = menu.addSlider(TR('Width'), this._main._torusWidth, this.updateTorusWidth.bind(this), 0.01, 0.5, 0.01);
      // this.ctrlLE = menu.addSlider(TR('Length'), this._main._torusLength, this.updateTorusLength.bind(this), 0.2, 2.0, 0.01);
      // menu.addSlider(TR('Radial'), this._main._torusRadial, this.updateTorusRadial.bind(this), 3, 64, 1);
      // menu.addSlider(TR('Tubular'), this._main._torusTubular, this.updateTorusTubular.bind(this), 3, 256, 1);

      // this.ctrlValidate = menu.addButton(TR('Validate !'), this, 'validatePreview');
      // this.ctrlValidate.setVisibility(false);
      // this.ctrlDiscard = menu.addButton(TR('Discard !'), this, 'discardPreview');
      // this.ctrlDiscard.setVisibility(false);

      // selection stuffs
      menu.addTitle(TR('sceneSelection'));
      menu.addCheckbox(TR('contourShow'), this._main._showContour, this.onShowContour.bind(this));
      this._ctrlIsolate = menu.addCheckbox(TR('renderingIsolate'), false, this.showHide.bind(this));
      this._ctrlIsolate.setVisibility(false);
      this._ctrlMerge = menu.addButton(TR('sceneMerge'), this, 'merge');
      this._ctrlMerge.setVisibility(false);

      // extra
      menu.addTitle(TR('renderingExtra'));
      menu.addCheckbox(TR('renderingGrid'), this._main._showGrid, this.onShowGrid.bind(this));
      menu.addCheckbox(TR('renderingSymmetryLine'), ShaderBase.showSymmetryLine, this.onShowSymmetryLine.bind(this));
    },
    validatePreview: function () {
      if (!this._main._meshPreview)
        this._main.addTorus(true);

      this._main._meshPreview.setShowWireframe(false);
      this._main.addNewMesh(this._main._meshPreview);
      this._main._meshPreview = null;

      this.ctrlDiscard.setVisibility(false);
      this.ctrlValidate.setVisibility(false);
      this._main.render();
    },
    discardPreview: function () {
      this._main._meshPreview = null;
      this.ctrlDiscard.setVisibility(false);
      this.ctrlValidate.setVisibility(false);
      this._main.render();
    },
    updateTorusRadius: function (val) {
      this._main._torusRadius = val;
      this.updateTorus();
    },
    updateTorusRadial: function (val) {
      this._main._torusRadial = val;
      this.updateTorus();
    },
    updateTorusTubular: function (val) {
      this._main._torusTubular = val;
      this.updateTorus();
    },
    updateTorusWidth: function (val) {
      this._main._torusWidth = val;
      if (this._main._torusLength < this._main._torusWidth) {
        this.ctrlLE.setValue(val);
        return;
      }
      this.updateTorus();
    },
    updateTorusLength: function (val) {
      this._main._torusLength = val;
      if (this._main._torusLength < this._main._torusWidth) {
        this.ctrlWI.setValue(val);
        return;
      }
      this.updateTorus();
    },
    updateTorus: function () {
      this._main.addTorus(true);
      this.ctrlDiscard.setVisibility(true);
      this.ctrlValidate.setVisibility(true);
      this._main.render();
    },
    updateMesh: function () {
      var nbMeshes = this._main.getMeshes().length;
      var nbSelected = this._main.getSelectedMeshes().length;
      this._ctrlIsolate.setVisibility(this._hideMeshes.length > 0 || (nbMeshes !== nbSelected && nbSelected >= 1));
      this._ctrlMerge.setVisibility(nbSelected > 1);
    },
    merge: function () {
      var main = this._main;
      var selMeshes = main.getSelectedMeshes();
      if (selMeshes.length < 2) return;

      var newMesh = Remesh.mergeMeshes(selMeshes, main.getMesh() || selMeshes[0]);
      main.removeMeshes(selMeshes);
      main.getStates().pushStateAddRemove(newMesh, selMeshes.slice());
      main.getMeshes().push(newMesh);
      main.setMesh(newMesh);
    },
    toggleShowHide: function (ignoreCB) {
      this._ctrlIsolate.setValue(!this._ctrlIsolate.getValue(), !!ignoreCB);
    },
    showHide: function (bool) {
      if (bool) this.isolate();
      else this.showAll();
      this.updateMesh();
    },
    isolate: function () {
      var main = this._main;
      var selMeshes = main.getSelectedMeshes();
      var meshes = main.getMeshes();
      if (meshes.length === selMeshes.length || meshes.length < 2) {
        this._ctrlIsolate.setValue(false, true);
        return;
      }

      var hMeshes = this._hideMeshes;
      hMeshes.length = 0;
      for (var i = 0; i < meshes.length; ++i) {
        var id = main.getIndexSelectMesh(meshes[i]);
        if (id < 0) {
          hMeshes.push(meshes[i]);
          meshes.splice(i--, 1);
        }
      }

      main.getStates().pushStateRemove(hMeshes.slice());
      main.getStates().pushStateCustom(this._cbToggleShowHide, this._cbToggleShowHide, true);
      main.render();
    },
    showAll: function () {
      var main = this._main;
      var meshes = main.getMeshes();
      var hMeshes = this._hideMeshes;
      for (var i = 0, nbAdd = hMeshes.length; i < nbAdd; ++i) {
        meshes.push(hMeshes[i]);
      }
      main.getStates().pushStateAdd(hMeshes.slice());
      main.getStates().pushStateCustom(this._cbToggleShowHide, this._cbToggleShowHide, true);
      hMeshes.length = 0;
      main.render();
    },
    onShowSymmetryLine: function (val) {
      ShaderBase.showSymmetryLine = val;
      this._main.render();
    },
    onShowGrid: function (bool) {
      var main = this._main;
      main._showGrid = bool;
      main.render();
    },
    onShowContour: function (bool) {
      var main = this._main;
      main._showContour = bool;
      main.render();
    },
    ////////////////
    // KEY EVENTS
    ////////////////
    onKeyDown: function (event) {
      if (event.handled === true)
        return;

      event.stopPropagation();
      if (!this._main._focusGui)
        event.preventDefault();

      if (event.which === 73) { // I
        this.toggleShowHide();
        event.handled = true;
      }
    }
  };

  module.exports = GuiScene;
});


text:
#  `amp-animation`

    Description
    Animation component

    Availability

Experimental; no validations yet.

Work in progress.

    Required Script
    <script async custom-element="amp-animation" src="https://cdn.ampproject.org/v0/amp-animation-0.1.js"></script>

    Supported Layouts
    nodisplay

## Overview

AMP Animations rely on [Web Animations API](https://www.w3.org/TR/web-animations/) to define and run animations in AMP documents.

## Format

An `amp-animation` element defines such an animation as a JSON structure.

### Top-level animation specification

The top-level object defines an overall animation process which consists of an arbitrary number of animation components
defined as an `animations` array:
```html
<amp-animation layout="nodisplay">
<script type="application/json">
{
  // Timing properties
  ...
  "animations": [
    {
      // Animation 1
    },
    ...
    {
      // Animation N
    }
  ]
}
</script>
</amp-animation>
```

### Placement in DOM

Initially, `<amp-animation>` is only allowed to be placed as a direct child of `<body>` element. This restriction
will be removed in the near future.

### Animation component

Each animation component is a [keyframes effect](https://www.w3.org/TR/web-animations/#dom-keyframeeffect-keyframeeffect)
and is comprised of:
 - Target element(s) referenced by a selector
 - Conditions, such as media query
 - Timing properties
 - Keyframes

```text
{
  "selector": "#target-id",
  "media": "(min-width:300px)",
  // Variables
  // Timing properties
  // Subtargets
  ...
  "keyframes": []
}
```

### Conditions

Conditions can specify whether this animation component is included in the final animation. Currently, only `media` expression is supported.

#### Media query

Media query can be specified using the `media` property. This attribute can contain any expression allowed
for [Window.matchMedia](https://developer.mozilla.org/en-US/docs/Web/API/Window/matchMedia) API.

If value is specified for an animation component, the animation component will only be included if the
media query will match the current environment.

### Variables

An animation component can declare CSS variables that will be used for timing and keyframes values via `var()` expressions. `var()` expressions are evaluated using the current target context. The CSS variables specified in animation components are propagated to nested animations, applied to animation targets and thus override CSS variables used in final animations.

For instance:
```html
<amp-animation layout="nodisplay">
<script type="application/json">
{
  "--delay": "0.5s",
  "--x": "100px",
  "animations": [
    {
      "selector": "#target1",
      "delay": "var(--delay)",
      "--x": "150px",
      "keyframes": {"transform": "translate(var(--x), var(--y, 0px)"}
    },
    ...
  ]
}
</script>
</amp-animation>
```

In this sample:
 - `--delay` is propagated into nested animations and used as a delay of `#target1` animation.
 - `--x` is propagated into nested animations but overriden by the `#target1` animation and later used for `transform` property.
 - `--y` is not specified anywhere in the `<amp-animation>` and thus will be queried on the `#target1` element. It defaults to `0px` if not defined in CSS either.

For more information on `var()`, see the [`var()` and `calc()` section](#var-and-calc-expressions).

### Timing properties

Top-level animation and animation components may contain timing properties. These properties are defined in detail in the
[AnimationEffectTimingProperties](https://www.w3.org/TR/web-animations/#dictdef-animationeffecttimingproperties) of the Web Animation spec. The set of properties allowed here includes:

    Property
    Type
    Default
    Description

    duration
    time
    0
    The animation duration. Either a numeric value in milliseconds or a CSS time value, e.g. `2s`.

    delay
    time
    0
    The delay before animation starts executing. Either a numeric value in milliseconds or a CSS time value, e.g. `2s`.

    endDelay
    time
    0
    The delay after the animation completes and before it's actually considered to be complete. Either a numeric value in milliseconds or a CSS time value, e.g. `2s`.

    iterations
    number or
"Infinity" or
"infinite"
    1
    The number of times the animation effect repeats.

    iterationStart
    number/CSS
    0
    The time offset at which the effect begins animating.

    easing
    string
    "linear"
    The timing function used to scale the time to produce easing effects.

    direction
    string
    "normal"
    One of "normal", "reverse", "alternate" or "alternate-reverse".

    fill
    string
    "none"
    One of "none", "forwards", "backwards", "both", "auto".

All timing properties allow either a direct numeric/string values or CSS values. For instance, "duration" can be specified as `1000` or `1s` or `1000ms`. In addition, `calc()` and `var()` and other CSS expressions are also allowed.

An example of timing properties in JSON:
```text
{
  ...
  "duration": "1s",
  "delay": 100,
  "endDelay": "var(--end-delay, 10ms)",
  "easing": "ease-in",
  "fill": "both"
  ...
}
```

Animation components inherit timing properties specified for the top-level animation.

### Subtargets

Everywhere where `selector` can be specified, it's possible to also specify `subtargets: []`. Subtargets can override timing properties or variables defined in the animation for specific subtargets indicated via either an index or a CSS selector.

For instance:
```text
{
  "selector": ".target",
  "delay": 100,
  "--y": "100px",
  "subtargets": [
    {
      "index": 0,
      "delay": 200,
    },
    {
      "selector": ":nth-child(2n+1)",
      "--y": "200px"
    }
  ]
}
```

In this example, by default all targets matched by the ".target" have delay of 100ms and "--y" of 100px. However, the first target (`index: 0`) is overriden to have delay of 200ms; and odd targets are overriden to have "--y" of 200px.

Notice, that multiple subtargets can match one target element.

### Keyframes

Keyframes can be specified in numerous ways described in the [keyframes section](https://www.w3.org/TR/web-animations/#processing-a-keyframes-argument) of the Web Animations spec or as a string refering to the `@keyframes` name in the CSS.

Some typical examples of keyframes definitions are below.

Shorthand object-form "to" format specifies the final state at 100%:
```text
{
  "keyframes": {"opacity": 0, "transform": "scale(2)"}
}
```

Shorthand object-form "from-to" format specifies the starting and final states at 0 and 100%:
```text
{
  "keyframes": {
    "opacity": [1, 0],
    "transform": ["scale(1)", "scale(2)"]
  }
}
```

Shorthand object-form "value-array" format specifies multiple values for starting, final states and multiple (equal-spaced) offsets:
```text
{
  "keyframes": {
    "opacity": [1, 0.1, 0],
    "transform": ["scale(1)", "scale(1.1)", "scale(2)"]
  }
}
```

The array-form specifies keyframes. Offsets are assigned automatically at 0, 100% and spaced evenly in-between:
```text
{
  "keyframes": [
    {"opacity": 1, "transform": "scale(1)"},
    {"opacity": 0, "transform": "scale(2)"}
  ]
}
```

The array-form can also include "offset" explicitly:
```text
{
  "keyframes": [
    {"opacity": 1, "transform": "scale(1)"},
    {"offset": 0.1, "opacity": 0.1, "transform": "scale(2)"},
    {"opacity": 0, "transform": "scale(3)"}
  ]
}
```

The array-form can also include "easing":
```text
{
  "keyframes": [
    {"easing": "ease-out", "opacity": 1, "transform": "scale(1)"},
    {"opacity": 0, "transform": "scale(2)"}
  ]
}
```

For additional keyframes formats refer to [Web Animations spec](https://www.w3.org/TR/web-animations/#processing-a-keyframes-argument).

The property values allow any valid CSS values, including `calc()`, `var()` and other CSS expressions.

#### Keyframes from CSS

Another way to specify keyframes is in the document's stylesheet (`<style>` tag) as `@keyframes` CSS rule. For instance:
```html
<style amp-custom>
  @keyframes keyframes1 {
    from {
      opacity: 0;
    }
    to {
      opacity: 1;
    }
  }
</style>

<amp-animation layout="nodisplay">
<script type="application/json">
{
  "duration": "1s",
  "keyframes": "keyframes1"
}
</script>
</amp-animation>
```

CSS `@keyframes` are mostly equivalent to inlining keyframes definition in the JSON per [Web Animations spec](https://www.w3.org/TR/web-animations/#processing-a-keyframes-argument). However, there are some nuances:
 - For broad-platform support, vendor prefixes, e.g. `@-ms-keyframes {}` or `-moz-transform` may be needed. Vendor prefixes are not needed and not allowed in the JSON format, but in CSS they could be necessary.
 - Platforms that do not support `calc()` and `var()` will not be able to take advantage of `amp-animation` polyfills when keyframes are specified in CSS. It's thus recommended to always include fallback values in CSS.
 - CSS extensions such as [`width()`, `height()` and `rand()`](#css-extensions) cannot be used in CSS.

#### Whitelisted properties for keyframes

Not all CSS properties can be used in keyframes. Only CSS properties that modern browsers can optimize and
animate quickly are whitelisted. This list will grow as more properties are confirmed to provide good
performance. Currently the list contains:
 - `opacity`
 - `transform`
 - `visibility`

Notice that the use of vendor prefixed CSS properties is neither needed nor allowed.

### Abbreviated forms of animation configuration

If the animation only involves a single element and a single keyframes effect is sufficient, the configuration
can be reduced to this one animation component only. For instance:
```html
<amp-animation layout="nodisplay">
<script type="application/json">
{
  "selector": "#target-id",
  "duration": "1s",
  "keyframes": {"opacity": 1}
}
</script>
</amp-animation>
```

If the animation is comprised of a list of components, but doesn't have top-level animation, the configuration
can be reduced to an array of components. For instance:
```html
<amp-animation layout="nodisplay">
<script type="application/json">
[
  {
    "selector": ".target-class",
    "duration": 1000,
    "keyframes": {"opacity": 1}
  },
  {
    "selector": ".target-class",
    "duration": 600,
    "delay": 400,
    "keyframes": {"transform": "scale(2)"}
  }
]
</script>
</amp-animation>
```

### Animation composition

Animations can reference other animations thus combining several `amp-animation` declarations into a single final animation. Referencing an animation from another animation is mostly the same as nesting. The reason why one would want to split animations into different elements would be to reuse the same animation from several places or to simply make each animation declaration smaller and more manageable.

For instance:
```html
<amp-animation id="anim1" layout="nodisplay">
<script type="application/json">
{
  "animation": "anim2",
  "duration": 1000,
  "--scale": 2
}
</script>
</amp-animation>

<amp-animation id="anim2" layout="nodisplay">
<script type="application/json">
{
  "selector": ".target-class",
  "keyframes": {"transform": "scale(var(--scale))"}
}
</script>
</amp-animation>
```

This sample animation, will combine "anim2" animation as part of "anim1". The "anim2" is included
without a target (`selector`). In such case, the included animation is expected to reference its own target.

Another form allows the including animation to provide the target or multiple targets. In that case, the included
animation is executed for each matched target. For instance:
```html
<amp-animation id="anim1" layout="nodisplay">
<script type="application/json">
{
  "selector": ".target-class",
  "animation": "anim2",
  "duration": 1000,
  "--scale": 2
}
</script>
</amp-animation>

<amp-animation id="anim2" layout="nodisplay">
<script type="application/json">
{
  "keyframes": {"transform": "scale(var(--scale))"}
}
</script>
</amp-animation>
```

Here, whether the ".target-class" matches one element, several or none - the "anim2" is executed for each matched target.

The variables and timing properties specified in the caller animation are passed to the included animation as well.

### `var()` and `calc()` expressions

`amp-animation` allows use of `var()` and `calc()` expressions for timing and keyframes values.

For instance:
```html
<amp-animation layout="nodisplay">
<script type="application/json">
[
  {
    "selector": ".target-class",
    "duration": "4s",
    "delay": "var(--delay)",
    "--y": "var(--other-y, 100px)",
    "keyframes": {"transform": "translate(calc(100vh + 20px), var(--y))"}
  }
]
</script>
</amp-animation>
```

Both `var()` and `calc()` polyfilled on platforms that do not directly support them. `var()` properties are extracted from the corresponding target elements. However, it's unfortunately impossible to fully polyfill `var()`. Thus, where compatibility is important, it's strongly recommended to include default values in the `var()` expressions. For instance:
```html
<amp-animation layout="nodisplay">
<script type="application/json">
[
  {
    "selector": ".target-class",
    "duration": "4s",
    "delay": "var(--delay, 100ms)",
  }
]
</script>
</amp-animation>
```

Animation components can specify their own variables as `--var-name` fields. These variables are propagated into nested animations and override variables of target elements specified via stylesheet (`<style>` tag). `var()` expressions first try to resolve variable values specified in the animations and then by querying target styles.

### CSS extensions

`amp-animation` provides several CSS extensions for typical animations needs: `rand()`, `width()`, and `height()`. These functions can be used everywhere where CSS values can be used within `amp-animation`, including timing and keyframes values.

#### CSS `rand()` extension

The `rand()` function returns a random CSS value. There are two forms.

The form without arguments simply returns the random number between 0 and 1.
```
{
  "animation-delay": "calc(10s * rand())"
}
```

The second form has two arguments and returns the random value between these two arguments.
```
{
  "animation-delay": "rand(5s, 10s)"
}
```

#### CSS `width()` and `height()` extensions

The `width()` and `height()` extensions return the width/height of the animated element or the element specified by the selector. The returned value is in pixels, e.g. `100px`.

The following forms are supported:
 - `width()` and `height()` - width/height of the animated element.
 - `width('.selector')` and `height('.selector')` - width/height of the element specified by the selector. Any CSS selector can be used. For instance, `width('#container > li')`.
 - `width(closest('.selector'))` and `height(closest('.selector'))` - width/height of the element specified by the closest selector.

The `width()` and `height()` are epsecially useful for transforms. The `left`, `top` and similar CSS properties that can use `%` values to express animations proportional to container size. However, `transform` property interpretes `%` values differently - as a percent of the selected element. Thus, the `width()` and `height()` can be used to express transform animations in terms of container elements and similar.

These functions can be combined with `calc()`, `var()` and other CSS expressions. For instance:
```
{
  "transform": "translateX(calc(width('#container') + 10px))"
}
```

## Triggering animation

The animation can be triggered via a `trigger` attribute or an `on` action.

### `trigger` attribute

Currently, `visibility` is the only available value for the `trigger` attribute. The `visibility` triggers when the underlying document or embed are visible (in viewport).

For instance:
```html
<amp-animation id="anim1" layout="nodisplay"
    trigger="visibility">
  ...
</amp-animation>
```

### Triggering via `on` action

For instance:

```html
<amp-animation id="anim1" layout="nodisplay">
  ...
</amp-animation>
<button on="tap:anim1.start">Animate</button>
```

## `on` actions

`amp-animation` element exports the following actions:

- `start` - Starts the animation is it's not running already. Timing properties and variables
  can be specified as action arguments. E.g. `anim1.start(delay=-100, --scale=2)`.
- `restart` - Starts the animation or restarts the currently running one. Timing properties and variables
  can be specified as action arguments. E.g. `anim1.start(delay=-100, --scale=2)`.
- `pause` - Pauses the currently running animation.
- `resume` - Resumes the currently running animation.
- `togglePause` - Toggles pause/resume actions.
- `seekTo` - Pauses the animation and seeks to the point of time specified by the `time` argument in milliseconds.
- `reverse` - Reverses the animation.
- `finish` - Finishes the animation.
- `cancel` - Cancels the animation.


text:
<?php

namespace Extension\core\modes;

/**
 * Description of Page
 *
 * @author De Cramer Oliver
 */
class CtrAction extends \OWeb\types\extension implements ModeInterface{

	public function init(){

	}

    public function initMode()
    {
        //On va charger le controleur.
        $man_ctr = \OWeb\manage\Controller::getInstance();

        //On va voir quel page on doit charger
        $get = \OWeb\OWeb::getInstance()->get_get();

        if (isset($get['page'])) {
            $ctr = $get['page'];
        } else {
            $ctr = OWEB_DEFAULT_PAGE;
        }

        try {

            $ctr = str_replace("\\\\", "\\", $ctr);
            $ctr = str_replace(".", "\\", $ctr);

            $ctr = $man_ctr->loadController('Page\\' . $ctr);
            $ctr->loadParams();
        } catch (\Exception $ex) {
            $ctr = $man_ctr->loadController('Page\OWeb\errors\http\NotFound');
            $ctr->loadParams();
        }
    }

    public function display()
    {
        //No display
    }
}

?>


text:
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**email** | **string** | Email address of the recipient |
**name** | **string** | Name of the recipient. **Maximum allowed characters are 70**. | [optional]

[[Back to Model list]](../../README.md#documentation-for-models) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to README]](../../README.md)


text:
from logging import getLogger

from ._uniref import _prepare

def prepare_db(downloaded, out_d='uniref',
               uniref_url='ftp://ftp.uniprot.org/pub/databases/uniprot/uniref/uniref100/uniref100.fasta.gz',
               force=False):
    logger = getLogger(__name__)
    logger.info('Preparing UniRef100 database')

    _prepare(downloaded, out_d, uniref_url, 100, force)


text:
import api from '../api/all'
import conversation from './conversation'

const state = {
    conversations: [],
    loadingConversations: false
}

const getters = {
    allConversations: state => {
        return state.conversations
    },
    loadingConversations: state => {
        return state.loadingConversations
    }
}

const actions = {
    getConversations ({dispatch, commit}, page) {
        commit('setConversationsLoading', true)

        api.getConversations(1).then((response) => {
            commit('setConversations', response.data.data)
            commit('setConversationsLoading', false)

            Echo.private('user.' + Laravel.user.id)
                .listen('ConversationCreated', (e) => {
                    commit('prependToConversations', e.data)
                })
                .listen('ConversationReplyCreated', (e) => {
                    commit('prependToConversations', e.data.parent.data)
                })
                .listen('ConversationUsersCreated', (e) => {
                    commit('updateConversationInList', e.data)
                })
        })
    }
}

const mutations = {
    setConversations (state, conversations) {
        state.conversations = conversations
    },
    setConversationsLoading (state, status) {
        state.loadingConversations = status
    },
    prependToConversations (state, conversation) {
        state.conversations = state.conversations.filter((c) => {
            return c.id !== conversation.id
        })

        state.conversations.unshift(conversation)
    },
    updateConversationInList (state, conversation) {
        state.conversations = state.conversations.map((c) => {
            if (c.id == conversation.id) {
                return conversation
            }

            return c
        })
    }
}

const modules = {
    conversation: conversation
}

export default {
    state,
    getters,
    mutations,
    actions,
    modules
}


text:
from pylab import *
from matplotlib.collections import LineCollection

# In order to efficiently plot many lines in a single set of axes,
# Matplotlib has the ability to add the lines all at once. Here is a
# simple example showing how it is done.

N = 50
x = arange(N)
# Here are many sets of y to plot vs x
ys = [x+i for i in x]

# We need to set the plot limits, they will not autoscale
ax = axes()
ax.set_xlim((amin(x),amax(x)))
ax.set_ylim((amin(amin(ys)),amax(amax(ys))))

# colors is sequence of rgba tuples
# linestyle is a string or dash tuple. Legal string values are
#          solid|dashed|dashdot|dotted.  The dash tuple is (offset, onoffseq)
#          where onoffseq is an even length tuple of on and off ink in points.
#          If linestyle is omitted, 'solid' is used
# See matplotlib.collections.LineCollection for more information
line_segments = LineCollection([list(zip(x,y)) for y in ys], # Make a sequence of x,y pairs
                                linewidths    = (0.5,1,1.5,2),
                                linestyles = 'solid')
line_segments.set_array(x)
ax.add_collection(line_segments)
fig = gcf()
axcb = fig.colorbar(line_segments)
axcb.set_label('Line Number')
ax.set_title('Line Collection with mapped colors')
sci(line_segments) # This allows interactive changing of the colormap.
show()