text:
package com.dslplatform.patterns;

/**
 * A domain object is uniquely represented by its URI.
 * Entity and snowflake are example of domain objects which are
 * identified by their identity, instead of their attributes.
 * While entity does not implement {@link Identifiable}, an aggregate root does.
 */
public interface Identifiable extends Searchable {
	/**
	 * Domain object identity.
	 * This identity can be used to lookup a domain object.
	 *
	 * @return  domain object identity
	 */
	public String getURI();
}


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

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>ServletRequestWrapper (Servlet 4.0 API Documentation - Apache Tomcat 9.0.0.M11)</title>
<link rel="stylesheet" type="text/css" href="../../stylesheet.css" title="Style">

JavaScript is disabled on your browser.

Skip navigation links

Overview

Package

Class

Tree

Deprecated

Index

Help

Servlet 4.0 - Apache Tomcat 9.0.0.M11

Prev Class

Next Class

Frames

No Frames

All Classes

Summary:

Nested |

Field |

Constr |

Method

Detail:

Field |

Constr |

Method

javax.servlet

Class ServletRequestWrapper

java.lang.Object

javax.servlet.ServletRequestWrapper

All Implemented Interfaces:

ServletRequest

Direct Known Subclasses:

HttpServletRequestWrapper

public class ServletRequestWrapper
extends java.lang.Object
implements ServletRequest

Provides a convenient implementation of the ServletRequest interface that can
 be subclassed by developers wishing to adapt the request to a Servlet. This
 class implements the Wrapper or Decorator pattern. Methods default to calling
 through to the wrapped request object.

Since:

Servlet 2.3

See Also:

ServletRequest

Constructor Summary

Constructors

Constructor and Description

ServletRequestWrapper(ServletRequest request)

Creates a ServletRequest adaptor wrapping the given request object.

Method Summary

All Methods Instance Methods Concrete Methods Deprecated Methods

Modifier and Type
Method and Description

AsyncContext
getAsyncContext()

The default behavior of this method is to return getAsyncContext() on the
 wrapped request object.

java.lang.Object
getAttribute(java.lang.String name)

The default behavior of this method is to call getAttribute(String name)
 on the wrapped request object.

java.util.Enumeration<java.lang.String>
getAttributeNames()

The default behavior of this method is to return getAttributeNames() on
 the wrapped request object.

java.lang.String
getCharacterEncoding()

The default behavior of this method is to return getCharacterEncoding()
 on the wrapped request object.

int
getContentLength()

The default behavior of this method is to return getContentLength() on
 the wrapped request object.

long
getContentLengthLong()

The default behavior of this method is to return getContentLengthLong()
 on the wrapped request object.

java.lang.String
getContentType()

The default behavior of this method is to return getContentType() on the
 wrapped request object.

DispatcherType
getDispatcherType()

The default behavior of this method is to call getDispatcherType() on the
 wrapped request object.

ServletInputStream
getInputStream()

The default behavior of this method is to return getInputStream() on the
 wrapped request object.

java.lang.String
getLocalAddr()

The default behavior of this method is to return getLocalAddr() on the
 wrapped request object.

java.util.Locale
getLocale()

The default behavior of this method is to return getLocale() on the
 wrapped request object.

java.util.Enumeration<java.util.Locale>
getLocales()

The default behavior of this method is to return getLocales() on the
 wrapped request object.

java.lang.String
getLocalName()

The default behavior of this method is to return getLocalName() on the
 wrapped request object.

int
getLocalPort()

The default behavior of this method is to return getLocalPort() on the
 wrapped request object.

java.lang.String
getParameter(java.lang.String name)

The default behavior of this method is to return getParameter(String
 name) on the wrapped request object.

java.util.Map<java.lang.String,java.lang.String[]>
getParameterMap()

The default behavior of this method is to return getParameterMap() on the
 wrapped request object.

java.util.Enumeration<java.lang.String>
getParameterNames()

The default behavior of this method is to return getParameterNames() on
 the wrapped request object.

java.lang.String[]
getParameterValues(java.lang.String name)

The default behavior of this method is to return
 getParameterValues(String name) on the wrapped request object.

java.lang.String
getProtocol()

The default behavior of this method is to return getProtocol() on the
 wrapped request object.

java.io.BufferedReader
getReader()

The default behavior of this method is to return getReader() on the
 wrapped request object.

java.lang.String
getRealPath(java.lang.String path)

Deprecated.

As of Version 3.0 of the Java Servlet API

java.lang.String
getRemoteAddr()

The default behavior of this method is to return getRemoteAddr() on the
 wrapped request object.

java.lang.String
getRemoteHost()

The default behavior of this method is to return getRemoteHost() on the
 wrapped request object.

int
getRemotePort()

The default behavior of this method is to return getRemotePort() on the
 wrapped request object.

ServletRequest
getRequest()

Get the wrapped request.

RequestDispatcher
getRequestDispatcher(java.lang.String path)

The default behavior of this method is to return
 getRequestDispatcher(String path) on the wrapped request object.

java.lang.String
getScheme()

The default behavior of this method is to return getScheme() on the
 wrapped request object.

java.lang.String
getServerName()

The default behavior of this method is to return getServerName() on the
 wrapped request object.

int
getServerPort()

The default behavior of this method is to return getServerPort() on the
 wrapped request object.

ServletContext
getServletContext()

The default behavior of this method is to return getServletContext() on
 the wrapped request object.

boolean
isAsyncStarted()

The default behavior of this method is to return isAsyncStarted() on the
 wrapped request object.

boolean
isAsyncSupported()

The default behavior of this method is to return isAsyncSupported() on
 the wrapped request object.

boolean
isSecure()

The default behavior of this method is to return isSecure() on the
 wrapped request object.

boolean
isWrapperFor(java.lang.Class<?> wrappedType)

TODO SERVLET3 - Add comments

boolean
isWrapperFor(ServletRequest wrapped)

TODO SERVLET3 - Add comments

void
removeAttribute(java.lang.String name)

The default behavior of this method is to call removeAttribute(String
 name) on the wrapped request object.

void
setAttribute(java.lang.String name,
            java.lang.Object o)

The default behavior of this method is to return setAttribute(String
 name, Object o) on the wrapped request object.

void
setCharacterEncoding(java.lang.String enc)

The default behavior of this method is to set the character encoding on
 the wrapped request object.

void
setRequest(ServletRequest request)

Sets the request object being wrapped.

AsyncContext
startAsync()

The default behavior of this method is to return startAsync() on the
 wrapped request object.

AsyncContext
startAsync(ServletRequest servletRequest,
          ServletResponse servletResponse)

The default behavior of this method is to return startAsync(Runnable) on
 the wrapped request object.

Methods inherited from class java.lang.Object

clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail

ServletRequestWrapper

public ServletRequestWrapper(ServletRequest request)

Creates a ServletRequest adaptor wrapping the given request object.

Parameters:

request - The request to wrap

Throws:

java.lang.IllegalArgumentException - if the request is null

Method Detail

getRequest

public ServletRequest getRequest()

Get the wrapped request.

Returns:

the wrapped request object

setRequest

public void setRequest(ServletRequest request)

Sets the request object being wrapped.

Parameters:

request - The new wrapped request.

Throws:

java.lang.IllegalArgumentException - if the request is null.

getAttribute

public java.lang.Object getAttribute(java.lang.String name)

The default behavior of this method is to call getAttribute(String name)
 on the wrapped request object.

Specified by:

getAttribute in interface ServletRequest

Parameters:

name - a String specifying the name of the attribute

Returns:

an Object containing the value of the attribute, or
         null if the attribute does not exist

getAttributeNames

public java.util.Enumeration<java.lang.String> getAttributeNames()

The default behavior of this method is to return getAttributeNames() on
 the wrapped request object.

Specified by:

getAttributeNames in interface ServletRequest

Returns:

an Enumeration of strings containing the names of the
         request's attributes

getCharacterEncoding

public java.lang.String getCharacterEncoding()

The default behavior of this method is to return getCharacterEncoding()
 on the wrapped request object.

Specified by:

getCharacterEncoding in interface ServletRequest

Returns:

a String containing the name of the character
         encoding, or null if the request does not specify a
         character encoding

setCharacterEncoding

public void setCharacterEncoding(java.lang.String enc)
                          throws java.io.UnsupportedEncodingException

The default behavior of this method is to set the character encoding on
 the wrapped request object.

Specified by:

setCharacterEncoding in interface ServletRequest

Parameters:

enc - a String containing the name of the character
            encoding.

Throws:

java.io.UnsupportedEncodingException - if this is not a valid encoding

getContentLength

public int getContentLength()

The default behavior of this method is to return getContentLength() on
 the wrapped request object.

Specified by:

getContentLength in interface ServletRequest

Returns:

an integer containing the length of the request body or -1 if the
         length is not known or is greater than Integer.MAX_VALUE

getContentLengthLong

public long getContentLengthLong()

The default behavior of this method is to return getContentLengthLong()
 on the wrapped request object.

Specified by:

getContentLengthLong in interface ServletRequest

Returns:

a long integer containing the length of the request body or -1 if
         the length is not known

Since:

Servlet 3.1

getContentType

public java.lang.String getContentType()

The default behavior of this method is to return getContentType() on the
 wrapped request object.

Specified by:

getContentType in interface ServletRequest

Returns:

a String containing the name of the MIME type of the
         request, or null if the type is not known

getInputStream

public ServletInputStream getInputStream()
                                  throws java.io.IOException

The default behavior of this method is to return getInputStream() on the
 wrapped request object.

Specified by:

getInputStream in interface ServletRequest

Returns:

a ServletInputStream object containing the body of the
         request

Throws:

java.io.IOException - if an input or output exception occurred

getParameter

public java.lang.String getParameter(java.lang.String name)

The default behavior of this method is to return getParameter(String
 name) on the wrapped request object.

Specified by:

getParameter in interface ServletRequest

Parameters:

name - a String specifying the name of the parameter

Returns:

a String representing the single value of the
         parameter

See Also:

ServletRequest.getParameterValues(java.lang.String)

getParameterMap

public java.util.Map<java.lang.String,java.lang.String[]> getParameterMap()

The default behavior of this method is to return getParameterMap() on the
 wrapped request object.

Specified by:

