text:
package org.pentaho.di.trans.steps.replacestring;

import java.util.List;

import org.apache.commons.lang.StringUtils;
import org.pentaho.di.core.CheckResult;
import org.pentaho.di.core.CheckResultInterface;
import org.pentaho.di.core.Const;
import org.pentaho.di.core.injection.AfterInjection;
import org.pentaho.di.core.util.Utils;
import org.pentaho.di.core.database.DatabaseMeta;
import org.pentaho.di.core.exception.KettleException;
import org.pentaho.di.core.exception.KettleStepException;
import org.pentaho.di.core.exception.KettleXMLException;
import org.pentaho.di.core.injection.Injection;
import org.pentaho.di.core.injection.InjectionSupported;
import org.pentaho.di.core.row.RowMetaInterface;
import org.pentaho.di.core.row.ValueMetaInterface;
import org.pentaho.di.core.row.value.ValueMetaString;
import org.pentaho.di.core.variables.VariableSpace;
import org.pentaho.di.core.xml.XMLHandler;
import org.pentaho.di.i18n.BaseMessages;
import org.pentaho.di.repository.ObjectId;
import org.pentaho.di.repository.Repository;
import org.pentaho.di.shared.SharedObjectInterface;
import org.pentaho.di.trans.Trans;
import org.pentaho.di.trans.TransMeta;
import org.pentaho.di.trans.step.BaseStepMeta;
import org.pentaho.di.trans.step.StepDataInterface;
import org.pentaho.di.trans.step.StepInterface;
import org.pentaho.di.trans.step.StepMeta;
import org.pentaho.di.trans.step.StepMetaInterface;
import org.pentaho.metastore.api.IMetaStore;
import org.w3c.dom.Node;

@InjectionSupported( localizationPrefix = "ReplaceString.Injection.", groups = { "FIELDS" } )
public class ReplaceStringMeta extends BaseStepMeta implements StepMetaInterface {

  private static Class<?> PKG = ReplaceStringMeta.class; // for i18n purposes, needed by Translator2!!

  @Injection( name = "FIELD_IN_STREAM", group = "FIELDS" )
  private String[] fieldInStream;

  @Injection( name = "FIELD_OUT_STREAM", group = "FIELDS" )
  private String[] fieldOutStream;

  @Injection( name = "USE_REGEX", group = "FIELDS" )
  private boolean[] useRegEx;

  @Injection( name = "REPLACE_STRING", group = "FIELDS" )
  private String[] replaceString;

  @Injection( name = "REPLACE_BY", group = "FIELDS" )
  private String[] replaceByString;

  /** Flag : set empty string **/
  @Injection( name = "EMPTY_STRING", group = "FIELDS" )
  private boolean[] setEmptyString;

  @Injection( name = "REPLACE_WITH_FIELD", group = "FIELDS" )
  private String[] replaceFieldByString;

  @Injection( name = "REPLACE_WHOLE_WORD", group = "FIELDS" )
  private boolean[] wholeWord;

  @Injection( name = "CASE_SENSITIVE", group = "FIELDS" )
  private boolean[] caseSensitive;

  @Injection( name = "IS_UNICODE", group = "FIELDS" )
  private boolean[] isUnicode;

  public static final String[] flagDescriptor = new String[] {
    BaseMessages.getString( PKG, "System.Combo.No" ), BaseMessages.getString( PKG, "System.Combo.Yes" ) };

  public ReplaceStringMeta() {
    super(); // allocate BaseStepMeta
  }

  /**
   * @return Returns the fieldInStream.
   */
  public String[] getFieldInStream() {
    return fieldInStream;
  }

  /**
   * @param keyStream
   *          The fieldInStream to set.
   */
  public void setFieldInStream( String[] keyStream ) {
    this.fieldInStream = keyStream;
  }

  public boolean[] getCaseSensitive() {
    return caseSensitive;
  }

  public boolean[] isUnicode() {
    return isUnicode;
  }

  public boolean[] getWholeWord() {
    return wholeWord;
  }

  public void setWholeWord( boolean[] wholeWord ) {
    this.wholeWord = wholeWord;
  }

  public boolean[] getUseRegEx() {
    return useRegEx;
  }

  public void setUseRegEx( boolean[] useRegEx ) {
    this.useRegEx = useRegEx;
  }

  /**
   * @return the setEmptyString
   */
  public boolean[] isSetEmptyString() {
    return setEmptyString;
  }

  /**
   * @param setEmptyString
   *          the setEmptyString to set
   */
  public void setEmptyString( boolean[] setEmptyString ) {
    this.setEmptyString = setEmptyString;
  }

  /**
   * @return Returns the fieldOutStream.
   */
  public String[] getFieldOutStream() {
    return fieldOutStream;
  }

  /**
   * @param keyStream
   *          The fieldOutStream to set.
   */
  public void setFieldOutStream( String[] keyStream ) {
    this.fieldOutStream = keyStream;
  }

  public String[] getReplaceString() {
    return replaceString;
  }

  public void setReplaceString( String[] replaceString ) {
    this.replaceString = replaceString;
  }

  public String[] getReplaceByString() {
    return replaceByString;
  }

  public void setReplaceByString( String[] replaceByString ) {
    this.replaceByString = replaceByString;
  }

  public String[] getFieldReplaceByString() {
    return replaceFieldByString;
  }

  public void setFieldReplaceByString( String[] replaceFieldByString ) {
    this.replaceFieldByString = replaceFieldByString;
  }

  public void setCaseSensitive( boolean[] caseSensitive ) {
    this.caseSensitive = caseSensitive;
  }

  public void setIsUnicode( boolean[] isUnicode ) {
    this.isUnicode = isUnicode;
  }

  public void loadXML( Node stepnode, List<DatabaseMeta> databases, IMetaStore metaStore ) throws KettleXMLException {
    readData( stepnode, databases );
  }

  public void allocate( int nrkeys ) {
    fieldInStream = new String[nrkeys];
    fieldOutStream = new String[nrkeys];
    useRegEx = new boolean[nrkeys];
    replaceString = new String[nrkeys];
    replaceByString = new String[nrkeys];
    setEmptyString = new boolean[nrkeys];
    replaceFieldByString = new String[nrkeys];
    wholeWord = new boolean[nrkeys];
    caseSensitive = new boolean[nrkeys];
    isUnicode = new boolean[nrkeys];
  }

  public Object clone() {
    ReplaceStringMeta retval = (ReplaceStringMeta) super.clone();
    int nrkeys = fieldInStream.length;

    retval.allocate( nrkeys );

    System.arraycopy( fieldInStream, 0, retval.fieldInStream, 0, nrkeys );
    System.arraycopy( fieldOutStream, 0, retval.fieldOutStream, 0, nrkeys );
    System.arraycopy( useRegEx, 0, retval.useRegEx, 0, nrkeys );
    System.arraycopy( replaceString, 0, retval.replaceString, 0, nrkeys );
    System.arraycopy( replaceByString, 0, retval.replaceByString, 0, nrkeys );
    System.arraycopy( setEmptyString, 0, retval.setEmptyString, 0, nrkeys );
    System.arraycopy( replaceFieldByString, 0, retval.replaceFieldByString, 0, nrkeys );
    System.arraycopy( wholeWord, 0, retval.wholeWord, 0, nrkeys );
    System.arraycopy( caseSensitive, 0, retval.caseSensitive, 0, nrkeys );
    System.arraycopy( isUnicode, 0, retval.isUnicode, 0, nrkeys );
    return retval;
  }

  private void readData( Node stepnode, List<? extends SharedObjectInterface> databases ) throws KettleXMLException {
    try {
      int nrkeys;

      Node lookup = XMLHandler.getSubNode( stepnode, "fields" );
      nrkeys = XMLHandler.countNodes( lookup, "field" );

      allocate( nrkeys );

      for ( int i = 0; i < nrkeys; i++ ) {
        Node fnode = XMLHandler.getSubNodeByNr( lookup, "field", i );

        fieldInStream[i] = Const.NVL( XMLHandler.getTagValue( fnode, "in_stream_name" ), "" );
        fieldOutStream[i] = Const.NVL( XMLHandler.getTagValue( fnode, "out_stream_name" ), "" );
        useRegEx[i] = getFlagFromString( Const.NVL( XMLHandler.getTagValue( fnode, "use_regex" ), "" ) );
        replaceString[i] = Const.NVL( XMLHandler.getTagValue( fnode, "replace_string" ), "" );
        replaceByString[i] = Const.NVL( XMLHandler.getTagValue( fnode, "replace_by_string" ), "" );
        String emptyString = XMLHandler.getTagValue( fnode, "set_empty_string" );

        setEmptyString[i] = !Utils.isEmpty( emptyString ) && "Y".equalsIgnoreCase( emptyString );
        replaceFieldByString[i] = Const.NVL( XMLHandler.getTagValue( fnode, "replace_field_by_string" ), "" );
        wholeWord[i] = getFlagFromString( Const.NVL( XMLHandler.getTagValue( fnode, "whole_word" ), "" ) );
        caseSensitive[i] =
          getFlagFromString( Const.NVL( XMLHandler.getTagValue( fnode, "case_sensitive" ), "" ) );
        isUnicode[i] =
          getFlagFromString( Const.NVL( XMLHandler.getTagValue( fnode, "is_unicode" ), "" ) );

      }
    } catch ( Exception e ) {
      throw new KettleXMLException( BaseMessages.getString(
        PKG, "ReplaceStringMeta.Exception.UnableToReadStepInfoFromXML" ), e );
    }
  }

  private static boolean getFlagFromString( String tt ) {
    return ( "Y".equalsIgnoreCase( tt ) || "yes".equalsIgnoreCase( tt )  || "true".equalsIgnoreCase( tt ) );
  }

  public void setDefault() {
    fieldInStream = null;
    fieldOutStream = null;
    int nrkeys = 0;

    allocate( nrkeys );
  }

  public String getXML() {
    StringBuilder retval = new StringBuilder( 500 );

    retval.append( "    <fields>" ).append( Const.CR );

    for ( int i = 0; i < fieldInStream.length; i++ ) {
      retval.append( "      <field>" ).append( Const.CR );
      retval.append( "        " ).append( XMLHandler.addTagValue( "in_stream_name", fieldInStream[i] ) );
      retval.append( "        " ).append( XMLHandler.addTagValue( "out_stream_name", fieldOutStream[i] ) );
      retval.append( "        " ).append( XMLHandler.addTagValue( "use_regex", getFlagTagValue( useRegEx[i] ) ) );
      retval.append( "        " ).append( XMLHandler.addTagValue( "replace_string", replaceString[i] ) );
      retval.append( "        " ).append( XMLHandler.addTagValue( "replace_by_string", replaceByString[i] ) );
      retval.append( "        " ).append( XMLHandler.addTagValue( "set_empty_string", setEmptyString[i] ) );
      retval.append( "        " ).append(
        XMLHandler.addTagValue( "replace_field_by_string", replaceFieldByString[i] ) );
      retval.append( "        " ).append( XMLHandler.addTagValue( "whole_word", getFlagTagValue( wholeWord[i] ) ) );
      retval.append( "        " )
        .append( XMLHandler.addTagValue( "case_sensitive", getFlagTagValue( caseSensitive[i] ) ) );
      retval.append( "        " ).append(
        XMLHandler.addTagValue( "is_unicode", getFlagTagValue( isUnicode[i] ) ) );
      retval.append( "      </field>" ).append( Const.CR );
    }

    retval.append( "    </fields>" ).append( Const.CR );

    return retval.toString();
  }

  /** BACKLOG-27839 Outputs Flags that were previously int as "yes" or "no" for Backwards Compatibility in XML. **/
  private static String getFlagTagValue( boolean flag ) {
    return ( flag ? "yes" : "no" );
  }

  public void readRep( Repository rep, IMetaStore metaStore, ObjectId id_step, List<DatabaseMeta> databases ) throws KettleException {
    try {
      int nrkeys = rep.countNrStepAttributes( id_step, "in_stream_name" );

      allocate( nrkeys );
      for ( int i = 0; i < nrkeys; i++ ) {
        fieldInStream[i] = Const.NVL( rep.getStepAttributeString( id_step, i, "in_stream_name" ), "" );
        fieldOutStream[i] = Const.NVL( rep.getStepAttributeString( id_step, i, "out_stream_name" ), "" );
        useRegEx[i] =
          getFlagFromString( Const.NVL( rep.getStepAttributeString( id_step, i, "use_regex" ), "" ) );
        replaceString[i] = Const.NVL( rep.getStepAttributeString( id_step, i, "replace_string" ), "" );
        replaceByString[i] = Const.NVL( rep.getStepAttributeString( id_step, i, "replace_by_string" ), "" );
        setEmptyString[i] = rep.getStepAttributeBoolean( id_step, i, "set_empty_string", false );
        replaceFieldByString[i] =
          Const.NVL( rep.getStepAttributeString( id_step, i, "replace_field_by_string" ), "" );
        wholeWord[i] =
          getFlagFromString( Const.NVL( rep.getStepAttributeString( id_step, i, "whole_world" ), "" ) );
        caseSensitive[i] =
          getFlagFromString( Const.NVL( rep.getStepAttributeString( id_step, i, "case_sensitive" ), "" ) );
        isUnicode[i] =
          getFlagFromString( Const.NVL( rep.getStepAttributeString( id_step, i, "is_unicode" ), "" ) );

      }
    } catch ( Exception e ) {
      throw new KettleException( BaseMessages.getString(
        PKG, "ReplaceStringMeta.Exception.UnexpectedErrorInReadingStepInfo" ), e );
    }
  }

