text:
<?php

namespace RadioSolution\ContactBundle\Entity;

use Symfony\Component\Validator\Mapping\ClassMetadata;
use Symfony\Component\Validator\Constraints\NotBlank;
use Symfony\Component\Validator\Constraints\Email;
use Symfony\Component\Validator\Constraints\Length;
use EWZ\Bundle\RecaptchaBundle\Validator\Constraints\IsTrue as Recaptcha;

class Enquiry
{
    protected $name;

    protected $email;

    protected $subject;

    protected $body;

    public $recaptcha;

    protected $company;

    protected $recipient;

    public function getName()
    {
        return $this->name;
    }

    public function setName($name)
    {
        $this->name = $name;
    }

    public function getEmail()
    {
        return $this->email;
    }

    public function setEmail($email)
    {
        $this->email = $email;
    }

    public function getSubject()
    {
        return $this->subject;
    }

    public function setSubject($subject)
    {
        $this->subject = $subject;
    }

    public function getBody()
    {
        return $this->body;
    }

    public function setBody($body)
    {
        $this->body = $body;
    }

    public static function loadValidatorMetadata(ClassMetadata $metadata)
    {
    	$metadata->addPropertyConstraint('name', new NotBlank());

    	$metadata->addPropertyConstraint('email', new Email());

    	$metadata->addPropertyConstraint('subject', new NotBlank());
    	$metadata->addPropertyConstraint('subject', new Length(array('max' => 50)));

    	//$metadata->addPropertyConstraint('body', new Length(array('min' => 10)));
    	$metadata->addPropertyConstraint('recaptcha', new Recaptcha());
    }

    public function getCompany()
    {
        return $this->company;
    }

    public function setCompany($company)
    {
        $this->company = $company;
        return $this;
    }

    public function getRecipient()
    {
        return $this->recipient;
    }

    public function setRecipient($recipient)
    {
        $this->recipient = $recipient;
        return $this;
    }
}


text:
using System;
using System.Collections.Generic;
using Mono.Unix;

using Gtk;
using Cairo;

using Hyena;
using Hyena.Gui;
using Hyena.Gui.Theatrics;

using Banshee.Base;
using Banshee.Collection;
using Banshee.Collection.Gui;
using Banshee.ServiceStack;
using Banshee.MediaEngine;

namespace Banshee.Gui.Widgets
{
    public class CoverArtDisplay : TrackInfoDisplay
    {
        private ImageSurface idle_album;

        public CoverArtDisplay ()
        {
        }

        public override void Dispose ()
        {
            var disposable = idle_album as IDisposable;
            if (disposable != null) {
                disposable.Dispose ();
            }

            base.Dispose ();
        }

        protected override int ArtworkSizeRequest {
            get { return Allocation.Width; }
        }

        protected override void RenderTrackInfo (Cairo.Context cr, TrackInfo track, bool renderTrack, bool renderArtistAlbum)
        {
        }

        protected override bool CanRenderIdle {
            get { return true; }
        }

        protected override void RenderIdle (Cairo.Context cr)
        {
            idle_album = idle_album ?? PixbufImageSurface.Create (Banshee.Gui.IconThemeUtils.LoadIcon (
                ArtworkSizeRequest, MissingAudioIconName), true);

            ArtworkRenderer.RenderThumbnail (cr, idle_album, false, Allocation.X, Allocation.Y,
                ArtworkSizeRequest, ArtworkSizeRequest,
                false, 0, true, BackgroundColor);
        }
    }
}

redpajama_set_name: RedPajamaGithub


text:
/*******************************************************************************
 * Copyright (c) 2014,2021 IBM Corp.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *    http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
/*
 * Contributors:
 *    Rowan Lonsdale - Initial implementation
 *    Various members of the WebSphere MQ Performance Team at IBM Hursley UK
 *******************************************************************************/
/*</copyright>*/
/*******************************************************************************/
/*                                                                             */
/* Performance Harness for IBM MQ C-MQI interface                              */
/*                                                                             */
/*******************************************************************************/

namespace cph {
class MQIConnection;
class MQIObject;
class MQIQueue;
class MQITopic;
class MQISubscription;
class MQIMessage;
class MQIException;
}

#ifndef MQOBJECT_H_
#define MQOBJECT_H_

#include <stdexcept>
#include <string>

#include "MQIOpts.hpp"
#include "MQIWorkerThread.hpp"
#include <cmqc.h>
#include "cphTrace.h"
#include "cphLog.h"

#define CPH_MQC_MSG_LEN 256

namespace cph {

/*
 * Class: MQIConnection
 * -------------------
 *
 * Represents a connection to MQ, backed by an MQHCONN.
 */
class MQIConnection {
friend class MQIObject;
friend class MQIQueue;
friend class MQITopic;
friend class MQISubscription;

private:
  Thread const * const pCurrentThread;
  CPH_TRACE * const pTrc;
  CPH_LOG * const pLog;
  MQIOpts const * const pOpts;
  char const * const name;

  MQHCONN hConn;
  bool ownsConnection;

  mutable char msg[CPH_MQC_MSG_LEN];

public:
  MQIConnection(MQIWorkerThread * const pOwner, bool reconnect);

  MQHMSG createPutMessageHandle(MQMD* md, char* propsBuffer, MQLONG bufferLength) const;
  MQHMSG createGetMessageHandle() const;
  void destroyMessageHandle(MQHMSG& handle) const;

  void commitTransaction() const;
  MQLONG commitTransaction_try() const;
  void rollbackTransaction() const;

  virtual ~MQIConnection();
};

/*
 * Class: MQIMessage
 * ----------------
 *
 * A wrapper around a byte buffer, with meta-data
 * recording the size of the buffer and the length of the message on the buffer,
 */
class MQIMessage {
public:
  /*The message buffer.*/
  MQBYTE * buffer;
  /*The size of the message buffer.*/
  MQLONG bufferLen;
  /*The length of the message on the buffer.*/
  MQLONG messageLen;

  MQIMessage(size_t size);
  MQIMessage(MQIOpts const * const pOpts, bool empty);
  void resize(MQLONG newSize);
  ~MQIMessage();
};

/*
 * Class: MQIException
 * ------------------
 *
 * Used to indicate an MQI call failed.
 * Records the completion code (MQCC)
 * and reason code (MQRC).
 */
class MQIException: public std::runtime_error {
public:
  /*The MQI function that failed.*/
  std::string const function;
  /*The completion code (MQCC) of the error.*/
  MQLONG const compCode;
  /*The reason code (MQRC) of the error.*/
  MQLONG const reasonCode;
  static bool printDetails;

  MQIException(std::string functionName, MQLONG compCode, MQLONG reasonCode, MQBYTE24 id = NULL, const MQCHAR48 qName = NULL);

  virtual ~MQIException() throw();
};

/*
 * Class: MQIObject
 * ----------------
 *
 * A wrapper around an MQHOBJ.
 */
class MQIObject {
  friend class MQIConnection;
  char * selectionString;
protected:
  /*The MQHCONN used to create this object.*/
  MQIConnection const * const pConn;

  /*The associated MQHOBJ.*/
  MQHOBJ hObj;
  MQOD od;

  /*Whether the object was opened to allow putting.*/
  bool const canPut;
  /*Whether the object was opened to allow getting.*/
  bool const canGet;

  inline void checkOpen() const;
  inline void checkNotOpen() const;

public:
  char const * const desc;

  MQIObject(MQIConnection const * const pConnection, MQLONG type, bool put, bool get, char const * const desc);
  virtual ~MQIObject();
  virtual void open(bool log);

  virtual char const * getName() const = 0;
  char const * getQMName() const;
  virtual void setName(char const * const format, ...) = 0;
  void setQMName(char const * const format, ...);
  void setQMName(MQCHAR48 const * qmName);

  void put(MQIMessage const * const msg, MQMD& md, MQPMO& pmo);
  MQLONG put_try(MQIMessage const * const msg, MQMD& md, MQPMO& pmo);
  void put1(MQIMessage const * const msg, MQMD& md, MQPMO& pmo);
  void get(MQIMessage * const msg, MQMD& md, MQGMO& gmo) const;
  MQLONG get_try(MQIMessage * const msg, MQMD& md, MQGMO& gmo) const;

  void createSelector(CPH_TRACE * pTrc, MQBYTE24 correlId, char * customSelector);

};

/*
 * Class: MQIQueue
 * ---------------
 *
 * Extends: MQIObject
 *
 * A wrapper around a queue MQHOBJ.
 */
class MQIQueue : public MQIObject {
public:
  MQIQueue(MQIConnection const * const pConnection, bool put, bool get);
  virtual ~MQIQueue();

  virtual char const * getName() const;
  virtual void setName(char const * const format, ...);
  void setName(MQCHAR48 const * name);
};

/*
 * Class: MQITopic
 * ---------------
 *
 * Extends: MQIObject
 *
 * A wrapper around a topic MQHOBJ.
 */
class MQITopic : public MQIObject {
public:
  MQITopic(MQIConnection const * const pConnection);
  virtual ~MQITopic();

  virtual char const * getName() const;
  virtual void setName(char const * const format, ...);
};

/*
 * Class: MQISubscription
 * ----------------------
 *
 * Extends: MQIObject
 *
 * An extension of MQIObject for handling managed subscriptions to topic strings.
 */
class MQISubscription : public MQIObject {
  friend class MQIConnection;

private:
  MQHOBJ hSub;
  MQSD sd;
  bool unsubscribeOnClose;

public:
  MQISubscription(MQIConnection const * const pConnection);
  virtual ~MQISubscription();
  virtual void open(bool log);

  virtual char const * getName() const;
  virtual void setName(char const * const format, ...);

  char const * getTopicString() const;
  void setTopicString(char const * const format, ...);

  virtual char const * getSubName() const;
  virtual void setSubName(char const * const format, ...);

