text:
module Aws::ElasticBeanstalk
  module Endpoints

    class AbortEnvironmentUpdate
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class ApplyEnvironmentManagedAction
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class AssociateEnvironmentOperationsRole
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class CheckDNSAvailability
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class ComposeEnvironments
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class CreateApplication
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class CreateApplicationVersion
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class CreateConfigurationTemplate
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class CreateEnvironment
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class CreatePlatformVersion
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class CreateStorageLocation
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DeleteApplication
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DeleteApplicationVersion
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DeleteConfigurationTemplate
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DeleteEnvironmentConfiguration
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DeletePlatformVersion
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DescribeAccountAttributes
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DescribeApplicationVersions
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DescribeApplications
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DescribeConfigurationOptions
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DescribeConfigurationSettings
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DescribeEnvironmentHealth
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DescribeEnvironmentManagedActionHistory
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DescribeEnvironmentManagedActions
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DescribeEnvironmentResources
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DescribeEnvironments
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DescribeEvents
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DescribeInstancesHealth
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DescribePlatformVersion
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class DisassociateEnvironmentOperationsRole
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class ListAvailableSolutionStacks
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class ListPlatformBranches
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class ListPlatformVersions
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class ListTagsForResource
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class RebuildEnvironment
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class RequestEnvironmentInfo
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class RestartAppServer
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class RetrieveEnvironmentInfo
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class SwapEnvironmentCNAMEs
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class TerminateEnvironment
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class UpdateApplication
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class UpdateApplicationResourceLifecycle
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class UpdateApplicationVersion
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class UpdateConfigurationTemplate
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class UpdateEnvironment
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class UpdateTagsForResource
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

    class ValidateConfigurationSettings
      def self.build(context)
        unless context.config.regional_endpoint
          endpoint = context.config.endpoint.to_s
        end
        Aws::ElasticBeanstalk::EndpointParameters.new(
          region: context.config.region,
          use_dual_stack: context.config.use_dualstack_endpoint,
          use_fips: context.config.use_fips_endpoint,
          endpoint: endpoint,
        )
      end
    end

  end
end


text:
class UserSessionsController < ApplicationController

  def new
    @user_session = UserSession.new
  end

  def create
    @user_session = UserSession.new(params[:user_session])
    if @user_session.save
      flash[:notice] = "Usuario aceptado."
      redirect_to exams_path
    else
      render :action => :new
    end
  end

  def destroy
    current_user_session.destroy  if current_user_session
    flash[:notice] = "Sesión cerrada."
    redirect_to new_user_session_url
  end
end

redpajama_set_name: RedPajamaGithub


text:
import logger from '@wdio/logger'

import WorkerInstance from './worker'
import { SHUTDOWN_TIMEOUT } from './constants'

const log = logger('wdio-local-runner')

export default class LocalRunner {
    constructor (configFile, config) {
        this.configFile = configFile
        this.config = config
        this.workerPool = {}
    }

    /**
     * nothing to initialise when running locally
     */
    initialise () {}

    getWorkerCount () {
        return Object.keys(this.workerPool).length
    }

    run ({ command, argv, ...options }) {
        /**
         * adjust max listeners on stdout/stderr when creating listeners
         */
        const workerCnt = this.getWorkerCount()
        if (workerCnt >= process.stdout.getMaxListeners() - 2) {
            process.stdout.setMaxListeners(workerCnt + 2)
            process.stderr.setMaxListeners(workerCnt + 2)
        }

        const worker = new WorkerInstance(this.config, options)
        this.workerPool[options.cid] = worker
        worker.postMessage(command, argv)

        return worker
    }

    /**
     * shutdown all worker processes
     *
     * @return {Promise}  resolves when all worker have been shutdown or
     *                    a timeout was reached
     */
    shutdown () {
        log.info('Shutting down spawned worker')

        for (const [cid, worker] of Object.entries(this.workerPool)) {
            if (!worker.isBusy) {
                delete this.workerPool[cid]
                continue
            }

            worker.postMessage('endSession', {})
        }

        return new Promise((resolve) => {
            const interval = setInterval(() => {
                const busyWorker = Object.entries(this.workerPool)
                    .filter(([, worker]) => worker.isBusy).length

                log.info(`Waiting for ${busyWorker} to shut down gracefully`)
                if (busyWorker === 0) {
                    clearInterval(interval)
                    log.info('shutting down')
                    return resolve()
                }
            }, 250)

            setTimeout(resolve, SHUTDOWN_TIMEOUT)
        })
    }
}


text:
A very opinionated framework to build applications using CQRS, event sourcing and domain driven design.

## Goal
The TripleD framework aims to take away as much boiler plate code as possible when building CQRS based applications which want to take advantage of event sourcing and domain driven design.

This framework aims to facilitate the creation and execution of commands. The idea is to be able to dispatch commands so that they can be executed in an (a)synchronous fashion.

## Usage
The framework supports Spring boot. This implies that if you add this framework jar to your classpath, it will be auto-configured with sensible defaults.

after adding the required dependencies, a `CommandDispatcher`, `EventPublisher` and `EventSubscriber`  should be available in your application context.
Additionally, When annotating a `@Configuration` class with `@EnableEventHandlerSupport` you should be able to annotate any spring service with `@Handler` and it will be registered automatically to the `EventBus`.

To get started with the EventBus the following dependencies should be added to your gradle configuration
```groovy
dependencies {
    compile ("eu.tripledframework:spring-boot-eventbus-starter:0.0.1-SNAPSHOT")
 }
```

The following configuration annotations should be used if you which to automatically register spring services as handlers.
```java
@EnableEventHandlerSupport(basePackage = "eu.tripledframework.demo")
public class EventBusDemoApplication {
    ....
}
```

The below sample illustrates how a springMVC controller would typically fire a command.
```java
@RestController
public class HelloController {

  @Autowired
  private CommandDispatcher dispatcher;

  @RequestMapping(value = "/hello/{name}", method = RequestMethod.GET)
    public HelloResponse sayHi(@PathVariable String name) throws ExecutionException, InterruptedException {
      Future<HelloResponse> future = dispatcher.dispatch(new HelloCommand(name));

      return future.get();
    }
}
```

A commandHandler would then be implemented as following
```java
@Handler
@Component
public class HelloCommandHandler {

  @Autowired
  private EventPublisher eventPublisher;

  @Handles(HelloCommand.class)
  public HelloResponse handleHelloCommand(HelloCommand helloCommand) {
    if (helloCommand.getName().equals("The devil")) {
      throw new IllegalArgumentException("I'm not saying hi to you! :P");
    }
    HelloResponse helloResponse = new HelloResponse("Hello " + helloCommand.getName());

    eventPublisher.publish(new SaidHelloDomainEvent(helloCommand.getName()));

    return helloResponse;
  }

}
```

> See the demo application which is incorporated in this repository as a sub project.

## Contribute
The project is still in a very early stage, however if you feel like contributing or have some brilliant ideas how to make this a killer framework, just contact me! I'm open for suggestions!


text:
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"/>
    <meta name="viewport" content="width=device-width,initial-scale=1.0"/>
    <meta name="format-detection" content="telephone=no"/>
    <link rel="stylesheet" href="static/css/master.css"/>
    <title>About | OpenPGPAuth</title>

OpenPGPAuth

Search

Add a key

Remove a key

API

About

          This is a small service that works like a PGP key server, except it uses OAuth to verify PGP userids before adding them into its database.

So it behaves as a database of OAuth-checked public keys for facebook, twitter, g+, gmail users and so on.  It also has convenient web APIs for applications to add or search for keys, which I hope makes it more web-developer friendly.

        I'm KB, a software developer. I wrote this as a small step to help create systems that let us communicate more securely, using our online identities and over existing services.

One application might be a tool that lets (say) facebook users exchange encrypted content through the sharer's dropbox account. If the recipients share their public keys, the sharer can encrypt the material so that only the recipients can use it.

This would let us securely share privacy-sensitive material like photos of children, medical data and so on. We could still use our online identities, but keep such content on storage we control, and secure it from everyone but the actual recipients.

It would be nice if there was an existing, reliable way for an identity provider to publish a public key for their users. But could a third-party service use the more common OAuth to bridge the gap instead? By verifying user id data in a PGP key against information available with OAuth, it would at least avoid casually inserting forged user ids into the system.

Which finally brings me to this site.  I coded a simple appengine service that does just that. It's a place to store and find PGP keys for online identities. However, it adds an OAuth verification step before adding a key, so while you'd still want to independently verify PGP keys the usual way, it raises the bar by that much.

In addition, the code is on github. You are free to reuse any bits in your own services if you prefer, make it better, anything really.

The site currently handles PGP public keys with Gmail or Yahoo email addresses, and Facebook,Twitter or Google+ keys that use profile URLs.