  public void saveRep( Repository rep, IMetaStore metaStore, ObjectId id_transformation, ObjectId id_step ) throws KettleException {
    try {
      for ( int i = 0; i < fieldInStream.length; i++ ) {
        rep.saveStepAttribute( id_transformation, id_step, i, "in_stream_name", fieldInStream[i] );
        rep.saveStepAttribute( id_transformation, id_step, i, "out_stream_name", fieldOutStream[i] );
        rep.saveStepAttribute( id_transformation, id_step, i, "use_regex", useRegEx[i] );
        rep.saveStepAttribute( id_transformation, id_step, i, "replace_string", replaceString[i] );
        rep.saveStepAttribute( id_transformation, id_step, i, "replace_by_string", replaceByString[i] );
        rep.saveStepAttribute( id_transformation, id_step, i, "set_empty_string", setEmptyString[i] );
        rep.saveStepAttribute( id_transformation, id_step, i, "replace_field_by_string", replaceFieldByString[i] );
        rep.saveStepAttribute( id_transformation, id_step, i, "whole_world", wholeWord[i] );
        rep.saveStepAttribute( id_transformation, id_step, i, "case_sensitive", caseSensitive[i] );
        rep.saveStepAttribute( id_transformation, id_step, i, "is_unicode", isUnicode[i] );

      }
    } catch ( Exception e ) {
      throw new KettleException( BaseMessages.getString( PKG, "ReplaceStringMeta.Exception.UnableToSaveStepInfo" )
        + id_step, e );
    }
  }

  public void getFields( RowMetaInterface inputRowMeta, String name, RowMetaInterface[] info, StepMeta nextStep,
    VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException {
    int nrFields = fieldInStream == null ? 0 : fieldInStream.length;
    for ( int i = 0; i < nrFields; i++ ) {
      String fieldName = space.environmentSubstitute( fieldOutStream[i] );
      ValueMetaInterface valueMeta;
      if ( !Utils.isEmpty( fieldOutStream[i] ) ) {
        // We have a new field
        valueMeta = new ValueMetaString( fieldName );
        valueMeta.setOrigin( name );
        //set encoding to new field from source field http://jira.pentaho.com/browse/PDI-11839
        ValueMetaInterface sourceField = inputRowMeta.searchValueMeta( fieldInStream[i] );
        if ( sourceField != null ) {
          valueMeta.setStringEncoding( sourceField.getStringEncoding() );
        }
        inputRowMeta.addValueMeta( valueMeta );
      } else {
        valueMeta = inputRowMeta.searchValueMeta( fieldInStream[i] );
        if ( valueMeta == null ) {
          continue;
        }
        valueMeta.setStorageType( ValueMetaInterface.STORAGE_TYPE_NORMAL );
      }
    }
  }

  public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepinfo,
    RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space,
    Repository repository, IMetaStore metaStore ) {

    CheckResult cr;
    String error_message = "";
    boolean first = true;
    boolean error_found = false;

    if ( prev == null ) {
      error_message += BaseMessages.getString( PKG, "ReplaceStringMeta.CheckResult.NoInputReceived" ) + Const.CR;
      cr = new CheckResult( CheckResult.TYPE_RESULT_ERROR, error_message, stepinfo );
      remarks.add( cr );
    } else {

      for ( int i = 0; i < fieldInStream.length; i++ ) {
        String field = fieldInStream[i];

        ValueMetaInterface v = prev.searchValueMeta( field );
        if ( v == null ) {
          if ( first ) {
            first = false;
            error_message +=
              BaseMessages.getString( PKG, "ReplaceStringMeta.CheckResult.MissingInStreamFields" ) + Const.CR;
          }
          error_found = true;
          error_message += "\t\t" + field + Const.CR;
        }
      }
      if ( error_found ) {
        cr = new CheckResult( CheckResult.TYPE_RESULT_ERROR, error_message, stepinfo );
      } else {
        cr =
          new CheckResult( CheckResult.TYPE_RESULT_OK, BaseMessages.getString(
            PKG, "ReplaceStringMeta.CheckResult.FoundInStreamFields" ), stepinfo );
      }
      remarks.add( cr );

      // Check whether all are strings
      first = true;
      error_found = false;
      for ( int i = 0; i < fieldInStream.length; i++ ) {
        String field = fieldInStream[i];

        ValueMetaInterface v = prev.searchValueMeta( field );
        if ( v != null ) {
          if ( v.getType() != ValueMetaInterface.TYPE_STRING ) {
            if ( first ) {
              first = false;
              error_message +=
                BaseMessages.getString( PKG, "ReplaceStringMeta.CheckResult.OperationOnNonStringFields" )
                  + Const.CR;
            }
            error_found = true;
            error_message += "\t\t" + field + Const.CR;
          }
        }
      }
      if ( error_found ) {
        cr = new CheckResult( CheckResult.TYPE_RESULT_ERROR, error_message, stepinfo );
      } else {
        cr =
          new CheckResult( CheckResult.TYPE_RESULT_OK, BaseMessages.getString(
            PKG, "ReplaceStringMeta.CheckResult.AllOperationsOnStringFields" ), stepinfo );
      }
      remarks.add( cr );

      if ( fieldInStream.length > 0 ) {
        for ( int idx = 0; idx < fieldInStream.length; idx++ ) {
          if ( Utils.isEmpty( fieldInStream[idx] ) ) {
            cr =
              new CheckResult(
                CheckResult.TYPE_RESULT_ERROR, BaseMessages.getString(
                  PKG, "ReplaceStringMeta.CheckResult.InStreamFieldMissing", new Integer( idx + 1 )
                    .toString() ), stepinfo );
            remarks.add( cr );

          }
        }
      }

      // Check if all input fields are distinct.
      for ( int idx = 0; idx < fieldInStream.length; idx++ ) {
        for ( int jdx = 0; jdx < fieldInStream.length; jdx++ ) {
          if ( fieldInStream[idx].equals( fieldInStream[jdx] ) && idx != jdx && idx < jdx ) {
            error_message =
              BaseMessages.getString( PKG, "ReplaceStringMeta.CheckResult.FieldInputError", fieldInStream[idx] );
            cr = new CheckResult( CheckResult.TYPE_RESULT_ERROR, error_message, stepinfo );
            remarks.add( cr );
          }
        }
      }

    }
  }

  public StepInterface getStep( StepMeta stepMeta, StepDataInterface stepDataInterface, int cnr,
    TransMeta transMeta, Trans trans ) {
    return new ReplaceString( stepMeta, stepDataInterface, cnr, transMeta, trans );
  }

  public StepDataInterface getStepData() {
    return new ReplaceStringData();
  }

  public boolean supportsErrorHandling() {
    return true;
  }

  private void nullToEmpty( String [] strings ) {
    for ( int i = 0; i < strings.length; i++ ) {
      if ( strings[ i ] == null ) {
        strings[ i ] = StringUtils.EMPTY;
      }
    }
  }
  /**
   * If we use injection we can have different arrays lengths.
   * We need synchronize them for consistency behavior with UI
   */
  @AfterInjection
  public void afterInjectionSynchronization() {
    int nrFields = ( fieldInStream == null ) ? -1 : fieldInStream.length;
    if ( nrFields <= 0 ) {
      return;
    }
    String[][] rtnStringArrays = Utils.normalizeArrays( nrFields, fieldOutStream, replaceString, replaceByString, replaceFieldByString );
    fieldOutStream = rtnStringArrays[ 0 ];
    replaceString = rtnStringArrays[ 1 ];
    replaceByString = rtnStringArrays[ 2 ];
    replaceFieldByString = rtnStringArrays[ 3 ];

    nullToEmpty( fieldOutStream );
    nullToEmpty( replaceString );
    nullToEmpty( replaceByString );
    nullToEmpty( replaceFieldByString );

    boolean[][] rtnBooleanArrays =
      Utils.normalizeArrays( nrFields, useRegEx, setEmptyString, wholeWord, caseSensitive, isUnicode );
    useRegEx = rtnBooleanArrays[ 0 ];
    setEmptyString = rtnBooleanArrays[ 1 ];
    wholeWord = rtnBooleanArrays[ 2 ];
    caseSensitive = rtnBooleanArrays[ 3 ];
    isUnicode = rtnBooleanArrays[ 4 ];
  }

}


text:
<?php

declare(strict_types=1);

namespace QueueJitsu\Job;

/**
 * Interface HasSetup
 *
 * @package QueueJitsu\Job
 */
interface HasTearDown
{
    /**
     * setUp
     */
    public function tearDown(): void;
}

redpajama_set_name: RedPajamaGithub


text:
<!DOCTYPE html>

    <title>Views example - Nucleon JS</title>
    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" />


text:
<?php

/* FOSUserBundle::layout.html.twig */
class __TwigTemplate_d98274451265bff3c334150e409e4e325ab3f83e1fcd11fdcce2516f472541f6 extends Twig_Template
{
    public function __construct(Twig_Environment $env)
    {
        parent::__construct($env);

        $this->parent = $this->env->loadTemplate("::layout/layout.html.twig");

        $this->blocks = array(
            'body' => array($this, 'block_body'),
            'fos_user_content' => array($this, 'block_fos_user_content'),
        );
    }

    protected function doGetParent(array $context)
    {
        return "::layout/layout.html.twig";
    }

    protected function doDisplay(array $context, array $blocks = array())
    {
        $this->parent->display($context, array_merge($this->blocks, $blocks));
    }

    // line 3
    public function block_body($context, array $blocks = array())
    {
        // line 4
        echo "

    ";
        // line 5
        $context['_parent'] = (array) $context;
        $context['_seq'] = twig_ensure_traversable($this->getAttribute($this->getAttribute($this->getAttribute((isset($context["app"]) ? $context["app"] : $this->getContext($context, "app")), "session"), "flashbag"), "all", array(), "method"));
        foreach ($context['_seq'] as $context["type"] => $context["messages"]) {
            // line 6
            echo "        ";
            $context['_parent'] = (array) $context;
            $context['_seq'] = twig_ensure_traversable((isset($context["messages"]) ? $context["messages"] : $this->getContext($context, "messages")));
            foreach ($context['_seq'] as $context["_key"] => $context["message"]) {
                // line 7
                echo "
env, (isset($context["type"]) ? $context["type"] : $this->getContext($context, "type")), "html", null, true);
                echo "\">
                ";
                // line 8
                echo twig_escape_filter($this->env, (isset($context["message"]) ? $context["message"] : $this->getContext($context, "message")), "html", null, true);
                echo "

        ";
            }
            $_parent = $context['_parent'];
            unset($context['_seq'], $context['_iterated'], $context['_key'], $context['message'], $context['_parent'], $context['loop']);
            $context = array_intersect_key($context, $_parent) + $_parent;
            // line 11
            echo "    ";
        }
        $_parent = $context['_parent'];
        unset($context['_seq'], $context['_iterated'], $context['type'], $context['messages'], $context['_parent'], $context['loop']);
        $context = array_intersect_key($context, $_parent) + $_parent;
        // line 12
        echo "
    ";
        // line 13
        $this->displayBlock('fos_user_content', $context, $blocks);
        // line 15
        echo "

";
    }

    // line 13
    public function block_fos_user_content($context, array $blocks = array())
    {
        // line 14
        echo "    ";
    }

    public function getTemplateName()
    {
        return "FOSUserBundle::layout.html.twig";
    }

    public function isTraitable()
    {
        return false;
    }

    public function getDebugInfo()
    {
        return array (  77 => 14,  74 => 13,  69 => 15,  67 => 13,  64 => 12,  58 => 11,  49 => 8,  44 => 7,  35 => 5,  32 => 4,  29 => 3,  93 => 40,  86 => 36,  80 => 33,  75 => 31,  71 => 30,  66 => 28,  62 => 27,  53 => 21,  39 => 6,  33 => 7,  31 => 6,  28 => 5,);
    }
}


text:
<?php

namespace Kendo\UI;

class GridMessagesCommands extends \Kendo\SerializableObject {
//>> Properties

    /**
    * Defines the text of "Cancel Changes" button located in the ToolBar of the widget.
    * @param string $value
    * @return \Kendo\UI\GridMessagesCommands
    */
    public function cancel($value) {
        return $this->setProperty('cancel', $value);
    }