getParameterMap in interface ServletRequest

Returns:

an immutable java.util.Map containing parameter names as keys and
         parameter values as map values. The keys in the parameter map are
         of type String. The values in the parameter map are of type
         String array.

getParameterNames

public java.util.Enumeration<java.lang.String> getParameterNames()

The default behavior of this method is to return getParameterNames() on
 the wrapped request object.

Specified by:

getParameterNames in interface ServletRequest

Returns:

an Enumeration of String objects, each
         String containing the name of a request parameter;
         or an empty Enumeration if the request has no
         parameters

getParameterValues

public java.lang.String[] getParameterValues(java.lang.String name)

The default behavior of this method is to return
 getParameterValues(String name) on the wrapped request object.

Specified by:

getParameterValues in interface ServletRequest

Parameters:

name - a String containing the name of the parameter
            whose value is requested

Returns:

an array of String objects containing the parameter's
         values

See Also:

ServletRequest.getParameter(java.lang.String)

getProtocol

public java.lang.String getProtocol()

The default behavior of this method is to return getProtocol() on the
 wrapped request object.

Specified by:

getProtocol in interface ServletRequest

Returns:

a String containing the protocol name and version
         number

getScheme

public java.lang.String getScheme()

The default behavior of this method is to return getScheme() on the
 wrapped request object.

Specified by:

getScheme in interface ServletRequest

Returns:

a String containing the name of the scheme used to
         make this request

getServerName

public java.lang.String getServerName()

The default behavior of this method is to return getServerName() on the
 wrapped request object.

Specified by:

getServerName in interface ServletRequest

Returns:

a String containing the name of the server

getServerPort

public int getServerPort()

The default behavior of this method is to return getServerPort() on the
 wrapped request object.

Specified by:

getServerPort in interface ServletRequest

Returns:

an integer specifying the port number

getReader

public java.io.BufferedReader getReader()
                                 throws java.io.IOException

The default behavior of this method is to return getReader() on the
 wrapped request object.

Specified by:

getReader in interface ServletRequest

Returns:

a BufferedReader containing the body of the request

Throws:

java.io.UnsupportedEncodingException - if the character set encoding used is not supported and
                the text cannot be decoded

java.io.IOException - if an input or output exception occurred

See Also:

ServletRequest.getInputStream()

getRemoteAddr

public java.lang.String getRemoteAddr()

The default behavior of this method is to return getRemoteAddr() on the
 wrapped request object.

Specified by:

getRemoteAddr in interface ServletRequest

Returns:

a String containing the IP address of the client
         that sent the request

getRemoteHost

public java.lang.String getRemoteHost()

The default behavior of this method is to return getRemoteHost() on the
 wrapped request object.

Specified by:

getRemoteHost in interface ServletRequest

Returns:

a String containing the fully qualified name of the
         client

setAttribute

public void setAttribute(java.lang.String name,
                         java.lang.Object o)

The default behavior of this method is to return setAttribute(String
 name, Object o) on the wrapped request object.

Specified by:

setAttribute in interface ServletRequest

Parameters:

name - a String specifying the name of the attribute

o - the Object to be stored

removeAttribute

public void removeAttribute(java.lang.String name)

The default behavior of this method is to call removeAttribute(String
 name) on the wrapped request object.

Specified by:

removeAttribute in interface ServletRequest

Parameters:

name - a String specifying the name of the attribute to
            remove

getLocale

public java.util.Locale getLocale()

The default behavior of this method is to return getLocale() on the
 wrapped request object.

Specified by:

getLocale in interface ServletRequest

Returns:

the preferred Locale for the client

getLocales

public java.util.Enumeration<java.util.Locale> getLocales()

The default behavior of this method is to return getLocales() on the
 wrapped request object.

Specified by:

getLocales in interface ServletRequest

Returns:

an Enumeration of preferred Locale
         objects for the client

isSecure

public boolean isSecure()

The default behavior of this method is to return isSecure() on the
 wrapped request object.

Specified by:

isSecure in interface ServletRequest

Returns:

a boolean indicating if the request was made using a secure
         channel

getRequestDispatcher

public RequestDispatcher getRequestDispatcher(java.lang.String path)

The default behavior of this method is to return
 getRequestDispatcher(String path) on the wrapped request object.

Specified by:

getRequestDispatcher in interface ServletRequest

Parameters:

path - a String specifying the pathname to the resource.
            If it is relative, it must be relative against the current
            servlet.

Returns:

a RequestDispatcher object that acts as a wrapper for
         the resource at the specified path, or null if the
         servlet container cannot return a RequestDispatcher

See Also:

RequestDispatcher,
ServletContext.getRequestDispatcher(java.lang.String)

getRealPath

@Deprecated
public java.lang.String getRealPath(java.lang.String path)

Deprecated. As of Version 3.0 of the Java Servlet API

The default behavior of this method is to return getRealPath(String path)
 on the wrapped request object.

Specified by:

getRealPath in interface ServletRequest

Parameters:

path - The virtual path to be converted to a real path

Returns:

ServletContext.getRealPath(String)

getRemotePort

public int getRemotePort()

The default behavior of this method is to return getRemotePort() on the
 wrapped request object.

Specified by:

getRemotePort in interface ServletRequest

Returns:

an integer specifying the port number

Since:

Servlet 2.4

getLocalName

public java.lang.String getLocalName()

The default behavior of this method is to return getLocalName() on the
 wrapped request object.

Specified by:

getLocalName in interface ServletRequest

Returns:

a String containing the host name of the IP on which
         the request was received.

Since:

Servlet 2.4

getLocalAddr

public java.lang.String getLocalAddr()

The default behavior of this method is to return getLocalAddr() on the
 wrapped request object.

Specified by:

getLocalAddr in interface ServletRequest

Returns:

a String containing the IP address on which the
         request was received.

Since:

Servlet 2.4

getLocalPort

public int getLocalPort()

The default behavior of this method is to return getLocalPort() on the
 wrapped request object.

Specified by:

getLocalPort in interface ServletRequest

Returns:

an integer specifying the port number

Since:

Servlet 2.4

getServletContext

public ServletContext getServletContext()

The default behavior of this method is to return getServletContext() on
 the wrapped request object.

Specified by:

getServletContext in interface ServletRequest

Returns:

TODO

Since:

Servlet 3.0

startAsync

public AsyncContext startAsync()
                        throws java.lang.IllegalStateException

The default behavior of this method is to return startAsync() on the
 wrapped request object.

Specified by:

startAsync in interface ServletRequest

Returns:

TODO

Throws:

java.lang.IllegalStateException - If asynchronous processing is not supported
         for this request or if the request is already in asynchronous
         mode

Since:

Servlet 3.0

startAsync

public AsyncContext startAsync(ServletRequest servletRequest,
                               ServletResponse servletResponse)
                        throws java.lang.IllegalStateException

The default behavior of this method is to return startAsync(Runnable) on
 the wrapped request object.

Specified by:

startAsync in interface ServletRequest

Parameters:

servletRequest - The ServletRequest with which to initialise the
                          asynchronous context

servletResponse - The ServletResponse with which to initialise the
                          asynchronous context

Returns:

TODO

Throws:

java.lang.IllegalStateException - If asynchronous processing is not supported
         for this request or if the request is already in asynchronous
         mode

Since:

Servlet 3.0

isAsyncStarted

public boolean isAsyncStarted()

The default behavior of this method is to return isAsyncStarted() on the
 wrapped request object.

Specified by:

isAsyncStarted in interface ServletRequest

Returns:

TODO

Since:

Servlet 3.0

isAsyncSupported

public boolean isAsyncSupported()

The default behavior of this method is to return isAsyncSupported() on
 the wrapped request object.

Specified by:

isAsyncSupported in interface ServletRequest

Returns:

TODO

Since:

Servlet 3.0

getAsyncContext

public AsyncContext getAsyncContext()

The default behavior of this method is to return getAsyncContext() on the
 wrapped request object.

Specified by:

getAsyncContext in interface ServletRequest

Returns:

The current AsyncContext

Since:

Servlet 3.0

isWrapperFor

public boolean isWrapperFor(ServletRequest wrapped)

TODO SERVLET3 - Add comments

Parameters:

wrapped - The request to compare to the wrapped request

Returns:

true if the request wrapped by this wrapper (or
         series of wrappers) is the same as the supplied request,
         otherwise false

Since:

Servlet 3.0

isWrapperFor

public boolean isWrapperFor(java.lang.Class<?> wrappedType)

TODO SERVLET3 - Add comments

Parameters:

wrappedType - The class to compare to the class of the wrapped
                    request

Returns:

true if the request wrapped by this wrapper (or
         series of wrappers) is the same type as the supplied type,
         otherwise false

Since:

Servlet 3.0

getDispatcherType

public DispatcherType getDispatcherType()

The default behavior of this method is to call getDispatcherType() on the
 wrapped request object.

Specified by:

getDispatcherType in interface ServletRequest

Returns:

TODO

Since:

Servlet 3.0

Skip navigation links

Overview

Package

Class

Tree

Deprecated

Index

Help

Servlet 4.0 - Apache Tomcat 9.0.0.M11

Prev Class

Next Class

Frames

No Frames

All Classes

Summary:

Nested |

Field |

Constr |

Method

Detail:

Field |

Constr |

Method

Copyright © 2000-2016 Apache Software Foundation. All Rights Reserved.

redpajama_set_name: RedPajamaGithub


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

<title>Minim : : Sampler : : setSample</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link href="stylesheet.css" rel="stylesheet" type="text/css">

    	Minim

    		core |
    		ugens |
    		analysis

Sampler

setSample

Description

    	Sets the sample data used by this Sampler by copying the
 contents of the provided MultiChannelBuffer into the internal buffer.

Signature

void setSample(MultiChannelBuffer newSampleData, float sampleRate)

Parameters

        newSampleData — MultiChannelBuffer: the new sample data for this Sampler

        sampleRate — float: the sample rate of the sample data

Returns

None

Related

    	MultiChannelBuffer

Example

None available

Usage

    	Web & Application


text:
package home.ned.lul;

