text:
import java.util.LinkedList;

public class Rocket {
    public static void main(String [] args) {
	Object obj = new Object();
	Foo foo = new Foo();
	foo.apa(obj);
	zoo(obj);
    }

    public static void zoo(Object obj) {
	obj = new Object();
    }

}

class Foo {
    int a = 34;
    public void apa(Object obj) {
	obj = new Object();
	Object a = new Object();

    }
}

redpajama_set_name: RedPajamaGithub


text:
.class public Landroid/print/PrintFileDocumentAdapter;
.super Landroid/print/PrintDocumentAdapter;
.source "PrintFileDocumentAdapter.java"

# annotations
.annotation system Ldalvik/annotation/MemberClasses;
    value = {
        Landroid/print/PrintFileDocumentAdapter$WriteFileAsyncTask;
    }
.end annotation

# static fields
.field private static final LOG_TAG:Ljava/lang/String; = "PrintedFileDocumentAdapter"

# instance fields
.field private final mContext:Landroid/content/Context;

.field private final mDocumentInfo:Landroid/print/PrintDocumentInfo;

.field private final mFile:Ljava/io/File;

.field private mWriteFileAsyncTask:Landroid/print/PrintFileDocumentAdapter$WriteFileAsyncTask;

# direct methods
.method static synthetic -get0(Landroid/print/PrintFileDocumentAdapter;)Landroid/content/Context;
    .registers 2

    iget-object v0, p0, Landroid/print/PrintFileDocumentAdapter;->mContext:Landroid/content/Context;

    return-object v0
.end method

.method static synthetic -get1(Landroid/print/PrintFileDocumentAdapter;)Ljava/io/File;
    .registers 2

    iget-object v0, p0, Landroid/print/PrintFileDocumentAdapter;->mFile:Ljava/io/File;

    return-object v0
.end method

.method public constructor <init>(Landroid/content/Context;Ljava/io/File;Landroid/print/PrintDocumentInfo;)V
    .registers 6
    .param p1, "context"    # Landroid/content/Context;
    .param p2, "file"    # Ljava/io/File;
    .param p3, "documentInfo"    # Landroid/print/PrintDocumentInfo;

    .prologue
    .line 66
    invoke-direct {p0}, Landroid/print/PrintDocumentAdapter;-><init>()V

    .line 68
    if-nez p2, :cond_e

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

    const-string/jumbo v1, "File cannot be null!"

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

    throw v0

    .line 71
    :cond_e
    if-nez p3, :cond_19

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

    const-string/jumbo v1, "documentInfo cannot be null!"

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

    throw v0

    .line 74
    :cond_19
    iput-object p1, p0, Landroid/print/PrintFileDocumentAdapter;->mContext:Landroid/content/Context;

    .line 75
    iput-object p2, p0, Landroid/print/PrintFileDocumentAdapter;->mFile:Ljava/io/File;

    .line 76
    iput-object p3, p0, Landroid/print/PrintFileDocumentAdapter;->mDocumentInfo:Landroid/print/PrintDocumentInfo;

    .line 67
    return-void
.end method

# virtual methods
.method public onLayout(Landroid/print/PrintAttributes;Landroid/print/PrintAttributes;Landroid/os/CancellationSignal;Landroid/print/PrintDocumentAdapter$LayoutResultCallback;Landroid/os/Bundle;)V
    .registers 8
    .param p1, "oldAttributes"    # Landroid/print/PrintAttributes;
    .param p2, "newAttributes"    # Landroid/print/PrintAttributes;
    .param p3, "cancellationSignal"    # Landroid/os/CancellationSignal;
    .param p4, "callback"    # Landroid/print/PrintDocumentAdapter$LayoutResultCallback;
    .param p5, "metadata"    # Landroid/os/Bundle;

    .prologue
    .line 83
    iget-object v0, p0, Landroid/print/PrintFileDocumentAdapter;->mDocumentInfo:Landroid/print/PrintDocumentInfo;

    const/4 v1, 0x0

    invoke-virtual {p4, v0, v1}, Landroid/print/PrintDocumentAdapter$LayoutResultCallback;->onLayoutFinished(Landroid/print/PrintDocumentInfo;Z)V

    .line 82
    return-void
.end method