    /**
    * Defines the text of "Cancel" button that is rendered in inline or popup editing mode.
    * @param string $value
    * @return \Kendo\UI\GridMessagesCommands
    */
    public function canceledit($value) {
        return $this->setProperty('canceledit', $value);
    }

    /**
    * Defines the text of "Add new record" button located in the ToolBar of the widget.
    * @param string $value
    * @return \Kendo\UI\GridMessagesCommands
    */
    public function create($value) {
        return $this->setProperty('create', $value);
    }

    /**
    * Defines the text of "Delete" button rendered in inline or popup editing mode.
    * @param string $value
    * @return \Kendo\UI\GridMessagesCommands
    */
    public function destroy($value) {
        return $this->setProperty('destroy', $value);
    }

    /**
    * Defines the text of "Edit" button that is rendered in inline or popup editing mode.
    * @param string $value
    * @return \Kendo\UI\GridMessagesCommands
    */
    public function edit($value) {
        return $this->setProperty('edit', $value);
    }

    /**
    * Defines the text of "Save Changes" button located in the ToolBar of the widget.
    * @param string $value
    * @return \Kendo\UI\GridMessagesCommands
    */
    public function save($value) {
        return $this->setProperty('save', $value);
    }

    /**
    * Defines the text of "Update" button that is rendered in inline or popup editing mode.
    * @param string $value
    * @return \Kendo\UI\GridMessagesCommands
    */
    public function update($value) {
        return $this->setProperty('update', $value);
    }

//<< Properties
}

?>


text:
module Main where

import Test.Hspec.Meta

import qualified Test.Hspec.ExpectationsSpec
import qualified Test.Hspec.Expectations.MatcherSpec

spec :: Spec
spec = do
  describe "Test.Hspec.ExpectationsSpec" Test.Hspec.ExpectationsSpec.spec
  describe "Test.Hspec.Expectations.MatcherSpec" Test.Hspec.Expectations.MatcherSpec.spec

main :: IO ()
main = hspec spec


text:
template<typename ComponentType, typename... Bases> struct SubArray;
namespace java
{
    namespace io
    {
typedef ::SubArray< ::java::io::Serializable, ::java::lang::ObjectArray > SerializableArray;
    } // io

    namespace lang
    {
typedef ::SubArray< ::java::lang::CharSequence, ObjectArray > CharSequenceArray;

        namespace reflect
        {
typedef ::SubArray< ::java::lang::reflect::AnnotatedElement, ::java::lang::ObjectArray > AnnotatedElementArray;
typedef ::SubArray< ::java::lang::reflect::GenericDeclaration, ::java::lang::ObjectArray, AnnotatedElementArray > GenericDeclarationArray;
typedef ::SubArray< ::java::lang::reflect::Type, ::java::lang::ObjectArray > TypeArray;
        } // reflect
typedef ::SubArray< ::java::lang::Class, ObjectArray, ::java::io::SerializableArray, ::java::lang::reflect::GenericDeclarationArray, ::java::lang::reflect::TypeArray, ::java::lang::reflect::AnnotatedElementArray > ClassArray;
typedef ::SubArray< ::java::lang::Comparable, ObjectArray > ComparableArray;
typedef ::SubArray< ::java::lang::String, ObjectArray, ::java::io::SerializableArray, ComparableArray, CharSequenceArray > StringArray;
    } // lang
} // java

namespace poi
{
    namespace ss
    {
        namespace formula
        {
typedef ::SubArray< ::poi::ss::formula::WorkbookEvaluator, ::java::lang::ObjectArray > WorkbookEvaluatorArray;

            namespace eval
            {
                namespace forked
                {
typedef ::SubArray< ::poi::ss::formula::eval::forked::ForkedEvaluator, ::java::lang::ObjectArray > ForkedEvaluatorArray;
                } // forked
            } // eval
        } // formula
    } // ss
} // poi

template<typename T, typename U>
static T java_cast(U* u)
{
    if(!u) return static_cast<T>(nullptr);
    auto t = dynamic_cast<T>(u);
    if(!t) throw new ::java::lang::ClassCastException();
    return t;
}

template<typename T>
static T* npc(T* t)
{
    if(!t) throw new ::java::lang::NullPointerException();
    return t;
}

poi::ss::formula::eval::forked::ForkedEvaluator::ForkedEvaluator(const ::default_init_tag&)
    : super(*static_cast< ::default_init_tag* >(0))
{
    clinit();
}

poi::ss::formula::eval::forked::ForkedEvaluator::ForkedEvaluator(::poi::ss::formula::EvaluationWorkbook* masterWorkbook, ::poi::ss::formula::IStabilityClassifier* stabilityClassifier, ::poi::ss::formula::udf::UDFFinder* udfFinder)
    : ForkedEvaluator(*static_cast< ::default_init_tag* >(0))
{
    ctor(masterWorkbook,stabilityClassifier,udfFinder);
}

void poi::ss::formula::eval::forked::ForkedEvaluator::ctor(::poi::ss::formula::EvaluationWorkbook* masterWorkbook, ::poi::ss::formula::IStabilityClassifier* stabilityClassifier, ::poi::ss::formula::udf::UDFFinder* udfFinder)
{
    super::ctor();
    _sewb = new ForkedEvaluationWorkbook(masterWorkbook);
    _evaluator = new ::poi::ss::formula::WorkbookEvaluator(_sewb, stabilityClassifier, udfFinder);
}

poi::ss::formula::EvaluationWorkbook* poi::ss::formula::eval::forked::ForkedEvaluator::createEvaluationWorkbook(::poi::ss::usermodel::Workbook* wb)
{
    clinit();
    if(dynamic_cast< ::poi::hssf::usermodel::HSSFWorkbook* >(wb) != nullptr) {
        return ::poi::hssf::usermodel::HSSFEvaluationWorkbook::create(java_cast< ::poi::hssf::usermodel::HSSFWorkbook* >(wb));
    } else {
        try {
            auto evalWB = ::java::lang::Class::forName(u"org.apache.poi.xssf.usermodel.XSSFEvaluationWorkbook"_j);
            auto xssfWB = ::java::lang::Class::forName(u"org.apache.poi.xssf.usermodel.XSSFWorkbook"_j);
            auto createM = npc(evalWB)->getDeclaredMethod(u"create"_j, new ::java::lang::ClassArray({static_cast< ::java::lang::Class* >(xssfWB)}));
            return java_cast< ::poi::ss::formula::EvaluationWorkbook* >(npc(createM)->invoke(nullptr, new ::java::lang::ObjectArray({static_cast< ::java::lang::Object* >(wb)})));
        } catch (::java::lang::Exception* e) {
            throw new ::java::lang::IllegalArgumentException(::java::lang::StringBuilder().append(u"Unexpected workbook type ("_j)->append(npc(npc(wb)->getClass())->getName())
                ->append(u") - check for poi-ooxml and poi-ooxml schemas jar in the classpath"_j)->toString(), e);
        }
    }
}

poi::ss::formula::eval::forked::ForkedEvaluator* poi::ss::formula::eval::forked::ForkedEvaluator::create(::poi::ss::usermodel::Workbook* wb, ::poi::ss::formula::IStabilityClassifier* stabilityClassifier, ::poi::ss::formula::udf::UDFFinder* udfFinder)
{
    clinit();
    return new ForkedEvaluator(createEvaluationWorkbook(wb), stabilityClassifier, udfFinder);
}

void poi::ss::formula::eval::forked::ForkedEvaluator::updateCell(::java::lang::String* sheetName, int32_t rowIndex, int32_t columnIndex, ::poi::ss::formula::eval::ValueEval* value)
{
    auto cell = npc(_sewb)->getOrCreateUpdatableCell(sheetName, rowIndex, columnIndex);
    npc(cell)->setValue(value);
    npc(_evaluator)->notifyUpdateCell(cell);
}

void poi::ss::formula::eval::forked::ForkedEvaluator::copyUpdatedCells(::poi::ss::usermodel::Workbook* workbook)
{
    npc(_sewb)->copyUpdatedCells(workbook);
}

poi::ss::formula::eval::ValueEval* poi::ss::formula::eval::forked::ForkedEvaluator::evaluate(::java::lang::String* sheetName, int32_t rowIndex, int32_t columnIndex)
{
    auto cell = npc(_sewb)->getEvaluationCell(sheetName, rowIndex, columnIndex);
    {
        auto v = npc(cell)->getCellTypeEnum();
        if((v == ::poi::ss::usermodel::CellType::BOOLEAN)) {
            return ::poi::ss::formula::eval::BoolEval::valueOf(npc(cell)->getBooleanCellValue());
        }
        if((v == ::poi::ss::usermodel::CellType::ERROR)) {
            return ::poi::ss::formula::eval::ErrorEval::valueOf(npc(cell)->getErrorCellValue());
        }
        if((v == ::poi::ss::usermodel::CellType::FORMULA)) {
            return npc(_evaluator)->evaluate(cell);
        }
        if((v == ::poi::ss::usermodel::CellType::NUMERIC)) {
            return new ::poi::ss::formula::eval::NumberEval(npc(cell)->getNumericCellValue());
        }
        if((v == ::poi::ss::usermodel::CellType::STRING)) {
            return new ::poi::ss::formula::eval::StringEval(npc(cell)->getStringCellValue());
        }
        if((v == ::poi::ss::usermodel::CellType::BLANK)) {
            return nullptr;
        }
        if((((v != ::poi::ss::usermodel::CellType::BOOLEAN) && (v != ::poi::ss::usermodel::CellType::ERROR) && (v != ::poi::ss::usermodel::CellType::FORMULA) && (v != ::poi::ss::usermodel::CellType::NUMERIC) && (v != ::poi::ss::usermodel::CellType::STRING) && (v != ::poi::ss::usermodel::CellType::BLANK)))) {
            throw new ::java::lang::IllegalStateException(::java::lang::StringBuilder().append(u"Bad cell type ("_j)->append(static_cast< ::java::lang::Object* >(npc(cell)->getCellTypeEnum()))
                ->append(u")"_j)->toString());
        }
end_switch0:;
    }

}

void poi::ss::formula::eval::forked::ForkedEvaluator::setupEnvironment(::java::lang::StringArray* workbookNames, ForkedEvaluatorArray* evaluators)
{
    clinit();
    auto wbEvals = new ::poi::ss::formula::WorkbookEvaluatorArray(npc(evaluators)->length);
    for (auto i = int32_t(0); i < npc(wbEvals)->length; i++) {
        wbEvals->set(i, npc((*evaluators)[i])->_evaluator);
    }
    ::poi::ss::formula::CollaboratingWorkbooksEnvironment::setup(workbookNames, wbEvals);
}

extern java::lang::Class *class_(const char16_t *c, int n);

java::lang::Class* poi::ss::formula::eval::forked::ForkedEvaluator::class_()
{
    static ::java::lang::Class* c = ::class_(u"org.apache.poi.ss.formula.eval.forked.ForkedEvaluator", 53);
    return c;
}

java::lang::Class* poi::ss::formula::eval::forked::ForkedEvaluator::getClass0()
{
    return class_();
}


text:
.class public abstract Landroid/view/IWindowFocusObserver$Stub;
.super Landroid/os/Binder;
.source "IWindowFocusObserver.java"

# interfaces
.implements Landroid/view/IWindowFocusObserver;

# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Landroid/view/IWindowFocusObserver;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x409
    name = "Stub"
.end annotation

.annotation system Ldalvik/annotation/MemberClasses;
    value = {
        Landroid/view/IWindowFocusObserver$Stub$Proxy;
    }
.end annotation

# static fields
.field private static final DESCRIPTOR:Ljava/lang/String; = "android.view.IWindowFocusObserver"

.field static final TRANSACTION_focusGained:I = 0x1

.field static final TRANSACTION_focusLost:I = 0x2

# direct methods
.method public constructor <init>()V
    .registers 2

    .prologue
    .line 14
    invoke-direct {p0}, Landroid/os/Binder;-><init>()V

    .line 16
    const-string/jumbo v0, "android.view.IWindowFocusObserver"

    invoke-virtual {p0, p0, v0}, Landroid/view/IWindowFocusObserver$Stub;->attachInterface(Landroid/os/IInterface;Ljava/lang/String;)V

    .line 14
    return-void
.end method