import android.annotation.SuppressLint;
import android.app.ActionBar;
import android.app.Activity;
import android.app.Service;
import android.content.Context;
import android.content.Intent;
import android.media.MediaPlayer;
import android.net.Uri;
import android.os.Bundle;
import android.os.Handler;
import android.os.IBinder;
import android.support.annotation.Nullable;
import android.util.DisplayMetrics;
import android.util.Log;
import android.view.MotionEvent;
import android.view.View;
import android.view.MenuItem;
import android.support.v4.app.NavUtils;
import android.view.Window;
import android.view.WindowManager;
import android.widget.VideoView;

import java.io.FileNotFoundException;
import java.io.IOException;

/**
 * An example full-screen activity that shows and hides the system UI (i.e.
 * status bar and navigation/system bar) with user interaction.
 */
public class NativePlaybackActivity extends Activity implements MediaPlayer.OnPreparedListener {

    public final static String TAG = "NATIVEPLAYBACKACTIVITY";
    /**
     * Whether or not the system UI should be auto-hidden after
     * {@link #AUTO_HIDE_DELAY_MILLIS} milliseconds.
     */
    private static final boolean AUTO_HIDE = true;

    /**
     * If {@link #AUTO_HIDE} is set, the number of milliseconds to wait after
     * user interaction before hiding the system UI.
     */
    private static final int AUTO_HIDE_DELAY_MILLIS = 3000;

    /**
     * Some older devices needs a small delay between UI widget updates
     * and a change of the status and navigation bar.
     */
//    private static final int UI_ANIMATION_DELAY = 300;
//    private final Handler mHideHandler = new Handler();
//    private View mContentView;
//    private final Runnable mHidePart2Runnable = new Runnable() {
//        @SuppressLint("InlinedApi")
//        @Override
//        public void run() {
//            // Delayed removal of status and navigation bar
//
//            // Note that some of these constants are new as of API 16 (Jelly Bean)
//            // and API 19 (KitKat). It is safe to use them, as they are inlined
//            // at compile-time and do nothing on earlier devices.
//            mContentView.setSystemUiVisibility(View.SYSTEM_UI_FLAG_LOW_PROFILE
//                    | View.SYSTEM_UI_FLAG_FULLSCREEN
//                    | View.SYSTEM_UI_FLAG_LAYOUT_STABLE
//                    | View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY
//                    | View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION
//                    | View.SYSTEM_UI_FLAG_HIDE_NAVIGATION);
//        }
//    };
//    private View mControlsView;
//    private final Runnable mShowPart2Runnable = new Runnable() {
//        @Override
//        public void run() {
//            // Delayed display of UI elements
//            ActionBar actionBar = getActionBar();
//            if (actionBar != null) {
//                actionBar.show();
//            }
//            mControlsView.setVisibility(View.VISIBLE);
//        }
//    };
//    private boolean mVisible;
//    private final Runnable mHideRunnable = new Runnable() {
//        @Override
//        public void run() {
//            hide();
//        }
//    };
    /**
     * Touch listener to use for in-layout UI controls to delay hiding the
     * system UI. This is to prevent the jarring behavior of controls going away
     * while interacting with activity UI.
     */
//    private final View.OnTouchListener mDelayHideTouchListener = new View.OnTouchListener() {
//        @Override
//        public boolean onTouch(View view, MotionEvent motionEvent) {
//            if (AUTO_HIDE) {
//                delayedHide(AUTO_HIDE_DELAY_MILLIS);
//            }
//            return false;
//        }
//    };
    private Movie mSelectedMovie;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        requestWindowFeature(Window.FEATURE_NO_TITLE);
        getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,WindowManager.LayoutParams.FLAG_FULLSCREEN);

        setContentView(R.layout.activity_native_playback);

        ActionBar actionBar = getActionBar();
        if (actionBar != null) {
            actionBar.setDisplayHomeAsUpEnabled(true);
        }

        String url = null;
        Intent intent = getIntent();
        if(intent.hasExtra(DetailsActivity.MOVIE)){
            mSelectedMovie = (Movie) getIntent()
                    .getSerializableExtra(DetailsActivity.MOVIE);
            url = mSelectedMovie.getVideoUrl();
        }else if(intent.hasExtra("network-stream")){
            url = intent.getSerializableExtra("network-stream").toString();
        }

        if(intent.hasExtra("extra-audio-stream")){
            Intent extraAudioIntent = new Intent(this, SeparateAudioStreamService.class);
            extraAudioIntent.putExtra("extra-audio-stream", intent.getSerializableExtra("extra-audio-stream").toString());
            startService(extraAudioIntent);
        }

        VideoView videoView = (VideoView)findViewById(R.id.fullscreen_content);
        videoView.setVideoPath(url);

        videoView.setOnPreparedListener(this);

//        mVisible = true;
//        mControlsView = findViewById(R.id.fullscreen_content_controls);
//        mContentView = findViewById(R.id.fullscreen_content);
//
//
//        // Set up the user interaction to manually show or hide the system UI.
//        mContentView.setOnClickListener(new View.OnClickListener() {
//            @Override
//            public void onClick(View view) {
//                toggle();
//            }
//        });
//
//        // Upon interacting with UI controls, delay any scheduled hide()
//        // operations to prevent the jarring behavior of controls going away
//        // while interacting with the UI.
//        findViewById(R.id.dummy_button).setOnTouchListener(mDelayHideTouchListener);
}

    @Override
    public void onPrepared(MediaPlayer mp) {
        mp.start();

        DisplayMetrics displayMetrics = new DisplayMetrics();
        WindowManager wm = (WindowManager) getApplicationContext().getSystemService(Context.WINDOW_SERVICE); // the results will be higher than using the activity context object or the getWindowManager() shortcut
        wm.getDefaultDisplay().getMetrics(displayMetrics);
        int screenWidth = displayMetrics.widthPixels;
        int screenHeight = displayMetrics.heightPixels;

        Log.d(TAG, "Width: "+screenWidth);
        Log.d(TAG, "Height: "+screenHeight);

    }

    @Override
    protected void onPostCreate(Bundle savedInstanceState) {
        super.onPostCreate(savedInstanceState);

        // Trigger the initial hide() shortly after the activity has been
        // created, to briefly hint to the user that UI controls
        // are available.
//        delayedHide(100);

    }

//    @Override
//    public boolean onOptionsItemSelected(MenuItem item) {
//        int id = item.getItemId();
//        if (id == android.R.id.home) {
//            // This ID represents the Home or Up button.
//            NavUtils.navigateUpFromSameTask(this);
//            return true;
//        }
//        return super.onOptionsItemSelected(item);
//    }
//
//    private void toggle() {
//        if (mVisible) {
//            hide();
//        } else {
//            show();
//        }
//    }
//
//    private void hide() {
//        // Hide UI first
//        ActionBar actionBar = getActionBar();
//        if (actionBar != null) {
//            actionBar.hide();
//        }
//        mControlsView.setVisibility(View.GONE);
//        mVisible = false;
//
//        // Schedule a runnable to remove the status and navigation bar after a delay
//        mHideHandler.removeCallbacks(mShowPart2Runnable);
//        mHideHandler.postDelayed(mHidePart2Runnable, UI_ANIMATION_DELAY);
//    }
//
//    @SuppressLint("InlinedApi")
//    private void show() {
//        // Show the system bar
//        mContentView.setSystemUiVisibility(View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN
//                | View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION);
//        mVisible = true;
//
//        // Schedule a runnable to display UI elements after a delay
//        mHideHandler.removeCallbacks(mHidePart2Runnable);
//        mHideHandler.postDelayed(mShowPart2Runnable, UI_ANIMATION_DELAY);
//    }
//
//    /**
//     * Schedules a call to hide() in [delay] milliseconds, canceling any
//     * previously scheduled calls.
//     */
//    private void delayedHide(int delayMillis) {
//        mHideHandler.removeCallbacks(mHideRunnable);
//        mHideHandler.postDelayed(mHideRunnable, delayMillis);
//    }
}


text:
'use strict';

/**
 * @ngdoc function
 * @name vl4dBanBoardApp.controller:MainCtrl
 * @description
 * # MainCtrl
 * Controller for the overall vl4d-ban-board app
 */
app.controller('MainCtrl', function($scope, $mdSidenav){
  //Sidenav items and urls
  $scope.items = [
                  {title: "Home", url: "/home"}
  ];

  $scope.toggleLeft = function() {
    $mdSidenav('left').toggle();
  };

});


text:
package imagepipeline

import ij.{IJ,ImagePlus,ImageStack}
import ij.process.ImageProcessor

package object funcs {
  import Defs._

  val readLines = new SimpleOp1[String, Array[String]]("image load", (path: String) => {
    import scalax.io._
    val input: Input = Resource.fromFile(path)
    input.string(Codec.UTF8).lines.toArray
  }, ("path", "[path]"))

  val stat = new SimpleOp1[ImageProcessor, RowData]("getStat", (img: ImageProcessor) => {
    val stat = img.getStatistics
    new RowData(stat.min, stat.max, stat.mean)
  }, ("image", "rowdata"))

  val statroi = new SimpleOp2[ImageProcessor, (Int, Int, Int, Int), RowData]("getStat", (img: ImageProcessor, roi: (Int, Int, Int, Int)) => {
    img.setRoi(roi._1, roi._2, roi._3, roi._4)
    val stat = img.getStatistics
    new RowData(stat.min, stat.max, stat.mean)
  }, ("image", "roi", "rowdata"))
  val contrast_do = (a: ImageProcessor) => {
    val b = a.duplicate
    b.setMinAndMax(0, 1000)
    b
  }: ImageProcessor
  val cropping = (a: ImageProcessor, roi: (Int, Int, Int, Int)) => {
    val b = a.duplicate
    b.setRoi(roi._1, roi._2, roi._3, roi._4)
    b.crop()
  }: ImageProcessor

  type Path = String

  import Pipeline._

  val selectRois: SimpleOp2[Path,Path,Array[Roi]] = new SimpleOp2[Path,Path,Array[Roi]]("select rois", (imagepath: Path, roi: Path) => {
    import scalax.io._
//    val input: Input = Resource.fromFile(roi)
//    input.string(Codec.UTF8).lines.toArray
    Array((0,0,100,100))
  }: Array[Roi], ("path","path","[roi]"))

}

object Defs {
  import funcs._

  import Pipeline._
  type Roi = (Int, Int, Int, Int)