  virtual void setDurable(bool unsubscribeOnCloseRequired, char const * const subNameFormat, ...);
};

/*
 * Function: bpstrncmp
 * -------------------
 *
 * Equivalent to strncmp, but treat blank-padding
 * and null-termination as equivalent.
 */
inline int bpstrncmp(char const * a, char const * b, size_t len){
  for(size_t i=0; i<len; i++){
    if(a!=NULL && a[i]=='\0') a = NULL;
    if(b!=NULL && b[i]=='\0') b = NULL;
    if(a==NULL && b==NULL) return 0;
    int result = (a==NULL ? ' ' : a[i]) - (b==NULL ? ' ' : b[i]);
    if(result!=0) return result;
  }
  return 0;
}

/*
 * Function: bpstrnlen
 * -------------------
 *
 * Finds the length of a possibly blank-padded string,
 * which is defined as to be one greater than the index of the last
 * non-blank character in the buffer that does not come after a null character,
 * or zero if no such character exists.
 */
inline size_t bpstrnlen(char const * str, size_t bufferLen){
  size_t rc = 0;
  for(size_t i=0; i<bufferLen; i++){
    if(str[i]=='\0') break;
    if(str[i]!=' ') rc = i+1;
  }
  return rc;
}

// printf format specifier for a fixed-width, 32-bit, hexidecimal number
#ifdef CPH_DOTRACE
#define f_id4 "%02X"
#endif

/*
 * Function: cphTraceId
 * --------------------
 *
 * Write an MQBYTE24 (used for message IDs and correlation IDs)
 * to the trace, split into 6 4-byte (8-digit) hexidecimal words.
 */
inline void cphTraceId(CPH_TRACE * const pTrc, char const * const label, MQBYTE24 const id){
#ifdef CPH_DOTRACE
  char convertedId[49] = "";
  int len = 0;

  unsigned char * idd = (unsigned char *)id;
  for (int i = 0; i < 24; ++i){
    len += sprintf(convertedId + len, f_id4, idd[i]);
  }

  CPHTRACEMSG(pTrc, "%s: Bytes: %s", label, convertedId)
#endif
}

/*
 * Macro: CPHCALLMQ
 * ----------------
 *
 * Calls an MQI function, logging a trace message before-hand,
 * and throwing an exception in the event of a failure.
 */
#define CPHCALLMQ(T, F, ...) \
  MQLONG mqcc=0, mqrc=0;\
  CPHTRACEMSG(T, (char*) "About to call %s.", #F)\
  F(__VA_ARGS__, &mqcc, &mqrc);\
  if(mqrc!=MQRC_NONE) {\
    CPHTRACEMSG(T, (char*) "Exception from call: Comp Code:%ld ;Reason: %ld", mqcc, mqrc)\
    throw cph::MQIException(#F, mqcc, mqrc);\
  }\

} /* Namespace */

#endif /* MQOBJECT_H_ */


text:
import NotificationTemplateList from './NotificationTemplateList';

export default NotificationTemplateList;
export { default as NotificationTemplateListItem } from './NotificationTemplateListItem';


text:
'use strict';

var assert = require('chai').assert;
var loopTools = require('../');
var ndloops = require('../plugins/ndloops');

describe('ndloops plugin', function () {
  describe('a for loop over two arrays', function () {
    var code;

    beforeEach(function () {
      code = loopTools.parse(function test (A, B) {
        'ndloop over(A, B)';
        for (var i = 0; i < 10; i++) {
          A[i] += B[i];
        }
      });
    });

    it('locates a for statement', function () {
      code.transform(ndloops({
        onComplete: function () {
          assert.equal(this.loops.length, 1);
          assert.equal(this.loops[0].node.type, 'ForStatement');
        }
      }));
    });

    it('extracts the arrays from the pragma', function () {
      code.transform(ndloops({
        onComplete: function () {
          assert.deepEqual(this.loops[0].pragma.arrayNames, ['A', 'B']);
        }
      }));
    });
  });
});


text:
<?php

namespace Riak\Client\Command\Kv\Builder;

use Riak\Client\Core\Query\RiakLocation;
use Riak\Client\Command\Kv\StoreValue;
use Riak\Client\RiakOption;

/**
 * Used to construct a StoreValue command.
 *
 * @author Fabio B. Silva <fabio.bat.silva@gmail.com>
 */
class StoreValueBuilder extends Builder
{
    /**
     * @var \Riak\Client\Core\Query\RiakLocation
     */
    private $location;

    /**
     * @var \Riak\Client\Core\Query\RiakObject|mixed
     */
    private $value;

    /**
     * @param \Riak\Client\Command\Kv\RiakLocation     $location
     * @param \Riak\Client\Core\Query\RiakObject|mixed $value
     */
    public function __construct(RiakLocation $location = null, $value = null)
    {
        $this->location = $location;
        $this->value    = $value;
    }

    /**
     * @param \Riak\Client\Core\Query\RiakLocation $location
     *
     * @return \Riak\Client\Command\Kv\Builder\StoreValueBuilder
     */
    public function withLocation(RiakLocation $location)
    {
        $this->location = $location;

        return $this;
    }

    /**
     * @param \Riak\Client\Core\Query\RiakObject|mixed $value
     *
     * @return \Riak\Client\Command\Kv\Builder\StoreValueBuilder
     */
    public function withValue($value)
    {
        $this->value = $value;

        return $this;
    }

    /**
     * Set the pw value.
     *
     * @param integer $pw
     *
     * @return \Riak\Client\Command\Kv\Builder\StoreValueBuilder
     */
    public function withPw($pw)
    {
        return $this->withOption(RiakOption::PW, $pw);
    }

    /**
     * Set the dw value.
     *
     * @param integer $dw
     *
     * @return \Riak\Client\Command\Kv\Builder\StoreValueBuilder
     */
    public function withDw($dw)
    {
        return $this->withOption(RiakOption::DW, $dw);
    }

    /**
     * Set the w value.
     *
     * @param integer $w
     *
     * @return \Riak\Client\Command\Kv\Builder\StoreValueBuilder
     */
    public function withW($w)
    {
        return $this->withOption(RiakOption::W, $w);
    }

    /**
     * Set the returnbody value.
     *
     * @param integer $flag
     *
     * @return \Riak\Client\Command\Kv\Builder\StoreValueBuilder
     */
    public function withReturnBody($flag)
    {
        return $this->withOption(RiakOption::RETURN_BODY, $flag);
    }

    /**
     * Build a FetchValue object
     *
     * @return \Riak\Client\Command\Kv\StoreValue
     */
    public function build()
    {
        return new StoreValue($this->location, $this->value, $this->options);
    }
}


text:
Organizing Tests: Page Objects
-----------------------------------

When writing test scripts for the pages of your application, it's best to use the [Page Objects](https://code.google.com/p/selenium/wiki/PageObjects) pattern to organize and make your tests more readable.

In Protractor, this could look like:

```javascript
var AngularHomepage = function() {
  this.nameInput = element(by.model('yourName'));
  this.greeting = element(by.binding('yourName'));

  this.get = function() {
    browser.get('http://www.angularjs.org');
  };

  this.setName = function(name) {
    this.nameInput.sendKeys(name);
  };
};
```

Your test then becomes:

```javascript
describe('angularjs homepage', function() {
  it('should greet the named user', function() {
    var angularHomepage = new AngularHomepage();
    angularHomepage.get();

    angularHomepage.setName('Julie');

    expect(angularHomepage.greeting.getText()).toEqual('Hello Julie!');
  });
});
```

It is possible to separate your tests in various test suites. The configuration becomes:

```javascript
// An example configuration file.
exports.config = {
  // The address of a running selenium server.
  seleniumAddress: 'http://localhost:4444/wd/hub',

  // Capabilities to be passed to the webdriver instance.
  capabilities: {
    'browserName': 'chrome'
  },

  // Spec patterns are relative to the location of the spec file. They may
  // include glob patterns.
  suites: {
    homepage: 'tests/e2e/homepage/**/*Spec.js',
    search: ['tests/e2e/contact_search/**/*Spec.js',
      'tests/e2e/venue_search/**/*Spec.js']
  },

  // Options to be passed to Jasmine-node.
  jasmineNodeOpts: {
    showColors: true, // Use colors in the command line report.
  }
};
```

You can then easily switch from the command line between running one or the other suite of tests. This will only run the homepage section of the tests:

    protractor protractor.conf.js --suite homepage


text:
namespace DAL.Migrations
{
    using System;
    using System.Data.Entity.Migrations;

    public partial class PersonPropTypes : DbMigration
    {
        public override void Up()
        {
            AlterColumn("dbo.People", "Login", c => c.String());
            AlterColumn("dbo.People", "Password", c => c.String());
        }

        public override void Down()
        {
            AlterColumn("dbo.People", "Password", c => c.Int(nullable: false));
            AlterColumn("dbo.People", "Login", c => c.Int(nullable: false));
        }
    }
}


text:
package org.lambda.query;

import org.lambda.functions.Function1;

import java.util.Collection;
import java.util.HashMap;
import java.util.Map;

public class Counter<T>
{
  private final Map<T, Integer> counts = new HashMap<>();
  public <O> void countAll(Collection<O> collection, Function1<O, T> extractor)
  {
    Query.select(collection, extractor).forEach(this::count);
  }
  public void count(T value)
  {
    Integer count = counts.computeIfAbsent(value, x -> 0) + 1;
    counts.put(value, count);
  }
  public T getMaxValue()
  {
    if (counts.isEmpty())
    { return null; }
    return Query.max(counts.entrySet(), Map.Entry::getValue).getKey();
  }
  public static <In, Out> Out getMaxValue(Collection<In> collection, Function1<In, Out> extractor)
  {
    Counter<Out> counter = new Counter<>();
    counter.countAll(collection, extractor);
    return counter.getMaxValue();
  }
}


text:
<?php

namespace Google\Service\BeyondCorp;

class ListAppGatewaysResponse extends \Google\Collection
{
  protected $collection_key = 'unreachable';
  protected $appGatewaysType = AppGateway::class;
  protected $appGatewaysDataType = 'array';
  /**
   * @var string
   */
  public $nextPageToken;
  /**
   * @var string[]
   */
  public $unreachable;

  /**
   * @param AppGateway[]
   */
  public function setAppGateways($appGateways)
  {
    $this->appGateways = $appGateways;
  }
  /**
   * @return AppGateway[]
   */
  public function getAppGateways()
  {
    return $this->appGateways;
  }
  /**
   * @param string
   */
  public function setNextPageToken($nextPageToken)
  {
    $this->nextPageToken = $nextPageToken;
  }
  /**
   * @return string
   */
  public function getNextPageToken()
  {
    return $this->nextPageToken;
  }
  /**
   * @param string[]
   */
  public function setUnreachable($unreachable)
  {
    $this->unreachable = $unreachable;
  }
  /**
   * @return string[]
   */
  public function getUnreachable()
  {
    return $this->unreachable;
  }
}

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


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

<TITLE>
MiPropertyChange
</TITLE>

<META NAME="keywords" CONTENT="com.swfm.mica.MiPropertyChange class">

<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">

      Package
    Class
      Tree
      Deprecated
      Index
      Help

 PREV CLASS
 NEXT CLASS

  FRAMES
 NO FRAMES

  All Classes

  SUMMARY: NESTED | FIELD | CONSTR | METHOD

DETAIL: FIELD | CONSTR | METHOD

com.swfm.mica

Class MiPropertyChange

java.lang.Object
  com.swfm.mica.MiPropertyChange

public class MiPropertyChange
extends java.lang.Object

Version:

%I% %G%

Author:

Michael L. Davis

Constructor Summary

MiPropertyChange()

MiPropertyChange(MiiModelEntity source,
                 java.lang.String propertyName,
                 java.lang.String propertyValue,
                 java.lang.String oldPropertyValue)

Method Summary

static void
freePropertyChange(MiPropertyChange event)

 java.lang.String
getOldPropertyValue()

 MiModelChangePhase
getPhase()

 java.lang.String
getPropertyName()

 java.lang.String
getPropertyValue()

 MiiModelEntity
getSource()

 MiValueValidationError
getVetoMessage()

 boolean
isVetoed()

static MiPropertyChange
newPropertyChange()

static MiPropertyChange
newPropertyChange(MiiModelEntity source,
                  java.lang.String name,
                  java.lang.String value,
                  java.lang.String oldValue)

 void
setOldPropertyValue(java.lang.String value)

 void
setPhase(MiModelChangePhase phase)

 void
setPropertyValue(java.lang.String value)

 void
setVetoed(boolean flag)

 void
setVetoMessage(MiValueValidationError msg)

 java.lang.String
toString()

 void
veto()

Methods inherited from class java.lang.Object

equals, getClass, hashCode, notify, notifyAll, wait, wait, wait

Constructor Detail

MiPropertyChange

public MiPropertyChange()

MiPropertyChange

public MiPropertyChange(MiiModelEntity source,
                        java.lang.String propertyName,
                        java.lang.String propertyValue,
                        java.lang.String oldPropertyValue)

Method Detail

getSource

public MiiModelEntity getSource()

getPhase

public MiModelChangePhase getPhase()

setPhase

public void setPhase(MiModelChangePhase phase)

veto

public void veto()

isVetoed

public boolean isVetoed()

setVetoed

public void setVetoed(boolean flag)

setVetoMessage

public void setVetoMessage(MiValueValidationError msg)

getVetoMessage

public MiValueValidationError getVetoMessage()

getPropertyName

public java.lang.String getPropertyName()

setPropertyValue

public void setPropertyValue(java.lang.String value)

getPropertyValue

public java.lang.String getPropertyValue()

setOldPropertyValue

public void setOldPropertyValue(java.lang.String value)

getOldPropertyValue

public java.lang.String getOldPropertyValue()

newPropertyChange

public static MiPropertyChange newPropertyChange(MiiModelEntity source,
                                                 java.lang.String name,
                                                 java.lang.String value,
                                                 java.lang.String oldValue)

newPropertyChange

public static MiPropertyChange newPropertyChange()

freePropertyChange

public static void freePropertyChange(MiPropertyChange event)

toString

public java.lang.String toString()

      Package
    Class
      Tree
      Deprecated
      Index
      Help

 PREV CLASS
 NEXT CLASS

  FRAMES
 NO FRAMES

  All Classes

  SUMMARY: NESTED | FIELD | CONSTR | METHOD

DETAIL: FIELD | CONSTR | METHOD


text:
<script type="text/javascript">
// Set the dimensions of the canvas / graph

var margin = {top: 30, right: 50, bottom: 30, left: 50},
    width = screen.width/2- margin.left - margin.right,
    height = screen.height/2 - margin.top - margin.bottom;

// Parse the date / time
var parseDate = d3.time.format("%d-%b-%y").parse;

// Set the ranges
var x = d3.time.scale().range([0, width]);
var y = d3.scale.linear().range([height, 0]);

// Define the axes
var xAxis = d3.svg.axis().scale(x)
    .orient("bottom"); // labels will appear below the axis line

var yAxis = d3.svg.axis().scale(y)
    .orient("left");

// Define the line
var valueline = d3.svg.line()
    .x(function(d) { return x(d.date); })
    .y(function(d) { return y(d.close); });

// Adds the svg canvas
var svg = d3.select("#graph")
    .append("svg")
        .attr("width", width + margin.left + margin.right)
        .attr("height", height + margin.top + margin.bottom)
    .append("g") //group the svg shapes
        .attr("transform",
              "translate(" + margin.left + "," + margin.top + ")");

// Get the data
d3.tsv("data.tsv", function(error, data) {
    data.forEach(function(d) {
        d.date = parseDate(d.date);
        d.close = +d.close;
    });

    // Scale the range of the data
    x.domain(d3.extent(data, function(d) { return d.date; }));
    y.domain([0, d3.max(data, function(d) { return d.close; })]);

    // Add the valueline path.
    svg.append("path")
        .attr("class", "line")
        .attr("d", valueline(data));

    // Add the X Axis
    svg.append("g")
        .attr("class", "x axis")
        .attr("transform", "translate(0," + height + ")")
        .call(xAxis);

    // Add the Y Axis
    svg.append("g")
        .attr("class", "y axis")
        .call(yAxis);

    // Add the title
    svg.append("text")
       .attr("class", "title")
       .attr("x", (width / 2))
       .attr("y", 0 - (margin.top / 2))
       .attr("text-anchor", "middle")
       .text("AAPL stock vs Time");

});

</script>


text:
package com.neovisionaries.jdo;

import javax.jdo.PersistenceManager;

/**
 * Task executed by {@link TaskExecutor}.
 *
 * <p>
 * {@link TransactionAwareTask} is an interface which inherits this interface.
 * {@link TaskAdapter} is an empty implementation of the {@code TransactionAwareTask}
 * interface.
 * </p>
 *
 * @since 1.2
 *
 * @author Takahiko Kawasaki
 */
public interface Task
{
    /**
     * Task body.
     *
     * @param manager
     *         A persistence manager.
     *
     * @return
     *         Any arbitrary object. The object returned by
     *         this method is returned from {@link TaskExecutor}'s
     *         {@code execute} methods. {@code TaskExecutor} does
     *         not care about what the object is. Even {@code null}
     *         is OK.
     */
    public Object run(PersistenceManager manager);
}


text:
.class public Lorg/apache/cordova/CordovaWebViewImpl;
.super Ljava/lang/Object;
.source "CordovaWebViewImpl.java"

# interfaces
.implements Lorg/apache/cordova/CordovaWebView;

# annotations
.annotation system Ldalvik/annotation/MemberClasses;
    value = {
        Lorg/apache/cordova/CordovaWebViewImpl$EngineClient;
    }
.end annotation

# static fields
.field static final synthetic $assertionsDisabled:Z

.field public static final TAG:Ljava/lang/String; = "CordovaWebViewImpl"

# instance fields
.field private appPlugin:Lorg/apache/cordova/CoreAndroid;

.field private boundKeyCodes:Ljava/util/Set;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Ljava/util/Set",
            "<",
            "Ljava/lang/Integer;",
            ">;"
        }
    .end annotation
.end field

.field private cordova:Lorg/apache/cordova/CordovaInterface;

.field protected final engine:Lorg/apache/cordova/CordovaWebViewEngine;

.field private engineClient:Lorg/apache/cordova/CordovaWebViewImpl$EngineClient;

.field private hasPausedEver:Z

.field private loadUrlTimeout:I

.field loadedUrl:Ljava/lang/String;

.field private mCustomView:Landroid/view/View;

.field private mCustomViewCallback:Landroid/webkit/WebChromeClient$CustomViewCallback;

.field private nativeToJsMessageQueue:Lorg/apache/cordova/NativeToJsMessageQueue;

.field private pluginManager:Lorg/apache/cordova/PluginManager;

.field private preferences:Lorg/apache/cordova/CordovaPreferences;

.field private resourceApi:Lorg/apache/cordova/CordovaResourceApi;

# direct methods
.method static constructor <clinit>()V
    .locals 1