.method public static asInterface(Landroid/os/IBinder;)Landroid/view/IWindowFocusObserver;
    .registers 3
    .param p0, "obj"    # Landroid/os/IBinder;

    .prologue
    const/4 v1, 0x0

    .line 24
    if-nez p0, :cond_4

    .line 25
    return-object v1

    .line 27
    :cond_4
    const-string/jumbo v1, "android.view.IWindowFocusObserver"

    invoke-interface {p0, v1}, Landroid/os/IBinder;->queryLocalInterface(Ljava/lang/String;)Landroid/os/IInterface;

    move-result-object v0

    .line 28
    .local v0, "iin":Landroid/os/IInterface;
    if-eqz v0, :cond_14

    instance-of v1, v0, Landroid/view/IWindowFocusObserver;

    if-eqz v1, :cond_14

    .line 29
    check-cast v0, Landroid/view/IWindowFocusObserver;

    .end local v0    # "iin":Landroid/os/IInterface;
    return-object v0

    .line 31
    .restart local v0    # "iin":Landroid/os/IInterface;
    :cond_14
    new-instance v1, Landroid/view/IWindowFocusObserver$Stub$Proxy;

    invoke-direct {v1, p0}, Landroid/view/IWindowFocusObserver$Stub$Proxy;-><init>(Landroid/os/IBinder;)V

    return-object v1
.end method

# virtual methods
.method public asBinder()Landroid/os/IBinder;
    .registers 1

    .prologue
    .line 35
    return-object p0
.end method

.method public onTransact(ILandroid/os/Parcel;Landroid/os/Parcel;I)Z
    .registers 8
    .param p1, "code"    # I
    .param p2, "data"    # Landroid/os/Parcel;
    .param p3, "reply"    # Landroid/os/Parcel;
    .param p4, "flags"    # I
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Landroid/os/RemoteException;
        }
    .end annotation

    .prologue
    const/4 v2, 0x1

    .line 39
    sparse-switch p1, :sswitch_data_32

    .line 65
    invoke-super {p0, p1, p2, p3, p4}, Landroid/os/Binder;->onTransact(ILandroid/os/Parcel;Landroid/os/Parcel;I)Z

    move-result v1

    return v1

    .line 43
    :sswitch_9
    const-string/jumbo v1, "android.view.IWindowFocusObserver"

    invoke-virtual {p3, v1}, Landroid/os/Parcel;->writeString(Ljava/lang/String;)V

    .line 44
    return v2

    .line 48
    :sswitch_10
    const-string/jumbo v1, "android.view.IWindowFocusObserver"

    invoke-virtual {p2, v1}, Landroid/os/Parcel;->enforceInterface(Ljava/lang/String;)V

    .line 50
    invoke-virtual {p2}, Landroid/os/Parcel;->readStrongBinder()Landroid/os/IBinder;

    move-result-object v0

    .line 51
    .local v0, "_arg0":Landroid/os/IBinder;
    invoke-virtual {p0, v0}, Landroid/view/IWindowFocusObserver$Stub;->focusGained(Landroid/os/IBinder;)V

    .line 52
    invoke-virtual {p3}, Landroid/os/Parcel;->writeNoException()V

    .line 53
    return v2

    .line 57
    .end local v0    # "_arg0":Landroid/os/IBinder;
    :sswitch_21
    const-string/jumbo v1, "android.view.IWindowFocusObserver"

    invoke-virtual {p2, v1}, Landroid/os/Parcel;->enforceInterface(Ljava/lang/String;)V

    .line 59
    invoke-virtual {p2}, Landroid/os/Parcel;->readStrongBinder()Landroid/os/IBinder;

    move-result-object v0

    .line 60
    .restart local v0    # "_arg0":Landroid/os/IBinder;
    invoke-virtual {p0, v0}, Landroid/view/IWindowFocusObserver$Stub;->focusLost(Landroid/os/IBinder;)V

    .line 61
    invoke-virtual {p3}, Landroid/os/Parcel;->writeNoException()V

    .line 62
    return v2

    .line 39
    :sswitch_data_32
    .sparse-switch
        0x1 -> :sswitch_10
        0x2 -> :sswitch_21
        0x5f4e5446 -> :sswitch_9
    .end sparse-switch
.end method


text:
#ifdef _WIN32
#include <SDL.h>
#else
#include <SDL/SDL.h>
#endif

#include <stdlib.h>
#include <exception>
#include <GL/glew.h>
#include <string>
#include "options.h"

#define PROGRAM_LOG_NAME "ProgramLog.txt"
#define SHADER_LOG_NAME "ShaderLog.txt"
static const float FPS_TICKS_60 = 17.0;

using namespace std;

typedef map<char, string> OptMap;

class InitException
{
  public:
    InitException(string m);
    const char * what();
  private:
    string msg;
};

// Helper class. Locks an SDL mutex, and unlocks automatically on scope exit
class SDLMutexLocker
{
  SDL_mutex* _mutex;

public:
  SDLMutexLocker(SDL_mutex* mutex) :
    _mutex(mutex)
  {
    SDL_LockMutex(_mutex);
  }

  ~SDLMutexLocker()
  {
    SDL_UnlockMutex(_mutex);
  }
};

InitException::InitException(string m):
  msg(m)
{}

const char * InitException::what()
{
  return msg.c_str();
}

void printProgramInfoLog(GLuint obj)
{
  int infologLength = 0;
  int charsWritten  = 0;
  char *infoLog;
  FILE * file;

  glGetProgramiv(obj, GL_INFO_LOG_LENGTH,&infologLength);

  if (infologLength > 0)
  {
#ifdef _WIN32
    fopen_s(&file, PROGRAM_LOG_NAME, "w");
#else
    file = fopen(PROGRAM_LOG_NAME, "w");
#endif
    infoLog = (char *)malloc(infologLength);
    glGetProgramInfoLog(obj, infologLength, &charsWritten, infoLog);
    fprintf(file, "%s\n",infoLog);
    free(infoLog);
    fclose(file);
  }
}

int file_open(FILE** file, const char* name, const char* mode)
{
#ifdef _WIN32
  return fopen_s(file, name, mode);
#else
  *file = fopen(name, mode);
  return errno
#endif
}

void printShaderInfoLog(GLuint obj)
{
  int infologLength = 0;
  int charsWritten  = 0;
  char *infoLog;
  FILE * file;

  glGetShaderiv(obj, GL_INFO_LOG_LENGTH, &infologLength);

  if (infologLength > 0)
  {
    file_open(&file, SHADER_LOG_NAME, "w");
    infoLog = (char *)malloc(infologLength);
    glGetShaderInfoLog(obj, infologLength, &charsWritten, infoLog);
    fprintf(file, "%s\n", infoLog);
    free(infoLog);
    fclose(file);
  }
}

class Program
{
  int w, h;
  int render_width;
  SDL_Event event;
  char * shader_path;
  GLuint frag, prog, bl, tr, res;
  Uint32 flags;
  double bottomleft[2];
  double topright[2];
  double zoom_factor;
  Uint32 _previous_ticks;
  unsigned _screen_shot_idx;
  SDL_Surface * _frame_buffer;
  FILE* _out_stream;
  SDL_mutex * _cond_lock;
  SDL_mutex * _frame_buffer_lock;
  SDL_cond * _write_cond;
  bool _frame_write_enable;
  bool _write_thread_quit;

  void render()
  {
    glClear(GL_COLOR_BUFFER_BIT);
    glLoadIdentity();
    // Create a flat plane to draw on.
    glBegin(GL_QUADS);
    // Bottom left.
    glVertex2f(-1.0, -1.0);
    // Top left
    glVertex2f(-1.0, 1.0);
    // Top right
    glVertex2f(1.0, 1.0);
    // Bottom right.
    glVertex2f(1.0, -1.0);
    glEnd();

    SDL_GL_SwapBuffers();
    //Block until the frame has finished rendering.
    glFinish();
  }

  int readBuffer()
  {
    int ret = 1;
    {
      SDLMutexLocker lock(_frame_buffer_lock);
      glReadPixels(0, 0, (GLsizei)w, (GLsizei)h, GL_BGR,
                   GL_UNSIGNED_BYTE, _frame_buffer->pixels);
    }

    if (glGetError() != GL_NO_ERROR)
    {
      cerr << "Failed to retrieve the frame-buffer." << endl;
      ret = 0;
    }
    return ret;
  }

  void saveScreenshot()
  {
    if (readBuffer())
    {
      stringstream name;
      name.width(2);
      name.fill('0');
      name << "screenshot" << _screen_shot_idx << ".bmp";
      SDL_SaveBMP(_frame_buffer, name.str().c_str());
      _screen_shot_idx++;
    }
  }

  void writeFrame()
  {
    if (readBuffer())
    {
      SDLMutexLocker lock(_cond_lock);
      _frame_write_enable = true;
      SDL_CondSignal(_write_cond);
    }
  }

  // Thread for writing frames to avoid IO waiting
  static int writeThread(void * prog)
  {
    Program* self = static_cast<Program *>(prog);
    while (1)
    {
      {
        SDLMutexLocker lock(self->_cond_lock);
        while (!self->_frame_write_enable && !self->_write_thread_quit)
        {
          SDL_CondWait(self->_write_cond, self->_cond_lock);
        }
        self->_frame_write_enable = false;
      }
      if (self->_write_thread_quit)
        return 0;
      {
        SDLMutexLocker lock(self->_frame_buffer_lock);
        fwrite(self->_frame_buffer->pixels, 1,
               self->_frame_buffer->pitch * self->_frame_buffer->h,
               self->_out_stream);
      }
    }
  }

  void initVideo()
  {
    SDL_GL_SetAttribute(SDL_GL_DOUBLEBUFFER, 0);
    SDL_WM_SetCaption("Mandelbrot Zoomer", NULL);
    if (SDL_SetVideoMode(this->w, this->h, 32, this->flags) < 0)
    {
      throw InitException(string("Could not initialise video: ") + SDL_GetError());
    }

    // If shader does not compile, display a green screen.
    glClearColor(0.0, 1.0, 0.0, 0.0);
    glewInit();
    if (!glewIsSupported("GL_VERSION_2_0"))
    {
      throw InitException("OpenGL 2.0 not supported.");
    }
  }

  void initCoordinates()
  {
    bottomleft[0] = -2.0;
    bottomleft[1] = -1.0;
    topright[0] = 1.0;
    topright[1] = 1.0;
    zoom_factor = 1.0;
  }

  void initShader()
  {
    ifstream shader_file;
    shader_file.open(shader_path, istream::in);
    if (!shader_file.good())
    {
      throw InitException("Could not read shader file.");
    }
    shader_file.seekg(0, shader_file.end);
    int length = (int)shader_file.tellg();
    shader_file.seekg(0, shader_file.beg);
    char *shader = new char[length + 1];
    memset(shader, 0, length + 1);
    shader_file.read(shader, length);
    frag = glCreateShader(GL_FRAGMENT_SHADER);

    glShaderSource(frag, 1, (const char **)&shader, NULL);
    glCompileShader(frag);
    delete[] shader;
    shader_file.close();
    printShaderInfoLog(frag);
    prog = glCreateProgram();
    glAttachShader(prog, frag);
    glLinkProgram(prog);
    printProgramInfoLog(prog);
    glUseProgram(prog);
    if (glGetError() != 0)
    {
      throw InitException("Shader did not compile, check logs.");
    }
    bl = glGetUniformLocation(prog, "bottomleft");
    tr = glGetUniformLocation(prog, "topright");
    res = glGetUniformLocation(prog, "resolution");
    if ((bl == -1)||(tr == -1)||(res == -1))
    {
      throw InitException("Could not get uniform location.");
    }
    initCoordinates();
    _previous_ticks = SDL_GetTicks();
  }

  void setUniformValues()
  {
    glUniform2dv(bl, 1, bottomleft);
    glUniform2dv(tr, 1, topright);
    glUniform2f(res, (float)render_width, (float)h);
  }

  int zoom(double * axis, double speed, bool save_stream, double min_width)
  {
    Uint32 ticks = SDL_GetTicks();
    int ret = 0;
    // Clamp speed
    if (speed < 1.0)
      speed = 1.0;
    if (speed > 60.0)
      speed = 60.0;
    // Don't adjust speed according to frame-rate when saving to file.
    if (!save_stream)
      speed *= (ticks - _previous_ticks) / FPS_TICKS_60;
    double normalised_speed = 10000 / (10000 + speed);
    for (int i = 0; i < 2; i++)
    {
      bottomleft[i] = axis[i] - (axis[i] - bottomleft[i]) * normalised_speed;
      topright[i] = axis[i] - (axis[i] - topright[i]) * normalised_speed;
    }
    zoom_factor /= normalised_speed;

    // Reset zoom once we reach maximum zoom
    if (!isnan(min_width) && (topright[0] - bottomleft[0]) <= min_width)
    {
      if (save_stream)
        ret = 1;
      else
        initCoordinates();
    }

    _previous_ticks = ticks;
    return ret;
  }