  val crop = new SimpleOp2[ImageProcessor, (Int, Int, Int, Int), ImageProcessor]("crop", cropping, ("image", "roi", "image"))
  val autocontrast = new SimpleOp1[ImageProcessor, ImageProcessor]("contrast", contrast_do, ("image", "image"))

  val combine2 = new SimpleOp2[ImageProcessor, ImageProcessor, ImageProcessor]("combine", (a: ImageProcessor, b: ImageProcessor) => {
    import ij.plugin.StackCombiner
    def f(img: ImageProcessor): ImageStack = {
      val s = new ImageStack(img.getWidth, img.getHeight)
      s.addSlice(img)
      s
    }
    println(a.getStatistics.mean,b.getStatistics.mean)
    val s1 = f(a)
    val s2 = f(b)
    val s: ImageStack = new StackCombiner().combineHorizontally(s1, s2)
//    new ImagePlus("test",s1).show()
//    new ImagePlus("test",s2).show()
//    Thread.sleep(1000)
    val r = s.getProcessor(1)
    val rng = new scala.util.Random
    IJ.save(new ImagePlus("test",r),"./out/%s.tif".format(rng.alphanumeric.take(3).mkString))
    //    new ImagePlus("result", r).show()
    r
  }, ("image", "image", "image"))

  val imload = new SimpleOp1[String, ImageProcessor]("image load", (path: String) => {
    IJ.openImage(path).getProcessor
  }, ("path", "image"))

  val bf = new InputImg("/Users/hiroyuki/repos/ImagePipeline/BF.jpg")
  val cy5 = new InputImg("/Users/hiroyuki/repos/ImagePipeline/Cy5.jpg")
  val roi = new InputRoi("cropping")
  val a = start(bf).then2(crop, roi).then(autocontrast)
  val b = start(cy5).then2(crop, roi).then(autocontrast)
//  val outimg = new OutputImg("result final.tiff", "Result")
  type CropType = Pipeline41[ImageProcessor,Roi,ImageProcessor,Roi,ImageProcessor]
  val cropAndCombine: CropType = cont2(combine2, a, b).end().inputOrder(bf,roi,cy5,roi)
//  cropAndCombine.verify(Array(bf.id, cy5.id), Array())

  val outstat = new OutputRowData()

  val file_path = new InputFilePath()

  val getstats: Pipeline11[Path,RowData] = start(file_path).then(imload).then(stat).end()

  val getstats_roi: Pipeline21[Path,Roi,RowData] = start(file_path).then(imload).then2(statroi, roi).end()

}


text:
package com.hazelcast.spring;

import com.hazelcast.nio.ssl.SSLContextFactory;

import javax.net.ssl.SSLContext;
import java.util.Properties;

public class DummySSLContextFactory implements SSLContextFactory {

    @Override
    public void init(Properties properties) throws Exception {
    }

    @Override
    public SSLContext getSSLContext() {
        return null;
    }
}


text:
/**
 * mixerChannelStrip.js
 *
 * @author Patrick Hund
 * @since 22 Jul 2016
 */
import fullRange from "../processors/fullRange";
import button from "../processors/button";
import messages from "../messages";

const mapping = new Map([
    [
        "level", {
            name: "mixer channel strip level",
            controller: 0x7,
            processor: fullRange
        }
    ],
    [
        "width", {
            name: "mixer channel strip width",
            controller: 0x8,
            processor: fullRange
        }
    ],
    [
        "pan", {
            name: "mixer channel strip pan",
            controller: 0xa,
            processor: fullRange
        }
    ],
    [
        "mute", {
            name: "mixer channel strip mute",
            controller: 0xc,
            processor: button
        }
    ],
    [
        "solo", {
            name: "mixer channel strip solo",
            controller: 0xd,
            processor: button
        }
    ],
    [
        "send-fx1-on", {
            name: "mixer channel strip send FX 1 on/off",
            controller: 0xe,
            processor: button
        }
    ],
    [
        "send-fx1-level", {
            name: "mixer channel strip send FX 1 level",
            controller: 0xf,
            processor: fullRange
        }
    ],
    [
        "send-fx1-pre-fader", {
            name: "mixer channel strip send FX 1 pre fader",
            controller: 0x10,
            processor: button
        }
    ],
    [
        "send-fx2-on", {
            name: "mixer channel strip send FX 2 on/off",
            controller: 0x11,
            processor: button
        }
    ],
    [
        "send-fx2-level", {
            name: "mixer channel strip send FX 2 level",
            controller: 0x12,
            processor: fullRange
        }
    ],
    [
        "send-fx2-pre-fader", {
            name: "mixer channel strip send FX 2 pre fader",
            controller: 0x13,
            processor: button
        }
    ],
    [
        "send-fx3-on", {
            name: "mixer channel strip send FX 3 on/off",
            controller: 0x14,
            processor: button
        }
    ],
    [
        "send-fx3-level", {
            name: "mixer channel strip send FX 3 level",
            controller: 0x15,
            processor: fullRange
        }
    ],
    [
        "send-fx3-pre-fader", {
            name: "mixer channel strip send FX 3 pre fader",
            controller: 0x16,
            processor: button
        }
    ],
    [
        "send-fx4-on", {
            name: "mixer channel strip send FX 4 on/off",
            controller: 0x17,
            processor: button
        }
    ],
    [
        "send-fx4-level", {
            name: "mixer channel strip send FX 4 level",
            controller: 0x18,
            processor: fullRange
        }
    ],
    [
        "send-fx4-pre-fader", {
            name: "mixer channel strip send FX 4 pre fader",
            controller: 0x19,
            processor: button
        }
    ],
    [
        "send-fx5-on", {
            name: "mixer channel strip send FX 5 on/off",
            controller: 0x1a,
            processor: button
        }
    ],
    [
        "send-fx5-level", {
            name: "mixer channel strip send FX 5 level",
            controller: 0x1b,
            processor: fullRange
        }
    ],
    [
        "send-fx5-pre-fader", {
            name: "mixer channel strip send FX 5 pre fader",
            controller: 0x1c,
            processor: button
        }
    ],
    [
        "send-fx6-on", {
            name: "mixer channel strip send FX 6 on/off",
            controller: 0x1d,
            processor: button
        }
    ],
    [
        "send-fx6-level", {
            name: "mixer channel strip send FX 6 level",
            controller: 0x1e,
            processor: fullRange
        }
    ],
    [
        "send-fx6-pre-fader", {
            name: "mixer channel strip send FX 6 pre fader",
            controller: 0x1f,
            processor: button
        }
    ],
    [
        "send-fx7-on", {
            name: "mixer channel strip send FX 7 on/off",
            controller: 0x27,
            processor: button
        }
    ],
    [
        "send-fx7-level", {
            name: "mixer channel strip send FX 7 level",
            controller: 0x28,
            processor: fullRange
        }
    ],
    [
        "send-fx7-pre-fader", {
            name: "mixer channel strip send FX 7 pre fader",
            controller: 0x29,
            processor: button
        }
    ],
    [
        "send-fx8-on", {
            name: "mixer channel strip send FX 8 on/off",
            controller: 0x2a,
            processor: button
        }
    ],
    [
        "send-fx8-level", {
            name: "mixer channel strip send FX 8 level",
            controller: 0x2b,
            processor: fullRange
        }
    ],
    [
        "send-fx8-pre-fader", {
            name: "mixer channel strip send FX 8 pre fader",
            controller: 0x2c,
            processor: button
        }
    ],
    [
        "compressor-on", {
            name: "mixer channel strip compressor on/off",
            controller: 0x2e,
            processor: button
        }
    ],
    [
        "compressor-threshold", {
            name: "mixer channel strip compressor threshold",
            controller: 0x2f,
            processor: fullRange
        }
    ],
    [
        "compressor-release", {
            name: "mixer channel strip compressor release",
            controller: 0x30,
            processor: fullRange
        }
    ],
    [
        "compressor-ratio", {
            name: "mixer channel strip compressor ratio",
            controller: 0x31,
            processor: fullRange
        }
    ],
    [
        "compressor-peak", {
            name: "mixer channel strip compressor peak",
            controller: 0x32,
            processor: button
        }
    ],
    [
        "compressor-fast-attack", {
            name: "mixer channel strip compressor fast attack",
            controller: 0x33,
            processor: button
        }
    ],
    [
        "gate-on", {
            name: "mixer channel strip gate on/off",
            controller: 0x35,
            processor: button
        }
    ],
    [
        "gate-threshold", {
            name: "mixer channel strip gate threshold",
            controller: 0x36,
            processor: fullRange
        }
    ],
    [
        "gate-hold", {
            name: "mixer channel strip gate hold",
            controller: 0x37,
            processor: fullRange
        }
    ],
    [
        "gate-release", {
            name: "mixer channel strip gate release",
            controller: 0x38,
            processor: fullRange
        }
    ],
    [
        "gate-range", {
            name: "mixer channel strip gate range",
            controller: 0x39,
            processor: fullRange
        }
    ],
    [
        "gate-fast-attack", {
            name: "mixer channel strip gate fast attack",
            controller: 0x3a,
            processor: button
        }
    ],
    [
        "gate-exp", {
            name: "mixer channel strip gate exp",
            controller: 0x3b,
            processor: button
        }
    ],
    [
        "gate-key", {
            name: "mixer channel strip gate key",
            controller: 0x3d,
            processor: button
        }
    ],
    [
        "hf-bell", {
            name: "mixer channel strip HF bell",
            controller: 0x54,
            processor: button
        }
    ],
    [
        "insert-fx-bypass", {
            name: "mixer channel strip insert FX bypass",
            controller: 0x44,
            processor: button
        }
    ],
    [
        "insert-fx-rotary1", {
            name: "mixer channel strip insert FX rotary 1",
            controller: 0x47,
            processor: fullRange
        }
    ],
    [
        "insert-fx-rotary2", {
            name: "mixer channel strip insert FX rotary 2",
            controller: 0x48,
            processor: fullRange
        }
    ],
    [
        "insert-fx-rotary3", {
            name: "mixer channel strip insert FX rotary 3",
            controller: 0x49,
            processor: fullRange
        }
    ],
    [
        "insert-fx-rotary4", {
            name: "mixer channel strip insert FX rotary 4",
            controller: 0x4a,
            processor: fullRange
        }
    ],
    [
        "insert-fx-button1", {
            name: "mixer channel strip insert FX button 1",
            controller: 0x4b,
            processor: button
        }
    ],
    [
        "insert-fx-button2", {
            name: "mixer channel strip insert FX button 2",
            controller: 0x4c,
            processor: button
        }
    ],
    [
        "insert-fx-button3", {
            name: "mixer channel strip insert FX button 3",
            controller: 0x4d,
            processor: button
        }
    ],
    [
        "insert-fx-button4", {
            name: "mixer channel strip insert FX button 4",
            controller: 0x4e,
            processor: button
        }
    ],
    [
        "eq-on", {
            name: "mixer channel strip EQ on/off",
            controller: 0x50,
            processor: button
        }
    ],
    [
        "eq-e-mode", {
            name: "mixer channel strip EQ e-mode",
            controller: 0x51,
            processor: button
        }
    ],
    [
        "hf-gain", {
            name: "mixer channel strip HF gain",
            controller: 0x52,
            processor: fullRange
        }
    ],
    [
        "hf-frequency", {
            name: "mixer channel strip HF frequency",
            controller: 0x53,
            processor: fullRange
        }
    ],
    [
        "hmf-gain", {
            name: "mixer channel strip HMF gain",
            controller: 0x55,
            processor: fullRange
        }
    ],
    [
        "hmf-frequency", {
            name: "mixer channel strip HMF frequency",
            controller: 0x56,
            processor: fullRange
        }
    ],
    [
        "hmf-q", {
            name: "mixer channel strip HMF Q",
            controller: 0x57,
            processor: fullRange
        }
    ],
    [
        "lmf-gain", {
            name: "mixer channel strip LMF gain",
            controller: 0x58,
            processor: fullRange
        }
    ],
    [
        "lmf-frequency", {
            name: "mixer channel strip LMF frequency",
            controller: 0x59,
            processor: fullRange
        }
    ],
    [
        "lmf-q", {
            name: "mixer channel strip LMF Q",
            controller: 0x5a,
            processor: fullRange
        }
    ],
    [
        "lf-gain", {
            name: "mixer channel strip LF gain",
            controller: 0x5b,
            processor: fullRange
        }
    ],
    [
        "lf-frequency", {
            name: "mixer channel strip LF frequency",
            controller: 0x5c,
            processor: fullRange
        }
    ],
    [
        "lf-bell", {
            name: "mixer channel strip LF bell",
            controller: 0x5d,
            processor: button
        }
    ],
    [
        "lpf-on", {
            name: "mixer channel strip LPF on/off",
            controller: 0x66,
            processor: button
        }
    ],
    [
        "lpf-frequency", {
            name: "mixer channel strip LPF frequency",
            controller: 0x67,
            processor: fullRange
        }
    ],
    [
        "hpf-on", {
            name: "mixer channel strip HPF on/off",
            controller: 0x68,
            processor: button
        }
    ],
    [
        "hpf-frequency", {
            name: "mixer channel strip HPF frequency",
            controller: 0x69,
            processor: fullRange
        }
    ],
    [
        "gain", {
            name: "mixer channel strip gain",
            controller: 0x6b,
            processor: fullRange
        }
    ],
    [
        "invert-phase", {
            name: "mixer channel strip invert phase",
            controller: 0x6c,
            processor: button
        }
    ]
]);