.method public onWrite([Landroid/print/PageRange;Landroid/os/ParcelFileDescriptor;Landroid/os/CancellationSignal;Landroid/print/PrintDocumentAdapter$WriteResultCallback;)V
    .registers 8
    .param p1, "pages"    # [Landroid/print/PageRange;
    .param p2, "destination"    # Landroid/os/ParcelFileDescriptor;
    .param p3, "cancellationSignal"    # Landroid/os/CancellationSignal;
    .param p4, "callback"    # Landroid/print/PrintDocumentAdapter$WriteResultCallback;

    .prologue
    .line 89
    new-instance v0, Landroid/print/PrintFileDocumentAdapter$WriteFileAsyncTask;

    invoke-direct {v0, p0, p2, p3, p4}, Landroid/print/PrintFileDocumentAdapter$WriteFileAsyncTask;-><init>(Landroid/print/PrintFileDocumentAdapter;Landroid/os/ParcelFileDescriptor;Landroid/os/CancellationSignal;Landroid/print/PrintDocumentAdapter$WriteResultCallback;)V

    iput-object v0, p0, Landroid/print/PrintFileDocumentAdapter;->mWriteFileAsyncTask:Landroid/print/PrintFileDocumentAdapter$WriteFileAsyncTask;

    .line 90
    iget-object v1, p0, Landroid/print/PrintFileDocumentAdapter;->mWriteFileAsyncTask:Landroid/print/PrintFileDocumentAdapter$WriteFileAsyncTask;

    sget-object v2, Landroid/os/AsyncTask;->THREAD_POOL_EXECUTOR:Ljava/util/concurrent/Executor;

    .line 91
    const/4 v0, 0x0

    check-cast v0, [Ljava/lang/Void;

    .line 90
    invoke-virtual {v1, v2, v0}, Landroid/print/PrintFileDocumentAdapter$WriteFileAsyncTask;->executeOnExecutor(Ljava/util/concurrent/Executor;[Ljava/lang/Object;)Landroid/os/AsyncTask;

    .line 88
    return-void
.end method


text:
#include "Wt/WAnimation"

namespace Wt {

WAnimation::WAnimation()
  : effects_(0),
    timing_(Linear),
    duration_(250)
{ }

WAnimation::WAnimation(WFlags<AnimationEffect> effects, TimingFunction timing,
		       int duration)
  : effects_(effects),
    timing_(timing),
    duration_(duration)
{ }

#ifdef WT_TARGET_JAVA

WAnimation::WAnimation(AnimationEffect effect, TimingFunction timing,
		       int duration)
  : effects_(effect),
    timing_(timing),
    duration_(duration)
{ }

WAnimation::WAnimation(AnimationEffect effect1, AnimationEffect effect2,
		       TimingFunction timing, int duration)
  : effects_(effect1 | effect2),
    timing_(timing),
    duration_(duration)
{ }

WAnimation WAnimation::clone() const
{
  WAnimation result;
  result.effects_ = effects_;
  result.duration_ = duration_;
  return result;
}
#endif // WT_TARGET_JAVA

bool WAnimation::operator==(const WAnimation& animation) const
{
  return animation.effects_ == effects_
    && animation.duration_ == duration_;
}

bool WAnimation::operator!=(const WAnimation& animation) const
{
  return !(*this == animation);
}

void WAnimation::setEffects(WFlags<AnimationEffect> effects)
{
  effects_ = effects;
}

void WAnimation::setDuration(int msecs)
{
  duration_ = msecs;
}

void WAnimation::setTimingFunction(TimingFunction tf)
{
  timing_ = tf;
}

bool WAnimation::empty() const
{
  return duration_ == 0 || !effects_;
}

}


text:
require File.expand_path("../sentence", __FILE__)
require File.expand_path("../corpus", __FILE__)

module Conll
  Token = Struct.new(:id, :form, :lemma, :cpos, :pos, :feats, :head_id, :deprel, :phead_id, :pdeprel)

  class Token
    attr_accessor :sentence

    def self.parse(line)
      fields = line.split(/\t/)
      fields = fields[0..2] + fields[3..-1].collect do |f|
        # Interpret dash/underscore as "missing value" and use nil instead
        (f == '_' or f == '-') ? nil : f
      end unless fields.size < 4
      # Pass in a reference to the sentence
      Token.new(*fields)
    end

    def initialize(*vals)
      super(*vals)
      # Split features
      @features = vals[5].split(/\|/) unless vals[5].nil?
      yield self if block_given?
    end

    # Gives the base-0 index of this token into the sentence
    def index
      self.id.to_i - 1
    end

    def first?
      self.index == 0
    end

    def last?
      self.index == @sentence.tokens.size - 1
    end

    def next
      @sentence.tokens[index + 1]
    end

    def prev
      @sentence.tokens[index - 1]
    end

    def features
      @features ||= []
    end

    def head
      find_token(self.head_id)
    end

    def dependents
      @sentence.tokens.find_all { |tok| tok.head_id == self.id }
    end

    def phead
      find_token(self.phead_id)
    end

    def to_s
      if self.features.size > 0
        self.feats = self.features.to_a.join('|')
      else
        self.feats = nil
      end
      self.values.collect { |val|
        val.nil? ? '_' : val
      }.join("\t")
    end

    def head_correct? gold_token
      self.head.id == gold_token.head.id
    end

    def label_correct? gold_token
      self.deprel == gold_token.deprel
    end

    def correct? gold_token
      head_correct? gold_token and label_correct? gold_token
    end

    def leading(n)
      @sentence.tokens[self.index-n .. self.index-1]
    end

    def trailing(n)
      @sentence.tokens[self.index+1 .. self.index+n]
    end

    private

    def find_token(id)
      if id == '0'
        @sentence.root
      else
        @sentence.tokens[id.to_i - 1]
      end
    end

  end

  class RootToken < Token
    def initialize
      super('0', 'ROOT')
    end
  end

end


text:
FindBLAS
--------

Find Basic Linear Algebra Subprograms (BLAS) library

This module finds an installed Fortran library that implements the
BLAS linear-algebra interface (see http://www.netlib.org/blas/).  The
list of libraries searched for is taken from the ``autoconf`` macro file,
``acx_blas.m4`` (distributed at
http://ac-archive.sourceforge.net/ac-archive/acx_blas.html).

Input Variables
^^^^^^^^^^^^^^^

The following variables may be set to influence this module's behavior:

``BLA_STATIC``
  if ``ON`` use static linkage

``BLA_VENDOR``
  If set, checks only the specified vendor, if not set checks all the
  possibilities.  List of vendors valid in this module:

  * Goto
  * OpenBLAS
  * FLAME
  * ATLAS PhiPACK
  * CXML
  * DXML
  * SunPerf
  * SCSL
  * SGIMATH
  * IBMESSL
  * Intel10_32 (intel mkl v10 32 bit)
  * Intel10_64lp (intel mkl v10+ 64 bit, threaded code, lp64 model)
  * Intel10_64lp_seq (intel mkl v10+ 64 bit, sequential code, lp64 model)
  * Intel10_64ilp (intel mkl v10+ 64 bit, threaded code, ilp64 model)
  * Intel10_64ilp_seq (intel mkl v10+ 64 bit, sequential code, ilp64 model)
  * Intel (obsolete versions of mkl 32 and 64 bit)
  * ACML
  * ACML_MP
  * ACML_GPU
  * Apple
  * NAS
  * Generic

``BLA_F95``
  if ``ON`` tries to find the BLAS95 interfaces

``BLA_PREFER_PKGCONFIG``
  if set ``pkg-config`` will be used to search for a BLAS library first
  and if one is found that is preferred

Result Variables
^^^^^^^^^^^^^^^^

This module defines the following variables:

``BLAS_FOUND``
  library implementing the BLAS interface is found
``BLAS_LINKER_FLAGS``
  uncached list of required linker flags (excluding ``-l`` and ``-L``).
``BLAS_LIBRARIES``
  uncached list of libraries (using full path name) to link against
  to use BLAS (may be empty if compiler implicitly links BLAS)
``BLAS95_LIBRARIES``
  uncached list of libraries (using full path name) to link against
  to use BLAS95 interface
``BLAS95_FOUND``
  library implementing the BLAS95 interface is found

.. note::

  C or CXX must be enabled to use Intel Math Kernel Library (MKL)

  For example, to use Intel MKL libraries and/or Intel compiler:

  .. code-block:: cmake

    set(BLA_VENDOR Intel10_64lp)
    find_package(BLAS)

Hints
^^^^^

Set ``MKLROOT`` environment variable to a directory that contains an MKL
installation.

#]=======================================================================]

include(${CMAKE_CURRENT_LIST_DIR}/CheckFunctionExists.cmake)
include(${CMAKE_CURRENT_LIST_DIR}/CheckFortranFunctionExists.cmake)
include(${CMAKE_CURRENT_LIST_DIR}/CMakePushCheckState.cmake)
include(${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake)
cmake_push_check_state()
set(CMAKE_REQUIRED_QUIET ${BLAS_FIND_QUIETLY})

set(_blas_ORIG_CMAKE_FIND_LIBRARY_SUFFIXES ${CMAKE_FIND_LIBRARY_SUFFIXES})

# Check the language being used
if( NOT (CMAKE_C_COMPILER_LOADED OR CMAKE_CXX_COMPILER_LOADED OR CMAKE_Fortran_COMPILER_LOADED) )
  if(BLAS_FIND_REQUIRED)
    message(FATAL_ERROR "FindBLAS requires Fortran, C, or C++ to be enabled.")
  else()
    message(STATUS "Looking for BLAS... - NOT found (Unsupported languages)")
    return()
  endif()
endif()

if(BLA_PREFER_PKGCONFIG)
  find_package(PkgConfig)
  pkg_check_modules(PKGC_BLAS blas)
  if(PKGC_BLAS_FOUND)
    set(BLAS_FOUND ${PKGC_BLAS_FOUND})
    set(BLAS_LIBRARIES "${PKGC_BLAS_LINK_LIBRARIES}")
    return()
  endif()
endif()

macro(Check_Fortran_Libraries LIBRARIES _prefix _name _flags _list _thread)
  # This macro checks for the existence of the combination of fortran libraries
  # given by _list.  If the combination is found, this macro checks (using the
  # Check_Fortran_Function_Exists macro) whether can link against that library
  # combination using the name of a routine given by _name using the linker
  # flags given by _flags.  If the combination of libraries is found and passes
  # the link test, LIBRARIES is set to the list of complete library paths that
  # have been found.  Otherwise, LIBRARIES is set to FALSE.

  # N.B. _prefix is the prefix applied to the names of all cached variables that
  # are generated internally and marked advanced by this macro.

  set(_libdir ${ARGN})

  set(_libraries_work TRUE)
  set(${LIBRARIES})
  set(_combined_name)
  if (NOT _libdir)
    if (WIN32)
      set(_libdir ENV LIB)
    elseif (APPLE)
      set(_libdir ENV DYLD_LIBRARY_PATH)
    else ()
      set(_libdir ENV LD_LIBRARY_PATH)
    endif ()
  endif ()

  list(APPEND _libdir "${CMAKE_C_IMPLICIT_LINK_DIRECTORIES}")

  foreach(_library ${_list})
    set(_combined_name ${_combined_name}_${_library})
    if(NOT "${_thread}" STREQUAL "")
      set(_combined_name ${_combined_name}_thread)
    endif()
    if(_libraries_work)
      if (BLA_STATIC)
        if (WIN32)
          set(CMAKE_FIND_LIBRARY_SUFFIXES .lib ${CMAKE_FIND_LIBRARY_SUFFIXES})
        endif ()
        if (APPLE)
          set(CMAKE_FIND_LIBRARY_SUFFIXES .lib ${CMAKE_FIND_LIBRARY_SUFFIXES})
        else ()
          set(CMAKE_FIND_LIBRARY_SUFFIXES .a ${CMAKE_FIND_LIBRARY_SUFFIXES})
        endif ()
      else ()
        if (CMAKE_SYSTEM_NAME STREQUAL "Linux")
          # for ubuntu's libblas3gf and liblapack3gf packages
          set(CMAKE_FIND_LIBRARY_SUFFIXES ${CMAKE_FIND_LIBRARY_SUFFIXES} .so.3gf)
        endif ()
      endif ()
      find_library(${_prefix}_${_library}_LIBRARY
        NAMES ${_library}
        PATHS ${_libdir}
        )
      mark_as_advanced(${_prefix}_${_library}_LIBRARY)
      set(${LIBRARIES} ${${LIBRARIES}} ${${_prefix}_${_library}_LIBRARY})
      set(_libraries_work ${${_prefix}_${_library}_LIBRARY})
    endif()
  endforeach()
  if(_libraries_work)
    # Test this combination of libraries.
    set(CMAKE_REQUIRED_LIBRARIES ${_flags} ${${LIBRARIES}} ${_thread})
    #  message("DEBUG: CMAKE_REQUIRED_LIBRARIES = ${CMAKE_REQUIRED_LIBRARIES}")
    if (CMAKE_Fortran_COMPILER_LOADED)
      check_fortran_function_exists("${_name}" ${_prefix}${_combined_name}_WORKS)
    else()
      check_function_exists("${_name}_" ${_prefix}${_combined_name}_WORKS)
    endif()
    set(CMAKE_REQUIRED_LIBRARIES)
    set(_libraries_work ${${_prefix}${_combined_name}_WORKS})
  endif()
  if(_libraries_work)
    if("${_list}" STREQUAL "")
      set(${LIBRARIES} "${LIBRARIES}-PLACEHOLDER-FOR-EMPTY-LIBRARIES")
    else()
      set(${LIBRARIES} ${${LIBRARIES}} ${_thread})  # for static link
    endif()
  else()
    set(${LIBRARIES} FALSE)
  endif()
  #message("DEBUG: ${LIBRARIES} = ${${LIBRARIES}}")
endmacro()

set(BLAS_LINKER_FLAGS)
set(BLAS_LIBRARIES)
set(BLAS95_LIBRARIES)
if (NOT $ENV{BLA_VENDOR} STREQUAL "")
  set(BLA_VENDOR $ENV{BLA_VENDOR})
else ()
  if(NOT BLA_VENDOR)
    set(BLA_VENDOR "All")
  endif()
endif ()

if (BLA_VENDOR STREQUAL "All")
  if(NOT BLAS_LIBRARIES)
    # Implicitly linked BLAS libraries
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      sgemm
      ""
      ""
      ""
      )
  endif()
endif ()

#BLAS in intel mkl 10+ library? (em64t 64bit)
if (BLA_VENDOR MATCHES "Intel" OR BLA_VENDOR STREQUAL "All")
  if (NOT BLAS_LIBRARIES)

    # System-specific settings
    if (WIN32)
      if (BLA_STATIC)
        set(BLAS_mkl_DLL_SUFFIX "")
      else()
        set(BLAS_mkl_DLL_SUFFIX "_dll")
      endif()
    else()
      # Switch to GNU Fortran support layer if needed (but not on Apple, where MKL does not provide it)
      if(CMAKE_Fortran_COMPILER_LOADED AND CMAKE_Fortran_COMPILER_ID STREQUAL "GNU" AND NOT APPLE)
          set(BLAS_mkl_INTFACE "gf")
          set(BLAS_mkl_THREADING "gnu")
          set(BLAS_mkl_OMP "gomp")
      else()
          set(BLAS_mkl_INTFACE "intel")
          set(BLAS_mkl_THREADING "intel")
          set(BLAS_mkl_OMP "iomp5")
      endif()
      set(BLAS_mkl_LM "-lm")
      set(BLAS_mkl_LDL "-ldl")
    endif()

    if (BLA_VENDOR MATCHES "_64ilp")
      set(BLAS_mkl_ILP_MODE "ilp64")
    else ()
      set(BLAS_mkl_ILP_MODE "lp64")
    endif ()

    if (CMAKE_C_COMPILER_LOADED OR CMAKE_CXX_COMPILER_LOADED)
      if(BLAS_FIND_QUIETLY OR NOT BLAS_FIND_REQUIRED)
        find_package(Threads)
      else()
        find_package(Threads REQUIRED)
      endif()

      set(BLAS_SEARCH_LIBS "")

      if(BLA_F95)
        set(BLAS_mkl_SEARCH_SYMBOL sgemm_f95)
        set(_LIBRARIES BLAS95_LIBRARIES)
        if (WIN32)
          # Find the main file (32-bit or 64-bit)
          set(BLAS_SEARCH_LIBS_WIN_MAIN "")
          if (BLA_VENDOR STREQUAL "Intel10_32" OR BLA_VENDOR STREQUAL "All")
            list(APPEND BLAS_SEARCH_LIBS_WIN_MAIN
              "mkl_blas95${BLAS_mkl_DLL_SUFFIX} mkl_intel_c${BLAS_mkl_DLL_SUFFIX}")
          endif()
          if (BLA_VENDOR MATCHES "^Intel10_64i?lp" OR BLA_VENDOR STREQUAL "All")
            list(APPEND BLAS_SEARCH_LIBS_WIN_MAIN
              "mkl_blas95_${BLAS_mkl_ILP_MODE}${BLAS_mkl_DLL_SUFFIX} mkl_intel_${BLAS_mkl_ILP_MODE}${BLAS_mkl_DLL_SUFFIX}")
          endif ()

          # Add threading/sequential libs
          set(BLAS_SEARCH_LIBS_WIN_THREAD "")
          if (BLA_VENDOR MATCHES "_seq$" OR BLA_VENDOR STREQUAL "All")
            list(APPEND BLAS_SEARCH_LIBS_WIN_THREAD
              "mkl_sequential${BLAS_mkl_DLL_SUFFIX}")
          endif()
          if (NOT BLA_VENDOR MATCHES "_seq$" OR BLA_VENDOR STREQUAL "All")
            # old version
            list(APPEND BLAS_SEARCH_LIBS_WIN_THREAD
              "libguide40 mkl_intel_thread${BLAS_mkl_DLL_SUFFIX}")
            # mkl >= 10.3
            list(APPEND BLAS_SEARCH_LIBS_WIN_THREAD
              "libiomp5md mkl_intel_thread${BLAS_mkl_DLL_SUFFIX}")
          endif()

          # Cartesian product of the above
          foreach (MAIN ${BLAS_SEARCH_LIBS_WIN_MAIN})
            foreach (THREAD ${BLAS_SEARCH_LIBS_WIN_THREAD})
              list(APPEND BLAS_SEARCH_LIBS
                "${MAIN} ${THREAD} mkl_core${BLAS_mkl_DLL_SUFFIX}")
            endforeach()
          endforeach()
        else ()
          if (BLA_VENDOR STREQUAL "Intel10_32" OR BLA_VENDOR STREQUAL "All")
            # old version
            list(APPEND BLAS_SEARCH_LIBS
              "mkl_blas95 mkl_${BLAS_mkl_INTFACE} mkl_${BLAS_mkl_THREADING}_thread mkl_core guide")

            # mkl >= 10.3
            list(APPEND BLAS_SEARCH_LIBS
              "mkl_blas95 mkl_${BLAS_mkl_INTFACE} mkl_${BLAS_mkl_THREADING}_thread mkl_core ${BLAS_mkl_OMP}")
          endif ()
          if (BLA_VENDOR MATCHES "^Intel10_64i?lp$" OR BLA_VENDOR STREQUAL "All")
            # old version
            list(APPEND BLAS_SEARCH_LIBS
              "mkl_blas95 mkl_${BLAS_mkl_INTFACE}_${BLAS_mkl_ILP_MODE} mkl_${BLAS_mkl_THREADING}_thread mkl_core guide")

            # mkl >= 10.3
            list(APPEND BLAS_SEARCH_LIBS
              "mkl_blas95_${BLAS_mkl_ILP_MODE} mkl_${BLAS_mkl_INTFACE}_${BLAS_mkl_ILP_MODE} mkl_${BLAS_mkl_THREADING}_thread mkl_core ${BLAS_mkl_OMP}")
          endif ()
          if (BLA_VENDOR MATCHES "^Intel10_64i?lp_seq$" OR BLA_VENDOR STREQUAL "All")
            list(APPEND BLAS_SEARCH_LIBS
              "mkl_blas95_${BLAS_mkl_ILP_MODE} mkl_${BLAS_mkl_INTFACE}_${BLAS_mkl_ILP_MODE} mkl_sequential mkl_core")
          endif ()
        endif ()
      else ()
        set(BLAS_mkl_SEARCH_SYMBOL sgemm)
        set(_LIBRARIES BLAS_LIBRARIES)
        if (WIN32)
          # Find the main file (32-bit or 64-bit)
          set(BLAS_SEARCH_LIBS_WIN_MAIN "")
          if (BLA_VENDOR STREQUAL "Intel10_32" OR BLA_VENDOR STREQUAL "All")
            list(APPEND BLAS_SEARCH_LIBS_WIN_MAIN
              "mkl_intel_c${BLAS_mkl_DLL_SUFFIX}")
          endif()
          if (BLA_VENDOR MATCHES "^Intel10_64i?lp" OR BLA_VENDOR STREQUAL "All")
            list(APPEND BLAS_SEARCH_LIBS_WIN_MAIN
              "mkl_intel_${BLAS_mkl_ILP_MODE}${BLAS_mkl_DLL_SUFFIX}")
          endif ()

          # Add threading/sequential libs
          set(BLAS_SEARCH_LIBS_WIN_THREAD "")
          if (NOT BLA_VENDOR MATCHES "_seq$" OR BLA_VENDOR STREQUAL "All")
            # old version
            list(APPEND BLAS_SEARCH_LIBS_WIN_THREAD
              "libguide40 mkl_intel_thread${BLAS_mkl_DLL_SUFFIX}")
            # mkl >= 10.3
            list(APPEND BLAS_SEARCH_LIBS_WIN_THREAD
              "libiomp5md mkl_intel_thread${BLAS_mkl_DLL_SUFFIX}")
          endif()
          if (BLA_VENDOR MATCHES "_seq$" OR BLA_VENDOR STREQUAL "All")
            list(APPEND BLAS_SEARCH_LIBS_WIN_THREAD
              "mkl_sequential${BLAS_mkl_DLL_SUFFIX}")
          endif()

          # Cartesian product of the above
          foreach (MAIN ${BLAS_SEARCH_LIBS_WIN_MAIN})
            foreach (THREAD ${BLAS_SEARCH_LIBS_WIN_THREAD})
              list(APPEND BLAS_SEARCH_LIBS
                "${MAIN} ${THREAD} mkl_core${BLAS_mkl_DLL_SUFFIX}")
            endforeach()
          endforeach()
        else ()
          if (BLA_VENDOR STREQUAL "Intel10_32" OR BLA_VENDOR STREQUAL "All")
            # old version
            list(APPEND BLAS_SEARCH_LIBS
              "mkl_${BLAS_mkl_INTFACE} mkl_${BLAS_mkl_THREADING}_thread mkl_core guide")

            # mkl >= 10.3
            list(APPEND BLAS_SEARCH_LIBS
              "mkl_${BLAS_mkl_INTFACE} mkl_${BLAS_mkl_THREADING}_thread mkl_core ${BLAS_mkl_OMP}")
          endif ()
          if (BLA_VENDOR MATCHES "^Intel10_64i?lp$" OR BLA_VENDOR STREQUAL "All")
            # old version
            list(APPEND BLAS_SEARCH_LIBS
              "mkl_${BLAS_mkl_INTFACE}_${BLAS_mkl_ILP_MODE} mkl_${BLAS_mkl_THREADING}_thread mkl_core guide")

            # mkl >= 10.3
            list(APPEND BLAS_SEARCH_LIBS
              "mkl_${BLAS_mkl_INTFACE}_${BLAS_mkl_ILP_MODE} mkl_${BLAS_mkl_THREADING}_thread mkl_core ${BLAS_mkl_OMP}")
          endif ()
          if (BLA_VENDOR MATCHES "^Intel10_64i?lp_seq$" OR BLA_VENDOR STREQUAL "All")
            list(APPEND BLAS_SEARCH_LIBS
              "mkl_${BLAS_mkl_INTFACE}_${BLAS_mkl_ILP_MODE} mkl_sequential mkl_core")
          endif ()

          #older vesions of intel mkl libs
          if (BLA_VENDOR STREQUAL "Intel" OR BLA_VENDOR STREQUAL "All")
            list(APPEND BLAS_SEARCH_LIBS
              "mkl")
            list(APPEND BLAS_SEARCH_LIBS
              "mkl_ia32")
            list(APPEND BLAS_SEARCH_LIBS
              "mkl_em64t")
          endif ()
        endif ()
      endif ()

      if (DEFINED ENV{MKLROOT})
        if (BLA_VENDOR STREQUAL "Intel10_32")
          set(_BLAS_MKLROOT_LIB_DIR "$ENV{MKLROOT}/lib/ia32")
        elseif (BLA_VENDOR MATCHES "^Intel10_64i?lp$" OR BLA_VENDOR MATCHES "^Intel10_64i?lp_seq$")
          set(_BLAS_MKLROOT_LIB_DIR "$ENV{MKLROOT}/lib/intel64")
        endif ()
      endif ()
      if (_BLAS_MKLROOT_LIB_DIR)
        if (WIN32)
          string(APPEND _BLAS_MKLROOT_LIB_DIR "_win")
        elseif (APPLE)
          string(APPEND _BLAS_MKLROOT_LIB_DIR "_mac")
        else ()
          string(APPEND _BLAS_MKLROOT_LIB_DIR "_lin")
        endif ()
      endif ()

      foreach (IT ${BLAS_SEARCH_LIBS})
        string(REPLACE " " ";" SEARCH_LIBS ${IT})
        if (NOT ${_LIBRARIES})
          check_fortran_libraries(
            ${_LIBRARIES}
            BLAS
            ${BLAS_mkl_SEARCH_SYMBOL}
            ""
            "${SEARCH_LIBS}"
            "${CMAKE_THREAD_LIBS_INIT};${BLAS_mkl_LM};${BLAS_mkl_LDL}"
            "${_BLAS_MKLROOT_LIB_DIR}"
            )
        endif ()
      endforeach ()

    endif ()
    unset(BLAS_mkl_ILP_MODE)
    unset(BLAS_mkl_INTFACE)
    unset(BLAS_mkl_THREADING)
    unset(BLAS_mkl_OMP)
    unset(BLAS_mkl_DLL_SUFFIX)
    unset(BLAS_mkl_LM)
    unset(BLAS_mkl_LDL)
  endif ()
endif ()

if(BLA_F95)
  find_package_handle_standard_args(BLAS REQUIRED_VARS BLAS95_LIBRARIES)
  set(BLAS95_FOUND ${BLAS_FOUND})
  if(BLAS_FOUND)
    set(BLAS_LIBRARIES "${BLAS95_LIBRARIES}")
  endif()
endif()

if (BLA_VENDOR STREQUAL "Goto" OR BLA_VENDOR STREQUAL "All")
  if(NOT BLAS_LIBRARIES)
    # gotoblas (http://www.tacc.utexas.edu/tacc-projects/gotoblas2)
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      sgemm
      ""
      "goto2"
      ""
      )
  endif()
endif ()

if (BLA_VENDOR STREQUAL "OpenBLAS" OR BLA_VENDOR STREQUAL "All")
  if(NOT BLAS_LIBRARIES)
    # OpenBLAS (http://www.openblas.net)
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      sgemm
      ""
      "openblas"
      ""
      )
  endif()
  if(NOT BLAS_LIBRARIES)
    find_package(Threads)
    # OpenBLAS (http://www.openblas.net)
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      sgemm
      ""
      "openblas"
      "${CMAKE_THREAD_LIBS_INIT}"
      )
  endif()
endif ()

if (BLA_VENDOR STREQUAL "FLAME" OR BLA_VENDOR STREQUAL "All")
  if(NOT BLAS_LIBRARIES)
    # FLAME's blis library (https://github.com/flame/blis)
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      sgemm
      ""
      "blis"
      ""
      )
  endif()
endif ()

if (BLA_VENDOR STREQUAL "ATLAS" OR BLA_VENDOR STREQUAL "All")
  if(NOT BLAS_LIBRARIES)
    # BLAS in ATLAS library? (http://math-atlas.sourceforge.net/)
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      dgemm
      ""
      "f77blas;atlas"
      ""
      )
  endif()