  void init(int sdl_flags=0)
  {
    if (w == 0 || h == 0)
    {
      const SDL_VideoInfo * mode;
      mode = SDL_GetVideoInfo();
      w = mode->current_w;
      h = mode->current_h;
    }
    // Normalise the width passed to the shader to 4:3 to avoid stretching the image.
    render_width = (h * 4) / 3;
    flags = SDL_OPENGL | sdl_flags;
    if (SDL_Init(SDL_INIT_VIDEO) < 0)
    {
      throw InitException("Could not initialise SDL.");
    }
    initVideo();
    initShader();
    _frame_buffer = SDL_CreateRGBSurface(0, w, h, 24, 0x00ff0000, 0x0000ff00, 0x000000ff, 0);
    _frame_buffer_lock = SDL_CreateMutex();
  }

  public:
    Program(char * shaderPath, int width, int height, bool fullscreen):
      shader_path(shaderPath), w(width), h(height),
      _screen_shot_idx(1),
      _frame_buffer(NULL),
      _out_stream(NULL),
      _frame_write_enable(false),
      _write_thread_quit(false),
      _cond_lock(NULL),
      _frame_buffer_lock(NULL),
      _write_cond(NULL)
    {
      int flags = 0;
      if (fullscreen) flags |= SDL_FULLSCREEN;
      init(flags);
    }

    ~Program()
    {
      if (_frame_buffer) SDL_FreeSurface(_frame_buffer);
      if (_out_stream) fclose(_out_stream);
      if (_frame_buffer_lock) SDL_DestroyMutex(_frame_buffer_lock);
      if (_cond_lock) SDL_DestroyMutex(_cond_lock);
      if (_write_cond) SDL_DestroyCond(_write_cond);
      SDL_Quit();
    }

    void eventLoop(bool save_stream, double axis[], double speed=10, double min_width=NAN)
    {
      int frame_count = 0;
      SDL_Thread* thread = NULL;

      if (save_stream)
      {
        if (file_open(&_out_stream, "out.raw", "wb") != 0)
        {
#ifdef _WIN32
          char buf[80];
          strerror_s(buf, 80, errno);
#else
          const char buf = strerror(errno);
#endif
          fprintf(stderr, "Could not open output stream: %s.\n", buf);
          save_stream = false;
        }
        else
        {
          _write_cond = SDL_CreateCond();
          _cond_lock = SDL_CreateMutex();
          thread = SDL_CreateThread(writeThread, this);
          if (NULL == thread)
          {
            fprintf(stderr, "SDL_CreateThread failed: %s\n", SDL_GetError());
          }
        }
      }

      while (1)
      {
        if (zoom(axis, speed, save_stream, min_width))
          goto exit;
        setUniformValues();
        render();
        frame_count++;
        if (save_stream) writeFrame();
        while(SDL_PollEvent(&event))
        {
          switch (event.type)
          {
            case SDL_KEYDOWN:
              switch (event.key.keysym.sym)
              {
                case SDLK_ESCAPE:
                  goto exit;
                case SDLK_UP:
                  axis[1] += 0.06/zoom_factor;
                  break;
                case SDLK_DOWN:
                  axis[1] -= 0.06/zoom_factor;
                  break;
                case SDLK_RIGHT:
                  axis[0] += 0.06/zoom_factor;
                  break;
                case SDLK_LEFT:
                  axis[0] -= 0.06/zoom_factor;
                  break;
                case SDLK_w:
                  speed += 1;
                  break;
                case SDLK_s:
                  speed -= 1;
                  break;
                case SDLK_q:
                  if (!save_stream) saveScreenshot();
                  break;
                case SDLK_SPACE:
                  initCoordinates();
                  break;
                default:
                  break;
              }
              break;
            case SDL_QUIT:
              goto exit;
            default:
              break;
          }
        }
      }
    exit:
      // Thread shutdown
      if (thread)
      {
        {
          SDLMutexLocker lock(_cond_lock);
          _write_thread_quit = true;
          SDL_CondSignal(_write_cond);
        }
        SDL_WaitThread(thread, NULL);
      }
      printf("Rendered %d frames.\n", frame_count);
      printf("Zoom axis: (%.10f, %.10f)\n", axis[0], axis[1]);
      printf("Speed: %f\n", speed);
      return;
    }
};

int main(int argc, char* argv[])
{
  int returncode = 0;
  unsigned long w, h;
  // Zoom in on a good point by default.
  double axis[] = {-1.1623416001, 0.2923689343};
  double speed = 10.0;
  const int Y_MAX = 1;
  const int Y_MIN = -1;
  const int X_MAX = 1;
  const int X_MIN = -2;
  w = 960;
  h = 720;

  try
  {
    OptMap options = get_options(argc, argv, "w:H:x:y:s:hrfd");
    if (options.count('h'))
    {
      cout << "Usage: " << argv[0] << " [-w WIDTH][-H HEIGHT][options]" << endl;
      cout << endl;
      cout << "Options:" << endl;
      cout << "  -w : Screen or window width in pixels. Default: " << w << endl;
      cout << "  -H : Screen or window height in pixels. Default: " << h << endl;
      cout << setprecision(10);
      cout << "  -x : X coordinate to zoom in at. Default: " << axis[0] << endl;
      cout << "  -y : Y coordinate to zoom in at. Default: " << axis[1] << endl;
      cout << "  -s : Initial zoom speed. Default: " << speed << endl;
      cout << "  -r : Save frame-buffer to raw video stream. SSD recommended." << endl;
      cout << "  -f : Open in fullscreen mode. Escape to exit." << endl;
      cout << "  -d : Use double-precision floating point. Slower, but can zoom further." << endl;
      cout << "  -h : Print this help message and quit." << endl;
      cout << endl;
      cout << "Controls:" << endl;
      cout << "  Direction Keys : Move zoom axis." << endl;
      cout << "  w : Increase speed." << endl;
      cout << "  s : Decrease speed." << endl;
      cout << "  q : Take screenshot, ignored if launched with '-r'." << endl;
      cout << "  SPACEBAR : Reset zoom." << endl;
      cout << "  ESC : Exit." << endl;
      return returncode;
    }
    if (options.count('w'))
    {
      w = strtoul(options['w'].c_str(), NULL, 10);
    }
    if (options.count('H'))
    {
      h = strtoul(options['H'].c_str(), NULL, 10);
    }
    if (options.count('x'))
    {
      double x = strtod(options['x'].c_str(), NULL);
      if (x > X_MIN && x < X_MAX)
        axis[0] = x;
      else
        fprintf(stderr, "X coordinate must be between %d and %d.\n", X_MIN, X_MAX);
    }
    if (options.count('y'))
    {
      double y = strtod(options['y'].c_str(), NULL);
      if (y > Y_MIN && y < Y_MAX)
        axis[1] = y;
      else
        fprintf(stderr, "Y coordinate must be between %d and %d.\n", Y_MIN, Y_MAX);
    }
    if (options.count('s'))
    {
      double s = strtod(options['s'].c_str(), NULL);
      if (s >= 0)
        speed = s;
      else
        fprintf(stderr, "Speed value must be positive.\n");
    }
    char * shader_file = (options.count('d') > 0) ? "mandelbrot-double.frag" : "mandelbrot-single.frag";
    // Width to limit zooming to.
    double min_width = (options.count('d') > 0) ? 20 * DBL_EPSILON : 20 * FLT_EPSILON;
    Program prog(shader_file, w, h, (options.count('f') > 0));
    prog.eventLoop((options.count('r') > 0), axis, speed, min_width);
  }
  catch (invalid_argument& e)
  {
    cerr << e.what() << endl;
    returncode = 1;
  }
  catch (InitException& e)
  {
    cerr << e.what() << endl;
    returncode = 1;
  }
  return returncode;
}


text:
package fi.mabrosim.shoppinglist.ui.pages;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.support.annotation.NonNull;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.AdapterView;
import android.widget.ExpandableListView;

import fi.mabrosim.shoppinglist.R;
import fi.mabrosim.shoppinglist.ui.editors.EditLabelActivity;
import fi.mabrosim.shoppinglist.utils.Actions;

public class PrepareItemsFragment extends PageFragment<PrepareItemsAdapter> {
    public PrepareItemsFragment() {
        super(new PrepareItemsAdapter());
    }

    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
        return inflater.inflate(R.layout.labels_expandable_list, container, false);
    }

    @Override
    public void onViewCreated(@NonNull View view, Bundle savedInstanceState) {
        super.onViewCreated(view, savedInstanceState);

        ExpandableListView listView = (ExpandableListView) getListView();
        listView.setAdapter(mAdapter);
        listView.setFastScrollEnabled(true);
        listView.setOnChildClickListener(mOnChildClickListener);
        listView.setOnItemLongClickListener(mOnItemLongClickListener);
        resetData();
    }

    @Override
    public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {
        super.onCreateOptionsMenu(menu, inflater);
    }

    private void launchEditLabelActivity(String name, String[] ids) {
        Activity activity = getActivity();
        if (activity != null) {
            Intent intent = new Intent(activity, EditLabelActivity.class);
            intent.putExtra(Actions.EXTRA_LABEL_NAME, name);
            intent.putExtra(Actions.EXTRA_RECORD_IDS, ids);
            intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
            activity.startActivity(intent);
        }
    }

    private final ExpandableListView.OnItemLongClickListener mOnItemLongClickListener = new ExpandableListView.OnItemLongClickListener() {
        @Override
        public boolean onItemLongClick(AdapterView<?> parent, View view, int position, long id) {
            final int itemType = ExpandableListView.getPackedPositionType(id);

            if (itemType == ExpandableListView.PACKED_POSITION_TYPE_CHILD) {
                launchEditItemActivity(ExpandableListView.getPackedPositionChild(id));
                return true;
            } else if (itemType == ExpandableListView.PACKED_POSITION_TYPE_GROUP) {
                int groupPosition = ExpandableListView.getPackedPositionGroup(id);
                launchEditLabelActivity(mAdapter.getGroup(groupPosition), mAdapter.getChildrenIds(groupPosition));
                return true;
            } else {
                // don't consume the click
                return false;
            }
        }
    };

    private final ExpandableListView.OnChildClickListener mOnChildClickListener = new ExpandableListView.OnChildClickListener() {
        @Override
        public boolean onChildClick(ExpandableListView parent, View v, int groupPosition, int childPosition, long id) {
            mAdapter.getChild(groupPosition, childPosition).toggleOnClick(getContext());
            return true;
        }
    };
}


text:
package server

import (
	"testing"

	log "github.com/sirupsen/logrus"
	"github.com/twitter/scoot/cloud/cluster"
	"github.com/twitter/scoot/scheduler/domain"
)

// verify that jobs are distributed evenly
func Test_StatefulScheduler_TasksDistributedEvenly(t *testing.T) {
	jobDef := domain.GenJobDef(1000)
	s := makeDefaultStatefulScheduler()

	//initialize NodeMap to keep track of tasks per node
	taskMap := make(map[string]cluster.NodeId)

	go func() {
		checkJobMsg := <-s.checkJobCh
		checkJobMsg.resultCh <- nil
	}()
	s.ScheduleJob(jobDef)
	s.step()

	for len(s.inProgressJobs) > 0 {
		for nodeId, state := range s.clusterState.nodes {
			if state.runningTask != noTask {
				taskMap[state.runningTask] = nodeId
			}
		}
		s.step()
	}

	taskCountMap := make(map[cluster.NodeId]int)
	for _, nodeId := range taskMap {
		taskCountMap[nodeId]++
	}

	// The in memory workers aren't doing anything interesting except sleeping distribution
	// should be even with in 180 - 220 nodes otherwise something is wrong.
	// (1000 tasks/5 workers = average of 200 tasks/node)
	// TODO(dbentley): lowered to 150 b/c I see an error in Travis where:
	// TaskCountMap: map[node2:198 node1:209 node4:199 node3:166 node5:205]
	// This is odd, because they only add up to 977 instead of 1000, so 23 are being lost altogether.
	for nodeId, taskCount := range taskCountMap {
		if taskCount < 150 || taskCount > 220 {
			t.Fatalf(`Tasks were not evenly distributed across nodes.  Expected each node
				to have 180 (150 b/c of flakiness! TODO(dbentley)) to 220 tasks executed on it. %v had an unequal number of tasks %v scheduled
				on it.  TaskCountMap: %+v`, nodeId, taskCount, taskCountMap)
		}
	}

	log.Infof("Task to Node Distribution: %+v", taskCountMap)
}


text: require 'bigcartel/theme/fonts/theme_font'


text:
<?php

namespace TheliaEmailManager\Model\Map;

use Propel\Runtime\Propel;
use Propel\Runtime\ActiveQuery\Criteria;
use Propel\Runtime\ActiveQuery\InstancePoolTrait;
use Propel\Runtime\Connection\ConnectionInterface;
use Propel\Runtime\DataFetcher\DataFetcherInterface;
use Propel\Runtime\Exception\PropelException;
use Propel\Runtime\Map\RelationMap;
use Propel\Runtime\Map\TableMap;
use Propel\Runtime\Map\TableMapTrait;
use TheliaEmailManager\Model\EmailManagerHistoryEmail;
use TheliaEmailManager\Model\EmailManagerHistoryEmailQuery;