export default messages(mapping);


text:
(*

category:      Test
synopsis:      Basic two reactions with three species and parameters local to
               reactions.
componentTags: Compartment, Species, Reaction
testTags:      Amount, LocalParameters
testType:      TimeCourse
levels:        1.2, 2.1, 2.2, 2.3, 2.4, 3.1
generatedBy:   Numeric

The model contains one compartment called "compartment".  There are three
species named S1, S2 and S3.  The model contains two reactions defined as:

[{width:30em,margin: 1em auto}|  *Reaction*  |  *Rate*  |
| S1 -> S2 | $k * S1 * compartment,$  |
| S2 -> S3 | $k * S2 * compartment,$  |]

Reaction S1 -> S2 defines one local parameter k.  Reaction S2 -> S3 also
defines one (different) local parameter k.  Both of these parameters have a
scope local to the defining reaction.

The initial conditions are as follows:

[{width:30em,margin: 1em auto}|       |*Value*          |*Units*  |
|Initial amount of S1                |$3.0 \x 10^-4$ |mole                      |
|Initial amount of S2                |$            0$ |mole                      |
|Initial amount of S3                |$            0$ |mole                      |
|Value of local parameter k          |$            1$ |second^-1^ |
|Value of local parameter k          |$            2$ |second^-1^ |
|Volume of compartment "compartment" |$            1$ |litre                     |]

The species values are given as amounts of substance to make it easier to
use the model in a discrete stochastic simulator, but (as per usual SBML
principles) their symbols represent their values in concentration units
where they appear in expressions.

*)

newcase[ "00057" ];

addCompartment[ compartment, size -> 1 ];
addSpecies[ S1, initialAmount -> 3.0 10^-4];
addSpecies[ S2, initialAmount -> 0];
addSpecies[ S3, initialAmount -> 0];
addReaction[ S1 -> S2, reversible -> False,
	     kineticLaw -> k * S1 * compartment, parameters -> {k -> 1} ];
addReaction[ S2 -> S3, reversible -> False,
	     kineticLaw -> k * S2 * compartment, parameters -> {k -> 2} ];

makemodel[]


text:
News Item List

             Create News Item

            {{ ::vm.translate.get('Name')}}
            Url
            {{::vm.translate.get('Is Published')}}
            {{ ::vm.translate.get('CreatedOn')}}
            Actions

                    <input class="form-control" st-search="Name" />

            <st-date-range predicate="CreatedOn" before="query.before" after="query.after"></st-date-range>

            {{newsItem.name}}
            {{newsItem.seoTitle}}

            {{newsItem.createdOn | date:'medium'}}

                <button ng-click="vm.deleteNewsItem(newsItem)" class="btn btn-danger btn-xs delete"> </button>

            Loading ...


text:
DD_DETAIL_BEGIN_
template <typename UndirectionalIteratorT_, typename ValueT_, typename BinaryFunctionT_>
ValueT_ product(
	UndirectionalIteratorT_ begin__,
	UndirectionalIteratorT_ end__,
	ValueT_ initial_value__,
	BinaryFunctionT_ multiply_assign__
) DD_NOEXCEPT_IF(noexcept(++begin__ != end__) && noexcept(multiply_assign__(initial_value__ DD_COMMA *begin__))) {
	for (; begin__ != end__; ++begin__) {
		multiply_assign__(initial_value__, *begin__);
	}
	return initial_value__;
}

template <typename UndirectionalIteratorT_, typename ValueT_>
inline ValueT_ product(
	UndirectionalIteratorT_ begin__,
	UndirectionalIteratorT_ end__,
	ValueT_ initial_value__
) DD_NOEXCEPT_AS(static_cast<ValueT_>(
	::DD::detail_::product(begin__ DD_COMMA end__ DD_COMMA initial_value__ DD_COMMA multiply_assign_with)
)) {
	return ::DD::detail_::product(begin__, end__, initial_value__, multiply_assign_with);
}

template <typename UndirectionalRangeT_, typename ValueT_, typename BinaryFunctionT_>
inline ValueT_ product(
	UndirectionalRangeT_& range__,
	ValueT_ initial_value__,
	BinaryFunctionT_ multiply_assign__
) DD_NOEXCEPT_AS(static_cast<ValueT_>(
	::DD::detail_::product(DD_SPLIT_RANGE(range__) DD_COMMA initial_value__ DD_COMMA multiply_assign__)
)) {
	return ::DD::detail_::product(DD_SPLIT_RANGE(range__), initial_value__, multiply_assign__);
}

template <typename UndirectionalRangeT_, typename ValueT_>
inline ValueT_ product(
	UndirectionalRangeT_& range__,
	ValueT_ initial_value__
) DD_NOEXCEPT_AS(static_cast<ValueT_>(
	::DD::detail_::product(range__ DD_COMMA initial_value__ DD_COMMA multiply_assign_with)
)) {
	return ::DD::detail_::product(range__, initial_value__, multiply_assign_with);
}

DD_DETAIL_END_

DD_BEGIN_
using detail_::product;

DD_END_

#endif


text:
class Middleclick < Cask
  url 'http://clement.beffa.org/labs/downloads/MiddleClick-maverick.zip'
  homepage 'http://clement.beffa.org/labs/projects/middleclick'
  version 'latest'
  no_checksum
  link 'MiddleClick.app'

  def caveats; <<-EOS.undent
    This cask requires OS X 10.9 Mavericks for the installed application to
    function correctly.

    Casks for installing this application under older versions of OS X, Mountain
    Lion and Snow Leopard, can be found in caskroom/homebrew-versions.
    EOS
  end
end


text:
// This file is automatically generated.

package adila.db;

/*
 * ZTE Z787
 *
 * DEVICE: apus
 * MODEL: Z787
 */
final class apus {
    public static final String DATA = "ZTE|Z787|";
}


text:
import { async, ComponentFixture, TestBed } from '@angular/core/testing';

import { Comp562Component } from './comp-562.component';

describe('Comp562Component', () => {
  let component: Comp562Component;
  let fixture: ComponentFixture<Comp562Component>;

  beforeEach(async(() => {
    TestBed.configureTestingModule({
      declarations: [ Comp562Component ]
    })
    .compileComponents();
  }));

  beforeEach(() => {
    fixture = TestBed.createComponent(Comp562Component);
    component = fixture.componentInstance;
    fixture.detectChanges();
  });

  it('should create', () => {
    expect(component).toBeTruthy();
  });
});


text:
<?php
session_start();
?>
<!DOCTYPE html>