endif ()

# BLAS in PhiPACK libraries? (requires generic BLAS lib, too)
if (BLA_VENDOR STREQUAL "PhiPACK" OR BLA_VENDOR STREQUAL "All")
  if(NOT BLAS_LIBRARIES)
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      sgemm
      ""
      "sgemm;dgemm;blas"
      ""
      )
  endif()
endif ()

# BLAS in Alpha CXML library?
if (BLA_VENDOR STREQUAL "CXML" OR BLA_VENDOR STREQUAL "All")
  if(NOT BLAS_LIBRARIES)
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      sgemm
      ""
      "cxml"
      ""
      )
  endif()
endif ()

# BLAS in Alpha DXML library? (now called CXML, see above)
if (BLA_VENDOR STREQUAL "DXML" OR BLA_VENDOR STREQUAL "All")
  if(NOT BLAS_LIBRARIES)
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      sgemm
      ""
      "dxml"
      ""
      )
  endif()
endif ()

# BLAS in Sun Performance library?
if (BLA_VENDOR STREQUAL "SunPerf" OR BLA_VENDOR STREQUAL "All")
  if(NOT BLAS_LIBRARIES)
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      sgemm
      "-xlic_lib=sunperf"
      "sunperf;sunmath"
      ""
      )
    if(BLAS_LIBRARIES)
      set(BLAS_LINKER_FLAGS "-xlic_lib=sunperf")
    endif()
  endif()