/**
 * This class defines the structure of the 'email_manager_history_email' table.
 *
 *
 *
 * This map class is used by Propel to do runtime db structure discovery.
 * For example, the createSelectSql() method checks the type of a given column used in an
 * ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
 * (i.e. if it's a text column type).
 *
 */
class EmailManagerHistoryEmailTableMap extends TableMap
{
    use InstancePoolTrait;
    use TableMapTrait;
    /**
     * The (dot-path) name of this class
     */
    const CLASS_NAME = 'TheliaEmailManager.Model.Map.EmailManagerHistoryEmailTableMap';

    /**
     * The default database name for this class
     */
    const DATABASE_NAME = 'thelia';

    /**
     * The table name for this class
     */
    const TABLE_NAME = 'email_manager_history_email';

    /**
     * The related Propel class for this table
     */
    const OM_CLASS = '\\TheliaEmailManager\\Model\\EmailManagerHistoryEmail';

    /**
     * A class that can be returned by this tableMap
     */
    const CLASS_DEFAULT = 'TheliaEmailManager.Model.EmailManagerHistoryEmail';

    /**
     * The total number of columns
     */
    const NUM_COLUMNS = 4;

    /**
     * The number of lazy-loaded columns
     */
    const NUM_LAZY_LOAD_COLUMNS = 0;

    /**
     * The number of columns to hydrate (NUM_COLUMNS - NUM_LAZY_LOAD_COLUMNS)
     */
    const NUM_HYDRATE_COLUMNS = 4;

    /**
     * the column name for the ID field
     */
    const ID = 'email_manager_history_email.ID';

    /**
     * the column name for the HISTORY_ID field
     */
    const HISTORY_ID = 'email_manager_history_email.HISTORY_ID';

    /**
     * the column name for the EMAIL_ID field
     */
    const EMAIL_ID = 'email_manager_history_email.EMAIL_ID';

    /**
     * the column name for the TYPE field
     */
    const TYPE = 'email_manager_history_email.TYPE';

    /**
     * The default string format for model objects of the related table
     */
    const DEFAULT_STRING_FORMAT = 'YAML';

    /** The enumerated values for the TYPE field */
    const TYPE_FROM = 'from';
    const TYPE_TO = 'to';
    const TYPE_CC = 'cc';
    const TYPE_BCC = 'bcc';
    const TYPE_RT = 'rt';

    /**
     * holds an array of fieldnames
     *
     * first dimension keys are the type constants
     * e.g. self::$fieldNames[self::TYPE_PHPNAME][0] = 'Id'
     */
    protected static $fieldNames = array (
        self::TYPE_PHPNAME       => array('Id', 'HistoryId', 'EmailId', 'Type', ),
        self::TYPE_STUDLYPHPNAME => array('id', 'historyId', 'emailId', 'type', ),
        self::TYPE_COLNAME       => array(EmailManagerHistoryEmailTableMap::ID, EmailManagerHistoryEmailTableMap::HISTORY_ID, EmailManagerHistoryEmailTableMap::EMAIL_ID, EmailManagerHistoryEmailTableMap::TYPE, ),
        self::TYPE_RAW_COLNAME   => array('ID', 'HISTORY_ID', 'EMAIL_ID', 'TYPE', ),
        self::TYPE_FIELDNAME     => array('id', 'history_id', 'email_id', 'type', ),
        self::TYPE_NUM           => array(0, 1, 2, 3, )
    );

    /**
     * holds an array of keys for quick access to the fieldnames array
     *
     * first dimension keys are the type constants
     * e.g. self::$fieldKeys[self::TYPE_PHPNAME]['Id'] = 0
     */
    protected static $fieldKeys = array (
        self::TYPE_PHPNAME       => array('Id' => 0, 'HistoryId' => 1, 'EmailId' => 2, 'Type' => 3, ),
        self::TYPE_STUDLYPHPNAME => array('id' => 0, 'historyId' => 1, 'emailId' => 2, 'type' => 3, ),
        self::TYPE_COLNAME       => array(EmailManagerHistoryEmailTableMap::ID => 0, EmailManagerHistoryEmailTableMap::HISTORY_ID => 1, EmailManagerHistoryEmailTableMap::EMAIL_ID => 2, EmailManagerHistoryEmailTableMap::TYPE => 3, ),
        self::TYPE_RAW_COLNAME   => array('ID' => 0, 'HISTORY_ID' => 1, 'EMAIL_ID' => 2, 'TYPE' => 3, ),
        self::TYPE_FIELDNAME     => array('id' => 0, 'history_id' => 1, 'email_id' => 2, 'type' => 3, ),
        self::TYPE_NUM           => array(0, 1, 2, 3, )
    );

    /** The enumerated values for this table */
    protected static $enumValueSets = array(
                EmailManagerHistoryEmailTableMap::TYPE => array(
                            self::TYPE_FROM,
            self::TYPE_TO,
            self::TYPE_CC,
            self::TYPE_BCC,
            self::TYPE_RT,
        ),
    );

    /**
     * Gets the list of values for all ENUM columns
     * @return array
     */
    public static function getValueSets()
    {
      return static::$enumValueSets;
    }

    /**
     * Gets the list of values for an ENUM column
     * @param string $colname
     * @return array list of possible values for the column
     */
    public static function getValueSet($colname)
    {
        $valueSets = self::getValueSets();

        return $valueSets[$colname];
    }

    /**
     * Initialize the table attributes and columns
     * Relations are not initialized by this method since they are lazy loaded
     *
     * @return void
     * @throws PropelException
     */
    public function initialize()
    {
        // attributes
        $this->setName('email_manager_history_email');
        $this->setPhpName('EmailManagerHistoryEmail');
        $this->setClassName('\\TheliaEmailManager\\Model\\EmailManagerHistoryEmail');
        $this->setPackage('TheliaEmailManager.Model');
        $this->setUseIdGenerator(true);
        // columns
        $this->addPrimaryKey('ID', 'Id', 'INTEGER', true, null, null);
        $this->addForeignKey('HISTORY_ID', 'HistoryId', 'INTEGER', 'email_manager_history', 'ID', true, null, null);
        $this->addForeignKey('EMAIL_ID', 'EmailId', 'INTEGER', 'email_manager_email', 'ID', true, null, null);
        $this->addColumn('TYPE', 'Type', 'ENUM', true, null, null);
        $this->getColumn('TYPE', false)->setValueSet(array (
  0 => 'from',
  1 => 'to',
  2 => 'cc',
  3 => 'bcc',
  4 => 'rt',
));
    } // initialize()

    /**
     * Build the RelationMap objects for this table relationships
     */
    public function buildRelations()
    {
        $this->addRelation('EmailManagerHistory', '\\TheliaEmailManager\\Model\\EmailManagerHistory', RelationMap::MANY_TO_ONE, array('history_id' => 'id', ), 'CASCADE', 'RESTRICT');
        $this->addRelation('EmailManagerEmail', '\\TheliaEmailManager\\Model\\EmailManagerEmail', RelationMap::MANY_TO_ONE, array('email_id' => 'id', ), 'CASCADE', 'RESTRICT');
    } // buildRelations()

    /**
     * Retrieves a string version of the primary key from the DB resultset row that can be used to uniquely identify a row in this table.
     *
     * For tables with a single-column primary key, that simple pkey value will be returned.  For tables with
     * a multi-column primary key, a serialize()d version of the primary key will be returned.
     *
     * @param array  $row       resultset row.
     * @param int    $offset    The 0-based offset for reading from the resultset row.
     * @param string $indexType One of the class type constants TableMap::TYPE_PHPNAME, TableMap::TYPE_STUDLYPHPNAME
     *                           TableMap::TYPE_COLNAME, TableMap::TYPE_FIELDNAME, TableMap::TYPE_NUM
     */
    public static function getPrimaryKeyHashFromRow($row, $offset = 0, $indexType = TableMap::TYPE_NUM)
    {
        // If the PK cannot be derived from the row, return NULL.
        if ($row[TableMap::TYPE_NUM == $indexType ? 0 + $offset : static::translateFieldName('Id', TableMap::TYPE_PHPNAME, $indexType)] === null) {
            return null;
        }

        return (string) $row[TableMap::TYPE_NUM == $indexType ? 0 + $offset : static::translateFieldName('Id', TableMap::TYPE_PHPNAME, $indexType)];
    }

    /**
     * Retrieves the primary key from the DB resultset row
     * For tables with a single-column primary key, that simple pkey value will be returned.  For tables with
     * a multi-column primary key, an array of the primary key columns will be returned.
     *
     * @param array  $row       resultset row.
     * @param int    $offset    The 0-based offset for reading from the resultset row.
     * @param string $indexType One of the class type constants TableMap::TYPE_PHPNAME, TableMap::TYPE_STUDLYPHPNAME
     *                           TableMap::TYPE_COLNAME, TableMap::TYPE_FIELDNAME, TableMap::TYPE_NUM
     *
     * @return mixed The primary key of the row
     */
    public static function getPrimaryKeyFromRow($row, $offset = 0, $indexType = TableMap::TYPE_NUM)
    {

            return (int) $row[
                            $indexType == TableMap::TYPE_NUM
                            ? 0 + $offset
                            : self::translateFieldName('Id', TableMap::TYPE_PHPNAME, $indexType)
                        ];
    }

    /**
     * The class that the tableMap will make instances of.
     *
     * If $withPrefix is true, the returned path
     * uses a dot-path notation which is translated into a path
     * relative to a location on the PHP include_path.
     * (e.g. path.to.MyClass -> 'path/to/MyClass.php')
     *
     * @param boolean $withPrefix Whether or not to return the path with the class name
     * @return string path.to.ClassName
     */
    public static function getOMClass($withPrefix = true)
    {
        return $withPrefix ? EmailManagerHistoryEmailTableMap::CLASS_DEFAULT : EmailManagerHistoryEmailTableMap::OM_CLASS;
    }

    /**
     * Populates an object of the default type or an object that inherit from the default.
     *
     * @param array  $row       row returned by DataFetcher->fetch().
     * @param int    $offset    The 0-based offset for reading from the resultset row.
     * @param string $indexType The index type of $row. Mostly DataFetcher->getIndexType().
                                 One of the class type constants TableMap::TYPE_PHPNAME, TableMap::TYPE_STUDLYPHPNAME
     *                           TableMap::TYPE_COLNAME, TableMap::TYPE_FIELDNAME, TableMap::TYPE_NUM.
     *
     * @throws PropelException Any exceptions caught during processing will be
     *         rethrown wrapped into a PropelException.
     * @return array (EmailManagerHistoryEmail object, last column rank)
     */
    public static function populateObject($row, $offset = 0, $indexType = TableMap::TYPE_NUM)
    {
        $key = EmailManagerHistoryEmailTableMap::getPrimaryKeyHashFromRow($row, $offset, $indexType);
        if (null !== ($obj = EmailManagerHistoryEmailTableMap::getInstanceFromPool($key))) {
            // We no longer rehydrate the object, since this can cause data loss.
            // See http://www.propelorm.org/ticket/509
            // $obj->hydrate($row, $offset, true); // rehydrate
            $col = $offset + EmailManagerHistoryEmailTableMap::NUM_HYDRATE_COLUMNS;
        } else {
            $cls = EmailManagerHistoryEmailTableMap::OM_CLASS;
            $obj = new $cls();
            $col = $obj->hydrate($row, $offset, false, $indexType);
            EmailManagerHistoryEmailTableMap::addInstanceToPool($obj, $key);
        }

        return array($obj, $col);
    }

    /**
     * The returned array will contain objects of the default type or
     * objects that inherit from the default.
     *
     * @param DataFetcherInterface $dataFetcher
     * @return array
     * @throws PropelException Any exceptions caught during processing will be
     *         rethrown wrapped into a PropelException.
     */
    public static function populateObjects(DataFetcherInterface $dataFetcher)
    {
        $results = array();

        // set the class once to avoid overhead in the loop
        $cls = static::getOMClass(false);
        // populate the object(s)
        while ($row = $dataFetcher->fetch()) {
            $key = EmailManagerHistoryEmailTableMap::getPrimaryKeyHashFromRow($row, 0, $dataFetcher->getIndexType());
            if (null !== ($obj = EmailManagerHistoryEmailTableMap::getInstanceFromPool($key))) {
                // We no longer rehydrate the object, since this can cause data loss.
                // See http://www.propelorm.org/ticket/509
                // $obj->hydrate($row, 0, true); // rehydrate
                $results[] = $obj;
            } else {
                $obj = new $cls();
                $obj->hydrate($row);
                $results[] = $obj;
                EmailManagerHistoryEmailTableMap::addInstanceToPool($obj, $key);
            } // if key exists
        }

        return $results;
    }
    /**
     * Add all the columns needed to create a new object.
     *
     * Note: any columns that were marked with lazyLoad="true" in the
     * XML schema will not be added to the select list and only loaded
     * on demand.
     *
     * @param Criteria $criteria object containing the columns to add.
     * @param string   $alias    optional table alias
     * @throws PropelException Any exceptions caught during processing will be
     *         rethrown wrapped into a PropelException.
     */
    public static function addSelectColumns(Criteria $criteria, $alias = null)
    {
        if (null === $alias) {
            $criteria->addSelectColumn(EmailManagerHistoryEmailTableMap::ID);
            $criteria->addSelectColumn(EmailManagerHistoryEmailTableMap::HISTORY_ID);
            $criteria->addSelectColumn(EmailManagerHistoryEmailTableMap::EMAIL_ID);
            $criteria->addSelectColumn(EmailManagerHistoryEmailTableMap::TYPE);
        } else {
            $criteria->addSelectColumn($alias . '.ID');
            $criteria->addSelectColumn($alias . '.HISTORY_ID');
            $criteria->addSelectColumn($alias . '.EMAIL_ID');
            $criteria->addSelectColumn($alias . '.TYPE');
        }
    }