    .prologue
    .line 47
    const-class v0, Lorg/apache/cordova/CordovaWebViewImpl;

    invoke-virtual {v0}, Ljava/lang/Class;->desiredAssertionStatus()Z

    move-result v0

    if-nez v0, :cond_0

    const/4 v0, 0x1

    :goto_0
    sput-boolean v0, Lorg/apache/cordova/CordovaWebViewImpl;->$assertionsDisabled:Z

    return-void

    :cond_0
    const/4 v0, 0x0

    goto :goto_0
.end method

.method public constructor <init>(Lorg/apache/cordova/CordovaWebViewEngine;)V
    .locals 1
    .param p1, "cordovaWebViewEngine"    # Lorg/apache/cordova/CordovaWebViewEngine;

    .prologue
    .line 86
    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    .line 57
    const/4 v0, 0x0

    iput v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->loadUrlTimeout:I

    .line 63
    new-instance v0, Lorg/apache/cordova/CordovaWebViewImpl$EngineClient;

    invoke-direct {v0, p0}, Lorg/apache/cordova/CordovaWebViewImpl$EngineClient;-><init>(Lorg/apache/cordova/CordovaWebViewImpl;)V

    iput-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engineClient:Lorg/apache/cordova/CordovaWebViewImpl$EngineClient;

    .line 73
    new-instance v0, Ljava/util/HashSet;

    invoke-direct {v0}, Ljava/util/HashSet;-><init>()V

    iput-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->boundKeyCodes:Ljava/util/Set;

    .line 87
    iput-object p1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    .line 88
    return-void
.end method

.method static synthetic access$000(Lorg/apache/cordova/CordovaWebViewImpl;)Lorg/apache/cordova/PluginManager;
    .locals 1
    .param p0, "x0"    # Lorg/apache/cordova/CordovaWebViewImpl;

    .prologue
    .line 47
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    return-object v0
.end method

.method static synthetic access$100(Lorg/apache/cordova/CordovaWebViewImpl;)I
    .locals 1
    .param p0, "x0"    # Lorg/apache/cordova/CordovaWebViewImpl;

    .prologue
    .line 47
    iget v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->loadUrlTimeout:I

    return v0
.end method

.method static synthetic access$108(Lorg/apache/cordova/CordovaWebViewImpl;)I
    .locals 2
    .param p0, "x0"    # Lorg/apache/cordova/CordovaWebViewImpl;

    .prologue
    .line 47
    iget v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->loadUrlTimeout:I

    add-int/lit8 v1, v0, 0x1

    iput v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->loadUrlTimeout:I

    return v0
.end method

.method static synthetic access$200(Lorg/apache/cordova/CordovaWebViewImpl;)Lorg/apache/cordova/CordovaInterface;
    .locals 1
    .param p0, "x0"    # Lorg/apache/cordova/CordovaWebViewImpl;

    .prologue
    .line 47
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->cordova:Lorg/apache/cordova/CordovaInterface;

    return-object v0
.end method

.method static synthetic access$300(Lorg/apache/cordova/CordovaWebViewImpl;)Ljava/util/Set;
    .locals 1
    .param p0, "x0"    # Lorg/apache/cordova/CordovaWebViewImpl;

    .prologue
    .line 47
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->boundKeyCodes:Ljava/util/Set;

    return-object v0
.end method

.method static synthetic access$400(Lorg/apache/cordova/CordovaWebViewImpl;)Landroid/view/View;
    .locals 1
    .param p0, "x0"    # Lorg/apache/cordova/CordovaWebViewImpl;

    .prologue
    .line 47
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->mCustomView:Landroid/view/View;

    return-object v0
.end method

.method static synthetic access$500(Lorg/apache/cordova/CordovaWebViewImpl;Ljava/lang/String;)V
    .locals 0
    .param p0, "x0"    # Lorg/apache/cordova/CordovaWebViewImpl;
    .param p1, "x1"    # Ljava/lang/String;

    .prologue
    .line 47
    invoke-direct {p0, p1}, Lorg/apache/cordova/CordovaWebViewImpl;->sendJavascriptEvent(Ljava/lang/String;)V

    return-void
.end method

.method public static createEngine(Landroid/content/Context;Lorg/apache/cordova/CordovaPreferences;)Lorg/apache/cordova/CordovaWebViewEngine;
    .locals 7
    .param p0, "context"    # Landroid/content/Context;
    .param p1, "preferences"    # Lorg/apache/cordova/CordovaPreferences;

    .prologue
    .line 76
    const-string v4, "webview"

    const-class v5, Lorg/apache/cordova/engine/SystemWebViewEngine;

    invoke-virtual {v5}, Ljava/lang/Class;->getCanonicalName()Ljava/lang/String;

    move-result-object v5