endif ()

# BLAS in SCSL library?  (SGI/Cray Scientific Library)
if (BLA_VENDOR STREQUAL "SCSL" OR BLA_VENDOR STREQUAL "All")
  if(NOT BLAS_LIBRARIES)
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      sgemm
      ""
      "scsl"
      ""
      )
  endif()
endif ()

# BLAS in SGIMATH library?
if (BLA_VENDOR STREQUAL "SGIMATH" OR BLA_VENDOR STREQUAL "All")
  if(NOT BLAS_LIBRARIES)
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      sgemm
      ""
      "complib.sgimath"
      ""
      )
  endif()
endif ()

# BLAS in IBM ESSL library? (requires generic BLAS lib, too)
if (BLA_VENDOR STREQUAL "IBMESSL" OR BLA_VENDOR STREQUAL "All")
  if(NOT BLAS_LIBRARIES)
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      sgemm
      ""
      "essl;blas"
      ""
      )
  endif()
endif ()

#BLAS in acml library?
if (BLA_VENDOR MATCHES "ACML" OR BLA_VENDOR STREQUAL "All")
  if( ((BLA_VENDOR STREQUAL "ACML") AND (NOT BLAS_ACML_LIB_DIRS)) OR
    ((BLA_VENDOR STREQUAL "ACML_MP") AND (NOT BLAS_ACML_MP_LIB_DIRS)) OR
    ((BLA_VENDOR STREQUAL "ACML_GPU") AND (NOT BLAS_ACML_GPU_LIB_DIRS))
    )
  # try to find acml in "standard" paths
  if( WIN32 )
    file( GLOB _ACML_ROOT "C:/AMD/acml*/ACML-EULA.txt" )
  else()
    file( GLOB _ACML_ROOT "/opt/acml*/ACML-EULA.txt" )
  endif()
  if( WIN32 )
    file( GLOB _ACML_GPU_ROOT "C:/AMD/acml*/GPGPUexamples" )
  else()
    file( GLOB _ACML_GPU_ROOT "/opt/acml*/GPGPUexamples" )
  endif()
  list(GET _ACML_ROOT 0 _ACML_ROOT)
  list(GET _ACML_GPU_ROOT 0 _ACML_GPU_ROOT)
  if( _ACML_ROOT )
    get_filename_component( _ACML_ROOT ${_ACML_ROOT} PATH )
    if( SIZEOF_INTEGER EQUAL 8 )
      set( _ACML_PATH_SUFFIX "_int64" )
    else()
      set( _ACML_PATH_SUFFIX "" )
    endif()
    if( CMAKE_Fortran_COMPILER_ID STREQUAL "Intel" )
      set( _ACML_COMPILER32 "ifort32" )
      set( _ACML_COMPILER64 "ifort64" )
    elseif( CMAKE_Fortran_COMPILER_ID STREQUAL "SunPro" )
      set( _ACML_COMPILER32 "sun32" )
      set( _ACML_COMPILER64 "sun64" )
    elseif( CMAKE_Fortran_COMPILER_ID STREQUAL "PGI" )
      set( _ACML_COMPILER32 "pgi32" )
      if( WIN32 )
        set( _ACML_COMPILER64 "win64" )
      else()
        set( _ACML_COMPILER64 "pgi64" )
      endif()
    elseif( CMAKE_Fortran_COMPILER_ID STREQUAL "Open64" )
      # 32 bit builds not supported on Open64 but for code simplicity
      # We'll just use the same directory twice
      set( _ACML_COMPILER32 "open64_64" )
      set( _ACML_COMPILER64 "open64_64" )
    elseif( CMAKE_Fortran_COMPILER_ID STREQUAL "NAG" )
      set( _ACML_COMPILER32 "nag32" )
      set( _ACML_COMPILER64 "nag64" )
    else()
      set( _ACML_COMPILER32 "gfortran32" )
      set( _ACML_COMPILER64 "gfortran64" )
    endif()

    if( BLA_VENDOR STREQUAL "ACML_MP" )
      set(_ACML_MP_LIB_DIRS
        "${_ACML_ROOT}/${_ACML_COMPILER32}_mp${_ACML_PATH_SUFFIX}/lib"
        "${_ACML_ROOT}/${_ACML_COMPILER64}_mp${_ACML_PATH_SUFFIX}/lib" )
    else()
      set(_ACML_LIB_DIRS
        "${_ACML_ROOT}/${_ACML_COMPILER32}${_ACML_PATH_SUFFIX}/lib"
        "${_ACML_ROOT}/${_ACML_COMPILER64}${_ACML_PATH_SUFFIX}/lib" )
    endif()
  endif()
elseif(BLAS_${BLA_VENDOR}_LIB_DIRS)
  set(_${BLA_VENDOR}_LIB_DIRS ${BLAS_${BLA_VENDOR}_LIB_DIRS})
endif()

if( BLA_VENDOR STREQUAL "ACML_MP" )
  foreach( BLAS_ACML_MP_LIB_DIRS ${_ACML_MP_LIB_DIRS})
    check_fortran_libraries (
      BLAS_LIBRARIES
      BLAS
      sgemm
      "" "acml_mp;acml_mv" "" ${BLAS_ACML_MP_LIB_DIRS}
      )
    if( BLAS_LIBRARIES )
      break()
    endif()
  endforeach()
elseif( BLA_VENDOR STREQUAL "ACML_GPU" )
  foreach( BLAS_ACML_GPU_LIB_DIRS ${_ACML_GPU_LIB_DIRS})
    check_fortran_libraries (
      BLAS_LIBRARIES
      BLAS
      sgemm
      "" "acml;acml_mv;CALBLAS" "" ${BLAS_ACML_GPU_LIB_DIRS}
      )
    if( BLAS_LIBRARIES )
      break()
    endif()
  endforeach()
else()
  foreach( BLAS_ACML_LIB_DIRS ${_ACML_LIB_DIRS} )
    check_fortran_libraries (
      BLAS_LIBRARIES
      BLAS
      sgemm
      "" "acml;acml_mv" "" ${BLAS_ACML_LIB_DIRS}
      )
    if( BLAS_LIBRARIES )
      break()
    endif()
  endforeach()