text:
<?xml version="1.0" encoding="utf-8"?>
<PRONOM-Report xmlns="http://pronom.nationalarchives.gov.uk">
  <report_format_detail>
    <FileFormat>
      <FormatID>2449</FormatID>
      <FormatName>Asylum Music Format</FormatName>
      <FormatVersion>
      </FormatVersion>
      <FormatAliases>
      </FormatAliases>
      <FormatFamilies>
      </FormatFamilies>
      <FormatTypes>Audio</FormatTypes>
      <FormatDisclosure>
      </FormatDisclosure>
      <FormatDescription>Asylum Music Format files (.amf) are music files used in 1990s MS-DOS games Crusader: No Remorse and Crusader: No Regret. Developed by Otto Chrons, they store song data and audio samples.</FormatDescription>
      <BinaryFileFormat>
      </BinaryFileFormat>
      <ByteOrders>
      </ByteOrders>
      <ReleaseDate>
      </ReleaseDate>
      <WithdrawnDate>
      </WithdrawnDate>
      <ProvenanceSourceID>180</ProvenanceSourceID>
      <ProvenanceName>The National Archives and Records Administration / The National Archives and Records Administration</ProvenanceName>
      <ProvenanceSourceDate>17 Feb 2022</ProvenanceSourceDate>
      <ProvenanceDescription>
      </ProvenanceDescription>
      <LastUpdatedDate>17 Feb 2022</LastUpdatedDate>
      <FormatNote>
      </FormatNote>
      <FormatRisk>
      </FormatRisk>
      <TechnicalEnvironment>
      </TechnicalEnvironment>
      <FileFormatIdentifier>
        <Identifier>fmt/1622</Identifier>
        <IdentifierType>PUID</IdentifierType>
      </FileFormatIdentifier>
      <ExternalSignature>
        <ExternalSignatureID>2915</ExternalSignatureID>
        <Signature>amf</Signature>
        <SignatureType>File extension</SignatureType>
      </ExternalSignature>
      <InternalSignature>
        <SignatureID>1963</SignatureID>
        <SignatureName>Asylum Music Format</SignatureName>
        <SignatureNote>BOF, offset 0, magic bytes: ASYLUM Music Format</SignatureNote>
        <ByteSequence>
          <ByteSequenceID>2282</ByteSequenceID>
          <PositionType>Absolute from BOF</PositionType>
          <Offset>0</Offset>
          <MaxOffset>0</MaxOffset>
          <IndirectOffsetLocation>
          </IndirectOffsetLocation>
          <IndirectOffsetLength>
          </IndirectOffsetLength>
          <Endianness>
          </Endianness>
          <ByteSequenceValue>4153594C554D204D7573696320466F726D6174</ByteSequenceValue>
        </ByteSequence>
      </InternalSignature>
    </FileFormat>
    <SearchCriteria>Criteria</SearchCriteria>
  </report_format_detail>
</PRONOM-Report>


text:
#ifndef __QUADCOPTER_CONFIG_H
#define __QUADCOPTER_CONFIG_H

/*Radio control*/
#define USE_FUTABA_CONTROLLER		0
#define USE_WFLY_CONTROLLER		1
#define USE_DEVO_v10_CONTROLLER 0
/* Hardware environments */
#define configRemoteControl				0       //if you no connect motor -> set 0.
#define configSD				0       //if you no connect SD card -> set 0.
#define configNRF				0       //if you no connect nRF module -> set 0.
/* Status report functions */
#define configSTATUS_NRF		0
#define configSTATUS_SHELL		1
#define configSTATUS_GET_MOTORS	0
#define configSTATUS_GET_ROLL_PITCH	0
#define configSTATUS_GET_ROLL_PITCH_YAW	0
#define configSTATUS_GET_ROLL_PITCH_MOTORS 0
/* gui3 */
#define configSTATUS_GET_MAG 0
#define configSTATUS_GET_ACC 0
#define configSTATUS_GET_GYRO 0

/*motot PWM parameter adjustment*/
#define adjustmentMotor1 0	//100
#define adjustmentMotor2 0	//100
#define adjustmentMotor3 0	//105
#define adjustmentMotor4 0	// -55

/* Set baudrate */
#define Serial_Baudrate 9600

/* Includes */
//FreeRTOS
#include "FreeRTOS.h"
#include "task.h"
#include "queue.h"
#include "semphr.h"

//FatFS
#include "diskio.h"
#include "ff.h"

//Algorithm
#include "PID.h"
#include "moving_average.h"
#include "quaternion.h"
#include "_math.h"

//System
#include "global.h"
#include "std.h"
#include "AHRS.h"
#include "remote_control.h"
#include "IMU_correct.h"
#include "communication.h"

//Driver
#include "stm32f4_system.h"
#include "stm32f4xx_conf.h"
#include "delay.h"
#include "flash.h"
#include "i2c.h"
#include "spi.h"
#include "sdio.h"
#include "led.h"
#include "motor.h"
#include "mpu9150.h"
#include "ms5611.h"
#include "nrf24l01.h"
#include "serial.h"
#include "sensor.h"

//Shell
#include "linenoise.h"
#include "shell.h"
#include "parser.h"
#include "watch.h"

//Debugger
#include "test.h"

//LCD
#include "tm_stm32f4_ili9341.h"
#include "tm_stm32f4_fonts.h"
#include "tm_stm32f4_spi.h"

#endif


text:
package com.intellij.lang.jsgraphql.psi;

import com.intellij.lang.jsgraphql.GraphQLLanguage;
import com.intellij.psi.tree.IElementType;
import org.jetbrains.annotations.NonNls;
import org.jetbrains.annotations.NotNull;

public class GraphQLTokenType extends IElementType {
  public GraphQLTokenType(@NotNull @NonNls String debugName) {
    super(debugName, GraphQLLanguage.INSTANCE);
  }
}


text:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<TITLE
>itf_mul</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.79"><LINK
REL="HOME"
TITLE="LIBIT Documentation"
HREF="index.html"><LINK
REL="UP"
HREF="refmanual.html"><LINK
REL="PREVIOUS"
TITLE="itf_expectation"
HREF="man.itf-expectation.html"><LINK
REL="NEXT"
TITLE="itf_integrate"
HREF="man.itf-integrate.html">

LIBIT Documentation

Prev		Next

itf_mul

Name
itf_mul -- multiplication operator

Synopsis

#include <it/math.h>

double itf_mul( double x, it_function_args(itf_sum) *args
        );

DESCRIPTION

The function itf_mul defines the product of two it_function_t. The product of the functions is obtained by computing the value of each function at position x and returning their product. The product operator has the following parameters, passed through the args argument.

Function parameters

f

         The first function to multiply.

f_args

         The parameters of the first function to multiply.

g

         The second function to multiply.

g_args

         The parameters of the second function to multiply.

RETURN VALUE

    The product for a given value 'x'

EXAMPLE

#include <math.h>

...

/* declare the integration parameters */
it_function_args(itf_mul) mul_args;
/* multiply the identity function with itself */
mul_args.f = itf_identity;
mul_args.f_args = NULL;
mul_args.g = itf_identity;
mul_args.g_args = NULL;
/* compute the value of the product in 1.0 */
itf_mul(1.0, &mul_args);

Prev	Home	Next

itf_expectation	Up	itf_integrate


text: require_relative 'yql/_req'


text:
// Copyright 2007-2010 The Apache Software Foundation.
//
// 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.
namespace Topshelf.Messages
{
	public enum ServiceEventType
	{
		Created,
		Starting,
		Running,
		Pausing,
		Paused,
		Continuing,
		Stopping,
		Stopped,
		Restarted,
		Fault,
		Unloaded,
		Unloading,
		Completed,
		FolderChanged,
		ShelfCreated,
		FolderRemoved,
	}
}


text:
package org.jesperancinha.xml.adder.csv;

import com.opencsv.bean.CsvBindByName;
import com.opencsv.bean.CsvBindByPosition;

/**
 * Created by joaofilipesabinoesperancinha on 18-02-16.
 */
public class AttributeAddBean {

    @CsvBindByName(capture = "name")
    @CsvBindByPosition(position = 0)
    private String name;

    @CsvBindByName(capture = "value")
    @CsvBindByPosition(position = 1)
    private String value;

    @CsvBindByName(capture = "xpath")
    @CsvBindByPosition(position = 2)
    private String xpath;

    public String getName() {
        return name;
    }

    public String getValue() {
        return value;
    }

    public String getXpath() {
        return xpath;
    }

    public void setName(String name) {
        this.name = name;
    }

    public void setValue(String value) {
        this.value = value;
    }

    public void setXpath(String xpath) {
        this.xpath = xpath;
    }
}


text:
export enum ResType {
  SUCCESS,
  ERROR,
  TRY_LATER,
  NOT_FOUND
}


text:
package ru.ag78.utils.loganalyzer.config;

import javax.xml.bind.annotation.XmlType;

@XmlType
public class LogFile {

    private String path;
    private String encoding;

    public LogFile() {

    }

    public LogFile(String path, String encoding) {

        super();
        this.path = path;
        this.encoding = encoding;
    }

    public String getPath() {

        return path;
    }

    public void setPath(String path) {

        this.path = path;
    }

    public String getEncoding() {

        return encoding;
    }

    public void setEncoding(String encoding) {

        this.encoding = encoding;
    }
}


text:
#ifndef CQChartsLineJoin_H
#define CQChartsLineJoin_H

#include <CQChartsEnum.h>
#include <CQUtilMeta.h>

#include <QPen>

/*!
 * \brief line join
 * \ingroup Charts
 */
class CQChartsLineJoin : public CQChartsEnum<CQChartsLineJoin> {
 public:
  static void registerMetaType();

  static int metaTypeId;

  //---

  CQUTIL_DEF_META_CONVERSIONS(CQChartsLineJoin, metaTypeId)

 public:
  CQChartsLineJoin();

  explicit CQChartsLineJoin(const Qt::PenJoinStyle &join);

  explicit CQChartsLineJoin(const QString &str);

 ~CQChartsLineJoin() { }

  //---

  const Qt::PenJoinStyle &join() const { return join_; }

  //---