    invoke-virtual {p1, v4, v5}, Lorg/apache/cordova/CordovaPreferences;->getString(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v0

    .line 78
    .local v0, "className":Ljava/lang/String;
    :try_start_0
    invoke-static {v0}, Ljava/lang/Class;->forName(Ljava/lang/String;)Ljava/lang/Class;

    move-result-object v3

    .line 79
    .local v3, "webViewClass":Ljava/lang/Class;, "Ljava/lang/Class<*>;"
    const/4 v4, 0x2

    new-array v4, v4, [Ljava/lang/Class;

    const/4 v5, 0x0

    const-class v6, Landroid/content/Context;

    aput-object v6, v4, v5

    const/4 v5, 0x1

    const-class v6, Lorg/apache/cordova/CordovaPreferences;

    aput-object v6, v4, v5

    invoke-virtual {v3, v4}, Ljava/lang/Class;->getConstructor([Ljava/lang/Class;)Ljava/lang/reflect/Constructor;

    move-result-object v1

    .line 80
    .local v1, "constructor":Ljava/lang/reflect/Constructor;, "Ljava/lang/reflect/Constructor<*>;"
    const/4 v4, 0x2

    new-array v4, v4, [Ljava/lang/Object;

    const/4 v5, 0x0

    aput-object p0, v4, v5

    const/4 v5, 0x1

    aput-object p1, v4, v5

    invoke-virtual {v1, v4}, Ljava/lang/reflect/Constructor;->newInstance([Ljava/lang/Object;)Ljava/lang/Object;

    move-result-object v4

    check-cast v4, Lorg/apache/cordova/CordovaWebViewEngine;
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    return-object v4

    .line 81
    .end local v1    # "constructor":Ljava/lang/reflect/Constructor;, "Ljava/lang/reflect/Constructor<*>;"
    .end local v3    # "webViewClass":Ljava/lang/Class;, "Ljava/lang/Class<*>;"
    :catch_0
    move-exception v2

    .line 82
    .local v2, "e":Ljava/lang/Exception;
    new-instance v4, Ljava/lang/RuntimeException;

    const-string v5, "Failed to create webview. "

    invoke-direct {v4, v5, v2}, Ljava/lang/RuntimeException;-><init>(Ljava/lang/String;Ljava/lang/Throwable;)V

    throw v4
.end method

.method private sendJavascriptEvent(Ljava/lang/String;)V
    .locals 2
    .param p1, "event"    # Ljava/lang/String;

    .prologue
    .line 341
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->appPlugin:Lorg/apache/cordova/CoreAndroid;

    if-nez v0, :cond_0

    .line 342
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    const-string v1, "CoreAndroid"

    invoke-virtual {v0, v1}, Lorg/apache/cordova/PluginManager;->getPlugin(Ljava/lang/String;)Lorg/apache/cordova/CordovaPlugin;

    move-result-object v0

    check-cast v0, Lorg/apache/cordova/CoreAndroid;

    iput-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->appPlugin:Lorg/apache/cordova/CoreAndroid;

    .line 345
    :cond_0
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->appPlugin:Lorg/apache/cordova/CoreAndroid;

    if-nez v0, :cond_1

    .line 346
    const-string v0, "CordovaWebViewImpl"

    const-string v1, "Unable to fire event without existing plugin"

    invoke-static {v0, v1}, Lorg/apache/cordova/LOG;->w(Ljava/lang/String;Ljava/lang/String;)V

    .line 350
    :goto_0
    return-void

    .line 349
    :cond_1
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->appPlugin:Lorg/apache/cordova/CoreAndroid;

    invoke-virtual {v0, p1}, Lorg/apache/cordova/CoreAndroid;->fireJavascriptEvent(Ljava/lang/String;)V

    goto :goto_0
.end method

# virtual methods
.method public backHistory()Z
    .locals 1

    .prologue
    .line 416
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v0}, Lorg/apache/cordova/CordovaWebViewEngine;->goBack()Z

    move-result v0

    return v0
.end method

.method public canGoBack()Z
    .locals 1

    .prologue
    .line 395
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v0}, Lorg/apache/cordova/CordovaWebViewEngine;->canGoBack()Z

    move-result v0

    return v0
.end method

.method public clearCache()V
    .locals 1

    .prologue
    .line 400
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v0}, Lorg/apache/cordova/CordovaWebViewEngine;->clearCache()V

    .line 401
    return-void
.end method

.method public clearCache(Z)V
    .locals 1
    .param p1, "b"    # Z
    .annotation runtime Ljava/lang/Deprecated;
    .end annotation

    .prologue
    .line 406
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v0}, Lorg/apache/cordova/CordovaWebViewEngine;->clearCache()V

    .line 407
    return-void
.end method

.method public clearHistory()V
    .locals 1

    .prologue
    .line 411
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v0}, Lorg/apache/cordova/CordovaWebViewEngine;->clearHistory()V

    .line 412
    return-void
.end method

.method public getContext()Landroid/content/Context;
    .locals 1

    .prologue
    .line 337
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v0}, Lorg/apache/cordova/CordovaWebViewEngine;->getView()Landroid/view/View;

    move-result-object v0

    invoke-virtual {v0}, Landroid/view/View;->getContext()Landroid/content/Context;

    move-result-object v0

    return-object v0
.end method

.method public getCookieManager()Lorg/apache/cordova/ICordovaCookieManager;
    .locals 1

    .prologue
    .line 321
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v0}, Lorg/apache/cordova/CordovaWebViewEngine;->getCookieManager()Lorg/apache/cordova/ICordovaCookieManager;

    move-result-object v0

    return-object v0
.end method

.method public getEngine()Lorg/apache/cordova/CordovaWebViewEngine;
    .locals 1

    .prologue
    .line 329
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    return-object v0
.end method

.method public getPluginManager()Lorg/apache/cordova/PluginManager;
    .locals 1

    .prologue
    .line 313
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    return-object v0
.end method

.method public getPreferences()Lorg/apache/cordova/CordovaPreferences;
    .locals 1

    .prologue
    .line 317
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->preferences:Lorg/apache/cordova/CordovaPreferences;

    return-object v0
.end method

.method public getResourceApi()Lorg/apache/cordova/CordovaResourceApi;
    .locals 1

    .prologue
    .line 325
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->resourceApi:Lorg/apache/cordova/CordovaResourceApi;

    return-object v0
.end method

.method public getUrl()Ljava/lang/String;
    .locals 1

    .prologue
    .line 384
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v0}, Lorg/apache/cordova/CordovaWebViewEngine;->getUrl()Ljava/lang/String;

    move-result-object v0

    return-object v0
.end method

.method public getView()Landroid/view/View;
    .locals 1

    .prologue
    .line 333
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v0}, Lorg/apache/cordova/CordovaWebViewEngine;->getView()Landroid/view/View;

    move-result-object v0

    return-object v0
.end method

.method public handleDestroy()V
    .locals 1

    .prologue
    .line 474
    invoke-virtual {p0}, Lorg/apache/cordova/CordovaWebViewImpl;->isInitialized()Z

    move-result v0

    if-nez v0, :cond_0

    .line 490
    :goto_0
    return-void

    .line 478
    :cond_0
    iget v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->loadUrlTimeout:I

    add-int/lit8 v0, v0, 0x1

    iput v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->loadUrlTimeout:I

    .line 481
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    invoke-virtual {v0}, Lorg/apache/cordova/PluginManager;->onDestroy()V

    .line 485
    const-string v0, "about:blank"

    invoke-virtual {p0, v0}, Lorg/apache/cordova/CordovaWebViewImpl;->loadUrl(Ljava/lang/String;)V

    .line 488
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v0}, Lorg/apache/cordova/CordovaWebViewEngine;->destroy()V

    .line 489
    invoke-virtual {p0}, Lorg/apache/cordova/CordovaWebViewImpl;->hideCustomView()V

    goto :goto_0
.end method

.method public handlePause(Z)V
    .locals 2
    .param p1, "keepRunning"    # Z

    .prologue
    const/4 v1, 0x1

    .line 428
    invoke-virtual {p0}, Lorg/apache/cordova/CordovaWebViewImpl;->isInitialized()Z

    move-result v0

    if-nez v0, :cond_1

    .line 440
    :cond_0
    :goto_0
    return-void

    .line 431
    :cond_1
    iput-boolean v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->hasPausedEver:Z

    .line 432
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    invoke-virtual {v0, p1}, Lorg/apache/cordova/PluginManager;->onPause(Z)V

    .line 433
    const-string v0, "pause"

    invoke-direct {p0, v0}, Lorg/apache/cordova/CordovaWebViewImpl;->sendJavascriptEvent(Ljava/lang/String;)V

    .line 436
    if-nez p1, :cond_0

    .line 438
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v0, v1}, Lorg/apache/cordova/CordovaWebViewEngine;->setPaused(Z)V

    goto :goto_0
.end method

.method public handleResume(Z)V
    .locals 2
    .param p1, "keepRunning"    # Z

    .prologue
    .line 443
    invoke-virtual {p0}, Lorg/apache/cordova/CordovaWebViewImpl;->isInitialized()Z

    move-result v0

    if-nez v0, :cond_1

    .line 457
    :cond_0
    :goto_0
    return-void

    .line 448
    :cond_1
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    const/4 v1, 0x0

    invoke-interface {v0, v1}, Lorg/apache/cordova/CordovaWebViewEngine;->setPaused(Z)V

    .line 449
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    invoke-virtual {v0, p1}, Lorg/apache/cordova/PluginManager;->onResume(Z)V

    .line 454
    iget-boolean v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->hasPausedEver:Z

    if-eqz v0, :cond_0

    .line 455
    const-string v0, "resume"

    invoke-direct {p0, v0}, Lorg/apache/cordova/CordovaWebViewImpl;->sendJavascriptEvent(Ljava/lang/String;)V

    goto :goto_0
.end method

.method public handleStart()V
    .locals 1

    .prologue
    .line 460
    invoke-virtual {p0}, Lorg/apache/cordova/CordovaWebViewImpl;->isInitialized()Z

    move-result v0

    if-nez v0, :cond_0

    .line 464
    :goto_0
    return-void

    .line 463
    :cond_0
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    invoke-virtual {v0}, Lorg/apache/cordova/PluginManager;->onStart()V

    goto :goto_0
.end method

.method public handleStop()V
    .locals 1

    .prologue
    .line 467
    invoke-virtual {p0}, Lorg/apache/cordova/CordovaWebViewImpl;->isInitialized()Z

    move-result v0

    if-nez v0, :cond_0

    .line 471
    :goto_0
    return-void

    .line 470
    :cond_0
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    invoke-virtual {v0}, Lorg/apache/cordova/PluginManager;->onStop()V

    goto :goto_0
.end method