<?php
require("includes/mysqli.php");
require("includes/functions.php");
date_default_timezone_set('America/New_York');
$date = date('m/d/Y', time());
$sqldate = date('Y-m-d',time());
$listcount =0;
$currtime = date('H:i:s', time());
if (isset($_REQUEST['logout']) and $_REQUEST['logout'] == 'y'){
  logout();
}
nav_check();
 ?>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <meta name="description" content="">
    <meta name="author" content="">
    <title>Shopping List</title>
    <link href="css/bootstrap.min.css" rel="stylesheet">
    <link href="css/stylesheet.css" rel="stylesheet">

  <?php
  if (isset($_GET['submit'])){
    $submittype=$_GET['submit'];
  if ($submittype == 'Add Item'){
    $newid=$_GET['id'];
    $newquan=$_GET['quan'];
    $newname=$_GET['name'];
    $newprice=$_GET['price'];
    $newaisle=$_GET['aisle'];
    $newgroup=$_GET['group'];
    $newaddby=$_GET['addby'];
    $newtime=$_GET['time'];
    $newdate=$_GET['date'];
    db_addlist($newquan,$newname,$newprice,$newaisle,$newgroup,$newaddby,$newtime,$newdate);
    header("Location: " . redirecturl() ."/index.php");
  }elseif ($submittype =='Remove Item'){
    $remitemid=$_GET['removelistid'];
    db_remitem($remitemid);
    header("Location: " . redirecturl() ."/index.php");
}
}
   ?>

        Shopping List

Home

New List

New Group

Mobile View

Manage Cart

Logout

    <button type="button" class="btn btn-primary btn-lg" data-toggle="modal" data-target="#newItem">Add New Item</button>

Shopping List for <?php echo $date?>

              <?php
              $con = db_connect();
              $result = mysqli_query($con, "SELECT * FROM currentlist WHERE qty > '0' ORDER BY aisle");
              print '
';
              $rowcount = $result->num_rows;
              if ($rowcount != 0){
              print ' Qty 	';
              print ' Name 	';
              print ' Price 	';
              print ' Aisle 	';
              print ' Added On 	';
              print ' Added By 	';
              print ' Edit 	';
              $i = 0;
            while($row = $result->fetch_assoc()){
              if ($i != $result->num_rows){
                //var_dump($row);
                $id[] = $row['id'];
                $qty[] = $row['qty'];
                $pname[] = $row['name'];
                $price[] = $row['price'];
                $aisle[] = $row['aisle'];
                $pgroup[] = $row['product_group'];
                $addedby[] = $row['add_by'];
                $timeadd[] = $row['time_add'];
                $dateadd[] = $row['date_add'];
                $i++;
              }
              }
              $i = 0;
              $totalprice = 0;
              $totalqty = 0;
              while($i != count($pname)) {
                $addedon = new DateTime($dateadd[$i] . ' ' . $timeadd[$i]);
                $addedon = $addedon->format('m/d/Y h:i a');
                print '
';
                print '' . $qty[$i] . '	';
                print '' . $pname[$i] . '	';
                print '$' . $price[$i] . '	';
                print '' . $aisle[$i] . '	';
                print '' . $addedon . '	';
                print '' . $addedby[$i] . '	';
                print 'IN CART EDIT   DELETE	';
                $totalprice = $totalprice + $price[$i];
                $totalqty = $totalqty + $qty[$i];
                $taxedprice = $totalprice * 1.06;
                print '
';
                $i++;
              }
              $listcount = $i;
              $i=0;
              print '
';
              print '' . $totalqty . '	';
              print '	';
              print '$' . $totalprice . '	';
              print '	';
              print '	';
              print '	';
              print '
';
              print '
';
              print '	';
              print 'Taxed Total: 	';
              print '$' . round($taxedprice,2) . '	';
              print '	';
              print '	';
              print '	';
              print '
';
              print '
';
            }else{
              echo '
No items need to be bought currently!
';
            }
               ?>

           <button type="button" class="close" data-dismiss="modal">×</button>

Add Item

           <?php
           //$addlist = db_addlist();
           $listcount++;
           $sqlgetgroups="SELECT * FROM shop_pgroups";
           $resultgrp = db_query($sqlgetgroups);
           if($resultgrp  != true){echo $resultgrp;}
           print "
           <form action=\"index.php\" method=\"get\">
           <input type=\"number\" class=\"form-control input-text input-sm\" placeholder=\"Quantity\" value=\"1\" name=\"quan\">

           <input type=\"text\" class=\"form-control input-text input-sm\" placeholder=\"Name\" name=\"name\">

           <input type=\"number\" step=\"any\" class=\"form-control input-text input-sm\" placeholder=\"Price\" name=\"price\">

           <select class=\"form-control\" name=\"aisle\" placeholder=\"Aisle\">
           <option></option>
           <option>1A</option>
           <option>2A</option>
           <option>3A</option>
           <option>4A</option>
           <option>4B</option>
           <option>5A</option>
           <option>6A</option>
           <option>7A</option>
           <option>13A</option>
           <option>13B</option>
           <option>14A</option>
           <option>14B</option>
           <option>15A</option>
           <option>15B</option>
           <option>16A</option>
           <option>16B</option>
           <option>17A</option>
           <option>17B</option>
           <option>18A</option>
           <option>18B</option>
           <option>19A</option>
           <option>19B</option>
           <option>20</option>
           <option>21</option>
           <option>22</option>
           <option>Beverage Center</option>
           <option>Frozen</option>
           <option>Deli</option>
           <option>Dairy</option>
           <option>Bakery</option>
           <option>Seafood</option>
           <option>Meat</option>
           <option>Alcohol</option>
           <option>Produce</option>
           </select>

           <select class=\"form-control\" name=\"group\" placeholder=\"Product Type\">
           <option></option>";
           while($rowgrp=$resultgrp->fetch_assoc()){
             echo "<option value='$rowgrp[name]'>$rowgrp[name]</option>";
           }
           echo"
           </select>

           <input type=\"submit\" name=\"submit\" class=\"btn btn-primary btn\" value=\"Add Item\" />
           <input type=\"hidden\" name=\"addby\" value=\"$_SESSION[name]\">

           <input type=\"hidden\" name=\"time\" value=\"$currtime\">

           <input type=\"hidden\" name=\"id\" value=\"" . db_nextid() . "\">

           <input type=\"hidden\" name=\"date\" value=\"$sqldate\">

           </form>";

             //  print "<form action=\"index.php\" method=\"get\">
Remove List Item
List #: <input type=\"text\" name=\"removelistid\">
<input type=\"submit\" name=\"submit\" value=\"Remove Item\" /></form>";
            ?>

           <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>

          <button type="button" class="close" data-dismiss="modal">×</button>

Create New List

          <?php
          print "<form action=\"includes/newlist.php\" method=\"post\">
          <input type=\"text\" class=\"form-control input-text input-sm\" name=\"name\" placeholder=\"List Name\">

          <input type=\"submit\" class=\"btn btn-primary btn\" name=\"newlist\" value=\"Store List\">

        </form>";
        ?>

          <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>

         <button type="button" class="close" data-dismiss="modal">×</button>

Create New Group

         <?php
         print "<form action=\"includes/creategroup.php\" method=\"post\">
         <input type=\"text\" class=\"form-control input-text input-sm\" name=\"name\" placeholder=\"Group Name\">

         <input type=\"submit\" class=\"btn btn-primary btn\" name=\"newlist\" value=\"Create\">

       </form>";
       ?>

         <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>

© <?php print date('Y'); ?> - SugarBombed

            <?php build_footer();?>


text:
export function mergeFuzzySetProps(aggregateFun, multiParam, ...sets) {
  const mfFunc = (...args) => aggregateFun(...sets.map((fs) => fs.func(...args)));
  const mfFuncMultiParam = (...args) => {
    let dimensionSum = 0;
    return aggregateFun(...sets.reduce((prev, fs) => {
      const x = fs.func(...args.slice(dimensionSum));
      dimensionSum += fs.dimension;
      return [...prev, x];
    }, []));
  };

  return {
    func: multiParam ? mfFuncMultiParam : mfFunc,
    dimension: Math.max(...sets.map((fs) => fs.dimension)),
    convex: sets.reduce((result, fs) => fs.convex && result, true),
    normal: sets.reduce((result, fs) => fs.normal && result, true),
    singleton: sets.reduce((result, fs) => fs.singleton && result, true),
    setType: sets.map((u) => u.setType),
    dataType: sets.map((u) => u.dataType),
    setInterval: sets.map((u) => u.setInterval),
    set: sets.map((u) => u.set),
  };
}


text:
package cn.joy.libs.platform;

/**
 * User: JiYu
 * Date: 2016-07-28
 * Time: 17-48
 *
 */

public abstract class Share<T extends Platform> {

	private static final String TAG = "Share";

	private T platform;
	private ShareParams params;

	private boolean shareByClient;

	public enum Target {
		QQ, QQZone, Wechat, WechatMoments, SinaWeibo
	}

	public Share(T platform, ShareParams params) {
		this(platform, params, true);
	}

	public Share(T platform, ShareParams params, boolean shareByClient) {
		this.platform = platform;
		this.params = params;
		this.shareByClient = shareByClient;
	}

	private PlatformActionListener listener;

	protected abstract boolean checkInstall();

	protected abstract boolean checkArgs();

	public Share listener(PlatformActionListener listener) {
		this.listener = listener;
		return this;
	}

	/**
	 * 分享
	 */
	public boolean share() {
		if (platform == null) {
			onError(ErrorCode.ERROR_NOT_INIT);
			return false;
		}
		//  检查是否需要安装客户端以及客户端是否已经安装
		if (shareByClient && !checkInstall()) {
			onError(ErrorCode.ERROR_NOT_INSTALL);
			return false;
		}
		//  检查参数是否正确
		if (!checkArgs()) {
			onError(ErrorCode.ERROR_ARGS);
			return false;
		}
		return true;
	}

	public ShareParams getShareParams() {
		return params;
	}

	public T getPlatform() {
		return platform;
	}

	public boolean isShareByClient() {
		return shareByClient;
	}

	protected void onComplete() {
		if (listener != null) {
			listener.onComplete(null);
		}
		onFinish();
	}

	protected void onError(int code) {
		Logs.d(TAG, code + "");
		if (listener != null) {
			listener.onError(code);
		}
		onFinish();
	}

	protected void onCancel() {
		if (listener != null) {
			listener.onCancel();
		}
		onFinish();
	}

	protected void onFinish() {
		getShareParams().destroy();
	}
}


text:
A sample hubot-script written in ES2015(babel)

## ES2015(babel) Tips