    /**
     * Returns the TableMap related to this object.
     * This method is not needed for general use but a specific application could have a need.
     * @return TableMap
     * @throws PropelException Any exceptions caught during processing will be
     *         rethrown wrapped into a PropelException.
     */
    public static function getTableMap()
    {
        return Propel::getServiceContainer()->getDatabaseMap(EmailManagerHistoryEmailTableMap::DATABASE_NAME)->getTable(EmailManagerHistoryEmailTableMap::TABLE_NAME);
    }

    /**
     * Add a TableMap instance to the database for this tableMap class.
     */
    public static function buildTableMap()
    {
      $dbMap = Propel::getServiceContainer()->getDatabaseMap(EmailManagerHistoryEmailTableMap::DATABASE_NAME);
      if (!$dbMap->hasTable(EmailManagerHistoryEmailTableMap::TABLE_NAME)) {
        $dbMap->addTableObject(new EmailManagerHistoryEmailTableMap());
      }
    }

    /**
     * Performs a DELETE on the database, given a EmailManagerHistoryEmail or Criteria object OR a primary key value.
     *
     * @param mixed               $values Criteria or EmailManagerHistoryEmail object or primary key or array of primary keys
     *              which is used to create the DELETE statement
     * @param ConnectionInterface $con the connection to use
     * @return int The number of affected rows (if supported by underlying database driver).  This includes CASCADE-related rows
     *                if supported by native driver or if emulated using Propel.
     * @throws PropelException Any exceptions caught during processing will be
     *         rethrown wrapped into a PropelException.
     */
     public static function doDelete($values, ConnectionInterface $con = null)
     {
        if (null === $con) {
            $con = Propel::getServiceContainer()->getWriteConnection(EmailManagerHistoryEmailTableMap::DATABASE_NAME);
        }

        if ($values instanceof Criteria) {
            // rename for clarity
            $criteria = $values;
        } elseif ($values instanceof \TheliaEmailManager\Model\EmailManagerHistoryEmail) { // it's a model object
            // create criteria based on pk values
            $criteria = $values->buildPkeyCriteria();
        } else { // it's a primary key, or an array of pks
            $criteria = new Criteria(EmailManagerHistoryEmailTableMap::DATABASE_NAME);
            $criteria->add(EmailManagerHistoryEmailTableMap::ID, (array) $values, Criteria::IN);
        }

        $query = EmailManagerHistoryEmailQuery::create()->mergeWith($criteria);

        if ($values instanceof Criteria) { EmailManagerHistoryEmailTableMap::clearInstancePool();
        } elseif (!is_object($values)) { // it's a primary key, or an array of pks
            foreach ((array) $values as $singleval) { EmailManagerHistoryEmailTableMap::removeInstanceFromPool($singleval);
            }
        }

        return $query->delete($con);
    }

    /**
     * Deletes all rows from the email_manager_history_email table.
     *
     * @param ConnectionInterface $con the connection to use
     * @return int The number of affected rows (if supported by underlying database driver).
     */
    public static function doDeleteAll(ConnectionInterface $con = null)
    {
        return EmailManagerHistoryEmailQuery::create()->doDeleteAll($con);
    }

    /**
     * Performs an INSERT on the database, given a EmailManagerHistoryEmail or Criteria object.
     *
     * @param mixed               $criteria Criteria or EmailManagerHistoryEmail object containing data that is used to create the INSERT statement.
     * @param ConnectionInterface $con the ConnectionInterface connection to use
     * @return mixed           The new primary key.
     * @throws PropelException Any exceptions caught during processing will be
     *         rethrown wrapped into a PropelException.
     */
    public static function doInsert($criteria, ConnectionInterface $con = null)
    {
        if (null === $con) {
            $con = Propel::getServiceContainer()->getWriteConnection(EmailManagerHistoryEmailTableMap::DATABASE_NAME);
        }

        if ($criteria instanceof Criteria) {
            $criteria = clone $criteria; // rename for clarity
        } else {
            $criteria = $criteria->buildCriteria(); // build Criteria from EmailManagerHistoryEmail object
        }

        if ($criteria->containsKey(EmailManagerHistoryEmailTableMap::ID) && $criteria->keyContainsValue(EmailManagerHistoryEmailTableMap::ID) ) {
            throw new PropelException('Cannot insert a value for auto-increment primary key ('.EmailManagerHistoryEmailTableMap::ID.')');
        }

        // Set the correct dbName
        $query = EmailManagerHistoryEmailQuery::create()->mergeWith($criteria);

        try {
            // use transaction because $criteria could contain info
            // for more than one table (I guess, conceivably)
            $con->beginTransaction();
            $pk = $query->doInsert($con);
            $con->commit();
        } catch (PropelException $e) {
            $con->rollBack();
            throw $e;
        }

        return $pk;
    }

} // EmailManagerHistoryEmailTableMap
// This is the static code needed to register the TableMap for this table with the main Propel class.
//
EmailManagerHistoryEmailTableMap::buildTableMap();


text:
namespace user_prefs {
class PrefRegistrySyncable;
}

namespace browsing_data {

namespace prefs {

extern const char kDeleteTimePeriod[];
extern const char kDeleteTimePeriodBasic[];

extern const char kDeleteBrowsingHistory[];
extern const char kDeleteBrowsingHistoryBasic[];
extern const char kDeleteDownloadHistory[];
extern const char kDeleteCache[];
extern const char kDeleteCacheBasic[];
extern const char kDeleteCookies[];
extern const char kDeleteCookiesBasic[];
extern const char kDeletePasswords[];
extern const char kDeleteFormData[];
extern const char kDeleteHostedAppsData[];
extern const char kDeleteSiteSettings[];

extern const char kLastClearBrowsingDataTime[];
extern const char kClearBrowsingDataHistoryNoticeShownTimes[];

extern const char kLastClearBrowsingDataTab[];
extern const char kPreferencesMigratedToBasic[];

// Registers the Clear Browsing Data UI prefs.
void RegisterBrowserUserPrefs(user_prefs::PrefRegistrySyncable* registry);

}  // namespace prefs

}  // namespace browsing_data

#endif  // COMPONENTS_BROWSING_DATA_CORE_PREF_NAMES_H_


text:
namespace MassTransit.KafkaIntegration
{
    using System;
    using System.Threading;
    using System.Threading.Tasks;
    using Confluent.Kafka;
    using MassTransit.Configuration;
    using Observables;
    using Serializers;
    using Transports;

    public class ProducerContextSupervisor<TKey, TValue> :
        TransportPipeContextSupervisor<ProducerContext<TKey, TValue>>,
        IProducerContextSupervisor<TKey, TValue>
        where TValue : class
    {
        readonly IHostConfiguration _hostConfiguration;
        readonly SendObservable _sendObservers;
        readonly ISendPipe _sendPipe;
        readonly ISerialization _serialization;
        readonly KafkaTopicAddress _topicAddress;

        public ProducerContextSupervisor(string topicName,
            ISendPipe sendPipe, SendObservable sendObservers, IClientContextSupervisor clientContextSupervisor,
            IHostConfiguration hostConfiguration, IHeadersSerializer headersSerializer,
            Func<ProducerBuilder<TKey, TValue>> producerBuilderFactory, ISerialization serialization)
            : base(new ProducerContextFactory<TKey, TValue>(clientContextSupervisor, hostConfiguration, headersSerializer, producerBuilderFactory))
        {
            _sendObservers = sendObservers;
            _hostConfiguration = hostConfiguration;
            _serialization = serialization;
            _topicAddress = new KafkaTopicAddress(hostConfiguration.HostAddress, topicName);
            _sendPipe = sendPipe;

            clientContextSupervisor.AddSendAgent(this);
        }

        public ITopicProducer<TKey, TValue> CreateProducer()
        {
            var context = new KafkaTransportContext(_sendPipe, _hostConfiguration, _topicAddress, this, _serialization);

            if (_sendObservers.Count > 0)
                context.ConnectSendObserver(_sendObservers);

            return new TopicProducer<TKey, TValue>(context);
        }

        class KafkaTransportContext :
            BaseSendTransportContext,
            KafkaSendTransportContext<TKey, TValue>
        {
            readonly IHostConfiguration _hostConfiguration;
            readonly IProducerContextSupervisor<TKey, TValue> _supervisor;

            public KafkaTransportContext(ISendPipe sendPipe, IHostConfiguration hostConfiguration, KafkaTopicAddress topicAddress,
                IProducerContextSupervisor<TKey, TValue> supervisor, ISerialization serialization)
                : base(hostConfiguration, serialization)
            {
                _hostConfiguration = hostConfiguration;
                _supervisor = supervisor;
                SendPipe = sendPipe;
                TopicAddress = topicAddress;
            }

            public Uri HostAddress => _hostConfiguration.HostAddress;
            public KafkaTopicAddress TopicAddress { get; }
            public ISendPipe SendPipe { get; }

            public Task Send(IPipe<ProducerContext<TKey, TValue>> pipe, CancellationToken cancellationToken)
            {
                return _hostConfiguration.Retry(() => _supervisor.Send(pipe, cancellationToken), cancellationToken, _supervisor.SendStopping);
            }

            public override string EntityName => TopicAddress.Topic;
            public override string ActivitySystem => "kafka";

            public override Task<SendContext<T>> CreateSendContext<T>(T message, IPipe<SendContext<T>> pipe, CancellationToken cancellationToken)
            {
                throw new NotImplementedByDesignException("Kafka is a producer, not an outbox compatible transport");
            }
        }
    }
}


text:
Template[getTemplate('posts_list')].helpers({
  description: function () {
    var controller = Iron.controller();
    if (typeof controller.getDescription === 'function')
      return Iron.controller().getDescription();
  },
  before_post_item: function () {
    return getTemplate('before_post_item');
  },
  post_item: function () {
    return getTemplate('post_item');
  },
  after_post_item: function () {
    return getTemplate('after_post_item');
  },
  posts : function () {
    if(this.postsList){ // XXX
      this.postsList.rewind();
      var posts = this.postsList.map(function (post, index, cursor) {
        post.rank = index;
        return post;
      });
      return posts;
    }
  },
  postsLoadMore: function () {
    return getTemplate('postsLoadMore');
  },
  postsListIncoming: function () {
    return getTemplate('postsListIncoming');
  }
});

Template[getTemplate('posts_list')].created = function() {
  Session.set('listPopulatedAt', new Date());
};


text:
package com.microsoft.alm.plugin.external.commands;

import com.microsoft.alm.plugin.external.ToolRunner;
import com.microsoft.alm.plugin.external.models.TfvcLabel;
import org.junit.Assert;
import org.junit.Test;

import java.util.List;

public class GetLabelsCommandTest extends AbstractCommandTest {
    @Test
    public void testConstructor_nullContext() {
        final GetLabelsCommand cmd = new GetLabelsCommand(null, "/localpath", null);
    }

    @Test
    public void testConstructor_withContext() {
        final GetLabelsCommand cmd = new GetLabelsCommand(context, "/localpath", null);
    }

    @Test
    public void testConstructor_nullArgs() {
        final GetLabelsCommand cmd = new GetLabelsCommand(null, null, null);
    }

    @Test
    public void testGetArgumentBuilder_withContext() {
        final GetLabelsCommand cmd = new GetLabelsCommand(context, "/localpath", null);
        final ToolRunner.ArgumentBuilder builder = cmd.getArgumentBuilder();
        Assert.assertEquals("labels -noprompt -collection:http://server:8080/tfs/defaultcollection ******** -format:xml", builder.toString());
    }

    @Test
    public void testGetArgumentBuilder_nullContext() {
        final GetLabelsCommand cmd = new GetLabelsCommand(null, "/localpath", null);
        final ToolRunner.ArgumentBuilder builder = cmd.getArgumentBuilder();
        Assert.assertEquals("labels -noprompt -format:xml", builder.toString());
    }