.method public hideCustomView()V
    .locals 3
    .annotation runtime Ljava/lang/Deprecated;
    .end annotation

    .prologue
    .line 278
    iget-object v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->mCustomView:Landroid/view/View;

    if-nez v1, :cond_0

    .line 292
    :goto_0
    return-void

    .line 279
    :cond_0
    const-string v1, "CordovaWebViewImpl"

    const-string v2, "Hiding Custom View"

    invoke-static {v1, v2}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 282
    iget-object v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->mCustomView:Landroid/view/View;

    const/16 v2, 0x8

    invoke-virtual {v1, v2}, Landroid/view/View;->setVisibility(I)V

    .line 285
    iget-object v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v1}, Lorg/apache/cordova/CordovaWebViewEngine;->getView()Landroid/view/View;

    move-result-object v1

    invoke-virtual {v1}, Landroid/view/View;->getParent()Landroid/view/ViewParent;

    move-result-object v0

    check-cast v0, Landroid/view/ViewGroup;

    .line 286
    .local v0, "parent":Landroid/view/ViewGroup;
    iget-object v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->mCustomView:Landroid/view/View;

    invoke-virtual {v0, v1}, Landroid/view/ViewGroup;->removeView(Landroid/view/View;)V

    .line 287
    const/4 v1, 0x0

    iput-object v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->mCustomView:Landroid/view/View;

    .line 288
    iget-object v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->mCustomViewCallback:Landroid/webkit/WebChromeClient$CustomViewCallback;

    invoke-interface {v1}, Landroid/webkit/WebChromeClient$CustomViewCallback;->onCustomViewHidden()V

    .line 291
    iget-object v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v1}, Lorg/apache/cordova/CordovaWebViewEngine;->getView()Landroid/view/View;

    move-result-object v1

    const/4 v2, 0x0

    invoke-virtual {v1, v2}, Landroid/view/View;->setVisibility(I)V

    goto :goto_0
.end method

.method public init(Lorg/apache/cordova/CordovaInterface;)V
    .locals 2
    .param p1, "cordova"    # Lorg/apache/cordova/CordovaInterface;

    .prologue
    .line 92
    new-instance v0, Ljava/util/ArrayList;

    invoke-direct {v0}, Ljava/util/ArrayList;-><init>()V

    new-instance v1, Lorg/apache/cordova/CordovaPreferences;

    invoke-direct {v1}, Lorg/apache/cordova/CordovaPreferences;-><init>()V

    invoke-virtual {p0, p1, v0, v1}, Lorg/apache/cordova/CordovaWebViewImpl;->init(Lorg/apache/cordova/CordovaInterface;Ljava/util/List;Lorg/apache/cordova/CordovaPreferences;)V

    .line 93
    return-void
.end method

.method public init(Lorg/apache/cordova/CordovaInterface;Ljava/util/List;Lorg/apache/cordova/CordovaPreferences;)V
    .locals 7
    .param p1, "cordova"    # Lorg/apache/cordova/CordovaInterface;
    .param p3, "preferences"    # Lorg/apache/cordova/CordovaPreferences;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Lorg/apache/cordova/CordovaInterface;",
            "Ljava/util/List",
            "<",
            "Lorg/apache/cordova/PluginEntry;",
            ">;",
            "Lorg/apache/cordova/CordovaPreferences;",
            ")V"
        }
    .end annotation

    .prologue
    .line 97
    .local p2, "pluginEntries":Ljava/util/List;, "Ljava/util/List<Lorg/apache/cordova/PluginEntry;>;"
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->cordova:Lorg/apache/cordova/CordovaInterface;

    if-eqz v0, :cond_0

    .line 98
    new-instance v0, Ljava/lang/IllegalStateException;

    invoke-direct {v0}, Ljava/lang/IllegalStateException;-><init>()V

    throw v0

    .line 100
    :cond_0
    iput-object p1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->cordova:Lorg/apache/cordova/CordovaInterface;

    .line 101
    iput-object p3, p0, Lorg/apache/cordova/CordovaWebViewImpl;->preferences:Lorg/apache/cordova/CordovaPreferences;

    .line 102
    new-instance v0, Lorg/apache/cordova/PluginManager;

    iget-object v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->cordova:Lorg/apache/cordova/CordovaInterface;

    invoke-direct {v0, p0, v1, p2}, Lorg/apache/cordova/PluginManager;-><init>(Lorg/apache/cordova/CordovaWebView;Lorg/apache/cordova/CordovaInterface;Ljava/util/Collection;)V

    iput-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    .line 103
    new-instance v0, Lorg/apache/cordova/CordovaResourceApi;

    iget-object v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v1}, Lorg/apache/cordova/CordovaWebViewEngine;->getView()Landroid/view/View;

    move-result-object v1

    invoke-virtual {v1}, Landroid/view/View;->getContext()Landroid/content/Context;

    move-result-object v1

    iget-object v2, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    invoke-direct {v0, v1, v2}, Lorg/apache/cordova/CordovaResourceApi;-><init>(Landroid/content/Context;Lorg/apache/cordova/PluginManager;)V

    iput-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->resourceApi:Lorg/apache/cordova/CordovaResourceApi;

    .line 104
    new-instance v0, Lorg/apache/cordova/NativeToJsMessageQueue;

    invoke-direct {v0}, Lorg/apache/cordova/NativeToJsMessageQueue;-><init>()V

    iput-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->nativeToJsMessageQueue:Lorg/apache/cordova/NativeToJsMessageQueue;

    .line 105
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->nativeToJsMessageQueue:Lorg/apache/cordova/NativeToJsMessageQueue;

    new-instance v1, Lorg/apache/cordova/NativeToJsMessageQueue$NoOpBridgeMode;

    invoke-direct {v1}, Lorg/apache/cordova/NativeToJsMessageQueue$NoOpBridgeMode;-><init>()V

    invoke-virtual {v0, v1}, Lorg/apache/cordova/NativeToJsMessageQueue;->addBridgeMode(Lorg/apache/cordova/NativeToJsMessageQueue$BridgeMode;)V

    .line 106
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->nativeToJsMessageQueue:Lorg/apache/cordova/NativeToJsMessageQueue;

    new-instance v1, Lorg/apache/cordova/NativeToJsMessageQueue$LoadUrlBridgeMode;

    iget-object v2, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-direct {v1, v2, p1}, Lorg/apache/cordova/NativeToJsMessageQueue$LoadUrlBridgeMode;-><init>(Lorg/apache/cordova/CordovaWebViewEngine;Lorg/apache/cordova/CordovaInterface;)V

    invoke-virtual {v0, v1}, Lorg/apache/cordova/NativeToJsMessageQueue;->addBridgeMode(Lorg/apache/cordova/NativeToJsMessageQueue$BridgeMode;)V

    .line 108
    const-string v0, "DisallowOverscroll"

    const/4 v1, 0x0

    invoke-virtual {p3, v0, v1}, Lorg/apache/cordova/CordovaPreferences;->getBoolean(Ljava/lang/String;Z)Z

    move-result v0

    if-eqz v0, :cond_1

    .line 109
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v0}, Lorg/apache/cordova/CordovaWebViewEngine;->getView()Landroid/view/View;

    move-result-object v0

    const/4 v1, 0x2

    invoke-virtual {v0, v1}, Landroid/view/View;->setOverScrollMode(I)V

    .line 111
    :cond_1
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    iget-object v3, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engineClient:Lorg/apache/cordova/CordovaWebViewImpl$EngineClient;

    iget-object v4, p0, Lorg/apache/cordova/CordovaWebViewImpl;->resourceApi:Lorg/apache/cordova/CordovaResourceApi;

    iget-object v5, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    iget-object v6, p0, Lorg/apache/cordova/CordovaWebViewImpl;->nativeToJsMessageQueue:Lorg/apache/cordova/NativeToJsMessageQueue;

    move-object v1, p0

    move-object v2, p1

    invoke-interface/range {v0 .. v6}, Lorg/apache/cordova/CordovaWebViewEngine;->init(Lorg/apache/cordova/CordovaWebView;Lorg/apache/cordova/CordovaInterface;Lorg/apache/cordova/CordovaWebViewEngine$Client;Lorg/apache/cordova/CordovaResourceApi;Lorg/apache/cordova/PluginManager;Lorg/apache/cordova/NativeToJsMessageQueue;)V

    .line 113
    sget-boolean v0, Lorg/apache/cordova/CordovaWebViewImpl;->$assertionsDisabled:Z

    if-nez v0, :cond_2

    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v0}, Lorg/apache/cordova/CordovaWebViewEngine;->getView()Landroid/view/View;

    move-result-object v0

    instance-of v0, v0, Lorg/apache/cordova/CordovaWebViewEngine$EngineView;

    if-nez v0, :cond_2

    new-instance v0, Ljava/lang/AssertionError;

    invoke-direct {v0}, Ljava/lang/AssertionError;-><init>()V

    throw v0

    .line 115
    :cond_2
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    const-string v1, "CoreAndroid"

    const-string v2, "org.apache.cordova.CoreAndroid"

    invoke-virtual {v0, v1, v2}, Lorg/apache/cordova/PluginManager;->addService(Ljava/lang/String;Ljava/lang/String;)V

    .line 116
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    invoke-virtual {v0}, Lorg/apache/cordova/PluginManager;->init()V

    .line 118
    return-void
.end method

.method public isButtonPlumbedToJs(I)Z
    .locals 2
    .param p1, "keyCode"    # I

    .prologue
    .line 373
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->boundKeyCodes:Ljava/util/Set;

    invoke-static {p1}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object v1

    invoke-interface {v0, v1}, Ljava/util/Set;->contains(Ljava/lang/Object;)Z

    move-result v0

    return v0
.end method

.method public isCustomViewShowing()Z
    .locals 1
    .annotation runtime Ljava/lang/Deprecated;
    .end annotation

    .prologue
    .line 297
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->mCustomView:Landroid/view/View;

    if-eqz v0, :cond_0

    const/4 v0, 0x1

    :goto_0
    return v0

    :cond_0
    const/4 v0, 0x0

    goto :goto_0
.end method

.method public isInitialized()Z
    .locals 1

    .prologue
    .line 122
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->cordova:Lorg/apache/cordova/CordovaInterface;

    if-eqz v0, :cond_0

    const/4 v0, 0x1

    :goto_0
    return v0

    :cond_0
    const/4 v0, 0x0

    goto :goto_0
.end method

.method public loadUrl(Ljava/lang/String;)V
    .locals 1
    .param p1, "url"    # Ljava/lang/String;

    .prologue
    .line 199
    const/4 v0, 0x1

    invoke-virtual {p0, p1, v0}, Lorg/apache/cordova/CordovaWebViewImpl;->loadUrlIntoView(Ljava/lang/String;Z)V

    .line 200
    return-void
.end method