  bool isValid() const { return true; }

  const Qt::PenJoinStyle &type() const { return join_; }
  void setType(const Qt::PenJoinStyle &join) { join_ = join; }

  //--

  QString toString() const override;
  bool fromString(const QString &str) override;

  //---

  QStringList enumNames() const override;

 private:
  Qt::PenJoinStyle join_ { Qt::MiterJoin };
};

//------

CQUTIL_DCL_META_TYPE(CQChartsLineJoin)

#endif


text:
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
  <property>
    <name>hbase.client.primaryCallTimeout.get</name>
    <value>15</value>
  </property>
  <property>
    <name>hbase.client.primaryCallTimeout.multiget</name>
    <value>16</value>
  </property>
</configuration>


text:
[![](https://img.shields.io/github/workflow/status/damnever/pigar/PyCI?style=flat-square)](https://github.com/damnever/pigar/actions) [![](https://img.shields.io/pypi/v/pigar.svg?style=flat-square)](https://pypi.org/project/pigar)

- Generating requirements.txt for Python project.
   - Handling the difference between different Python versions.
   - Jupyter notebook (`*.ipynb`) support.
   - Including the import statements from ``exec``/``eval``, doctest of docstring, etc.
- Searching packages by import name.
- Checking the latest versions for Python project.

**NOTE**: [Pipenv](https://packaging.python.org/tutorials/managing-dependencies/#managing-dependencies) or other tools is recommended for improving your development flow.

![](https://raw.githubusercontent.com/damnever/pigar/master/guide.gif)

### Installation

`pigar` can run on Python 2.7.+ and 3.2+.

To install it with `pip`, use:
```
[sudo] pip install pigar
```
To install it with ``conda``, use:
```
conda install -c conda-forge pigar
```
To get the newest code from GitHub:
```
pip install git+https://github.com/damnever/pigar.git@[master or other branch] --upgrade
```

### Usage

- `pigar` can consider all kinds of complicated situations. For example, this project has [py2_requirements.txt](./py2_requirements.txt) and [py3_requirements.txt](./py3_requirements.txt) for different Python versions(see the above GIF).

    ```
    # Generate requirements.txt for current directory.
    $ pigar

    # Generating requirements.txt for given directory in given file.
    $ pigar -p ../dev-requirements.txt -P ../
    ```

    `pigar` can list all files which referenced the package(the line numbers for Jupyter notebook may be a bit confusing), for example:
    ```
    # project/foo.py: 2,3
    # project/bar/baz.py: 2,7,8,9
    foobar == 3.3.3
    ```

    If the requirements.txt is overwritten, ``pigar`` will show the difference between the old and the new.

- If you do not know the import name that belongs to a specific package (more generally, does `Import Error: xxx` drive you crazy?), such as `bs4` which may come from `beautifulsoup4` or `MySQLdb` which could come from `MySQL_Python`, try searching for it:

    ```
    $ pigar -s bs4 MySQLdb
    ```

- Checking for the latest version:

    ```
    # Specify a requirements file.
    $ pigar -c ./requirements.txt

    # Or, you can let pigar searching all *requirements.txt in the current directory
    # level by itself. If not found, pigar will generate a new requirements.txt
    # for the current project, then check for the latest versions.
    $ pigar -c
    ```

- More:

   ```
   pigar --help
   ```

### FAQ

<details>
  <summary>
  (1) Why `pigar` generates multiple packages for same import name?

  (2) Why `pigar` generates different packages for same import name in different environment?
  </summary>

`pigar` can not handle it gracefully, you may need to remove the duplicate packages in requirements.txt manually.
Install the required package(remove others) in local environment should fix it as well.

Related issues: [#32](https://github.com/damnever/pigar/issues/32), [#68](https://github.com/damnever/pigar/issues/68), [#75](https://github.com/damnever/pigar/issues/75#issuecomment-605639825).
</details>

### More

`pigar` does not use regular expressions in such a violent way. Instead, it uses AST, which is a better method for extracting imported names from arguments of `exec`/`eval`, doctest of docstring, etc.

Also, `pigar` can detect the difference between different Python versions. For example, you can find `concurrent.futures` from the Python 3.2 standard library, but you will need install `futures` in earlier versions of Python to get `concurrent.futures`, this is not a hardcode.

If you have any issues or suggestions, [please submit an issue on GitHub](https://github.com/damnever/pigar/issues). [**All contributions are appreciated!**](https://github.com/damnever/pigar/graphs/contributors)

### LICENSE

[The BSD 3-Clause License](https://github.com/damnever/pigar/blob/master/LICENSE)


text:
OneviewCookbook::ResourceBaseProperties.load(self)

property :deployment_plans, Array, default: []
property :golden_images, Array, default: []
property :os_build_plans, Array, default: []
property :plan_scripts, Array, default: []
property :new_name, String
property :file_path, String
property :deployment_group, String
property :timeout, Integer

resource_name :image_streamer_artifact_bundle

default_action :create_if_missing

action :create_if_missing do
  OneviewCookbook::Helper.do_resource_action(self, :ArtifactBundle, :create_if_missing, OneviewCookbook::ImageStreamer)
end

action :update_name do
  OneviewCookbook::Helper.do_resource_action(self, :ArtifactBundle, :update_name, OneviewCookbook::ImageStreamer)
end

action :delete do
  OneviewCookbook::Helper.do_resource_action(self, :ArtifactBundle, :delete, OneviewCookbook::ImageStreamer)
end

action :download do
  OneviewCookbook::Helper.do_resource_action(self, :ArtifactBundle, :download, OneviewCookbook::ImageStreamer)
end

action :upload do
  OneviewCookbook::Helper.do_resource_action(self, :ArtifactBundle, :upload, OneviewCookbook::ImageStreamer)
end

action :extract do
  OneviewCookbook::Helper.do_resource_action(self, :ArtifactBundle, :extract, OneviewCookbook::ImageStreamer)
end

action :backup do
  OneviewCookbook::Helper.do_resource_action(self, :ArtifactBundle, :backup, OneviewCookbook::ImageStreamer)
end

action :backup_from_file do
  OneviewCookbook::Helper.do_resource_action(self, :ArtifactBundle, :backup_from_file, OneviewCookbook::ImageStreamer)
end

action :download_backup do
  OneviewCookbook::Helper.do_resource_action(self, :ArtifactBundle, :download_backup, OneviewCookbook::ImageStreamer)
end

action :extract_backup do
  OneviewCookbook::Helper.do_resource_action(self, :ArtifactBundle, :extract_backup, OneviewCookbook::ImageStreamer)
end


text:
"""
STATEMENT
Given a list, rotate the list to the right by k places, where k is non-negative.

CLARIFICATIONS
- Is the list given as an array? No, a linked list.
- Each node in the linked list is an object of a custom data structure, right? Yes.
  Define them.
- Can k be more than the length of the list? Sure.
- Do I return the head of the updated list? Yes.

EXAMPLES
1->2->3->4->5->None, 2 => 4->5->1->2->3->NULL

COMMENTS
- If k is much longer than the list length, we should not update the list unneccessarily,
  so k should be updated to the k modulo list length.
- If k is 0, return the original list.
"""

def rotateRight(head, k):
        """
        :type head: ListNode
        :type k: int
        :rtype: ListNode
        """
      if head is None:
    		return head

      temp = head
    	list_length = 1

      while temp.next is not None:
    		temp = temp.next
    		list_length += 1

      k = k%list_length
    	if k == 0:
    		return head

      prev, curr = head, head
    	count = 1

      while count <= k:
    		curr = curr.next
    		count += 1

      while curr.next is not None:
    		prev = prev.next
    		curr = curr.next
    	to_return = prev.next
    	prev.next = None
    	curr.next = head
    	return to_return


text:
#ifndef _ASM_FCNTL_H
#define _ASM_FCNTL_H

/* open/fcntl - O_SYNC is only implemented on blocks devices and on files
   located on an ext2 file system */
#define O_ACCMODE	0x0003
#define O_RDONLY	0x0000
#define O_WRONLY	0x0001
#define O_RDWR		0x0002
#define O_APPEND	0x0008
#define O_SYNC		0x0010
#define O_NONBLOCK	0x0080
#define O_CREAT         0x0100	/* not fcntl */
#define O_TRUNC		0x0200	/* not fcntl */
#define O_EXCL		0x0400	/* not fcntl */
#define O_NOCTTY	0x0800	/* not fcntl */
#define FASYNC		0x1000	/* fcntl, for BSD compatibility */
#define O_LARGEFILE	0x2000	/* allow large file opens */
#define O_DIRECT	0x8000	/* direct disk access hint */
#define O_DIRECTORY	0x10000	/* must be a directory */
#define O_NOFOLLOW	0x20000	/* don't follow links */
#define O_NOATIME	0x40000

#define O_NDELAY	O_NONBLOCK

#define F_DUPFD		0	/* dup */
#define F_GETFD		1	/* get close_on_exec */
#define F_SETFD		2	/* set/clear close_on_exec */
#define F_GETFL		3	/* get file->f_flags */
#define F_SETFL		4	/* set file->f_flags */
#define F_GETLK		14
#define F_SETLK		6
#define F_SETLKW	7

#define F_SETOWN	24	/*  for sockets. */
#define F_GETOWN	23	/*  for sockets. */
#define F_SETSIG	10	/*  for sockets. */
#define F_GETSIG	11	/*  for sockets. */

#ifndef __mips64
#define F_GETLK64	33	/*  using 'struct flock64' */
#define F_SETLK64	34
#define F_SETLKW64	35
#endif

/* for F_[GET|SET]FL */
#define FD_CLOEXEC	1	/* actually anything with low bit set goes */

/* for posix fcntl() and lockf() */
#define F_RDLCK		0
#define F_WRLCK		1
#define F_UNLCK		2

/* for old implementation of bsd flock () */
#define F_EXLCK		4	/* or 3 */
#define F_SHLCK		8	/* or 4 */

/* for leases */
#define F_INPROGRESS	16

/* operations for bsd flock(), also used by the kernel implementation */
#define LOCK_SH		1	/* shared lock */
#define LOCK_EX		2	/* exclusive lock */
#define LOCK_NB		4	/* or'd with one of the above to prevent
				   blocking */
#define LOCK_UN		8	/* remove lock */

#define LOCK_MAND	32	/* This is a mandatory flock */
#define LOCK_READ	64	/* ... Which allows concurrent read operations */
#define LOCK_WRITE	128	/* ... Which allows concurrent write operations */
#define LOCK_RW		192	/* ... Which allows concurrent read & write ops */

/*
 * The flavours of struct flock.  "struct flock" is the ABI compliant
 * variant.  Finally struct flock64 is the LFS variant of struct flock.  As
 * a historic accident and inconsistence with the ABI definition it doesn't
 * contain all the same fields as struct flock.
 */

#ifndef __mips64

typedef struct flock {
	short	l_type;
	short	l_whence;
	__kernel_off_t l_start;
	__kernel_off_t l_len;
	long	l_sysid;
	__kernel_pid_t l_pid;
	long	pad[4];
} flock_t;

typedef struct flock64 {
	short	l_type;
	short	l_whence;
	loff_t	l_start;
	loff_t	l_len;
	pid_t	l_pid;
} flock64_t;

#else /* 64-bit definitions */

typedef struct flock {
	short	l_type;
	short	l_whence;
	__kernel_off_t l_start;
	__kernel_off_t l_len;
	__kernel_pid_t l_pid;
} flock_t;

#endif

#define F_LINUX_SPECIFIC_BASE	1024

#endif /* _ASM_FCNTL_H */


text:
.class public Landroid/support/v4/app/NotificationCompat;
.super Ljava/lang/Object;
.source "NotificationCompat.java"

# annotations
.annotation system Ldalvik/annotation/MemberClasses;
    value = {
        Landroid/support/v4/app/NotificationCompat$1;,
        Landroid/support/v4/app/NotificationCompat$CarExtender;,
        Landroid/support/v4/app/NotificationCompat$WearableExtender;,
        Landroid/support/v4/app/NotificationCompat$Extender;,
        Landroid/support/v4/app/NotificationCompat$Action;,
        Landroid/support/v4/app/NotificationCompat$InboxStyle;,
        Landroid/support/v4/app/NotificationCompat$BigTextStyle;,
        Landroid/support/v4/app/NotificationCompat$BigPictureStyle;,
        Landroid/support/v4/app/NotificationCompat$Style;,
        Landroid/support/v4/app/NotificationCompat$Builder;,
        Landroid/support/v4/app/NotificationCompat$NotificationCompatImplApi21;,
        Landroid/support/v4/app/NotificationCompat$NotificationCompatImplApi20;,
        Landroid/support/v4/app/NotificationCompat$NotificationCompatImplKitKat;,
        Landroid/support/v4/app/NotificationCompat$NotificationCompatImplJellybean;,
        Landroid/support/v4/app/NotificationCompat$NotificationCompatImplIceCreamSandwich;,
        Landroid/support/v4/app/NotificationCompat$NotificationCompatImplHoneycomb;,
        Landroid/support/v4/app/NotificationCompat$NotificationCompatImplGingerbread;,
        Landroid/support/v4/app/NotificationCompat$NotificationCompatImplBase;,
        Landroid/support/v4/app/NotificationCompat$BuilderExtender;,
        Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;
    }
.end annotation

# static fields
.field public static final CATEGORY_ALARM:Ljava/lang/String; = "alarm"

.field public static final CATEGORY_CALL:Ljava/lang/String; = "call"

.field public static final CATEGORY_EMAIL:Ljava/lang/String; = "email"

.field public static final CATEGORY_ERROR:Ljava/lang/String; = "err"

.field public static final CATEGORY_EVENT:Ljava/lang/String; = "event"

.field public static final CATEGORY_MESSAGE:Ljava/lang/String; = "msg"

.field public static final CATEGORY_PROGRESS:Ljava/lang/String; = "progress"

.field public static final CATEGORY_PROMO:Ljava/lang/String; = "promo"

.field public static final CATEGORY_RECOMMENDATION:Ljava/lang/String; = "recommendation"

.field public static final CATEGORY_SERVICE:Ljava/lang/String; = "service"

.field public static final CATEGORY_SOCIAL:Ljava/lang/String; = "social"

.field public static final CATEGORY_STATUS:Ljava/lang/String; = "status"

.field public static final CATEGORY_SYSTEM:Ljava/lang/String; = "sys"

.field public static final CATEGORY_TRANSPORT:Ljava/lang/String; = "transport"

.field public static final COLOR_DEFAULT:I = 0x0
    .annotation build Landroid/support/annotation/ColorInt;
    .end annotation
.end field

.field public static final DEFAULT_ALL:I = -0x1

.field public static final DEFAULT_LIGHTS:I = 0x4

.field public static final DEFAULT_SOUND:I = 0x1

.field public static final DEFAULT_VIBRATE:I = 0x2

.field public static final EXTRA_BACKGROUND_IMAGE_URI:Ljava/lang/String; = "android.backgroundImageUri"

.field public static final EXTRA_BIG_TEXT:Ljava/lang/String; = "android.bigText"

.field public static final EXTRA_COMPACT_ACTIONS:Ljava/lang/String; = "android.compactActions"

.field public static final EXTRA_INFO_TEXT:Ljava/lang/String; = "android.infoText"

.field public static final EXTRA_LARGE_ICON:Ljava/lang/String; = "android.largeIcon"

.field public static final EXTRA_LARGE_ICON_BIG:Ljava/lang/String; = "android.largeIcon.big"

.field public static final EXTRA_MEDIA_SESSION:Ljava/lang/String; = "android.mediaSession"

.field public static final EXTRA_PEOPLE:Ljava/lang/String; = "android.people"

.field public static final EXTRA_PICTURE:Ljava/lang/String; = "android.picture"

.field public static final EXTRA_PROGRESS:Ljava/lang/String; = "android.progress"

.field public static final EXTRA_PROGRESS_INDETERMINATE:Ljava/lang/String; = "android.progressIndeterminate"

.field public static final EXTRA_PROGRESS_MAX:Ljava/lang/String; = "android.progressMax"

.field public static final EXTRA_SHOW_CHRONOMETER:Ljava/lang/String; = "android.showChronometer"

.field public static final EXTRA_SHOW_WHEN:Ljava/lang/String; = "android.showWhen"

.field public static final EXTRA_SMALL_ICON:Ljava/lang/String; = "android.icon"

.field public static final EXTRA_SUB_TEXT:Ljava/lang/String; = "android.subText"

.field public static final EXTRA_SUMMARY_TEXT:Ljava/lang/String; = "android.summaryText"

.field public static final EXTRA_TEMPLATE:Ljava/lang/String; = "android.template"

.field public static final EXTRA_TEXT:Ljava/lang/String; = "android.text"

.field public static final EXTRA_TEXT_LINES:Ljava/lang/String; = "android.textLines"

.field public static final EXTRA_TITLE:Ljava/lang/String; = "android.title"

.field public static final EXTRA_TITLE_BIG:Ljava/lang/String; = "android.title.big"

.field public static final FLAG_AUTO_CANCEL:I = 0x10

.field public static final FLAG_FOREGROUND_SERVICE:I = 0x40

.field public static final FLAG_GROUP_SUMMARY:I = 0x200

.field public static final FLAG_HIGH_PRIORITY:I = 0x80

.field public static final FLAG_INSISTENT:I = 0x4

.field public static final FLAG_LOCAL_ONLY:I = 0x100

.field public static final FLAG_NO_CLEAR:I = 0x20

.field public static final FLAG_ONGOING_EVENT:I = 0x2

.field public static final FLAG_ONLY_ALERT_ONCE:I = 0x8

.field public static final FLAG_SHOW_LIGHTS:I = 0x1

.field private static final IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

.field public static final PRIORITY_DEFAULT:I = 0x0

.field public static final PRIORITY_HIGH:I = 0x1

.field public static final PRIORITY_LOW:I = -0x1

.field public static final PRIORITY_MAX:I = 0x2

.field public static final PRIORITY_MIN:I = -0x2

.field public static final STREAM_DEFAULT:I = -0x1

.field public static final VISIBILITY_PRIVATE:I = 0x0

.field public static final VISIBILITY_PUBLIC:I = 0x1

.field public static final VISIBILITY_SECRET:I = -0x1

# direct methods
.method static constructor <clinit>()V
    .registers 2

    .prologue
    .line 830
    sget v0, Landroid/os/Build$VERSION;->SDK_INT:I

    const/16 v1, 0x15

    if-lt v0, v1, :cond_e

    .line 831
    new-instance v0, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplApi21;

    invoke-direct {v0}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplApi21;-><init>()V

    sput-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    .line 847
    :goto_d
    return-void

    .line 832
    :cond_e
    sget v0, Landroid/os/Build$VERSION;->SDK_INT:I

    const/16 v1, 0x14

    if-lt v0, v1, :cond_1c

    .line 833
    new-instance v0, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplApi20;

    invoke-direct {v0}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplApi20;-><init>()V

    sput-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    goto :goto_d

    .line 834
    :cond_1c
    sget v0, Landroid/os/Build$VERSION;->SDK_INT:I

    const/16 v1, 0x13

    if-lt v0, v1, :cond_2a

    .line 835
    new-instance v0, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplKitKat;

    invoke-direct {v0}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplKitKat;-><init>()V

    sput-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    goto :goto_d

    .line 836
    :cond_2a
    sget v0, Landroid/os/Build$VERSION;->SDK_INT:I

    const/16 v1, 0x10

    if-lt v0, v1, :cond_38

    .line 837
    new-instance v0, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplJellybean;

    invoke-direct {v0}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplJellybean;-><init>()V

    sput-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    goto :goto_d

    .line 838
    :cond_38
    sget v0, Landroid/os/Build$VERSION;->SDK_INT:I

    const/16 v1, 0xe

    if-lt v0, v1, :cond_46

    .line 839
    new-instance v0, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplIceCreamSandwich;

    invoke-direct {v0}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplIceCreamSandwich;-><init>()V

    sput-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    goto :goto_d

    .line 840
    :cond_46
    sget v0, Landroid/os/Build$VERSION;->SDK_INT:I

    const/16 v1, 0xb

    if-lt v0, v1, :cond_54

    .line 841
    new-instance v0, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplHoneycomb;

    invoke-direct {v0}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplHoneycomb;-><init>()V

    sput-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    goto :goto_d

    .line 842
    :cond_54
    sget v0, Landroid/os/Build$VERSION;->SDK_INT:I

    const/16 v1, 0x9

    if-lt v0, v1, :cond_62

    .line 843
    new-instance v0, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplGingerbread;

    invoke-direct {v0}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplGingerbread;-><init>()V

    sput-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    goto :goto_d

    .line 845
    :cond_62
    new-instance v0, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplBase;

    invoke-direct {v0}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImplBase;-><init>()V

    sput-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    goto :goto_d
.end method

.method public constructor <init>()V
    .registers 1

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

    .line 2940
    return-void
.end method

.method static synthetic access$000(Landroid/support/v4/app/NotificationBuilderWithActions;Ljava/util/ArrayList;)V
    .registers 2
    .param p0, "x0"    # Landroid/support/v4/app/NotificationBuilderWithActions;
    .param p1, "x1"    # Ljava/util/ArrayList;

    .prologue
    .line 42
    invoke-static {p0, p1}, Landroid/support/v4/app/NotificationCompat;->addActionsToBuilder(Landroid/support/v4/app/NotificationBuilderWithActions;Ljava/util/ArrayList;)V

    return-void
.end method

.method static synthetic access$100(Landroid/support/v4/app/NotificationBuilderWithBuilderAccessor;Landroid/support/v4/app/NotificationCompat$Style;)V
    .registers 2
    .param p0, "x0"    # Landroid/support/v4/app/NotificationBuilderWithBuilderAccessor;
    .param p1, "x1"    # Landroid/support/v4/app/NotificationCompat$Style;

    .prologue
    .line 42
    invoke-static {p0, p1}, Landroid/support/v4/app/NotificationCompat;->addStyleToBuilderJellybean(Landroid/support/v4/app/NotificationBuilderWithBuilderAccessor;Landroid/support/v4/app/NotificationCompat$Style;)V

    return-void
.end method

.method static synthetic access$200()Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;
    .registers 1

    .prologue
    .line 42
    sget-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    return-object v0
.end method

.method static synthetic access$500(Landroid/os/Bundle;Ljava/lang/String;)[Landroid/app/Notification;
    .registers 3
    .param p0, "x0"    # Landroid/os/Bundle;
    .param p1, "x1"    # Ljava/lang/String;

    .prologue
    .line 42
    invoke-static {p0, p1}, Landroid/support/v4/app/NotificationCompat;->getNotificationArrayFromBundle(Landroid/os/Bundle;Ljava/lang/String;)[Landroid/app/Notification;

    move-result-object v0

    return-object v0
.end method

.method private static addActionsToBuilder(Landroid/support/v4/app/NotificationBuilderWithActions;Ljava/util/ArrayList;)V
    .registers 5
    .param p0, "builder"    # Landroid/support/v4/app/NotificationBuilderWithActions;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Landroid/support/v4/app/NotificationBuilderWithActions;",
            "Ljava/util/ArrayList",
            "<",
            "Landroid/support/v4/app/NotificationCompat$Action;",
            ">;)V"
        }
    .end annotation

    .prologue
    .line 794
    .local p1, "actions":Ljava/util/ArrayList;, "Ljava/util/ArrayList<Landroid/support/v4/app/NotificationCompat$Action;>;"
    invoke-virtual {p1}, Ljava/util/ArrayList;->iterator()Ljava/util/Iterator;

    move-result-object v1

    .local v1, "i$":Ljava/util/Iterator;
    :goto_4
    invoke-interface {v1}, Ljava/util/Iterator;->hasNext()Z

    move-result v2

    if-eqz v2, :cond_14

    invoke-interface {v1}, Ljava/util/Iterator;->next()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Landroid/support/v4/app/NotificationCompat$Action;

    .line 795
    .local v0, "action":Landroid/support/v4/app/NotificationCompat$Action;
    invoke-interface {p0, v0}, Landroid/support/v4/app/NotificationBuilderWithActions;->addAction(Landroid/support/v4/app/NotificationCompatBase$Action;)V

    goto :goto_4

    .line 797
    .end local v0    # "action":Landroid/support/v4/app/NotificationCompat$Action;
    :cond_14
    return-void
.end method

.method private static addStyleToBuilderJellybean(Landroid/support/v4/app/NotificationBuilderWithBuilderAccessor;Landroid/support/v4/app/NotificationCompat$Style;)V
    .registers 12
    .param p0, "builder"    # Landroid/support/v4/app/NotificationBuilderWithBuilderAccessor;
    .param p1, "style"    # Landroid/support/v4/app/NotificationCompat$Style;

    .prologue
    .line 801
    if-eqz p1, :cond_14

    .line 802
    instance-of v0, p1, Landroid/support/v4/app/NotificationCompat$BigTextStyle;

    if-eqz v0, :cond_15

    move-object v8, p1

    .line 803
    check-cast v8, Landroid/support/v4/app/NotificationCompat$BigTextStyle;

    .line 804
    .local v8, "bigTextStyle":Landroid/support/v4/app/NotificationCompat$BigTextStyle;
    iget-object v0, v8, Landroid/support/v4/app/NotificationCompat$BigTextStyle;->mBigContentTitle:Ljava/lang/CharSequence;

    iget-boolean v1, v8, Landroid/support/v4/app/NotificationCompat$BigTextStyle;->mSummaryTextSet:Z

    iget-object v2, v8, Landroid/support/v4/app/NotificationCompat$BigTextStyle;->mSummaryText:Ljava/lang/CharSequence;

    iget-object v3, v8, Landroid/support/v4/app/NotificationCompat$BigTextStyle;->mBigText:Ljava/lang/CharSequence;

    invoke-static {p0, v0, v1, v2, v3}, Landroid/support/v4/app/NotificationCompatJellybean;->addBigTextStyle(Landroid/support/v4/app/NotificationBuilderWithBuilderAccessor;Ljava/lang/CharSequence;ZLjava/lang/CharSequence;Ljava/lang/CharSequence;)V

    .line 827
    .end local v8    # "bigTextStyle":Landroid/support/v4/app/NotificationCompat$BigTextStyle;
    :cond_14
    :goto_14
    return-void

    .line 809
    :cond_15
    instance-of v0, p1, Landroid/support/v4/app/NotificationCompat$InboxStyle;

    if-eqz v0, :cond_28

    move-object v9, p1

    .line 810
    check-cast v9, Landroid/support/v4/app/NotificationCompat$InboxStyle;

    .line 811
    .local v9, "inboxStyle":Landroid/support/v4/app/NotificationCompat$InboxStyle;
    iget-object v0, v9, Landroid/support/v4/app/NotificationCompat$InboxStyle;->mBigContentTitle:Ljava/lang/CharSequence;

    iget-boolean v1, v9, Landroid/support/v4/app/NotificationCompat$InboxStyle;->mSummaryTextSet:Z

    iget-object v2, v9, Landroid/support/v4/app/NotificationCompat$InboxStyle;->mSummaryText:Ljava/lang/CharSequence;

    iget-object v3, v9, Landroid/support/v4/app/NotificationCompat$InboxStyle;->mTexts:Ljava/util/ArrayList;

    invoke-static {p0, v0, v1, v2, v3}, Landroid/support/v4/app/NotificationCompatJellybean;->addInboxStyle(Landroid/support/v4/app/NotificationBuilderWithBuilderAccessor;Ljava/lang/CharSequence;ZLjava/lang/CharSequence;Ljava/util/ArrayList;)V

    goto :goto_14

    .line 816
    .end local v9    # "inboxStyle":Landroid/support/v4/app/NotificationCompat$InboxStyle;
    :cond_28
    instance-of v0, p1, Landroid/support/v4/app/NotificationCompat$BigPictureStyle;

    if-eqz v0, :cond_14

    move-object v7, p1

    .line 817
    check-cast v7, Landroid/support/v4/app/NotificationCompat$BigPictureStyle;

    .line 818
    .local v7, "bigPictureStyle":Landroid/support/v4/app/NotificationCompat$BigPictureStyle;
    iget-object v1, v7, Landroid/support/v4/app/NotificationCompat$BigPictureStyle;->mBigContentTitle:Ljava/lang/CharSequence;

    iget-boolean v2, v7, Landroid/support/v4/app/NotificationCompat$BigPictureStyle;->mSummaryTextSet:Z

    iget-object v3, v7, Landroid/support/v4/app/NotificationCompat$BigPictureStyle;->mSummaryText:Ljava/lang/CharSequence;

    iget-object v4, v7, Landroid/support/v4/app/NotificationCompat$BigPictureStyle;->mPicture:Landroid/graphics/Bitmap;

    iget-object v5, v7, Landroid/support/v4/app/NotificationCompat$BigPictureStyle;->mBigLargeIcon:Landroid/graphics/Bitmap;

    iget-boolean v6, v7, Landroid/support/v4/app/NotificationCompat$BigPictureStyle;->mBigLargeIconSet:Z

    move-object v0, p0

    invoke-static/range {v0 .. v6}, Landroid/support/v4/app/NotificationCompatJellybean;->addBigPictureStyle(Landroid/support/v4/app/NotificationBuilderWithBuilderAccessor;Ljava/lang/CharSequence;ZLjava/lang/CharSequence;Landroid/graphics/Bitmap;Landroid/graphics/Bitmap;Z)V

    goto :goto_14
.end method

.method public static getAction(Landroid/app/Notification;I)Landroid/support/v4/app/NotificationCompat$Action;
    .registers 3
    .param p0, "notif"    # Landroid/app/Notification;
    .param p1, "actionIndex"    # I

    .prologue
    .line 3308
    sget-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    invoke-interface {v0, p0, p1}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;->getAction(Landroid/app/Notification;I)Landroid/support/v4/app/NotificationCompat$Action;

    move-result-object v0

    return-object v0
.end method

.method public static getActionCount(Landroid/app/Notification;)I
    .registers 2
    .param p0, "notif"    # Landroid/app/Notification;

    .prologue
    .line 3298
    sget-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    invoke-interface {v0, p0}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;->getActionCount(Landroid/app/Notification;)I

    move-result v0

    return v0
.end method

.method public static getCategory(Landroid/app/Notification;)Ljava/lang/String;
    .registers 2
    .param p0, "notif"    # Landroid/app/Notification;

    .prologue
    .line 3317
    sget-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    invoke-interface {v0, p0}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;->getCategory(Landroid/app/Notification;)Ljava/lang/String;

    move-result-object v0

    return-object v0
.end method

.method public static getExtras(Landroid/app/Notification;)Landroid/os/Bundle;
    .registers 2
    .param p0, "notif"    # Landroid/app/Notification;

    .prologue
    .line 3290
    sget-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    invoke-interface {v0, p0}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;->getExtras(Landroid/app/Notification;)Landroid/os/Bundle;

    move-result-object v0

    return-object v0
.end method

.method public static getGroup(Landroid/app/Notification;)Ljava/lang/String;
    .registers 2
    .param p0, "notif"    # Landroid/app/Notification;

    .prologue
    .line 3335
    sget-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    invoke-interface {v0, p0}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;->getGroup(Landroid/app/Notification;)Ljava/lang/String;

    move-result-object v0

    return-object v0
.end method

.method public static getLocalOnly(Landroid/app/Notification;)Z
    .registers 2
    .param p0, "notif"    # Landroid/app/Notification;

    .prologue
    .line 3327
    sget-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    invoke-interface {v0, p0}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;->getLocalOnly(Landroid/app/Notification;)Z

    move-result v0

    return v0
.end method

.method private static getNotificationArrayFromBundle(Landroid/os/Bundle;Ljava/lang/String;)[Landroid/app/Notification;
    .registers 6
    .param p0, "bundle"    # Landroid/os/Bundle;
    .param p1, "key"    # Ljava/lang/String;

    .prologue
    .line 3272
    invoke-virtual {p0, p1}, Landroid/os/Bundle;->getParcelableArray(Ljava/lang/String;)[Landroid/os/Parcelable;

    move-result-object v0

    .line 3273
    .local v0, "array":[Landroid/os/Parcelable;
    instance-of v3, v0, [Landroid/app/Notification;

    if-nez v3, :cond_a

    if-nez v0, :cond_10

    .line 3274
    :cond_a
    check-cast v0, [Landroid/app/Notification;

    .end local v0    # "array":[Landroid/os/Parcelable;
    check-cast v0, [Landroid/app/Notification;

    move-object v2, v0

    .line 3281
    :goto_f
    return-object v2

    .line 3276
    .restart local v0    # "array":[Landroid/os/Parcelable;
    :cond_10
    array-length v3, v0

    new-array v2, v3, [Landroid/app/Notification;

    .line 3277
    .local v2, "typedArray":[Landroid/app/Notification;
    const/4 v1, 0x0

    .local v1, "i":I
    :goto_14
    array-length v3, v0

    if-ge v1, v3, :cond_20

    .line 3278
    aget-object v3, v0, v1

    check-cast v3, Landroid/app/Notification;

    aput-object v3, v2, v1

    .line 3277
    add-int/lit8 v1, v1, 0x1

    goto :goto_14

    .line 3280
    :cond_20
    invoke-virtual {p0, p1, v2}, Landroid/os/Bundle;->putParcelableArray(Ljava/lang/String;[Landroid/os/Parcelable;)V

    goto :goto_f
.end method

.method public static getSortKey(Landroid/app/Notification;)Ljava/lang/String;
    .registers 2
    .param p0, "notif"    # Landroid/app/Notification;

    .prologue
    .line 3361
    sget-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    invoke-interface {v0, p0}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;->getSortKey(Landroid/app/Notification;)Ljava/lang/String;

    move-result-object v0

    return-object v0
.end method

.method public static isGroupSummary(Landroid/app/Notification;)Z
    .registers 2
    .param p0, "notif"    # Landroid/app/Notification;

    .prologue
    .line 3345
    sget-object v0, Landroid/support/v4/app/NotificationCompat;->IMPL:Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;

    invoke-interface {v0, p0}, Landroid/support/v4/app/NotificationCompat$NotificationCompatImpl;->isGroupSummary(Landroid/app/Notification;)Z

    move-result v0

    return v0
.end method


text:
package chrome.sockets.tcpServer.bindings

import scala.scalajs.js

class CreateInfo extends js.Object {

  def socketId: SocketId = js.native

}


text:
using System;
using System.ComponentModel.DataAnnotations.Schema;
using System.Threading.Tasks;
using Husky.KeyValues;
using Microsoft.Extensions.Configuration;

namespace Husky
{
	public abstract partial class ConfigBase
	{
		protected ConfigBase(IKeyValueManager keyValues, IConfiguration? appSettings) {
			KeyValues = keyValues;
			Configuration = appSettings;

			var hasChange = false;
			var props = this.GetType().GetProperties();

			foreach ( var p in props ) {

				if ( p.IsDefined(typeof(NotMappedAttribute), false) ) {
					continue;
				}
				if ( p.SetMethod == null ) {
					continue;
				}

				var defaultValue = p.GetValue(this);
				if ( defaultValue != null ) {
					var dbValue = KeyValues.GetOrAdd(p.Name, defaultValue.ToString());

					if ( !defaultValue.Equals(dbValue) ) {
						p.SetValue(this, Convert.ChangeType(dbValue, p.PropertyType));
						hasChange = true;
					}
				}
			}

			if ( hasChange ) {
				KeyValues.SaveAll();
			}
		}

		protected IKeyValueManager KeyValues { get; }
		protected IConfiguration? Configuration { get; }

		public void Reload() => KeyValues.Reload();
		public void Save(string key, string value) => KeyValues.Save(key, value);
		public void Save<T>(string key, T value) where T : struct => KeyValues.Save(key, value);
		public void SaveAll() => KeyValues.SaveAll();
		public async Task SaveAllAsync() => await KeyValues.SaveAllAsync();

		[NotMapped] public virtual bool IsTestEnv => Configuration?.GetValue<bool>("IsTestEnv") ?? false;
		[NotMapped] public virtual string? SecretToken => Configuration?.GetValue<string>("Security:SecretToken");
		[NotMapped] public virtual string? SuperCode => Configuration?.GetValue<string>("Security:SuperCode");
	}
}


text:
using Ecologylab.BigSemantics.Generated.Library.CreativeWorkNS.ArtworkNS.CartoonNS;
using Ecologylab.BigSemantics.MetaMetadataNS;
using Ecologylab.BigSemantics.MetadataNS.Builtins;
using Ecologylab.BigSemantics.MetadataNS.Scalar;
using Ecologylab.Collections;
using Simpl.Fundamental.Generic;
using Simpl.Serialization;
using Simpl.Serialization.Attributes;
using System;
using System.Collections;
using System.Collections.Generic;

namespace Ecologylab.BigSemantics.Generated.Library.CreativeWorkNS.ArtworkNS.CartoonNS
{
	[SimplInherit]
	public class GlobeCartoon : Cartoon
	{
		[SimplScalar]
		private MetadataDate datePublished;

		public GlobeCartoon()
		{ }

		public GlobeCartoon(MetaMetadataCompositeField mmd) : base(mmd) { }

		public MetadataDate DatePublished
		{
			get{return datePublished;}
			set
			{
				if (this.datePublished != value)
				{
					this.datePublished = value;
					// TODO we need to implement our property change notification mechanism.
				}
			}
		}
	}
}


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

package com.google.api.services.dataflow.model;

/**
 * Information about an output of a SeqMapTask.
 *
 *
 This is the Java data model class that specifies how to parse/serialize into the JSON that is
 * transmitted over HTTP when working with the Dataflow API. For a detailed explanation see:
 * https://developers.google.com/api-client-library/java/google-http-java-client/json
 *

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

  /**
   * The sink to write the output value to.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private Sink sink;

  /**
   * The id of the TupleTag the user code will tag the output value by.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String tag;

  /**
   * The sink to write the output value to.
   * @return value or {@code null} for none
   */
  public Sink getSink() {
    return sink;
  }

  /**
   * The sink to write the output value to.
   * @param sink sink or {@code null} for none
   */
  public SeqMapTaskOutputInfo setSink(Sink sink) {
    this.sink = sink;
    return this;
  }

  /**
   * The id of the TupleTag the user code will tag the output value by.
   * @return value or {@code null} for none
   */
  public java.lang.String getTag() {
    return tag;
  }

  /**
   * The id of the TupleTag the user code will tag the output value by.
   * @param tag tag or {@code null} for none
   */
  public SeqMapTaskOutputInfo setTag(java.lang.String tag) {
    this.tag = tag;
    return this;
  }

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

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

}


text:
module Gamework
  class Menu < Gamework::Composite
    attr_reader :cursor_position, :menu_options, :background

    def initialize(options={})
      defaults = {
        x: 0, y: 0, z: 1000,
        width:  options[:size]||100,
        height: options[:size]||28,
        columns: 1,
        justify: :center,
        padding: 0,
        margin: 0,
        menu_options: [],
        fixed:  true
      }
      if (pos = options.delete :position)
        options[:x] = pos[0]
        options[:y] = pos[1]
      end
      super(defaults.merge options)
    end

    def add_background(options={})
      defaults = {
        x: @x, y: @y, z: @z-1,
        width: @width + (@padding*2),
        height: height_with_margin
      }
      @background = Gamework::Shape.new :rectangle, defaults.merge(options)
      add_drawable(@background)
    end

    def add_option(text)
      options = {
        x: @x+@padding,
        y: next_option_y,
        z: @z+1,
        width: @width,
        height: @height,
        justify: @justify
      }
      text = Gamework::Text.new text, options
      @menu_options << text
      add_drawable(text)
    end

    def add_cursor(options={})
      defaults = {
        x: @x+@padding,
        y: @y+@padding,
        z: @z,
        width: @width,
        height: @height,
        color: 0x33ffffff
      }
      @cursor = Gamework::Shape.new :rectangle, defaults.merge(options)
      @cursor_position = 0
      add_drawable(@cursor)
    end

    def move_cursor(direction)
      @cursor_position = next_cursor_index(direction)
      reposition_cursor
    end

    def next_cursor_index(direction)
      # Determine the next possible index
      # for the cursor based for a given
      # direction

      last    = @menu_options.size - 1
      current = @cursor_position
      case direction.intern
      when :up
        current == 0 ? last : current-1
      when :down
        current == last ? 0 : current+1
      end
    end

    def reposition_cursor
      # Reset the cursor shape position
      # based on the current value of
      # cursor_position

      full_height = @margin + @height
      y = @y + @padding + (full_height*@cursor_position)
      @cursor.set_position @cursor.x, y
    end

    def next_option_y
      # Calculates the y position of
      # the next option based on the total
      # number of options, margin size,
      # padding, and y position of the menu.

      i = @menu_options.size
      (@height*i) + (@margin*i) + @y + @padding
    end

    def height_with_margin
      # Calculates the total height of all
      # options in the menu, including margin
      # between options and padding around all.

      # Add height for each option's margin
      margins = (@margin * @menu_options.size)
      # Don't add margin below final option
      margins -= @margin if margins > 0
      # Allocate options height and padding
      (@height * @menu_options.size) + margins + (@padding*2)
    end

  end
end


text:
using System;
using System.Collections;
using System.IO;
using FluorineFx.Configuration;

namespace FluorineFx.IO.Writers
{
    class AMF3CacheableObjectWriter : IAMFWriter
    {
        public AMF3CacheableObjectWriter()
        {
        }

        #region IAMFWriter Members

        public bool IsPrimitive { get { return true; } }

        public void WriteData(AMFWriter writer, object data)
        {
            writer.WriteAMF3Data((data as CacheableObject).Object);
        }

        #endregion
    }
}


text:
layout: post
title: "NERC Exeter: Metagenomics three hour practical"
description: ""
category:
tags: []
---

##Whole-genome shotgun metagenomics learning objectives

- Know how to subsample reads from a FASTQ file without losing paired-information (20 minutes)
- Know how to perform basic taxonomic assignment using a marker-gene method: MetaPhlan (10 minutes)
- Assess the impact sampling has on discovery of taxa (20 minutes)
- Know how to use MEGAN to visualise taxonomic information (30 minutes)
- Understand how the Lowest Common Ancestor parameters affect sensitivity and specificity of taxonomic assignments (20 minutes)
- Know how to use MEGAN to visualise functional information (30 minutes)
- Understand how to compare multiple samples in MEGAN (30 minutes)

###Optional, more advanced objectives (if you finish, or when back at home)
- Know how to generate a heatmap of taxa from Metaphlan results (20 minutes)
- Assemble a metagenome with Velvet (30 minutes)
- Know how to perform basic taxonomic and functional assignment using a sequence similarity method: BLAST/RapSearch2 (10 minutes)

#Part I: Multivariate statistics tutorial

Login to Amazon cloud and start a new Terminal

Download the tutorial archive onto your instance:

	wget http://nickloman.github.io/static/MultivariateStats.tar.gz

Go into Tutorials, untar the archive and cd into it:

	tar xvfz MultivariateStats.tar.gz

	cd MultivariateStats

Download the tutorial slides from <http://nickloman.github.io/static/MultivariateStatsTutorial.pdf> and follow the steps

# Part II: Taxonomic assignments from metagenomics data
##Datasets for this practical

For this practical we will use some real clinical metagenomics data from the E. coli outbreak in 2011, published in this JAMA article: <http://jama.jamanetwork.com/article.aspx?articleid=1677374>

*List* the contents of the the ~/shotgun\_metagenomics/ directory (remember ~ is just a short-cut for your home directory, e.g. /home/ubuntu, so this is the same as /home\/ubuntu/shotgun_metagenomics).

Q1. What format are the reads, and what can you deduce about the sequencing from them?

Q2. How many reads are in the biggest and the smallest files?

Initially, perform your work on the 2638-N12-STEC dataset.

Then, when you have run through the tutorial once, do it again but choose a dataset at random (or one you think might be particularly interesting!).

##Subsample reads with *seqtk*

seqtk is a useful 'Swiss army knife' for basic sequence manipulation.

Test it works:

	$ seqtk

	Usage:   seqtk <command> <arguments>

	Command: seq       common transformation of FASTA/Q
             comp      get the nucleotide composition of FASTA/Q
         	 sample    subsample sequences
        	 subseq    extract subsequences from FASTA/Q
         	 trimfq    trim FASTQ using the Phred algorithm
         	 hety      regional heterozygosity
         	 mutfa     point mutate FASTA at specified positions
         	 mergefa   merge two FASTA/Q files
         	 randbase  choose a random base from hets
         	 cutN      cut sequence at long N
         	 listhet   extract the position of each het

####Subsampling reads

This command shows how to subsample 100,000 read pairs from two large paired FASTQ files (remember to use the same random seed to keep pairing). Seqtk is smart enough to understand whether a file is zipped or not, so you don't need to unzip them first, but it will always output uncompressed files.

For two hypothetical files, pair1.fastq.gz and pair2.fastq.gz:

	seqtk sample -s100 pair1.fastq.gz 100000 > <MYREADS>_1.fastq
	seqtk sample -s100 pair2.fastq.gz 100000 > <MYREADS>_2.fastq

Replace <MYREADS> with an informative name, so if you are dealing with sample 2638 and have subsampled 10000 reads then perhaps `2638_10000_1.fastq` would be sensible.

You can read more about seqtk at C. Titus Brown's tutorial page here: <http://ged.msu.edu/angus/tutorials-2013/seqtk_tools.html>

### Taxonomic assignments with Metaphlan

The Metaphlan home page is here: <http://huttenhower.sph.harvard.edu/metaphlan>. Metaphlan is already installed on the Amazon Machine Image.

###Running Metaphlan

Metaphlan can use either BLAST or Bowtie2 for assignments. Bowtie2 is significantly faster, so we will use that. It should be already on your path.

Metaphlan doesn't need paired-end information, so you can just join your two files together to make use of all the data:

	cat <MYREADS>_1.fastq <MYREADS>_2.fastq > <MYREADS>.fastq

	metaphlan.py <MYREADS>.fastq --bowtie2db ~/software/metaphlan/bowtie2db/mpa --bt2_ps sensitive-local --nproc 8

The output will be sent to *stdout*, so you need to redirect it to a file, remember you can do this:

	metaphlan.py <MYREADS>.fastq --bowtie2db ~/software/metaphlan/bowtie2db/mpa --bt2_ps sensitive-local --nproc 8 > <MYREADS>_results.txt

*Hint*: Each time you run Metaphlan it will produce an output file named according to the input file. Metaphlan will not run if that file already exists, so ensure you use a different input file each time, or simply delete the file it produces first: it is is named `<MYREADS>.bowtie2out.txt`.

Run metaphlan for subsamplings of 1000, 10000, 100000 and 1000000 reads.

##Questions

Q3. How long did each file take to run? (hint prepend `time` to your command)

Examine the output of metaphlan (i.e. <MYREADS>\_results.txt).

Q4. What are the relative proportions of the most abundant phyla?  What about species?

Update the Google Docs spreadsheet here with your results:
<http://tinyurl.com/evomics-metaphlan>

Q5. How many different genera were detected at each sampling level?

##Advanced usage
There are other useful values of `-t` you can use other than `rel_ab`, the default:

* `rel_ab`: profiling a metagenomes in terms of relative abundances
* `reads_map`: mapping from reads to clades (only reads hitting a marker)
* `clade_profiles`: normalized marker counts for clades with at least a non-null marker
* `marker_ab_table`: normalized marker counts (only when > 0.0 and normalized by metagenome size if --nreads is specified)
* `marker_pres_table`: list of markers present in the sample (threshold at 1.0 if not differently specified with --pres_th

Now, go back to the beginning, choosing a new, uncharacterised sample. Add the results to the Google Docs file.

If you finish this before the recap, then try yet another sample and then go on to the heatmap generation exercise under the *Advanced* section.

## Visualizing results

### MEGAN

MEGAN is both a taxonomic analysis software, and a visualization tool. It is very helpful when 'mining' your dataset.

MEGAN is quite memory hungry and should be set-up to use as much memory as you can afford. We have done this for you already, but instructions for doing this are in the Advanced section.

MEGAN takes the results of read alignments as input. This alignment information typically comes from BLAST-format files, but can also come from SAM files produced by short-read aligners such as Bowtie2 and BWA, or the `aln` format from RAPSearch2.

Because generating the BLAST format files takes so long, we have precomputed them for you and generated MEGAN5-compatible files, but see at the bottom of the exercise for details on how to generate your own files for your data:

Start by downloading the results file for a random subsampling of 250,000 reads from the 2638-H dataset:

 - <http://nick-evomics.s3.amazonaws.com/2638-H-STEC.rap.rma>

Load this file into MEGAN (MEGAN is available under the "Other" menu on the Amazon Machine Image desktop).

For more information on using the various functionality in MEGAN, see the user manual: <http://ab.inf.uni-tuebingen.de/data/software/megan5/download/manual.pdf>

Please see this videocast for a recap of the MEGAN functionality:

<http://www.youtube.com/watch?v=R8dpD_lj6Ts&feature=em-upload_owner>

Have a look at the assignments.

Q6. How do they compare to your Metaphlan results? Are more taxa predicted or fewer?

Q7. Which taxon has the most assignments made to it?

Q8. What taxonomic level does this taxon belong to?

Q9. Why are so many reads being assigned at this level? Is it reasonable?

*Hint*: Inspect the read alignments by using right-mouse click (secondary click on Mac) on the nodes and chosing "Inspect reads".

Q10. Are there species in there that are unexpected?

Q11. What do the alignments look like? Are they good quality? Are they full-length?

Can you change the LCA parameters to make the results more specific?

Try it.

Does that make the results "better" or "worse" ?

Experiment more.

How about now?

Q12. Are there remaining species that don't make sense?

Q13. Inspect some taxa. Are there any you feel confident calling as present? Are there any you don't feel confident about? Why?

Try looking at the functional mode by clicking on the KEGG icon. Explore the different pathways and their presence/absence.

Q14. Does this sample have the Shiga-toxin genes in it? (hint: look under Human Diseases category) ?

Now, download some more files, you can choose one, or several from this list! If you relate the file names to the original paper we published you could even put together a hypothesis to test (note the diagnosis is in the file name).

 - <http://nick-evomics.s3.amazonaws.com/1122-H-Cdiff.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/1196-H-Salm.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/1196-N21-Salmonella.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/1253-H-Cdiff.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2535-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2535b-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2638-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2661-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2668-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2723-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2741-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2752-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2758-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2772-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2828-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2840-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2848-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2849-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2878-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2880-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2896-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/2971-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/3014-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/3093-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/3132-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/3134-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/3135-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/3185-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/3303-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/3549-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/3587-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/3646-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/3751-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/3852-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/3958-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/4096-H-Salm.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/4096-N2-Salmonella.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/4112-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/4141-H-STEC.rap.rma>
 - <http://nick-evomics.s3.amazonaws.com/4168-H-STEC.rap.rma>

Try out the MEGAN comparison mode by opening a few files.

Q15. Which sample (of the ones you picked) has the most *Escherichia* ?

If you get this far before the recap (or in your spare time), try assembling one of the files with Velvet or one of the other assemblers you use last week.

##Advanced

### Metaphlan

#### Heatmaps of multiple samples

Metaphlan comes with some plotting scripts which permit the generation of heatmaps.

You need to merge the results you generated from Metaphlan each sample:

    ~/software/metaphlan/utils/merge_metaphlan_tables.py <table1> <table2> <table3> <tableN..> > merged_table.txt

Top 10 genera:

	~/software/metaphlan/plotting_scripts/metaphlan_hclust_heatmap.py --in merged_table.txt --out test.png --tax_lev g --top 10

Open the `test.png` file after you have created it.

A more complex example (from the Metaphlan tutorial <https://bitbucket.org/nsegata/metaphlan/wiki/MetaPhlAn_Pipelines_Tutorial>)

	/home/ubuntu/software/metaphlan/plotting_scripts/metaphlan_hclust_heatmap.pymetaphlan_hclust_heatmap.py -c bbcry --top 25 \
	   --minv 0.1 -s log
	   --in merged_abundance_table.txt
	   --out output_images/abundance_heatmap.png

Here the settings mean:
* abundances for species only (default --tax_lev s)
* in logarithmic scale (-s log)
* reporting only the 25 most abundant clades (--top 25),
* according to the 90th percentile of the abundances in each clade (default --perc 90)
* with custom color map (-c bbcry).

In this example, the clustering is performed with "average" linkage (default -m average), using "Bray-Curtis" distance for clades (default -d braycurtis) and "correlation" for samples (default -f correlation).

### Importing Metaphlan data into QIIME

QIIME is capable of analysing any tabulated data, not just 16S amplicon OTUs or taxa. It can therefore be adopted for analysis of whole-genome shotgun data, for example taxonomic data from MetaPHlan or functional pathway data from HUMANn/KEGG.

Once you have merged Metaphlan tables, it is quite straight-forward to analyse this data in QIIME:

	/home/ubuntu/software/metaphlan/utils/merge_metaphlan_tables.py *.txt >real_data.txt
	biom convert -i real_data.txt -o real_data.biom --table-type "taxon table"

Generate beta-diversity tables:

	beta_diversity.py -i real_data.biom -m bray_curtis -o betadiv

Generate PCoA output:

	principal_coordinates.py -i betadiv/bray_curtis_real_data.txt -o betadiv/bray_curtis_real_data.pc

Generate PCoA plots with EMPeror:

	make_emperor.py -i betadiv/bray_curtis_real_data.pc -m qiime_metadata.tsv -o pca

### High-throughput functional assignments with KEGG

These are the steps to reproduce the functional assignments at home, because it takes some time you may not want to do this during the workshop (although you could do it during free/open study).

	wget --http-user kegg --http-passwd ggek http://huttenhower.sph.harvard.edu/kegg/kegg.reduced.fasta.tar.bz2
	tar xvfj kegg.reduced.fasta.tar.bz2

Install RAPSearch2 and add the binaries to your path.

	prerapsearch -d kegg.reduced.fasta -n kegg.reduced.fasta.rap
	rapsearch -q ../taxchris/"$tag".fastq -d kegg.reduced.fasta.rap -o "$tag" -z 16 -v 20 -b 1 -t q -a t

### Analysis with HUMANn

#### Installing HUMANn

	wget https://bitbucket.org/biobakery/humann/downloads/humann-v0.99.tar.gz
	tar xvfz humann-v.0.99.tar.gz
	sudo apt-get install scons

#### Configuring HUMANn

By default, HUMANn looks for BLAST files which end in '.txt' (or gzipped). So you need to copy the files ending in .m8 from RAPSearch2 into the input/ directory from the HUMANn installation and rename them to .txt.

#### Running HUMANn

	scons

#### Analysing HUMANn output

The relevant files are the pathway files which start with `04` in the `output` directory.

### Creating BLAST files for MEGAN

If you are interested in creating BLAST files for MEGAN so you can run it yourself, please see the reference material on my blog at:

<http://pathogenomics.bham.ac.uk/blog/2013/08/methods-for-taxonomic-assignment-of-shotgun-whole-genome-metagenomics-reads/>

####MEGAN Memory Requirement

By default, MEGAN uses 2Gb of RAM on 64-bit Linux. This isn't quite enough sometimes, we will make it use 6Gb instead (you could use more, but never more than the physical memory available on the machine). To do this you need to edit the `/opt/megan/MEGAN.vmoptions` file and change the content from:

	-Xmx2000m

to

	-Xmx6000m

This needs to be done as sudo. If you are lazy, just run:

	sudo bash -c 'echo "-Xmx6000m" > /opt/megan/MEGAN.vmoptions'

Check it is correct by `cat`ing the file:

	cat /opt/megan/MEGAN.vmoptions