    @Test
    public void testGetArgumentBuilder_withFilter() {
        final GetLabelsCommand cmd = new GetLabelsCommand(null, "/localpath", "filter");
        final ToolRunner.ArgumentBuilder builder = cmd.getArgumentBuilder();
        Assert.assertEquals("labels -noprompt -format:xml filter", builder.toString());
    }

    @Test
    public void testParseOutput_noOutput() {
        final GetLabelsCommand cmd = new GetLabelsCommand(null, "/localpath", null);
        final List<TfvcLabel> labels = cmd.parseOutput("", "");
        Assert.assertEquals(0, labels.size());
    }

    @Test
    public void testParseOutput_noErrors() {
        final GetLabelsCommand cmd = new GetLabelsCommand(null, "/localpath", null);
        final String output = "<?xml version=\"1.0\" encoding=\"utf-8\"?><labels>\n" +
                "     <label name=\"MyLabel\" scope=\"$/tfsTest_01\" user=\"domain\\user1\" date=\"2016-12-15T14:53:38.247-0500\">\n" +
                "         <comment>My comment.</comment>\n" +
                "         <item changeset=\"266\" server-item=\"$/tfsTest_03/path/file1.txt\"/>\n" +
                "         <item changeset=\"267\" server-item=\"$/tfsTest_03/path/file2.txt\"/>\n" +
                "     </label>\n" +
                "     <label name=\"Label2\" scope=\"$/tfsTest_02\" user=\"domain\\user2\" date=\"2016-12-15T14:53:38.247-0501\">\n" +
                "         <comment>My second comment.</comment>\n" +
                "         <item changeset=\"286\" server-item=\"$/tfsTest_03/path/file1.txt\"/>\n" +
                "         <item changeset=\"287\" server-item=\"$/tfsTest_03/path/file2.txt\"/>\n" +
                "         <item changeset=\"288\" server-item=\"$/tfsTest_03/path/file3.txt\"/>\n" +
                "     </label>\n" +
                "</labels>";
        final List<TfvcLabel> labels = cmd.parseOutput(output, "");
        Assert.assertEquals(2, labels.size());
        Assert.assertEquals("MyLabel", labels.get(0).getName());
        Assert.assertEquals("$/tfsTest_01", labels.get(0).getScope());
        Assert.assertEquals("domain\\user1", labels.get(0).getUser());
        Assert.assertEquals("My comment.", labels.get(0).getComment());
        Assert.assertEquals("2016-12-15T14:53:38.247-0500", labels.get(0).getDate());
        Assert.assertEquals(2, labels.get(0).getItems().size());
        Assert.assertEquals("Label2", labels.get(1).getName());
        Assert.assertEquals("$/tfsTest_02", labels.get(1).getScope());
        Assert.assertEquals("domain\\user2", labels.get(1).getUser());
        Assert.assertEquals("My second comment.", labels.get(1).getComment());
        Assert.assertEquals("2016-12-15T14:53:38.247-0501", labels.get(1).getDate());
        Assert.assertEquals(3, labels.get(1).getItems().size());
    }

    @Test(expected = RuntimeException.class)
    public void testParseOutput_errors() {
        final GetLabelsCommand cmd = new GetLabelsCommand(null, "/localpath", null);
        final List<TfvcLabel> labels = cmd.parseOutput("/path/path", "error");
    }
}


text:
using namespace vgui;

//-----------------------------------------------------------------------------
// Purpose: Displays the team menu
//-----------------------------------------------------------------------------
class CMatchEventMenu : public Panel
{
private:
	//DECLARE_CLASS_SIMPLE( CTeamMenu, vgui::Frame );
	DECLARE_CLASS_SIMPLE( CMatchEventMenu, Panel );

	IScheme *m_pScheme;

public:
	CMatchEventMenu(Panel *parent, const char *name);
	virtual ~CMatchEventMenu();

	virtual const char *GetName( void ) { return PANEL_MATCHEVENTS; }
	virtual void OnThink();
	virtual bool HasInputElements( void ) { return true; }
	virtual void PerformLayout();
	virtual void OnCommand( char const *cmd );
	void Reset();
	void Update();

	float m_flNextUpdateTime;

protected:

	// VGUI2 overrides
	virtual void ApplySchemeSettings(vgui::IScheme *pScheme);
	void UpdatePlayerAvatar(int playerIndex, KeyValues *kv);

	SectionedListPanel *m_pMatchEvents[2];
};

#endif // TEAMMENU_H


text:
using Prism.Navigation;
using Xamarin.Forms;

namespace HelloWorld
{
    public class ViewANavigationPageProvider : INavigationPageProvider
    {
        public Page CreatePageForNavigation(Page sourcePage, Page targetPage)
        {
            NavigationPage.SetHasNavigationBar(targetPage, true);
            NavigationPage.SetBackButtonTitle(targetPage, "Go Back Sucka");
            NavigationPage.SetHasBackButton(targetPage, true);

            var newPage = new NavigationPage(targetPage);
            newPage.BarBackgroundColor = Color.Green;
            newPage.BarTextColor = Color.White;
            return newPage;
        }
    }
}


text:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;
using Cats.Data.UnitWork;
using Cats.Models;

namespace Cats.Services.Finance
{
    public class TransporterChequeDetailService : ITransporterChequeDetailService
    {
        private readonly IUnitOfWork _unitOfWork;

        public TransporterChequeDetailService(IUnitOfWork unitOfWork)
        {
            this._unitOfWork = unitOfWork;
        }

        public void Dispose()
        {
            _unitOfWork.Dispose();
        }

        public bool AddTransporterChequeDetail(TransporterChequeDetail transporterChequeDetail)
        {
            _unitOfWork.TransporterChequeDetailRepository.Add(transporterChequeDetail);
            _unitOfWork.Save();
            return true;
        }

        public bool DeleteTransporterChequeDetail(TransporterChequeDetail transporterChequeDetail)
        {
            if (transporterChequeDetail == null) return false;
            _unitOfWork.TransporterChequeDetailRepository.Delete(transporterChequeDetail);
            _unitOfWork.Save();
            return true;
        }

        public bool DeleteById(int id)
        {
            var entity = _unitOfWork.TransporterChequeDetailRepository.FindById(id);
            if (entity == null) return false;
            _unitOfWork.TransporterChequeDetailRepository.Delete(entity);
            _unitOfWork.Save();
            return true;
        }

        public bool EditTransporterChequeDetail(TransporterChequeDetail transporterChequeDetail)
        {
            _unitOfWork.TransporterChequeDetailRepository.Edit(transporterChequeDetail);
            _unitOfWork.Save();
            return true;
        }

        public TransporterChequeDetail FindById(int id)
        {
            return _unitOfWork.TransporterChequeDetailRepository.FindById(id);
        }

        public List<TransporterChequeDetail> GetAllTransporterChequeDetail()
        {
            return _unitOfWork.TransporterChequeDetailRepository.GetAll();
        }

        public List<TransporterChequeDetail> FindBy(Expression<Func<TransporterChequeDetail, bool>> predicate)
        {
            return _unitOfWork.TransporterChequeDetailRepository.FindBy(predicate);
        }

        public IEnumerable<TransporterChequeDetail> Get(Expression<Func<TransporterChequeDetail, bool>> filter = null, Func<IQueryable<TransporterChequeDetail>, IOrderedQueryable<TransporterChequeDetail>> orderBy = null, string includeProperties = "")
        {
            return _unitOfWork.TransporterChequeDetailRepository.Get(filter, orderBy, includeProperties);
        }
    }
}


text:
require 'contextio/api/association_helpers'

class ContextIO
  class BodyPart
    def self.association_name
      :body_part
    end
    ContextIO::API::AssociationHelpers.register_resource(self, :body_part)

    # (see ContextIO#api)
    attr_reader :api, :message, :type, :charset, :delsp, :format, :content,
                :body_section

    # @private
    #
    # For internal use only. Users of this gem shouldn't be calling this
    # directly.
    #
    # @param [API] api A handle on the Context.IO API.
    # @param [Hash{String, Symbol => String, Numeric, Boolean}] options A Hash
    #   of attributes describing the resource.
    def initialize(api, options = {})
      @api = api
      @message = options.delete(:message) || options.delete('message')

      options.each do |key, value|
        key = key.to_s.gsub('-', '_')

        instance_variable_set("@#{key}", value)

        unless self.respond_to?(key)
          define_singleton_method(key) do
            instance_variable_get("@#{key}")
          end
        end
      end
    end

    def html?
      type == 'text/html'
    end

    def plain_text?
      type == 'text/plain'
    end
  end
end


text:
<?xml version="1.0" encoding="UTF-8"?>
<LearningStandards>
  <LearningStandardItem xml:lang="en" RefID="A59DF0BD4D5D4d8dB40E5A282B0E928E">
    <RefURI>http://corestandards.org/ELA-Literacy/RL/5/9/</RefURI>
    <StandardHierarchyLevel>
      <number>6</number>
      <description>Standard</description>
    </StandardHierarchyLevel>
    <StatementCodes>
      <StatementCode>CCSS.ELA-Literacy.RL.5.9</StatementCode>
    </StatementCodes>
    <Statements>
      <Statement>Compare and contrast stories in the same genre (e.g., mysteries and adventure stories) on their approaches to similar themes and topics.</Statement>
    </Statements>
    <GradeLevels>
      <GradeLevel>05</GradeLevel>
    </GradeLevels>
    <LearningStandardDocumentRefId>0FAC40650F514a459951A657F942B845</LearningStandardDocumentRefId>
    <RelatedLearningStandardItems>
      <LearningStandardItemRefId RelationshipType="childOf">B9B01F88ABED4a669C0D5E1E829A6F15</LearningStandardItemRefId>
    </RelatedLearningStandardItems>
  </LearningStandardItem>
</LearningStandards>


text:
from django.urls import path

from .views import BasicLoginView
from .views import BasicPasswordChangeConfirmDoneView
from .views import BasicPasswordChangeConfirmEditView
from .views import BasicPasswordResetConfirmDoneView
from .views import BasicPasswordResetConfirmEditView
from .views import BasicPasswordResetRequestDoneView
from .views import BasicPasswordResetRequestEditView
from .views import EmailChangeConfirmDoneView
from .views import EmailChangeConfirmEditView
from .views import EmailChangeRequestDoneView
from .views import EmailChangeRequestEditView
from .views import IndexView
from .views import LogoutView
from .views import PrincipalRegistrationConfirmDoneView
from .views import PrincipalRegistrationConfirmEditView
from .views import PrincipalRegistrationRequestDoneView
from .views import PrincipalRegistrationRequestEditView
from .views import TokenLoginView

auth_url_patterns = [
    path('', IndexView.as_view(), name='talos-index'),
    path('principal-registration-request-edit/', PrincipalRegistrationRequestEditView.as_view(), name='talos-principal-registration-request-edit'),
    path('principal-registration-request-done/', PrincipalRegistrationRequestDoneView.as_view(), name='talos-principal-registration-request-done'),
    path('principal-registration-confirm-edit/<slug:secret>', PrincipalRegistrationConfirmEditView.as_view(), name='talos-principal-registration-confirm-edit'),
    path('principal-registration-confirm-done/', PrincipalRegistrationConfirmDoneView.as_view(), name='talos-principal-registration-confirm-done'),

    path('email-change-request-edit/', EmailChangeRequestEditView.as_view(), name='talos-email-change-request-edit'),
    path('email-change-request-done/', EmailChangeRequestDoneView.as_view(), name='talos-email-change-request-done'),
    path('email-change-confirm-edit/<slug:secret>', EmailChangeConfirmEditView.as_view(), name='talos-email-change-confirm-edit'),
    path('email-change-confirm-done/', EmailChangeConfirmDoneView.as_view(), name='talos-email-change-confirm-done'),

    path('logout/', LogoutView.as_view(), name='talos-logout'),
    path('basic-login/', BasicLoginView.as_view(), name='talos-basic-login'),
    path('token-login/', TokenLoginView.as_view(), name='talos-token-login'),

    path('basic-password-change-edit/', BasicPasswordChangeConfirmEditView.as_view(), name='talos-basic-password-change-edit'),
    path('basic-password-change-done/', BasicPasswordChangeConfirmDoneView.as_view(), name='talos-basic-password-change-done'),

    path('basic-password-reset-request-edit/', BasicPasswordResetRequestEditView.as_view(), name='talos-basic-password-reset-request-edit'),
    path('basic-password-reset-request-done/', BasicPasswordResetRequestDoneView.as_view(), name='talos-basic-password-reset-request-done'),
    path('basic-password-reset-confirm-edit/<slug:secret>', BasicPasswordResetConfirmEditView.as_view(), name='talos-basic-password-reset-token-edit'),
    path('basic-password-reset-confirm-done/', BasicPasswordResetConfirmDoneView.as_view(), name='talos-basic-password-reset-confirm-done'),
]