endif()

# Either acml or acml_mp should be in LD_LIBRARY_PATH but not both
if(NOT BLAS_LIBRARIES)
  check_fortran_libraries(
    BLAS_LIBRARIES
    BLAS
    sgemm
    ""
    "acml;acml_mv"
    ""
    )
endif()
if(NOT BLAS_LIBRARIES)
  check_fortran_libraries(
    BLAS_LIBRARIES
    BLAS
    sgemm
    ""
    "acml_mp;acml_mv"
    ""
    )
endif()
if(NOT BLAS_LIBRARIES)
  check_fortran_libraries(
    BLAS_LIBRARIES
    BLAS
    sgemm
    ""
    "acml;acml_mv;CALBLAS"
    ""
    )
endif()
endif () # ACML

# Apple BLAS library?
if (BLA_VENDOR STREQUAL "Apple" OR BLA_VENDOR STREQUAL "All")
  if(NOT BLAS_LIBRARIES)
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      dgemm
      ""
      "Accelerate"
      ""
      )
  endif()
endif ()

if (BLA_VENDOR STREQUAL "NAS" OR BLA_VENDOR STREQUAL "All")
  if ( NOT BLAS_LIBRARIES )
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      dgemm
      ""
      "vecLib"
      ""
      )
  endif ()
endif ()

# Generic BLAS library?
if (BLA_VENDOR STREQUAL "Generic" OR BLA_VENDOR STREQUAL "All")
  if(NOT BLAS_LIBRARIES)
    check_fortran_libraries(
      BLAS_LIBRARIES
      BLAS
      sgemm
      ""
      "blas"
      ""
      )
  endif()
endif ()

if(NOT BLA_F95)
  find_package_handle_standard_args(BLAS REQUIRED_VARS BLAS_LIBRARIES)
endif()

# On compilers that implicitly link BLAS (such as ftn, cc, and CC on Cray HPC machines)
# we used a placeholder for empty BLAS_LIBRARIES to get through our logic above.
if (BLAS_LIBRARIES STREQUAL "BLAS_LIBRARIES-PLACEHOLDER-FOR-EMPTY-LIBRARIES")
  set(BLAS_LIBRARIES "")
endif()

cmake_pop_check_state()
set(CMAKE_FIND_LIBRARY_SUFFIXES ${_blas_ORIG_CMAKE_FIND_LIBRARY_SUFFIXES})


text:
package com.speedment.common.codegen.model.modifier;

import com.speedment.common.codegen.model.modifier.Keyword.Static;
import com.speedment.common.codegen.model.modifier.Keyword.Default;

/**
 *
 * @author Emil Forslund
 * @param <T> The extending type
 * @since  2.0
 */
public interface InterfaceMethodModifier<T extends InterfaceMethodModifier<T>>
extends Static<T>, Default<T> {}


text:
#region Usings

using System;
using System.Linq;
using Xunit;

#endregion

namespace Extend.Testing
{
    public partial class TypeExTest
    {
        [Fact]
        public void GetAttributeDefinitionsNullTest()
        {
            Type t = null;
            // ReSharper disable once AssignNullToNotNullAttribute
            // ReSharper disable once ReturnValueOfPureMethodIsNotUsed
            Action test = () => t.GetAttributeDefinitions<MyDisplayAttribute>();

            Assert.Throws<ArgumentNullException>( test );
        }

        [Fact]
        public void GetAttributeDefinitionsTest()
        {
            var actual = typeof(TestPerson).GetAttributeDefinitions<MyDisplayAttribute>()
                                           .ToList();
            Assert.Equal( 2, actual.Count );

            var actualItem = actual.Single( x => x.Property.Name == "FirstName" );
            Assert.Single( actualItem.Attributes );
            Assert.Equal( "FirstName-DisplayName",
                          actualItem.Attributes.Single()
                                    .Name );

            actualItem = actual.Single( x => x.Property.Name == "LastName" );
            Assert.Single( actualItem.Attributes );
            Assert.Equal( "LastName-DisplayName",
                          actualItem.Attributes.Single()
                                    .Name );
        }

        [Fact]
        public void GetAttributeDefinitionsTest1()
        {
            var actual = typeof(TestPerson).GetAttributeDefinitions<MyTestAttribute>()
                                           .ToList();
            Assert.Single( actual );

            var actualItem = actual.Single( x => x.Property.Name == "DateOfBirth" );
            Assert.Equal( 2, actualItem.Attributes.Count() );
            Assert.Equal( 1, actualItem.Attributes.Count( x => x.Value == "1" ) );
            Assert.Equal( 1, actualItem.Attributes.Count( x => x.Value == "2" ) );
        }

        [Fact]
        public void GetAttributeDefinitionsTest2()
        {
            var actual = typeof(TestPersonInherit).GetAttributeDefinitions<MyTestAttribute>()
                                                  .ToList();
            Assert.Equal( 2, actual.Count );

            var actualItem = actual.Single( x => x.Property.Name == "DateOfBirth" );
            Assert.Equal( 2, actualItem.Attributes.Count() );
            Assert.Equal( 1, actualItem.Attributes.Count( x => x.Value == "1" ) );
            Assert.Equal( 1, actualItem.Attributes.Count( x => x.Value == "2" ) );

            actualItem = actual.Single( x => x.Property.Name == "Weight" );
            Assert.Single( actualItem.Attributes );
            Assert.Equal( "10000",
                          actualItem.Attributes.Single()
                                    .Value );
        }

        #region Nested Types

        [AttributeUsage( AttributeTargets.Property, AllowMultiple = true )]
        private class MyDisplayAttribute : Attribute
        {
            #region Properties

            public String Name { get; set; }

            #endregion
        }

        [AttributeUsage( AttributeTargets.Property, AllowMultiple = true )]
        private class MyTestAttribute : Attribute
        {
            #region Properties

            public String Value { get; set; }

            #endregion
        }

        private class TestPerson
        {
            #region Properties

            [MyDisplay( Name = "FirstName-DisplayName" )]
            // ReSharper disable once UnusedMember.Local
            public String FirstName { get; set; } = "Name";

            [MyDisplay( Name = "LastName-DisplayName" )]
            // ReSharper disable once UnusedMember.Local
            public String LastName { get; set; } = "LastName";

            [MyTest( Value = "1" )]
            [MyTest( Value = "2" )]
            // ReSharper disable once UnusedMember.Local
            public DateTime DateOfBirth { get; set; } = DateTime.Now;

            #endregion
        }

        private class TestPersonInherit : TestPerson
        {
            #region Properties

            [MyTest( Value = "10000" )]
            // ReSharper disable once UnusedMember.Local
            public Double Weight { get; set; } = 100;

            #endregion
        }

        #endregion
    }
}


text:
package com.digirati.elucidate.common.infrastructure.exception;

@SuppressWarnings("serial")
public class InvalidIRIException extends RuntimeException {

    public InvalidIRIException(String message, Throwable cause) {
        super(message, cause);
    }
}


text:
#ifndef MSONENOTEAPISECTIONGROUPCOLLECTIONOPERATIONS_H
#define MSONENOTEAPISECTIONGROUPCOLLECTIONOPERATIONS_H

#import "MSOneNoteApiModels.h"
#import "api/api.h"
#import "core/core.h"
#import "core/MSOrcOperations.h"

/** MSOneNoteApiSectionGroupCollectionOperations
 *
 */
@interface MSOneNoteApiSectionGroupCollectionOperations : MSOrcOperations

@end

#endif


text:
tandem
=====

Tandem provides supporting material for simulations using phetioEngine.js.  This library is licensed
so that it can be used in published simulations (as opposed to phetioEngine.js which is licensed separately).

By PhET Interactive Simulations
https://phet.colorado.edu/