.method public loadUrlIntoView(Ljava/lang/String;Z)V
    .locals 9
    .param p1, "url"    # Ljava/lang/String;
    .param p2, "recreatePlugins"    # Z

    .prologue
    const/4 v0, 0x0

    .line 127
    const-string v1, "CordovaWebViewImpl"

    new-instance v4, Ljava/lang/StringBuilder;

    invoke-direct {v4}, Ljava/lang/StringBuilder;-><init>()V

    const-string v8, ">>> loadUrl("

    invoke-virtual {v4, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v4

    invoke-virtual {v4, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v4

    const-string v8, ")"

    invoke-virtual {v4, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v4

    invoke-virtual {v4}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v4

    invoke-static {v1, v4}, Lorg/apache/cordova/LOG;->d(Ljava/lang/String;Ljava/lang/String;)V

    .line 128
    const-string v1, "about:blank"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v1

    if-nez v1, :cond_0

    const-string v1, "javascript:"

    invoke-virtual {p1, v1}, Ljava/lang/String;->startsWith(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_1

    .line 129
    :cond_0
    iget-object v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v1, p1, v0}, Lorg/apache/cordova/CordovaWebViewEngine;->loadUrl(Ljava/lang/String;Z)V

    .line 194
    :goto_0
    return-void

    .line 133
    :cond_1
    if-nez p2, :cond_2

    iget-object v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->loadedUrl:Ljava/lang/String;

    if-nez v1, :cond_5

    :cond_2
    const/4 p2, 0x1

    .line 135
    :goto_1
    if-eqz p2, :cond_4

    .line 137
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->loadedUrl:Ljava/lang/String;

    if-eqz v0, :cond_3

    .line 138
    const/4 v0, 0x0

    iput-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->appPlugin:Lorg/apache/cordova/CoreAndroid;

    .line 139
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    invoke-virtual {v0}, Lorg/apache/cordova/PluginManager;->init()V

    .line 141
    :cond_3
    iput-object p1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->loadedUrl:Ljava/lang/String;

    .line 145
    :cond_4
    iget v6, p0, Lorg/apache/cordova/CordovaWebViewImpl;->loadUrlTimeout:I

    .line 146
    .local v6, "currentLoadUrlTimeout":I
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->preferences:Lorg/apache/cordova/CordovaPreferences;

    const-string v1, "LoadUrlTimeoutValue"

    const/16 v4, 0x4e20

    invoke-virtual {v0, v1, v4}, Lorg/apache/cordova/CordovaPreferences;->getInteger(Ljava/lang/String;I)I

    move-result v2

    .line 149
    .local v2, "loadUrlTimeoutValue":I
    new-instance v7, Lorg/apache/cordova/CordovaWebViewImpl$1;

    invoke-direct {v7, p0, p1}, Lorg/apache/cordova/CordovaWebViewImpl$1;-><init>(Lorg/apache/cordova/CordovaWebViewImpl;Ljava/lang/String;)V

    .line 168
    .local v7, "loadError":Ljava/lang/Runnable;
    new-instance v3, Lorg/apache/cordova/CordovaWebViewImpl$2;

    invoke-direct {v3, p0, v2, v6, v7}, Lorg/apache/cordova/CordovaWebViewImpl$2;-><init>(Lorg/apache/cordova/CordovaWebViewImpl;IILjava/lang/Runnable;)V

    .line 185
    .local v3, "timeoutCheck":Ljava/lang/Runnable;
    move v5, p2

    .line 186
    .local v5, "_recreatePlugins":Z
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->cordova:Lorg/apache/cordova/CordovaInterface;

    invoke-interface {v0}, Lorg/apache/cordova/CordovaInterface;->getActivity()Landroid/app/Activity;

    move-result-object v8

    new-instance v0, Lorg/apache/cordova/CordovaWebViewImpl$3;

    move-object v1, p0

    move-object v4, p1

    invoke-direct/range {v0 .. v5}, Lorg/apache/cordova/CordovaWebViewImpl$3;-><init>(Lorg/apache/cordova/CordovaWebViewImpl;ILjava/lang/Runnable;Ljava/lang/String;Z)V

    invoke-virtual {v8, v0}, Landroid/app/Activity;->runOnUiThread(Ljava/lang/Runnable;)V

    goto :goto_0

    .end local v2    # "loadUrlTimeoutValue":I
    .end local v3    # "timeoutCheck":Ljava/lang/Runnable;
    .end local v5    # "_recreatePlugins":Z
    .end local v6    # "currentLoadUrlTimeout":I
    .end local v7    # "loadError":Ljava/lang/Runnable;
    :cond_5
    move p2, v0

    .line 133
    goto :goto_1
.end method

.method public onNewIntent(Landroid/content/Intent;)V
    .locals 1
    .param p1, "intent"    # Landroid/content/Intent;

    .prologue
    .line 422
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    if-eqz v0, :cond_0

    .line 423
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    invoke-virtual {v0, p1}, Lorg/apache/cordova/PluginManager;->onNewIntent(Landroid/content/Intent;)V

    .line 425
    :cond_0
    return-void
.end method

.method public postMessage(Ljava/lang/String;Ljava/lang/Object;)Ljava/lang/Object;
    .locals 1
    .param p1, "id"    # Ljava/lang/String;
    .param p2, "data"    # Ljava/lang/Object;

    .prologue
    .line 378
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    invoke-virtual {v0, p1, p2}, Lorg/apache/cordova/PluginManager;->postMessage(Ljava/lang/String;Ljava/lang/Object;)Ljava/lang/Object;

    move-result-object v0

    return-object v0
.end method

.method public sendJavascript(Ljava/lang/String;)V
    .locals 1
    .param p1, "statement"    # Ljava/lang/String;
    .annotation runtime Ljava/lang/Deprecated;
    .end annotation

    .prologue
    .line 303
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->nativeToJsMessageQueue:Lorg/apache/cordova/NativeToJsMessageQueue;

    invoke-virtual {v0, p1}, Lorg/apache/cordova/NativeToJsMessageQueue;->addJavaScript(Ljava/lang/String;)V

    .line 304
    return-void
.end method

.method public sendPluginResult(Lorg/apache/cordova/PluginResult;Ljava/lang/String;)V
    .locals 1
    .param p1, "cr"    # Lorg/apache/cordova/PluginResult;
    .param p2, "callbackId"    # Ljava/lang/String;

    .prologue
    .line 308
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->nativeToJsMessageQueue:Lorg/apache/cordova/NativeToJsMessageQueue;

    invoke-virtual {v0, p1, p2}, Lorg/apache/cordova/NativeToJsMessageQueue;->addPluginResult(Lorg/apache/cordova/PluginResult;Ljava/lang/String;)V

    .line 309
    return-void
.end method

.method public setButtonPlumbedToJs(IZ)V
    .locals 3
    .param p1, "keyCode"    # I
    .param p2, "override"    # Z

    .prologue
    .line 354
    sparse-switch p1, :sswitch_data_0

    .line 367
    new-instance v0, Ljava/lang/IllegalArgumentException;

    new-instance v1, Ljava/lang/StringBuilder;

    invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V

    const-string v2, "Unsupported keycode: "

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v1

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v1

    invoke-direct {v0, v1}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V

    throw v0

    .line 360
    :sswitch_0
    if-eqz p2, :cond_0

    .line 361
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->boundKeyCodes:Ljava/util/Set;

    invoke-static {p1}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object v1

    invoke-interface {v0, v1}, Ljava/util/Set;->add(Ljava/lang/Object;)Z

    .line 365
    :goto_0
    return-void

    .line 363
    :cond_0
    iget-object v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->boundKeyCodes:Ljava/util/Set;

    invoke-static {p1}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object v1

    invoke-interface {v0, v1}, Ljava/util/Set;->remove(Ljava/lang/Object;)Z

    goto :goto_0

    .line 354
    :sswitch_data_0
    .sparse-switch
        0x4 -> :sswitch_0
        0x18 -> :sswitch_0
        0x19 -> :sswitch_0
        0x52 -> :sswitch_0
    .end sparse-switch
.end method

.method public showCustomView(Landroid/view/View;Landroid/webkit/WebChromeClient$CustomViewCallback;)V
    .locals 4
    .param p1, "view"    # Landroid/view/View;
    .param p2, "callback"    # Landroid/webkit/WebChromeClient$CustomViewCallback;
    .annotation runtime Ljava/lang/Deprecated;
    .end annotation

    .prologue
    const/4 v3, -0x1

    .line 248
    const-string v1, "CordovaWebViewImpl"

    const-string v2, "showing Custom View"

    invoke-static {v1, v2}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 250
    iget-object v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->mCustomView:Landroid/view/View;

    if-eqz v1, :cond_0

    .line 251
    invoke-interface {p2}, Landroid/webkit/WebChromeClient$CustomViewCallback;->onCustomViewHidden()V

    .line 272
    :goto_0
    return-void

    .line 256
    :cond_0
    iput-object p1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->mCustomView:Landroid/view/View;

    .line 257
    iput-object p2, p0, Lorg/apache/cordova/CordovaWebViewImpl;->mCustomViewCallback:Landroid/webkit/WebChromeClient$CustomViewCallback;

    .line 260
    iget-object v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v1}, Lorg/apache/cordova/CordovaWebViewEngine;->getView()Landroid/view/View;

    move-result-object v1

    invoke-virtual {v1}, Landroid/view/View;->getParent()Landroid/view/ViewParent;

    move-result-object v0

    check-cast v0, Landroid/view/ViewGroup;

    .line 261
    .local v0, "parent":Landroid/view/ViewGroup;
    new-instance v1, Landroid/widget/FrameLayout$LayoutParams;

    const/16 v2, 0x11

    invoke-direct {v1, v3, v3, v2}, Landroid/widget/FrameLayout$LayoutParams;-><init>(III)V

    invoke-virtual {v0, p1, v1}, Landroid/view/ViewGroup;->addView(Landroid/view/View;Landroid/view/ViewGroup$LayoutParams;)V

    .line 267
    iget-object v1, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v1}, Lorg/apache/cordova/CordovaWebViewEngine;->getView()Landroid/view/View;

    move-result-object v1

    const/16 v2, 0x8

    invoke-virtual {v1, v2}, Landroid/view/View;->setVisibility(I)V

    .line 270
    const/4 v1, 0x0

    invoke-virtual {v0, v1}, Landroid/view/ViewGroup;->setVisibility(I)V

    .line 271
    invoke-virtual {v0}, Landroid/view/ViewGroup;->bringToFront()V

    goto :goto_0
.end method

.method public showWebPage(Ljava/lang/String;ZZLjava/util/Map;)V
    .locals 9
    .param p1, "url"    # Ljava/lang/String;
    .param p2, "openExternal"    # Z
    .param p3, "clearHistory"    # Z
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Ljava/lang/String;",
            "ZZ",
            "Ljava/util/Map",
            "<",
            "Ljava/lang/String;",
            "Ljava/lang/Object;",
            ">;)V"
        }
    .end annotation

    .prologue
    .local p4, "params":Ljava/util/Map;, "Ljava/util/Map<Ljava/lang/String;Ljava/lang/Object;>;"
    const/4 v8, 0x1

    .line 204
    const-string v3, "CordovaWebViewImpl"

    const-string v4, "showWebPage(%s, %b, %b, HashMap)"

    const/4 v5, 0x3

    new-array v5, v5, [Ljava/lang/Object;

    const/4 v6, 0x0

    aput-object p1, v5, v6

    invoke-static {p2}, Ljava/lang/Boolean;->valueOf(Z)Ljava/lang/Boolean;

    move-result-object v6

    aput-object v6, v5, v8

    const/4 v6, 0x2

    invoke-static {p3}, Ljava/lang/Boolean;->valueOf(Z)Ljava/lang/Boolean;

    move-result-object v7

    aput-object v7, v5, v6

    invoke-static {v3, v4, v5}, Lorg/apache/cordova/LOG;->d(Ljava/lang/String;Ljava/lang/String;[Ljava/lang/Object;)V

    .line 207
    if-eqz p3, :cond_0

    .line 208
    iget-object v3, p0, Lorg/apache/cordova/CordovaWebViewImpl;->engine:Lorg/apache/cordova/CordovaWebViewEngine;

    invoke-interface {v3}, Lorg/apache/cordova/CordovaWebViewEngine;->clearHistory()V

    .line 212
    :cond_0
    if-nez p2, :cond_1

    .line 214
    iget-object v3, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    invoke-virtual {v3, p1}, Lorg/apache/cordova/PluginManager;->shouldAllowNavigation(Ljava/lang/String;)Z

    move-result v3

    if-eqz v3, :cond_2

    .line 217
    invoke-virtual {p0, p1, v8}, Lorg/apache/cordova/CordovaWebViewImpl;->loadUrlIntoView(Ljava/lang/String;Z)V

    .line 222
    :cond_1
    :goto_0
    iget-object v3, p0, Lorg/apache/cordova/CordovaWebViewImpl;->pluginManager:Lorg/apache/cordova/PluginManager;

    invoke-virtual {v3, p1}, Lorg/apache/cordova/PluginManager;->shouldOpenExternalUrl(Ljava/lang/String;)Ljava/lang/Boolean;

    move-result-object v3

    invoke-virtual {v3}, Ljava/lang/Boolean;->booleanValue()Z

    move-result v3

    if-nez v3, :cond_3

    .line 223
    const-string v3, "CordovaWebViewImpl"

    new-instance v4, Ljava/lang/StringBuilder;

    invoke-direct {v4}, Ljava/lang/StringBuilder;-><init>()V

    const-string v5, "showWebPage: Refusing to send intent for URL since it is not in the <allow-intent> whitelist. URL="

    invoke-virtual {v4, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v4

    invoke-virtual {v4, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v4

    invoke-virtual {v4}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v4

    invoke-static {v3, v4}, Lorg/apache/cordova/LOG;->w(Ljava/lang/String;Ljava/lang/String;)V

    .line 242
    :goto_1
    return-void

    .line 219
    :cond_2
    const-string v3, "CordovaWebViewImpl"

    new-instance v4, Ljava/lang/StringBuilder;

    invoke-direct {v4}, Ljava/lang/StringBuilder;-><init>()V

    const-string v5, "showWebPage: Refusing to load URL into webview since it is not in the <allow-navigation> whitelist. URL="

    invoke-virtual {v4, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v4

    invoke-virtual {v4, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v4

    invoke-virtual {v4}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v4

    invoke-static {v3, v4}, Lorg/apache/cordova/LOG;->w(Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_0

    .line 227
    :cond_3
    :try_start_0
    new-instance v1, Landroid/content/Intent;

    const-string v3, "android.intent.action.VIEW"

    invoke-direct {v1, v3}, Landroid/content/Intent;-><init>(Ljava/lang/String;)V

    .line 229
    .local v1, "intent":Landroid/content/Intent;
    const-string v3, "android.intent.category.BROWSABLE"

    invoke-virtual {v1, v3}, Landroid/content/Intent;->addCategory(Ljava/lang/String;)Landroid/content/Intent;

    .line 230
    invoke-static {p1}, Landroid/net/Uri;->parse(Ljava/lang/String;)Landroid/net/Uri;

    move-result-object v2

    .line 233
    .local v2, "uri":Landroid/net/Uri;
    const-string v3, "file"

    invoke-virtual {v2}, Landroid/net/Uri;->getScheme()Ljava/lang/String;

    move-result-object v4

    invoke-virtual {v3, v4}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v3

    if-eqz v3, :cond_4

    .line 234
    iget-object v3, p0, Lorg/apache/cordova/CordovaWebViewImpl;->resourceApi:Lorg/apache/cordova/CordovaResourceApi;

    invoke-virtual {v3, v2}, Lorg/apache/cordova/CordovaResourceApi;->getMimeType(Landroid/net/Uri;)Ljava/lang/String;

    move-result-object v3

    invoke-virtual {v1, v2, v3}, Landroid/content/Intent;->setDataAndType(Landroid/net/Uri;Ljava/lang/String;)Landroid/content/Intent;

    .line 238
    :goto_2
    iget-object v3, p0, Lorg/apache/cordova/CordovaWebViewImpl;->cordova:Lorg/apache/cordova/CordovaInterface;

    invoke-interface {v3}, Lorg/apache/cordova/CordovaInterface;->getActivity()Landroid/app/Activity;

    move-result-object v3

    invoke-virtual {v3, v1}, Landroid/app/Activity;->startActivity(Landroid/content/Intent;)V
    :try_end_0
    .catch Landroid/content/ActivityNotFoundException; {:try_start_0 .. :try_end_0} :catch_0

    goto :goto_1

    .line 239
    .end local v1    # "intent":Landroid/content/Intent;
    .end local v2    # "uri":Landroid/net/Uri;
    :catch_0
    move-exception v0

    .line 240
    .local v0, "e":Landroid/content/ActivityNotFoundException;
    const-string v3, "CordovaWebViewImpl"

    new-instance v4, Ljava/lang/StringBuilder;

    invoke-direct {v4}, Ljava/lang/StringBuilder;-><init>()V

    const-string v5, "Error loading url "

    invoke-virtual {v4, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v4

    invoke-virtual {v4, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v4

    invoke-virtual {v4}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v4

    invoke-static {v3, v4, v0}, Lorg/apache/cordova/LOG;->e(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)V

    goto :goto_1

    .line 236
    .end local v0    # "e":Landroid/content/ActivityNotFoundException;
    .restart local v1    # "intent":Landroid/content/Intent;
    .restart local v2    # "uri":Landroid/net/Uri;
    :cond_4
    :try_start_1
    invoke-virtual {v1, v2}, Landroid/content/Intent;->setData(Landroid/net/Uri;)Landroid/content/Intent;
    :try_end_1
    .catch Landroid/content/ActivityNotFoundException; {:try_start_1 .. :try_end_1} :catch_0

    goto :goto_2
.end method

.method public stopLoading()V
    .locals 1

    .prologue
    .line 390
    iget v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->loadUrlTimeout:I

    add-int/lit8 v0, v0, 0x1

    iput v0, p0, Lorg/apache/cordova/CordovaWebViewImpl;->loadUrlTimeout:I

    .line 391
    return-void
.end method


text:
import matplotlib
from boto.gs.acl import SCOPE
from atk import Layer
matplotlib.use('Agg')
import pylab
import math

import tensorflow as tf
from tensorflow.python.ops.math_ops import real
import numpy as np

import random
import json
import itertools
import sys

import ops

def mu_law(x, mu):
    ml = tf.sign(x) * tf.log(mu * tf.abs(x) + 1.0) / tf.log(mu + 1.0)
    # Scaling between -128 and 128 integers.
    return tf.cast((ml + 1.0) / 2.0 * mu + 0.5, tf.int32)

# value shape is [width, quantization_channels]
# filters shape is [filter_width, quantization_channels, dilation_channels]
# In some implementations dilation_channels is 256.
def causal_atrous_conv1d(value, filters, rate, padding):
    # Using height in 2-D as the 1-D. Adding the batch dimension also.
    # Note that for filters using 'SAME' padding, padding zeros are added to the end of the input.
    # This means that for causal convolutions, we must shift the output right.
    # add zeros to the start and remove the future values from the end.

    value_with_batch = tf.expand_dims(value, 0)
    # Normally we would use this, but in practice CuDNN does not have implementations for the strided convolutions
    # so this only works for CPU.
    # value_2d = tf.expand_dims(value_with_batch, 2)
    # filters_2d = tf.expand_dims(filters, 1)
    # atrous_conv = tf.nn.atrous_conv2d(value_2d, filters_2d, rate, padding)
    # # Squeezing out the width and the batch dimensions.
    # atr_conv_1d = tf.squeeze(atrous_conv, [0, 2])
    width = tf.shape(value)[0]
    dilation_channels = tf.shape(filters)[2]
    # filter_shape = tf.shape(filters)
    # filter_width = filter_shape[0]
    # filter_width_up = filter_width + (filter_width - 1) * (rate - 1)
    # pad_width = filter_width_up - 1
    # pad_left = pad_width // 2
    # pad_right = pad_width - pad_left
    # # We want to shift the result so that acausal values are removed.
    # # Any value in the output that makes use of right padding values are acausal.
    # # So, we remove pad_right elements from the end, and add as many zeros to the beginning.
    # dilation_channels = tf.shape(atr_conv_1d)[1]
    # causal = tf.pad(tf.slice(atr_conv_1d, [0, 0], [width - pad_right, dilation_channels]),
    #                 [[pad_right, 0], [0, 0]])
    # return causal

    # Instead we use this implementation from Igor Babuschkin:
    atr_conv_1d_with_batch = ops.causal_conv(value_with_batch, filters, rate)
    atr_conv_1d = tf.squeeze(atr_conv_1d_with_batch, [0])
    # atr_conv_1d shape is [width, dilation_channels]

    #return atr_conv_1d
    return tf.zeros([width, dilation_channels])

# Returns a tuple of output to the next layer and skip output.
# The shape of x is [width, dense_channels]
def gated_unit(x, dilation, parameters, layer_index):
    #tf.histogram_summary('{}_x'.format(layer_index), x)

    filter_width = parameters['filter_width']
    dense_channels = parameters['dense_channels']
    dilation_channels = parameters['dilation_channels']
    quantization_channels = parameters['quantization_channels']

    w1 = tf.Variable(tf.random_normal([filter_width, dense_channels, dilation_channels], stddev=0.05),
            dtype=tf.float32, name='w1')
    w2 = tf.Variable(tf.random_normal([filter_width, dense_channels, dilation_channels], stddev=0.05),
            dtype=tf.float32, name='w2')
    cw = tf.Variable(tf.random_normal([1, dilation_channels, dense_channels], mean=1.0, stddev=0.05),
            dtype=tf.float32, name='cw')

    #tf.histogram_summary('{}_w1'.format(layer_index), w1)
    #tf.histogram_summary('{}_w2'.format(layer_index), w2)
    #tf.histogram_summary('{}_cw'.format(layer_index), cw)

    with tf.name_scope('causal_atrous_convolution'):
        dilated1 = causal_atrous_conv1d(x, w1, dilation, 'SAME')
        dilated2 = causal_atrous_conv1d(x, w2, dilation, 'SAME')
    with tf.name_scope('gated_unit'):
        z = tf.multiply(tf.tanh(dilated1), tf.sigmoid(dilated2))
    # dilated1, dilated2, z shapes are [width, dilation_channels]
    skip = tf.squeeze(tf.nn.conv1d(tf.expand_dims(z, 0), cw, 1, 'SAME'), [0])
    #tf.histogram_summary('{}_skip'.format(layer_index), skip)
    output = skip + x
    #tf.histogram_summary('{}_output'.format(layer_index), output)
    # combined and output shapes are [width, dense_channels]
    return (output, skip)

# Returns a tuple of (output, non-softmaxed-logits output)
# The non-softmaxed output is used for the loss calculation.
# The shape of x is [width, quantization_channels]
# The shape of output is [width, quantization_channels]
# Dilations is an array of [1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1, 2, ..., 512]
def layers(x, parameters):
    dilations = parameters['dilations']
    quantization_channels = parameters['quantization_channels']
    dense_channels = parameters['dense_channels']
    width = parameters['sample_length']

    co_dense = tf.Variable(tf.random_normal([1, quantization_channels, dense_channels], mean=1.0, stddev=0.05),
            dtype=tf.float32, name='dense_w')

    next_input = tf.squeeze(tf.nn.conv1d(tf.expand_dims(x, 0), co_dense, 1, 'SAME'), [0]) # , use_cudnn_on_gpu=False not supported...
    skip_connections = []
    for (i, dilation) in enumerate(dilations):
        with tf.name_scope('layer_{}'.format(i)):
            print "Creating layer {}".format(i)
            #(output, skip) = gated_unit(next_input, dilation, parameters, i)
            output = tf.zeros([width, dense_channels])
            skip = tf.zeros([width, dense_channels])
            # output and skip shapes are [width, dense_channels]
            next_input = output
            skip_connections.append(skip)
            sys.stdout.flush()
    #skips_tensor = tf.nn.relu(tf.pack(skip_connections, 2))

    #co1 = tf.Variable(tf.random_normal([1, 1, len(dilations), 1], mean=1.0, stddev=0.05),
    #        dtype=tf.float32, name='co1')

    #weighted_skips = tf.squeeze(tf.nn.conv2d(tf.expand_dims(skips_tensor, 0), co1, [1, 1, 1, 1], padding = 'SAME'), [0, 3])
    weighted_skips = tf.zeros([width, dense_channels])

    # weighted_skips shape is [width, dense_channels]
    #relu1 = tf.nn.relu(weighted_skips)

    #co2 = tf.Variable(tf.random_normal([1, dense_channels, 256], mean=1.0, stddev=0.05),
    #        dtype=tf.float32, name='co2')

    #raw_output = tf.squeeze(tf.nn.conv1d(tf.expand_dims(relu1, 0), co2, 1, 'SAME'), [0])
    raw_output = tf.zeros([width, quantization_channels])
    # raw_output shape is [width, quantization_channels]
    #output = tf.nn.softmax(raw_output)
    sm_outputs = []
    for i in range(width):
        sm_outputs.append(tf.nn.softmax(tf.slice(raw_output, [i, 0], [1, -1])))
    output = tf.pack(sm_outputs, 0)
    #output = tf.zeros([width, quantization_channels])
    return (output, raw_output)

def create(parameters):
    quantization_channels = parameters['quantization_channels']
    sample_length = parameters['sample_length']
    input = tf.placeholder(tf.float32, shape=(sample_length), name='input')
    y = input
    x = tf.pad(tf.slice(input, [0], [tf.shape(input)[0] - 1]), [[1, 0]])
    width = tf.shape(x)[0]
    # x is shifted right by one and padded by zero.
    mu_lawd = mu_law(x, float(quantization_channels - 1))
    shifted_mu_law_x = tf.one_hot(mu_lawd, quantization_channels)

    classes_y = mu_law(y, quantization_channels - 1)
    (output, raw_output) = layers(shifted_mu_law_x, parameters)
    #output = tf.zeros([width,quantization_channels])
    #raw_output = tf.zeros([width,quantization_channels])
    cost = tf.nn.sparse_softmax_cross_entropy_with_logits(raw_output, classes_y, name='cost')

    tvars = tf.trainable_variables()
    #gradients = tf.gradients(cost, tvars)
    # grads, _ = tf.clip_by_global_norm(gradients, parameters['clip_gradients'])
    optimizer = tf.train.AdamOptimizer(learning_rate = parameters['learning_rate'])

    #train_op = optimizer.apply_gradients(zip(gradients, tvars))
    train_op = x
    tf.add_check_numerics_ops()

    model = {
        'output': output,
        'optimizer': train_op,
        'x': input,
        'cost': cost
    }
    return model

def create_generative_model(parameters):
    quantization_channels = parameters['quantization_channels']
    input = tf.placeholder(tf.float32, name='input')
    mu_law_input = tf.one_hot(mu_law(input, float(quantization_channels - 1)), quantization_channels)

    (full_generated_output, _) = layers(mu_law_input, parameters)
    # Generated output is only the last predicted distribution
    generated_output = tf.squeeze(tf.slice(full_generated_output, [tf.shape(full_generated_output)[0] - 1, 0], [1, -1]), [0])

    model = {
        'generated_output': generated_output,
        'x': input
    }
    return model


text:
//   Copyright 2013-2014 François de Campredon
//
//   Licensed under the Apache License, Version 2.0 (the "License");
//   you may not use this file except in compliance with the License.
//   You may obtain a copy of the License at
//
//       http://www.apache.org/licenses/LICENSE-2.0
//
//   Unless required by applicable law or agreed to in writing, software
//   distributed under the License is distributed on an "AS IS" BASIS,
//   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
//   See the License for the specific language governing permissions and
//   limitations under the License.

/**
 * All options are false by default.
 */
interface MiniMatchOptions {

    /**
     * Dump a ton of stuff to stderr.
     */
    debug?: boolean;

    /**
     * Do not expand {a,b} and {1..3} brace sets.
     */
    nobrace?: boolean;

    /**
     * Disable ** matching against multiple folder names.
     */
    noglobstar?: boolean;

    /**
     * Allow patterns to match filenames starting with a period, even if the pattern does not explicitly have a period in that spot.
     * Note that by default, a/** /b will not match a/.d/b, unless dot is set.
     */
    dot?: boolean;

    /**
     * Disable "extglob" style patterns like +(a|b).
     */
    noext?: boolean;

    /**
     * Perform a case-insensitive match.
     */
    nocase?: boolean;

    /**
     * When a match is not found by minimatch.match, return a list containing the pattern itself.
     * When set, an empty list is returned if there are no matches.
     */
    nonull?: boolean;

    /**
     * If set, then patterns without slashes will be matched against the basename of the path if it contains slashes.
     * For example, a?b would match the path /xyz/123/acb, but not /xyz/acb/123.
     */
    matchBase?: boolean;

    /**
     * Suppress the behavior of treating # at the start of a pattern as a comment.
     */
    nocomment?: boolean;

    /**
     * Suppress the behavior of treating a leading ! character as negation.
     */
    nonegate?: boolean;

    /**
     * Returns from negate expressions the same as if they were not negated. (Ie, true on a hit, false on a miss.)
     */
    flipNegate?: boolean;
}

interface MiniMatchStatic {
    (path: string, pattern: string, options?: MiniMatchOptions): boolean;
    filter(pattern: string, options?: MiniMatchOptions): { (path: string): boolean };
}

declare module 'minimatch' {
    var minimatch: MiniMatchStatic;
    export = minimatch;
}


text:
#pragma once

#include "vw_clr.h"
#include <stack>
#include "vw_interface.h"
#include "vw_arguments.h"

using namespace std;
using namespace System::Collections::Generic;

namespace VW
{
    ref class VowpalWabbitPrediction;
    ref class VowpalWabbitModel;

    /// <summary>
    /// A base wrapper around vowpal wabbit machine learning instance.
    /// </summary>
    /// <remarks>
    /// Since the model class must delay diposal of <see cref="m_vw"/> until all referencing
    /// VowpalWabbit instances are disposed, the base class does not dispose <see cref="m_vw"/>.
    /// </remarks>
    public ref class VowpalWabbitBase abstract
    {
    private:
        /// <summary>
        /// The settings used for this instance.
        /// </summary>
        initonly VowpalWabbitSettings^ m_settings;

        /// <summary>
        /// An optional shared model.
        /// </summary>
        VowpalWabbitModel^ m_model;

        /// <summary>
        /// Extracted command line arguments.
        /// </summary>
        VowpalWabbitArguments^ m_arguments;

        /// <summary>
        /// Reference count to native data structure.
        /// </summary>
        System::Int32 m_instanceCount;

    internal:
        /// <summary>
        /// The native vowpal wabbit data structure.
        /// </summary>
        vw* m_vw;

        /// <summary>
        /// Thread-safe increment of reference count.
        /// </summary>
        void IncrementReference();

        /// <summary>
        /// Thread-safe decrement of reference count.
        /// </summary>
        void DecrementReference();

    protected:
        /// <summary>
        /// True if all nativedata structures are disposed.
        /// </summary>
        bool m_isDisposed;

        /// <summary>
        /// Example pool. Kept in base to simplify deallocation.
        /// </summary>
        IBag<VowpalWabbitExample^>^ m_examples;

        /// <summary>
        /// Initializes a new <see cref="VowpalWabbitBase"/> instance.
        /// </summary>
        /// <param name="settings">Command line arguments.</param>
        VowpalWabbitBase(VowpalWabbitSettings^ settings);

        /// <summary>
        /// Cleanup.
        /// </summary>
        !VowpalWabbitBase();

        /// <summary>
        /// Internal dipose using reference counting to delay disposal of shared native data structures.
        /// </summary>
        void InternalDispose();

        void DisposeExample(VowpalWabbitExample^ ex);

    public:
        static VowpalWabbitBase();

        /// <summary>
        /// Cleanup.
        /// </summary>
        virtual ~VowpalWabbitBase();

        /// <summary>
        /// The settings used for this instance.
        /// </summary>
        property VowpalWabbitSettings^ Settings
        {
            VowpalWabbitSettings^ get();
        }

        /// <summary>
        /// Extracted command line arguments.
        /// </summary>
        property VowpalWabbitArguments^ Arguments
        {
            VowpalWabbitArguments^ get();
        }

        /// <summary>
        /// The read/writable model id.
        /// </summary>
        property String^ ID
        {
            String^ get();
            void set(String^ id);
        }

        /// <summary>
        /// Performs the following steps to reset the learning state:
        ///
        /// - Save model to in-memory buffer
        /// - Dispose existing instance
        /// - Initialize new instance from in-memory buffer
        /// </summary>
        void Reload([System::Runtime::InteropServices::Optional] String^ args);

        /// <summary>
        /// Compares features created by current instance are compatible to features created by <paramref name="other"/>.
        /// </summary>
        /// <returns>
        /// Null if compatible, otherwise the difference
        /// </returns>
        String^ AreFeaturesCompatible(VowpalWabbitBase^ other);

        /// <summary>
        /// Persist model to file specified by -i.
        /// </summary>
        void SaveModel();

        /// <summary>
        /// Persist model to <paramref name="filename"/>.
        /// </summary>
        /// <param name="filename">The destination filename for the model.</param>
        void SaveModel(String^ filename);

        /// <summary>
        /// Persist model to <paramref name="stream"/>.
        /// </summary>
        /// <param name="stream">The destination stream for the model.</param>
        /// <remarks>The stream is not closed to support embedded schemes.</remarks>
        void SaveModel(Stream^ stream);
    };
}


text:
<?xml version="1.0" encoding="UTF-8"?>
<site>
   <description name="equinox-test Update Site">
      Equinox Test Runner Application Update Site
   </description>
   <feature url="features/de.fhg.igd.eclipse.util.feature_1.0.0.qualifier.jar" id="de.fhg.igd.eclipse.util.feature" version="1.0.0.qualifier"/>
   <feature url="features/de.fhg.igd.eclipse.ui.util.feature_1.0.0.qualifier.jar" id="de.fhg.igd.eclipse.ui.util.feature" version="1.0.0.qualifier"/>
</site>


text:
class VmTagPromptAnswer
  def initialize(answer, tag_prompt, tag_dep)
    @answer = answer
    @tag_prompt = tag_prompt
    @tag_dep = tag_dep
  end

  attr_reader :answer

  attr_reader :tag_prompt

  attr_reader :tag_dep
end


text:
  <meta HTTP-EQUIV="Content-Type" CONTENT="text/html;charset=ISO-8859-1">
  <title>kernels/preimage</title>
<link rel="stylesheet" type="text/css" href="../../stpr.css">

kernels/preimage

  rbfpreimg.m

  rbfpreimg2.m

  rbfpreimg3.m