Strictly recommended declaring `use strcit` after header comments.
Hubot parses header comments and use them (e.g. `hubot help`).
If you miss declaring `use strict`, babel inserts some codes before your header comments.

## How to Run with docker

```
docker-compose build
docker-compose run --rm -it hubot
```

or

```
docker build -t hubot-script-es6-sample .
docker run --rm -it hubot-script-es6-sample
```

## How to Debug with docker

```
docker-compose run --rm -it -p 5858:5858 hubotdebug
```

or

```
docker run --rm -it -p 5858:5858 hubot-script-es6-sample coffee --nodejs '--debug' node_modules/hubot/bin/hubot
```


text:
from django.db import migrations

judge_description = (
    "Judges help evaluate startups as part of our Accelerator"
    " Programs. Judges are selected based on their relevant "
    "background and expertise. By offering your judging services"
    " you agree to share your profile data with Mass Challenge"
    " staff in order to match you with appropriate startups."
    " For more information, read about Judging at Mass Challenge.")
mentor_description = (
    "Mentors volunteer to advise a startup for the duration of a "
    "Mass Challenge Program, although many stay engaged for much longer."
    " By offering your mentoring services you make your profile available"
    " to startups looking for expert advice on a long-term basis. "
    "Read more about Mentoring at Mass Challenge.")
speaker_description = (
    "Speakers offer their expertise to the Mass Challenge community"
    " in the form of in-person and virtual presentations. Volunteer"
    " speakers may be contacted by Mass Challenge staff to arrange"
    " for possible speaking opportunities. Read more about Speaking"
    "  at Mass Challenge.")
advisor_description = (
    "Advisors offer their expertise to the Mass Challenge community by"
    " holding office hours, scheduled based on your availability, for "
    "which community members may schedule appointments. Advisors are "
    "listed in our Directory and may be contacted by community members"
    " for appointments. Read more about Office Hours  at Mass Challenge.")
entrepreneur_description = (
    "Entrepreneurs are involved in founding or working for a startup"
    " company. If you've been involved with an early-stage company in"
    " the past, are currently running one, or intend to do so in the "
    "future,  you're welcome at Mass Challenge! Read more about being"
    " an Entrepreneur  at Mass Challenge.")
enterprise_description = (
    "Enterprise employees are associated with corporations interesting "
    "in partnering with the Mass Challenge innovation ecosystem as part"
    " of their company's strategy and operations.")
investor_description = (
    "Investor. Individuals currently or previously involved in placing"
    " investments with early stage companies are welcome to indicate the"
    " role of investor. Investors are included in our community-based investor"
    " directories and may receive outreach from community members.")

PARTICIPATION_ROLE = 'PARTICIPATION_ROLE'
ADVISING_STARTUP_BUSINESS_AREA = 'ADVISING_STARTUP_BUSINESS_AREA'
ADVISING_STARTUP_SUPPORT_BELIEVE = 'ADVISING_STARTUP_SUPPORT_BELIEVE'

participation_data = [
    ['Judge', judge_description, PARTICIPATION_ROLE],
    ['Mentor', mentor_description, PARTICIPATION_ROLE],
    ['Speaker', speaker_description, PARTICIPATION_ROLE],
    ['Advisor', advisor_description, PARTICIPATION_ROLE],
    ['Entrepreneur', entrepreneur_description, PARTICIPATION_ROLE],
    ['Enterprise Employee', enterprise_description, PARTICIPATION_ROLE],
    ['Investor', investor_description, PARTICIPATION_ROLE],
    ['Market Fit', '', ADVISING_STARTUP_BUSINESS_AREA],
    ['Solution/Product Development', '', ADVISING_STARTUP_BUSINESS_AREA],
    ['Business Model', '', ADVISING_STARTUP_BUSINESS_AREA],
    ['Marketing Operations', '', ADVISING_STARTUP_BUSINESS_AREA],
    ['Sales', '', ADVISING_STARTUP_BUSINESS_AREA],
    ['Operations', '', ADVISING_STARTUP_BUSINESS_AREA],
    ['Team & Organizational Design', '', ADVISING_STARTUP_BUSINESS_AREA],
    ['Financing', '', ADVISING_STARTUP_BUSINESS_AREA],
    ['Legal, Compliance, and IP', '', ADVISING_STARTUP_BUSINESS_AREA],
    ['Systems & Technology', '', ADVISING_STARTUP_BUSINESS_AREA],
    ['Industry-specific Expertise', '', ADVISING_STARTUP_SUPPORT_BELIEVE],
    [('General Functional Expertise (Marketing, Organizational Design,'
      ' Sales, etc.)'), '', ADVISING_STARTUP_SUPPORT_BELIEVE],
    ['Sounding Board / Feedback / Deck Development',
     '', ADVISING_STARTUP_SUPPORT_BELIEVE],
    ['Work / Personal Life Balance', '', ADVISING_STARTUP_SUPPORT_BELIEVE],
    ['Managing a Scale-Up Organization', '', ADVISING_STARTUP_SUPPORT_BELIEVE],
    ['Company Culture', '', ADVISING_STARTUP_SUPPORT_BELIEVE],
    ['Introductions to your Network (Investors, Industry, Customers, etc.)',
     '', ADVISING_STARTUP_SUPPORT_BELIEVE],
]

def add_community_participation_data(apps, schema_editor):
    CommunityParticipation = apps.get_model(
        'accelerator', 'CommunityParticipation')
    CommunityParticipation.objects.bulk_create(
        [CommunityParticipation(
            name=name, sort_order=sort_order, description=desc, type=type)
            for sort_order, (name, desc, type)
            in enumerate(participation_data, 1)])

class Migration(migrations.Migration):
    dependencies = [
        ('accelerator', '0080_community_participation_model'),
    ]

    operations = [
        migrations.RunPython(add_community_participation_data,
                             migrations.RunPython.noop)
    ]


text:
package bzh.msansm1.androdek.media.movie;

import android.os.Bundle;
import android.support.design.widget.FloatingActionButton;
import android.support.design.widget.Snackbar;
import android.support.v7.widget.LinearLayoutManager;
import android.support.v7.widget.RecyclerView;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;

import java.util.ArrayList;
import java.util.List;

import butterknife.BindView;
import butterknife.ButterKnife;
import bzh.msansm1.androdek.R;
import bzh.msansm1.androdek.media.MediaFragment;
import bzh.msansm1.androdek.persistence.MedekConfig;
import bzh.msansm1.medekapi.MedekApi;
import bzh.msansm1.medekapi.RetrofitManager;
import bzh.msansm1.medekapi.json.JsonError;
import bzh.msansm1.medekapi.json.movie.JsonMovie;
import eu.davidea.flexibleadapter.FlexibleAdapter;
import eu.davidea.flexibleadapter.SelectableAdapter;
import eu.davidea.flexibleadapter.items.IFlexible;

/**
 * A placeholder fragment containing a simple view.
 */
public class MovieFragment extends MediaFragment {

    @BindView(R.id.add_movie)
    FloatingActionButton addMovie;

    @BindView(R.id.moviesList)
    RecyclerView moviesList;

    @BindView(R.id.moviesEmpty)
    TextView moviesEmpty;

    private RecyclerView.LayoutManager mLayoutManager;
    private FlexibleAdapter<IFlexible> adapter;

    public MovieFragment() {
    }

    public static MovieFragment getFragment(){
        return new MovieFragment();
    }

    public static MovieFragment getFragment(Boolean mylist) {
        MovieFragment frag = new MovieFragment();
        Bundle args = new Bundle();
        args.putBoolean("mylist", mylist);
        frag.setArguments(args);
        return frag;
    }

    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container,
                             Bundle savedInstanceState) {
        View view = inflater.inflate(R.layout.fragment_movie, container, false);
        ButterKnife.bind(this,view);

        mLayoutManager = new LinearLayoutManager(mActivity);
        moviesList.setLayoutManager(mLayoutManager);

        final MedekConfig conf = mActivity.getRealm().where(MedekConfig.class).findFirst();

        final List<IFlexible> movieItems = new ArrayList<>();
        MedekApi.getInstance().getAllMovies(0, 50, "title", "asc", new RetrofitManager.MedekCallBack<List<JsonMovie>>() {
            @Override
            public void success(List<JsonMovie> jsonMovies) {
                if (!jsonMovies.isEmpty()) {
                    moviesEmpty.setVisibility(View.GONE);
                    List<IFlexible> newItems = new ArrayList<>();
                    for (JsonMovie m : jsonMovies) {
                        newItems.add(new MovieItem(m.getId(), m.getTitle(), m.getRealisator(), conf.getApiUrl()+"medekimg/movie/"+m.getId()+"/cover.jpg"));
                    }
                    adapter.updateDataSet(newItems);
                }
            }

            @Override
            public void failure(JsonError error) {
                Snackbar.make(getView(), error.getTitle(), Snackbar.LENGTH_LONG)
                        .setAction("Action", null).show();
            }
        });

        if (!movieItems.isEmpty()) {
            moviesEmpty.setVisibility(View.GONE);
        }

        //Initialize the Adapter
        adapter = new FlexibleAdapter<>(movieItems);

        adapter.setAnimationOnScrolling(true)
                .setAnimationOnReverseScrolling(true);
        adapter.setMode(SelectableAdapter.MODE_SINGLE);

        //Initialize the RecyclerView and attach the Adapter to it as usual
        moviesList.setAdapter(adapter);

        adapter.setSwipeEnabled(true);

        addMovie.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                Snackbar.make(view, "Add Movie", Snackbar.LENGTH_LONG)
                        .setAction("Action", null).show();
            }
        });

        return view;
    }
}


text:
package cloudcallcenter

//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.
//
// Code generated by Alibaba Cloud SDK Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenerated.

import (
	"github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests"
	"github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses"
)

// AddUsersToSkillGroup invokes the cloudcallcenter.AddUsersToSkillGroup API synchronously
// api document: https://help.aliyun.com/api/cloudcallcenter/adduserstoskillgroup.html
func (client *Client) AddUsersToSkillGroup(request *AddUsersToSkillGroupRequest) (response *AddUsersToSkillGroupResponse, err error) {
	response = CreateAddUsersToSkillGroupResponse()
	err = client.DoAction(request, response)
	return
}