### Documentation
The [PhET Development Overview](https://github.com/phetsims/phet-info/blob/master/doc/phet-development-overview.md) is the most complete guide to PhET Simulation Development. This guide includes how
to obtain simulation code and its dependencies, notes about architecture & design, how to test and build the sims, as well as other important information.

### License
See the [license](LICENSE)


text:
package org.apache.axis2.jaxws.server.dispatcher;

import org.apache.axis2.description.AxisOperation;
import org.apache.axis2.jaxws.Constants;
import org.apache.axis2.jaxws.WebServiceExceptionLogger;
import org.apache.axis2.jaxws.ExceptionFactory;
import org.apache.axis2.jaxws.core.MessageContext;
import org.apache.axis2.jaxws.server.EndpointCallback;
import org.apache.axis2.jaxws.server.EndpointInvocationContext;
import org.apache.axis2.jaxws.server.InvocationHelper;
import org.apache.axis2.jaxws.server.InvocationListener;
import org.apache.axis2.jaxws.server.InvocationListenerBean;
import org.apache.axis2.jaxws.utility.ClassUtils;
import org.apache.axis2.jaxws.utility.JavaUtils;
import org.apache.axis2.transport.TransportUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.util.List;
import java.util.concurrent.Callable;
/**
 * JavaDispatcher is an abstract class that can be extended to implement an EndpointDispatcher to a
 * Java object.
 */
public abstract class JavaDispatcher implements EndpointDispatcher {

    private static final Log log = LogFactory.getLog(JavaDispatcher.class);

    protected Class serviceImplClass;
    protected Object serviceInstance;

    protected JavaDispatcher(Class impl, Object serviceInstance) {
        this.serviceImplClass = impl;
        this.serviceInstance = serviceInstance;
    }

    public abstract MessageContext invoke(MessageContext request) throws Exception;

    public abstract void invokeOneWay(MessageContext request);

    public abstract void invokeAsync(MessageContext request, EndpointCallback callback);

    protected abstract MessageContext createResponse(MessageContext request, Object[] input, Object output);

    protected abstract MessageContext createFaultResponse(MessageContext request, Throwable fault);

    public Class getServiceImplementationClass() {
        return serviceImplClass;
    }

    protected Object invokeTargetOperation(Method method, Object[] args) throws Throwable {
        Object output = null;
        try {
            output = method.invoke(serviceInstance, args);
        } catch (Throwable t) {

            // Delegate logging the exception to the WebServiceExceptionLogger.
            // Users can specifiy debug tracing of the WebServiceExceptionLogger to see
            // all exceptions.
            // Otherwise the WebServiceExceptionLogger only logs errors for non-checked exceptions
            WebServiceExceptionLogger.log(method,
                                          t,
                                          false,
                                          serviceImplClass,
                                          serviceInstance,
                                          args);

            throw t;
        }

        return output;
    }

    protected class AsyncInvocationWorker implements Callable {

        private Method method;
        private Object[] params;
        private ClassLoader classLoader;
        private EndpointInvocationContext eic;

        public AsyncInvocationWorker(Method m, Object[] p, ClassLoader cl, EndpointInvocationContext ctx) {
            method = m;
            params = p;
            classLoader = cl;
            eic = ctx;
        }

        public Object call() throws Exception {
            try {
                if (log.isDebugEnabled()) {
                    log.debug("Invoking target endpoint via the async worker.");
                }

                // Set the proper class loader so that we can properly marshall the
                // outbound response.
                ClassLoader currentLoader = Thread.currentThread().getContextClassLoader();
                if (classLoader != null && (classLoader != currentLoader)) {
                    Thread.currentThread().setContextClassLoader(classLoader);
                    if (log.isDebugEnabled()) {
                        log.debug("Context ClassLoader set to:" + classLoader);
                    }
                }

                // We have the method that is going to be invoked and the parameter data to invoke it
                // with, so just invoke the operation.
                Object output = null;
                boolean faultThrown = false;
                Throwable fault = null;
                try {
                    output = invokeTargetOperation(method, params);
                }
                catch (Exception e) {
                    fault = ClassUtils.getRootCause(e);
                    Throwable newFault = InvocationHelper.determineMappedException(fault, eic);
                    if(newFault != null) {
                        fault = newFault;
                    }
                    faultThrown = true;
                }

                // If this is a one way invocation, we are done and just need to return.
                if (eic.isOneWay()) {
                    if (log.isDebugEnabled()) {
                        log.debug("Invocation pattern was one way, work complete.");
                    }

                    responseReady(eic);
                    return null;
                }

                // Create the response MessageContext
                MessageContext request = eic.getRequestMessageContext();
                MessageContext response = null;
                if (faultThrown) {
                    // If a fault was thrown, we need to create a slightly different
                    // MessageContext, than in the response path.
                    response = createFaultResponse(request, fault);
                    setExceptionProperties(response, method, fault);
                } else {
                    if (log.isDebugEnabled()) {
                        log.debug("Async invocation of the endpoint was successful.  Creating response message.");
                    }
                    response = createResponse(request, params, output);
                }

                EndpointInvocationContext eic = null;
                if (request.getInvocationContext() != null) {
                    eic = (EndpointInvocationContext) request.getInvocationContext();
                    eic.setResponseMessageContext(response);
                }

                EndpointCallback callback = eic.getCallback();
                boolean handleFault = response.getMessage().isFault();
                if (!handleFault) {
                    if (log.isDebugEnabled()) {
                        log.debug("No fault detected in response message, sending back application response.");
                    }
                    callback.handleResponse(eic);
                }
                else {
                    if (log.isDebugEnabled()) {
                        log.debug("A fault was detected.  Sending back a fault response.");
                    }
                    callback.handleFaultResponse(eic);
                }

                // Set the thread's ClassLoader back to what it originally was.
                Thread.currentThread().setContextClassLoader(currentLoader);

                // Clean up the cached attachments from the request and the response.
                TransportUtils.deleteAttachments(eic.getRequestMessageContext().getAxisMessageContext());
                TransportUtils.deleteAttachments(eic.getResponseMessageContext().getAxisMessageContext());
            } catch (Throwable e) {
                // Exceptions are swallowed, there is no reason to rethrow them
                if (log.isDebugEnabled()) {
                    log.debug("AN UNEXPECTED ERROR OCCURRED IN THE ASYNC WORKER THREAD");
                    log.debug("Exception is:" + e, e);
                }
            }

            return null;
        }
    }

    /**
     * This will call the InvocationListener instances that were called during
     * the request processing for this message.
     */
    protected void responseReady(EndpointInvocationContext eic)  {
        List<InvocationListener> listenerList = eic.getInvocationListeners();
        if(listenerList != null) {
            InvocationListenerBean bean = new InvocationListenerBean(eic, InvocationListenerBean.State.RESPONSE);
            for(InvocationListener listener : listenerList) {
                try {
                    listener.notify(bean);
                }
                catch(Exception e) {
                    throw ExceptionFactory.makeWebServiceException(e);
                }
            }
        }
    }

    protected static void setFaultResponseAction(Throwable exception,
                                                 MessageContext request,
                                                 MessageContext response) {
         AxisOperation operation = request.getOperationDescription().getAxisOperation();
         if (operation != null) {
             exception = ClassUtils.getRootCause(exception);
             String action = operation.getFaultAction(exception.getClass().getName());

             if (action != null)
                 response.getAxisMessageContext().setWSAAction(action);
         }
    }

    /**
     * Determine if the thrown exception is a checked exception.
     * If so, then set the name of the checked exception on the response context
     * @param response MessageContext
     * @param m Method
     * @param t Throwable
     */
    protected static void setCheckedExceptionProperty(MessageContext response, Method m, Throwable t) {
        // Get the root of the exception
        if (t instanceof InvocationTargetException) {
            t = ((InvocationTargetException) t).getTargetException();
        }

        // Determine if the thrown exception is checked
        Class checkedException = JavaUtils.getCheckedException(t, m);

        // Add the property
        if (checkedException != null) {
            response.setProperty(Constants.CHECKED_EXCEPTION, checkedException.getCanonicalName());
        }
    }

    /**
     * Store the actual exception on the response context
     * @param response MessageContext
     * @param t Throwable
     */
    protected static void setWebMethodExceptionProperty(MessageContext response,
                                                        Throwable t) {
        // Get the root of the exception
        if (t instanceof InvocationTargetException) {
            t = ((InvocationTargetException) t).getTargetException();
        }

        // Add the property
        if (t != null) {
            response.setProperty(Constants.JAXWS_WEBMETHOD_EXCEPTION, t);
        }
    }

    /**
     * Information about the exception is stored on the outbound response context
     * @param response MessageContext
     * @param m Method
     * @param t Throwable
     */
    protected static void setExceptionProperties(MessageContext response,
                                                 Method m,
                                                 Throwable t) {
        setCheckedExceptionProperty(response, m, t);
        setWebMethodExceptionProperty(response, t);
    }

}


text:
var lineCounter;
var startIndex;
var endIndex;
var summaries;

var startBound = $('
').addClass('bound start-bound').text('start');
var endBound = $('
').addClass('bound end-bound').text('end');

var parseText = function(input, output) {
  input = JSON.parse(input)["裁判全文"];
  lineCounter = 0;
  output.html('');
  summaries = [];
  $('#json-box').show();
  $(output).bind('mouseup', function() {
    //console.log(new Date());
    var selection;
    if (window.getSelection) {
      selection = window.getSelection();
    } else if (document.selection) {
      selection = document.selection.createRange();
    }
    if (selection.toString() !== '') {
      startBound.detach();
      endBound.detach();
      var elements = [
        $(selection.anchorNode.parentElement.parentElement.parentElement),
        $(selection.extentNode.parentElement.parentElement.parentElement),
      ];
      elements.sort(function(a, b) { return b.attr('data-line-number')-a.attr('data-line-number')});
      var startEl = elements.pop();
      var endEl = elements.pop();
      startEl.before(startBound);
      endEl.after(endBound);

      startIndex = parseInt(startEl.attr('data-line-number'));
      endIndex = parseInt(endEl.attr('data-line-number'));
      console.log('Line Start: ' + startIndex);
      console.log('Line End: ' + endIndex);
      window.hl = $('.line').slice(startIndex, endIndex+1);
      $('.selected-line').removeClass('selected-line');
      $(window.hl).addClass('selected-line');
      //$(selection.anchorNode.parentElement.parentElement.parentElement).before(startBound);
      //$(selection.focusNode.parentElement.parentElement.parentElement).after(endBound);
      //selection.empty();
      window.selection = selection;
      $('#submit-form').show();
    }
  });
  $('#submit').click(function() {
    var title = $('#title').val();
    var summary = $('#summary').val();
    if (title.length > 0 && summary.length > 0) {
      summaries.push({
        "line_start": startIndex,
        "line_end": endIndex,
        "title": title,
        "summary": summary
      });
    } else {
    }
    if (summaries.length > 0) {
      console.log(JSON.stringify(summaries));
      $('#json-text').val(JSON.stringify(summaries));
      importHighlight(summaries);
    }
    startBound.detach();
    endBound.detach();
  });
  $('#import-json').click(function() {
    var json = $('#json-text').val();
    if (json.length > 0) {
      summaries = JSON.parse(json);
      importHighlight(summaries);
    }
    startBound.detach();
    endBound.detach();
  });
  window.input = input;
  var lines = input.split(/\n/);
  window.lines = lines;
  var ch_num = ['一', '二', '三', '四', '五', '六', '七', '八', '九', '十'];
  var h1i = 0;
  var h2i;
  $.each(lines, function(i, line) {
    var h1pattern = '^' + ch_num[h1i] + '、.*';
    var h2pattern = '[((]' + ch_num[h2i] + '[))].*';
    if (line.match(/^\s+主\s*文\s*$/)) {
      renderLine(output, 'header-main', line);
    } else if (line.match(h1pattern)) {
      renderLine(output, 'header1', line);
      h1i++;
      h2i = 0;
    } else if (line.match(h2pattern)) {
      renderLine(output, 'header2', line);
      h2i++;
    } else if (line.match(/^\s{4}[^\s].*/)) {
      //renderLine(output, 'content-s4', line);
      renderLine(output, '', line);
    } else if (line.match(/^\s{6}[^\s].*/)) {
      //renderLine(output, 'content-s6', line);
      renderLine(output, '', line);
    } else {
      renderLine(output, '', line);
    }
  });
  $('.line-number').css('width', lineCounter.toString().length * 10 + 'px');
}

var renderLine = function(output, type, line) {
  var div = $('

').addClass('line').attr('data-line-number', lineCounter);
  var label = $('');
  //var cb = $('<input/>').attr('type', 'checkbox').addClass('cb');
  var number = $('').addClass('line-number').text(lineCounter);
  var text = $('').addClass('content ' + type).text(line);
  //label.append(cb);
  label.append(number);
  label.append(text);
  div.append(label);
  output.append(div);
  lineCounter++;
}
var importHighlight = function(json_array) {
  $('.line').removeClass('marked');
  $('.marked-split').remove();
  $('.summary-box').remove();
  $.each(json_array, function(i, json) {
    var lines = $('.line').slice(json.line_start, json.line_end + 1).addClass('marked');
    var summaryBox = $('

').addClass('summary-box');
    //var title = $('

').addClass('box-title').text('標題:' + json.title);
    //var summary = $('

').addClass('box-summary').text('摘要:' + json.summary);
    var summary = $('

').addClass('box-summary').html('標題:' + json.title + '
' + '摘要:' + json.summary);
    //summaryBox.append(title);
    summaryBox.append(summary);
    lines.last().after(summaryBox);
    lines.last().after($('

').addClass('marked-split'));
  });
}


text:
var infowindow = new google.maps.InfoWindow;
  var mapCenter = new google.maps.LatLng(9.633931465220899, -84.25418434999995); //Google map Coordinates
  var map;
  var url;
  var url2;
  var files;
  var readmore;
  var avgLat;
  var avgLng;
  var publications = [];

    function onMarkerClick(marker,contentString){
      //var marker = this;

      infowindow.close();

      infowindow.setContent(contentString);

      infowindow.open(map, marker);
    }

    function map_initialize()
  {
      var googleMapOptions =
      {
        center: mapCenter, // map center
        zoom: 8, //zoom level, 0 = earth view to higher value
        maxZoom: 18,
        minZoom: 4,
        zoomControlOptions: {
        style: google.maps.ZoomControlStyle.SMALL //zoom control size
      },
        scaleControl: true, // enable scale control
        mapTypeId: google.maps.MapTypeId.ROADMAP // google map type
      };

        map = new google.maps.Map(document.getElementById("google_map"), googleMapOptions);

        var bounds = new google.maps.LatLngBounds();

      //Load Markers from the XML File, Check (map_process.php)

        for(var i = 0; i < publications.length; i++){
            create_marker(publications[i].point, publications[i].name, publications[i].address, false, false, false, url2+"/"+ publications[i].type +".png", publications[i].photo, publications[i].id, publications[i].observacion);
            bounds.extend(publications[i].point);
        }

        map.fitBounds(bounds);
  }

    function create_marker(MapPos, MapTitle, MapDesc,  InfoOpenDefault, DragAble, Removable, iconPath, imagen, id, observacion)
  {
    //new marker
    eval('var marker' + id + ' = new google.maps.Marker({ position: MapPos,  map: map, draggable:DragAble,animation: google.maps.Animation.DROP,title:MapTitle, icon: iconPath});');

    var texto= MapDesc.slice(0,180);

    var texto2= observacion.slice(0,50);
    //Content structure of info Window for the Markers
    var contentString = '
'+
    '
'+
    '
'+MapTitle+'

'+
    texto+
    '

'+
    texto2+
    '

leer Más
'+
    '

';

    google.maps.event.addListener(map, 'click', function() {
      infowindow.close();
    });
    var marker_obj = eval('marker' + id);
    google.maps.event.addListener(marker_obj, 'click', function(){
        onMarkerClick(this,contentString);
    });
    if(InfoOpenDefault) //whether info window should be open by default
    {
      infowindow.open(map,marker_obj);
    }
  }

  function get_publications(){
      var latArray = [];
      var lngArray = [];

      $.ajax({
  url: url,
  async: false,
  success: function(data) {
     $(data).find("marker").each(function () {
            var name    = $(this).attr('name');
            var address   = $(this).attr('address');
            var type    = $(this).attr('type');
            var photo    = $(this).attr('photo');
            var id    = $(this).attr('id');
            var observacion    = $(this).attr('observacion');
            var lat = parseFloat($(this).attr('lat'));
            latArray.push(lat);
            var lng = parseFloat($(this).attr('lng'));
            lngArray.push(lng);
            var point   = new google.maps.LatLng(lat,lng);
            publications.push({name: name, address: address,type:type,photo:photo,id:id,observacion:observacion,point:point});
        });
  }
  });
        latArray.sort(sortNumber);
        lngArray.sort(sortNumber);

        avgLat = latArray[0]+((latArray[latArray.length-1]-latArray[0])/2);
        avgLng = lngArray[0]+((lngArray[lngArray.length-1]-lngArray[0])/2);

        mapCenter = new google.maps.LatLng(avgLat, avgLng);

  }

  function sortNumber(a,b) {
    return a - b;
}

$(document).ready(function() {
    $("#send").click(function()
    {
         $('#msjerrror').hide();
      var markers = [];
    var googleMapOptions =
      {
        center: mapCenter, // map center
        zoom: 8, //zoom level, 0 = earth view to higher value
        maxZoom: 18,
        minZoom: 4,
        zoomControlOptions: {
        style: google.maps.ZoomControlStyle.SMALL //zoom control size
      },
        scaleControl: true, // enable scale control
        mapTypeId: google.maps.MapTypeId.ROADMAP // google map type
      };

        map = new google.maps.Map(document.getElementById("google_map"), googleMapOptions);
       function setAllMap(map) {
          for (var i = 0; i < markers.length; i++) {
            markers[i].setMap(map);
          }
        }
        function clearOverlays() {
          setAllMap(null);
        }
     clearOverlays();
        markers = [];
        var bounds = new google.maps.LatLngBounds();

      //Load Markers from the XML File, Check (map_process.php)

   var data = $('#formbuscar').serializeArray();
   var busquedaavance = $('#busquedaavance').val();
    if (busquedaavance == 1){
        var url = "../Inicio/busqueda";

        }
    else {var url = "index.php/Inicio/busqueda";

        }
    ;
       $.ajax({
        type: "post",
        url: url,
        cache: false,

        data:{
	                data:data
	            },
        success: function(data1){
        try{
             if(data1 == null){
                $('#msjerrror').show();
                $('#msjerrror').append('Con esa busqueda no hay ningun resultado, Intente con otra opcion');
            }
            $(data1).find("marker").each(function () {
            var name    = $(this).attr('name');
            var address   = $(this).attr('address');
            var type    = $(this).attr('type');
            var photo    = $(this).attr('photo');
            var id    = $(this).attr('id');
            var observacion    = $(this).attr('observacion');
            var point   = new google.maps.LatLng(parseFloat($(this).attr('lat')),parseFloat($(this).attr('lng')));
            create_marker(point, name, address, false, false, false, url2+"/"+ type +".png", photo, id, observacion);
            bounds.extend(point);
            map.fitBounds(bounds);
        });

        }catch(e) {
            alert('Exception while request..');
        }
        },
        error: function(){
            alert('Error while request..');
        }
        });

  });

    $("#mostrar").click(function(){
            $('#cmenu').show(500);
            $('#cmenu').show("slow");
            $('.form-search.content-description').css("margin-bottom","25px", 'slow');
     });

         $("#ocultar").click(function(){
            $('#cmenu').hide(500);
            $('#cmenu').hide("fast");
            $('.form-search.content-description').css("margin-bottom","20px", 'slow');
     });

     $(".send1").click(function()
    {

       $('#msjerrror').hide();
       $('#msjerrror').empty();
       var categoria = $(this).attr("id")
       $(".mainmenu-itemvertical").removeClass("active");
       $("#"+categoria).addClass("active");
       dataarray = [ {
    "name" : "tipo_categoria",
    "value" : categoria }];
      var markers = [];
    var googleMapOptions =
      {
        center: mapCenter, // map center
        zoom: 8, //zoom level, 0 = earth view to higher value
        maxZoom: 18,
        minZoom: 4,
        zoomControlOptions: {
        style: google.maps.ZoomControlStyle.SMALL //zoom control size
      },
        scaleControl: true, // enable scale control
        mapTypeId: google.maps.MapTypeId.ROADMAP // google map type
      };

        map = new google.maps.Map(document.getElementById("google_map"), googleMapOptions);
       function setAllMap(map) {
          for (var i = 0; i < markers.length; i++) {
            markers[i].setMap(map);
          }
        }

        function clearOverlays() {
          setAllMap(null);
        }
     clearOverlays();
        markers = [];

        var bounds = new google.maps.LatLngBounds();

      //Load Markers from the XML File, Check (map_process.php)

        for(var i = 0; i < publications.length; i++){
            if(publications[i].type == categoria){
            create_marker(publications[i].point, publications[i].name, publications[i].address, false, false, false, url2+"/"+ publications[i].type +".png", publications[i].photo, publications[i].id, publications[i].observacion);
            bounds.extend(publications[i].point);
        }
        }

        map.fitBounds(bounds);

   var data = dataarray;
       $.ajax({
        type: "post",
        url: "index.php/Inicio/busqueda",
        cache: false,

        data:{
	                data:data
	            },
        success: function(data1){
        try{
            if(data1 == null){
                $('#msjerrror').show();
                $('#msjerrror').append('Con esa busqueda no hay ningun resultado, Intente con otra opcion');
            }
            $(data1).find("marker").each(function () {
            var name    = $(this).attr('name');
            var address   = $(this).attr('address');
            var type    = $(this).attr('type');
            var photo    = $(this).attr('photo');
            var id    = $(this).attr('id');
            var observacion    = $(this).attr('observacion');
            var point   = new google.maps.LatLng(parseFloat($(this).attr('lat')),parseFloat($(this).attr('lng')));
            create_marker(point, name, address, false, false, false, url2+"/"+ type +".png", photo, id, observacion);
        });

        }catch(e) {
            alert('Exception while request..');
        }
        },
        error: function(){
            alert('Error while request..');
        }
        });

  });

    $('#msjerrror').hide();
    $(".nav-content-left ul li").mouseover(function(e) {$(this).addClass(" iehover ");});
    $(".nav-content-left ul li").mouseout(function(e) {$(this).removeClass(" iehover ");});
   var dondeestoy = $('#dondeestoy').val();
    if(dondeestoy == 'Inicio'){
        url = 'index.php/Inicio/mapa';
        url2 = 'icons';
        files = "files";
        readmore = "index.php/Publicadas";
    }
    else{
        url = '../Inicio/mapa';
        url2 = '../../icons';
        files = "../../files";
        readmore = "../../index.php/Publicadas";
    }
    $( ".gm-style-iw" ).css('width','404px');
    $('#cmenu').hide();

  get_publications();

  map_initialize(); // initialize google map

  //############### Google Map Initialize ##############
});


text:
    No available parameters to follow. Please add one first.

   0">
    <schema-based-editor schema="$ctrl.SCHEMA" local-value="$ctrl.localValue">
    </schema-based-editor>


text:
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
    var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
    if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
    else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
    return c > 3 && r && Object.defineProperty(target, key, r), r;
};
var __metadata = (this && this.__metadata) || function (k, v) {
    if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
};
import { Component } from '@angular/core';
import { NavController, NavParams, AlertController, LoadingController } from 'ionic-angular';
import { FormBuilder, Validators } from '@angular/forms';
import { AngularFire } from 'angularfire2';
import { AuthService } from '../../providers/auth.service';
import { EnquirySentPage } from '../enquiry-sent/enquiry-sent';
import { Storage } from '@ionic/storage';
import firebase from 'firebase';
/*
  Generated class for the SendEnquiry page.

  See http://ionicframework.com/docs/v2/components/#navigation for more info on
  Ionic pages and navigation.
*/
var SendEnquiryPage = (function () {
    function SendEnquiryPage(navCtrl, navParams, formBuilder, af, alertCtrl, loadingCtrl, authService, storage) {
        var _this = this;
        this.navCtrl = navCtrl;
        this.navParams = navParams;
        this.formBuilder = formBuilder;
        this.af = af;
        this.alertCtrl = alertCtrl;
        this.loadingCtrl = loadingCtrl;
        this.authService = authService;
        this.storage = storage;
        storage.ready().then(function () {
            storage.get('currentuser').then(function (val) {
                _this.currentuser = JSON.parse(val);
                _this.product = navParams.get("product");
                _this.sellerID = _this.product.uid;
                //console.log(this.currentuser);
                //this.currentuser = firebase.auth().currentUser;
                _this.userEnquiries = af.database.list('/users/' + _this.currentuser.uid + '/enquiries');
                _this.sellerEnquiries = af.database.list('/users/' + _this.sellerID + '/enquiries');
                if (_this.product.mrate) {
                    _this.productmrate = _this.product.mrate;
                }
                else {
                    _this.productmrate = null;
                }
                if (_this.product.krate) {
                    _this.productkrate = _this.product.krate;
                }
                else {
                    _this.productkrate = null;
                }
                _this.productunit = "Kg";
                _this.authService.getFullProfile(_this.sellerID).first()
                    .subscribe(function (user) {
                    //loading.dismiss();
                    // this.user.displayName = user.displayName;
                    //this.user.email = user.email || user.providerData[0].email || 'Not set yet.';
                    //this.user.photoURL = user.photoURL || this.user.photoURL;
                    _this.seller = user;
                    //console.log(this.seller);
                }, function (error) {
                    //loading.dismiss();
                    console.log('Error: ' + JSON.stringify(error));
                });
                _this.authService.getFullProfile(_this.currentuser.uid).first()
                    .subscribe(function (user) {
                    //loading.dismiss();
                    // this.user.displayName = user.displayName;
                    //this.user.email = user.email || user.providerData[0].email || 'Not set yet.';
                    //this.user.photoURL = user.photoURL || this.user.photoURL;
                    _this.user = user;
                    //console.log(this.user);
                }, function (error) {
                    //loading.dismiss();
                    console.log('Error: ' + JSON.stringify(error));
                });
            })
                .catch(function (err) {
                return console.log(err);
            });
        }).catch(function (err) {
            return console.log(err);
        });
        this.enquiryForm = formBuilder.group({
            rate: ['', Validators.required],
            quantity: ['', Validators.required],
            unit: ['', Validators.required],
            payment: ['', Validators.required],
            details: ['',]
        });
    }
    SendEnquiryPage.prototype.ionViewDidLoad = function () {
        console.log('ionViewDidLoad SendEnquiryPage');
        //console.log(this.seller);
        //console.log(this.productID);
    };
    SendEnquiryPage.prototype.showConfirm = function (enquiryForm) {
        var _this = this;
        if (!enquiryForm.valid) {
            var alert_1 = this.alertCtrl.create({
                title: 'Invalid Entries!',
                subTitle: 'Please fill all required entries',
                buttons: ['OK']
            });
            alert_1.present();
        }
        else {
            var confirm_1 = this.alertCtrl.create({
                title: 'Submit Enquiry?',
                message: 'Do you want to send this enquiry to the seller?',
                buttons: [
                    {
                        text: 'No',
                    },
                    {
                        text: 'Agree',
                        handler: function () {
                            _this.submitEnquiry();
                        }
                    }
                ]
            });
            confirm_1.present();
        }
    };
    SendEnquiryPage.prototype.submitEnquiry = function () {
        var _this = this;
        this.loading = this.loadingCtrl.create({
            content: 'Sending Enquiry, Please Wait...'
        });
        this.userEnquiries.push(this.enquiryForm.value).then(function (data) {
            //console.log(this.enquiryForm.value);
            _this.af.database.object('users/' + _this.currentuser.uid + '/enquiries/' + data.key).update({
                type: 'sent',
                otheruser: _this.sellerID,
                otheruserName: _this.seller.name,
                otheruserNo: _this.seller.mobile,
                product: _this.product,
                productName: _this.product.name,
                productUnit: _this.productunit,
                productMrate: _this.productmrate,
                productKrate: _this.productkrate,
                timestamp: firebase.database['ServerValue']['TIMESTAMP']
                //detials: this.productForm.value.name,
            }).then(function (info) {
                //console.log("successsent");
                //this.navCtrl.pop();
                //this.navCtrl.pop();
            });
            _this.af.database.object('users/' + _this.sellerID + '/enquiries/' + data.key).update({
                type: 'received',
                otheruser: _this.currentuser.uid,
                otheruserName: _this.user.name,
                otheruserNo: _this.user.mobile,
                product: _this.product,
                productName: _this.product.name,
                productUnit: _this.productunit,
                productMrate: _this.productmrate,
                productKrate: _this.productkrate,
                rate: _this.enquiryForm.value.rate,
                quantity: _this.enquiryForm.value.quantity,
                unit: _this.enquiryForm.value.unit,
                payment: _this.enquiryForm.value.payment,
                details: _this.enquiryForm.value.details,
                timestamp: firebase.database['ServerValue']['TIMESTAMP']
                //detials: this.productForm.value.name,
            }).then(function (info) {
                //console.log("successrcv");
                //this.navCtrl.pop();
                //this.navCtrl.pop();
            });
            _this.loading.present();
            setTimeout(function () {
                _this.navCtrl.pop({ animate: false });
                _this.navCtrl.push(EnquirySentPage, { enquiryID: data.key, sellerID: _this.sellerID, uid: _this.currentuser.uid }, { animate: false });
            }, 1000);
            setTimeout(function () {
                _this.loading.dismiss();
            }, 3000);
        });
    };
    return SendEnquiryPage;
}());
SendEnquiryPage = __decorate([
    Component({
        selector: 'page-send-enquiry',
        templateUrl: 'send-enquiry.html'
    }),
    __metadata("design:paramtypes", [NavController, NavParams, FormBuilder, AngularFire, AlertController, LoadingController, AuthService, Storage])
], SendEnquiryPage);
export { SendEnquiryPage };
//# sourceMappingURL=send-enquiry.js.map


text:
mkdir C:\published_game
mkdir C:\published_game\assets
mkdir C:\published_game\assets\murmurs

copy %~dp0deploy\* C:\published_game\
copy %~dp0src\assets\* C:\published_game\assets\
copy %~dp0src\assets\murmurs\* C:\published_game\assets\murmurs\
copy %~dp0src\index.html C:\published_game\index.html


text:
/////////////////////////////////////////////////////////////////////////////
//
// (C) Copyright Ion Gaztanaga  2006-2009
//
// Distributed under the Boost Software License, Version 1.0.
//    (See accompanying file LICENSE_1_0.txt or copy at
//          http://www.boost.org/LICENSE_1_0.txt)
//
// See http://www.boost.org/libs/intrusive for documentation.
//
/////////////////////////////////////////////////////////////////////////////
//[doc_entity_code
#include <boost/intrusive/list.hpp>

using namespace boost::intrusive;

//A class that can be inserted in an intrusive list
class entity : public list_base_hook<>
{
   public:
   virtual ~entity();
   //...
};

//"some_entity" derives from "entity"
class some_entity  :  public entity
{/**/};

//Definition of the intrusive list
typedef list<entity> entity_list;

//A global list
entity_list global_list;

//The destructor removes itself from the global list
entity::~entity()
{  global_list.erase(entity_list::s_iterator_to(*this));  }

//Function to insert a new "some_entity" in the global list
void insert_some_entity()
{  global_list.push_back (*new some_entity(/*...*/));  }

//Function to clear an entity from the intrusive global list
void clear_list ()
{
   // entity's destructor removes itself from the global list implicitly
   while (!global_list.empty())
      delete &global_list.front();
}

int main()
{
   //Insert some new entities
   insert_some_entity();
   insert_some_entity();
   //global_list's destructor will free objects
   return 0;
}

//]