// AddUsersToSkillGroupWithChan invokes the cloudcallcenter.AddUsersToSkillGroup API asynchronously
// api document: https://help.aliyun.com/api/cloudcallcenter/adduserstoskillgroup.html
// asynchronous document: https://help.aliyun.com/document_detail/66220.html
func (client *Client) AddUsersToSkillGroupWithChan(request *AddUsersToSkillGroupRequest) (<-chan *AddUsersToSkillGroupResponse, <-chan error) {
	responseChan := make(chan *AddUsersToSkillGroupResponse, 1)
	errChan := make(chan error, 1)
	err := client.AddAsyncTask(func() {
		defer close(responseChan)
		defer close(errChan)
		response, err := client.AddUsersToSkillGroup(request)
		if err != nil {
			errChan <- err
		} else {
			responseChan <- response
		}
	})
	if err != nil {
		errChan <- err
		close(responseChan)
		close(errChan)
	}
	return responseChan, errChan
}

// AddUsersToSkillGroupWithCallback invokes the cloudcallcenter.AddUsersToSkillGroup API asynchronously
// api document: https://help.aliyun.com/api/cloudcallcenter/adduserstoskillgroup.html
// asynchronous document: https://help.aliyun.com/document_detail/66220.html
func (client *Client) AddUsersToSkillGroupWithCallback(request *AddUsersToSkillGroupRequest, callback func(response *AddUsersToSkillGroupResponse, err error)) <-chan int {
	result := make(chan int, 1)
	err := client.AddAsyncTask(func() {
		var response *AddUsersToSkillGroupResponse
		var err error
		defer close(result)
		response, err = client.AddUsersToSkillGroup(request)
		callback(response, err)
		result <- 1
	})
	if err != nil {
		defer close(result)
		callback(nil, err)
		result <- 0
	}
	return result
}

// AddUsersToSkillGroupRequest is the request struct for api AddUsersToSkillGroup
type AddUsersToSkillGroupRequest struct {
	*requests.RpcRequest
	SkillLevel   *[]string `position:"Query" name:"SkillLevel"  type:"Repeated"`
	InstanceId   string    `position:"Query" name:"InstanceId"`
	SkillGroupId string    `position:"Query" name:"SkillGroupId"`
	UserId       *[]string `position:"Query" name:"UserId"  type:"Repeated"`
}

// AddUsersToSkillGroupResponse is the response struct for api AddUsersToSkillGroup
type AddUsersToSkillGroupResponse struct {
	*responses.BaseResponse
	RequestId      string `json:"RequestId" xml:"RequestId"`
	Success        bool   `json:"Success" xml:"Success"`
	Code           string `json:"Code" xml:"Code"`
	Message        string `json:"Message" xml:"Message"`
	HttpStatusCode int    `json:"HttpStatusCode" xml:"HttpStatusCode"`
}

// CreateAddUsersToSkillGroupRequest creates a request to invoke AddUsersToSkillGroup API
func CreateAddUsersToSkillGroupRequest() (request *AddUsersToSkillGroupRequest) {
	request = &AddUsersToSkillGroupRequest{
		RpcRequest: &requests.RpcRequest{},
	}
	request.InitWithApiInfo("CloudCallCenter", "2017-07-05", "AddUsersToSkillGroup", "", "")
	request.Method = requests.POST
	return
}

// CreateAddUsersToSkillGroupResponse creates a response to parse from AddUsersToSkillGroup response
func CreateAddUsersToSkillGroupResponse() (response *AddUsersToSkillGroupResponse) {
	response = &AddUsersToSkillGroupResponse{
		BaseResponse: &responses.BaseResponse{},
	}
	return
}


text:
extern "C" {
#endif

typedef struct _opts_t
{ const char * path;
  const char * query[2];
  const char * output;   // if not null, output selected tiles in a cache file here
  int nocorners;
} opts_t;

opts_t parsargs(int *argc, char** argv[], int *isok);

#ifdef __cplusplus
} //extern "C"
#endif


text:
<?php
/**
 * OAuth
 *
 * @package OAuth
 * @author Andy Smith
 * @author Gary Jones <gary@garyjones.co.uk>
 * @license https://raw.github.com/jacobkiers/OAuth/master/LICENSE MIT
 * @link https://github.com/jacobkiers/OAuth
 */

namespace JacobKiers\OAuth;

/**
 * Group of static utility methods.
 *
 * @package OAuth
 * @author Andy Smith
 */
class Util
{
    /**
     * Encode a string according to RFC 3986.
     *
     * @param string $input
     *
     * @return string Encoded string.
     */
    public static function urlencodeRfc3986($input)
    {
        if (is_array($input)) {
            return array_map(array('JacobKiers\OAuth\Util', 'urlencodeRfc3986'), $input);
        } elseif (is_scalar($input)) {
            return str_replace('+', ' ', str_replace('%7E', '~', rawurlencode($input)));
        } else {
            return '';
        }
    }

    /**
     * Decode a string.
     *
     * This decode function isn't taking into consideration the above modifications to the encoding process.
     * However, this method doesn't seem to be used anywhere so leaving it as is.
     *
     * @param string $string
     *
     * @return string Decoded string.
     */
    public static function urldecodeRfc3986($string)
    {
        return urldecode($string);
    }

    /**
     * Utility function for turning the Authorization: header into parameters.
     *
     * Has to do some unescaping. Can filter out any non-oauth parameters if needed (default behaviour).
     *
     * May 28th, 2010 - method updated to tjerk.meesters for a speed improvement.
     *                  see http://code.google.com/p/oauth/issues/detail?id=163
     *
     * @param string $header
     * @param bool   $only_allow_oauth_parameters
     *
     * @return array
     */
    public static function splitHeader($header, $only_allow_oauth_parameters = true)
    {
        $params = array();
        $regex = '/(' . ($only_allow_oauth_parameters ? 'oauth_' : '') . '[a-z_-]*)=(:?"([^"]*)"|([^,]*))/';
        if (preg_match_all($regex, $header, $matches)) {
            foreach ($matches[1] as $i => $h) {
                $params[$h] = Util::urldecodeRfc3986(empty($matches[3][$i]) ? $matches[4][$i] : $matches[3][$i]);
            }
            if (isset($params['realm'])) {
                unset($params['realm']);
            }
        }
        return $params;
    }

    /**
     * Helper to try to sort out headers for people who aren't running apache
     *
     * @return array
     */
    public static function getHeaders()
    {
        $out = array();
        if (function_exists('apache_request_headers')) {
            // we need this to get the actual Authorization: header
            // because apache tends to tell us it doesn't exist
            $headers = apache_request_headers();

            // sanitize the output of apache_request_headers because
            // we always want the keys to be Cased-Like-This and arh()
            // returns the headers in the same case as they are in the
            // request
            foreach ($headers as $key => $value) {
                $key = str_replace(' ', '-', ucwords(strtolower(str_replace('-', ' ', $key))));
                $out[$key] = $value;
            }
        } else {
            // otherwise we don't have apache and are just going to have to hope
            // that $_SERVER actually contains what we need
            if (isset($_SERVER['CONTENT_TYPE'])) {
                $out['Content-Type'] = $_SERVER['CONTENT_TYPE'];
            }
            if (isset($_ENV['CONTENT_TYPE'])) {
                $out['Content-Type'] = $_ENV['CONTENT_TYPE'];
            }

            foreach ($_SERVER as $key => $value) {
                if (substr($key, 0, 5) == "HTTP_") {
                    // this is chaos, basically it is just there to capitalize the first
                    // letter of every word that is not an initial HTTP and strip HTTP
                    // code from przemek
                    $key = str_replace(' ', '-', ucwords(strtolower(str_replace('_', ' ', substr($key, 5)))));
                    $out[$key] = $value;
                }
            }
        }
        return $out;
    }

    /**
     * Pull key=value querystring into an array.
     *
     * This function takes a input like a=b&a=c&d=e and returns the parsed
     * parameters like this
     * array('a' => array('b','c'), 'd' => 'e')
     *
     * @param string $input
     *
     * @return array
     */
    public static function parseParameters($input)
    {
        if (!isset($input) || !$input) {
            return array();
        }

        $pairs = explode('&', $input);

        $parsed_parameters = array();
        foreach ($pairs as $pair) {
            $split = explode('=', $pair, 2);
            $parameter = Util::urldecodeRfc3986($split[0]);
            $value = isset($split[1]) ? Util::urldecodeRfc3986($split[1]) : '';

            if (isset($parsed_parameters[$parameter])) {
                // We have already recieved parameter(s) with this name, so add to the list
                // of parameters with this name

                if (is_scalar($parsed_parameters[$parameter])) {
                    // This is the first duplicate, so transform scalar (string) into an array
                    // so we can add the duplicates
                    $parsed_parameters[$parameter] = array($parsed_parameters[$parameter]);
                }

                $parsed_parameters[$parameter][] = $value;
            } else {
                $parsed_parameters[$parameter] = $value;
            }
        }
        return $parsed_parameters;
    }

    /**
     * Build query string from parameters, with correct encoding.
     *
     * @param array $params
     *
     * @return string
     */
    public static function buildHttpQuery(array $params)
    {
        if (!$params) {
            return '';
        }

        // Urlencode both keys and values
        $keys = Util::urlencodeRfc3986(array_keys($params));
        $values = Util::urlencodeRfc3986(array_values($params));
        $params = array_combine($keys, $values);

        // Parameters are sorted by name, using lexicographical byte value ordering.
        // Ref: Spec: 9.1.1 (1)
        uksort($params, 'strcmp');

        $pairs = array();
        foreach ($params as $parameter => $value) {
            if (is_array($value)) {
                // If two or more parameters share the same name, they are sorted by their value
                // Ref: Spec: 9.1.1 (1)
                // June 12th, 2010 - changed to sort because of issue 164 by hidetaka
                sort($value, SORT_STRING);
                foreach ($value as $duplicate_value) {
                    $pairs[] = $parameter . '=' . $duplicate_value;
                }
            } else {
                $pairs[] = $parameter . '=' . $value;
            }
        }
        // For each parameter, the name is separated from the corresponding value by an '=' character (ASCII code 61)
        // Each name-value pair is separated by an '&' character (ASCII code 38)
        return implode('&', $pairs);
    }
}