text:
bash /tmp/docker/basebuild/install_requirements.sh

puppet apply /tmp/docker/manifests/stage1.pp
puppet apply /tmp/docker/manifests/stage2.pp
puppet apply /tmp/docker/manifests/stage4.pp

apt-get install -y libpq-dev redis-server libicu-dev

cd /tmp
/usr/local/rvm/wrappers/default/bundle --without development --deployment --path=/var/lib/dtk-bundler-vendor

# Prevent intermittent Gitolite issues
# http://stackoverflow.com/a/2510548/15677
sed -i 's/^AcceptEnv LANG LC_\*$//g' /etc/ssh/sshd_config
# http://stackoverflow.com/questions/22547939/docker-gitlab-container-ssh-git-login-error
sed -i '/session    required     pam_loginuid.so/d' /etc/pam.d/sshd

apt-get clean && apt-get autoclean && apt-get -y autoremove

rm -rf /etc/puppet/modules /tmp/* /var/lib/postgresql/ /var/lib/apt/lists/* /var/tmp/*


text:
package james.monochrome.data.tiles;

import android.content.Context;

import james.monochrome.data.PositionData;
import james.monochrome.utils.TileUtils;

public class GrassTileData extends TileData {

    public GrassTileData(Context context, int thickness, PositionData position) {
        super(context, TileUtils.getRandomGrass(1, thickness), position);
    }

    @Override
    public void onTouch() {
    }

    @Override
    public void onEnter() {
    }

    @Override
    public void onExit() {
    }

    @Override
    public boolean canEnter() {
        return true;
    }
}

redpajama_set_name: RedPajamaGithub


text:
#ifndef PROCESS_H_
#define PROCESS_H_

#include <string>
#include "Streams.h"

namespace NativeTask {

using std::string;

class PipeInputStream : public InputStream {
private:
  uint64_t _read;
  int    _fd;
public:
  int getFd() {
    return _fd;
  }
  void setFd(int fd) {
    _fd = fd;
  }

  PipeInputStream(int fd=-1) :
    _read(0),
    _fd(fd) {
  }

  virtual ~PipeInputStream() {
  }

  virtual void seek(uint64_t position);

  virtual uint64_t tell();

  virtual int32_t read(void * buff, uint32_t length);

  virtual void close();
};

/**
 * Local raw filesystem file output stream
 */
class PipeOutputStream : public OutputStream {
private:
  uint64_t _written;
  int    _fd;
public:
  int getFd() {
    return _fd;
  }
  void setFd(int fd) {
    _fd = fd;
  }

  PipeOutputStream(int fd=-1) :
    _written(0),
    _fd(fd) {
  }

  virtual ~PipeOutputStream() {
  }

  virtual uint64_t tell();

  virtual void write(const void * buff, uint32_t length);

  virtual void flush();

  virtual void close();
};

class Process {
public:
  /**
   * Popen with stdin,stdout,stderr
   * @return subprocess pid
   */
  static int Popen(const string & cmd,
                   int & fdstdin,
                   int & fdstdout,
                   int & fdstderr);

  static int Popen(const string & cmd,
                   FILE *& fstdin,
                   FILE *& fstdout,
                   FILE *& fstderr);

  static int Popen(const string & cmd,
                   PipeOutputStream & pstdin,
                   PipeInputStream & pstdout,
                   PipeInputStream & pstderr);

  static int Run(const string & cmd, string * out, string * err);
};

} // namespace NativeTask

#endif /* PROCESS_H_ */


text: echo "Please use 'cargo dev bless' instead."


text:
macro_rules! unborrow {
    // =========================================================================================================
    // PRIVATE RULES

    // This rule fires when we have parsed all the arguments.
    // It just falls through to output stage.
    // (FIXME could fold the output rule into this one to reduce recursion)
    (@parse () -> ($names:tt $lets:tt) $($thru:tt)*) => {
        unborrow!(@out $names $lets $($thru)*)
    };

    // Parse an argument and continue parsing
    // This is the key rule, assigning a name for the argument and generating the let statement.
    (@parse ($arg:expr, $($rest:tt)*) -> ([$($names:ident),*] [$($lets:stmt);*]) $($thru:tt)*) => {
        unborrow!(@parse ($($rest)*) -> ([$($names,)* arg] [$($lets;)* let arg = $arg]) $($thru)*)
        //                                            ^                    ^
        // Right here an ident is created out of thin air using hygiene.
        // Every time the macro recurses, we get a new syntax context, so "arg" is actually a new identifier!
    };

    // Output stage for free functions.
    // Assembles the let statements and variable names into a block which computes the arguments,
    // calls the method, and returns its result.
    (@out [$($names:ident),*] [$($lets:stmt);*] ($($meth:ident)::+) $arg1:expr) => {{
        $($lets;)*
        $($meth)::+($arg1, $($names),*)
    }};

    // Output stage for object methods.
    (@out [$($names:ident),*] [$($lets:stmt);*] $($obj:ident).+) => {{
        $($lets;)*
        $($obj).+($($names),*)
    }};

    // =========================================================================================================
    // PUBLIC RULES

    // Macro entry point for object methods.
    ($($obj:ident).+ ($($args:expr),*)) => {
        unborrow!(@parse ($($args,)*) -> ([] []) $($obj).+)
        //                |               |  |   ^ info about the method call, saved for later
        //                |               |  ^ generated let statements
        //                |               ^ generated argument names
        //                ^ arguments to be parsed
    };

    // Macro entry point for free functions.
    ($($meth:ident)::+ ($arg1:expr, $($args:expr),*)) => {
        unborrow!(@parse ($($args,)*) -> ([] []) ($($meth)::+) $arg1)
    };
}


text:
module HTMLProofer
  module Configuration
    require_relative 'version'

    PROOFER_DEFAULTS = {
      :allow_hash_href => false,
      :alt_ignore => [],
      :assume_extension => false,
      :check_external_hash => false,
      :check_favicon => false,
      :check_html => false,
      :check_img_http => false,
      :check_opengraph => false,
      :checks_to_ignore => [],
      :directory_index_file => 'index.html',
      :disable_external => false,
      :empty_alt_ignore => false,
      :enforce_https => false,
      :error_sort => :path,
      :extension => '.html',
      :external_only => false,
      :file_ignore => [],
      :http_status_ignore => [],
      :internal_domains => [],
      :log_level => :info,
      :only_4xx => false,
      :url_ignore => [],
      :url_swap => {}
    }

    TYPHOEUS_DEFAULTS = {
      :followlocation => true,
      :headers => {
        'User-Agent' => "Mozilla/5.0 (compatible; HTML Proofer/#{HTMLProofer::VERSION}; +https://github.com/gjtorikian/html-proofer)"
      }
    }

    HYDRA_DEFAULTS = {
      :max_concurrency => 50
    }

    PARALLEL_DEFAULTS = {}

    VALIDATION_DEFAULTS = {
      :report_script_embeds => false,
      :report_missing_names => false,
      :report_invalid_tags => false
    }

    CACHE_DEFAULTS = {}

    def self.to_regex?(item)
      if item.start_with?('/') && item.end_with?('/')
        Regexp.new item[1...-1]
      else
        item
      end
    end
  end
end


text:
#ifndef QQMLVALUETYPEWRAPPER_P_H
#define QQMLVALUETYPEWRAPPER_P_H

//
//  W A R N I N G
//  -------------
//
// This file is not part of the Qt API.  It exists purely as an
// implementation detail.  This header file may change from version to
// version without notice, or even be removed.
//
// We mean it.
//

#include <QtCore/qglobal.h>
#include <private/qtqmlglobal_p.h>

#include <private/qv4value_p.h>
#include <private/qv4object_p.h>

QT_BEGIN_NAMESPACE

class QQmlValueType;

namespace QV4 {

namespace Heap {

struct QQmlValueTypeWrapper : Object {
    void init() { Object::init(); }
    void destroy();
    QQmlPropertyCache *propertyCache() const { return _propertyCache; }
    void setPropertyCache(QQmlPropertyCache *c) {
        if (c)
            c->addref();
        if (_propertyCache)
            _propertyCache->release();
        _propertyCache = c;
    }
    mutable void *gadgetPtr;
    QQmlValueType *valueType;

    void setValue(const QVariant &value) const;
    QVariant toVariant() const;

private:
    QQmlPropertyCache *_propertyCache;
};

}

struct Q_QML_EXPORT QQmlValueTypeWrapper : Object
{
    V4_OBJECT2(QQmlValueTypeWrapper, Object)
    V4_PROTOTYPE(valueTypeWrapperPrototype)
    V4_NEEDS_DESTROY

public:

    static ReturnedValue create(ExecutionEngine *engine, QObject *, int, const QMetaObject *metaObject, int typeId);
    static ReturnedValue create(ExecutionEngine *engine, const QVariant &, const QMetaObject *metaObject, int typeId);

    QVariant toVariant() const;
    bool toGadget(void *data) const;
    bool isEqual(const QVariant& value);
    int typeId() const;
    bool write(QObject *target, int propertyIndex) const;

    static ReturnedValue get(const Managed *m, String *name, bool *hasProperty);
    static void put(Managed *m, String *name, const Value &value);
    static bool isEqualTo(Managed *m, Managed *other);
    static PropertyAttributes query(const Managed *, String *name);
    static void advanceIterator(Managed *m, ObjectIterator *it, Value *name, uint *index, Property *p, PropertyAttributes *attributes);

    static QV4::ReturnedValue method_toString(CallContext *ctx);

    static void initProto(ExecutionEngine *v4);
};

}

QT_END_NAMESPACE

#endif // QV8VALUETYPEWRAPPER_P_H


text:
import Ember from 'ember';
import layout from '../templates/components/bulma-panel-tabs';
import { _helpers, _responsiveHelpers } from '../constants';

const {
  Component
} = Ember;

export default Component.extend({
  layout,
  classNames: ['panel-tabs'],
  classNameBindings: [].concat(_helpers, _responsiveHelpers)
});


text:
using namespace std;

TEST(rtspClient, DoOPTIONS_InvalidInput)
{
	string RtspUri1("rtsp://192.15.100/ansersion");
	string RtspUri2("rtsp://192.168.15.1007/ansersion");
	string RtspUri3("ansersion:/192.168.15.100:554/ansersion");
    RtspClient Client1;
    RtspClient Client2(RtspUri2);
    RtspClient Client3(RtspUri3);

	EXPECT_NE(Client1.DoOPTIONS(RtspUri1), RTSP_NO_ERROR);
	EXPECT_NE(Client1.DoOPTIONS(), RTSP_NO_ERROR);
	EXPECT_NE(Client2.DoOPTIONS(), RTSP_NO_ERROR);
	EXPECT_NE(Client3.DoOPTIONS(), RTSP_NO_ERROR);
}

TEST(rtspClient, DoOPTIONS_RegularInput)
{
	// string RtspUri1("rtsp://127.0.0.1/ansersion");
	// string RtspUri2("rtsp://127.0.0.1/ansersion");
	// string RtspUri3("rtsp://127.0.0.1:554/ansersion");
	string RtspUri1("rtsp://192.168.81.157:8554/ansersion");
	string RtspUri2("rtsp://192.168.81.157:8554/ansersion");
	string RtspUri3("rtsp://192.168.81.157:8554/ansersion");
    RtspClient Client1;
    RtspClient Client2(RtspUri2);
    RtspClient Client3(RtspUri3);

	EXPECT_EQ(Client1.DoOPTIONS(RtspUri1), RTSP_NO_ERROR);
	EXPECT_EQ(Client1.DoOPTIONS(), RTSP_NO_ERROR);
	EXPECT_EQ(Client2.DoOPTIONS(), RTSP_NO_ERROR);
	EXPECT_EQ(Client3.DoOPTIONS(), RTSP_NO_ERROR);
}

TEST(rtspClient, DoDESCRIBE_InvalidInput)
{
	string RtspUri1("rtsp://192.15.100/ansersion");
	string RtspUri2("rtsp://192.168.15.1007/ansersion");
	string RtspUri3("ansersion:/192.168.15.100:554/ansersion");
    RtspClient Client1;
    RtspClient Client2(RtspUri2);
    RtspClient Client3(RtspUri3);

	EXPECT_NE(Client1.DoDESCRIBE(RtspUri1), RTSP_NO_ERROR);
	EXPECT_NE(Client1.DoDESCRIBE(), RTSP_NO_ERROR);
	EXPECT_NE(Client2.DoDESCRIBE(), RTSP_NO_ERROR);
	EXPECT_NE(Client3.DoDESCRIBE(), RTSP_NO_ERROR);
}

TEST(rtspClient, DoDESCRIBE_RegularInput)
{
	// string RtspUri1("rtsp://127.0.0.1/ansersion");
	// string RtspUri2("rtsp://127.0.0.1/ansersion");
	// string RtspUri3("rtsp://127.0.0.1:554/ansersion");
	string RtspUri1("rtsp://192.168.81.157:8554/ansersion");
	string RtspUri2("rtsp://192.168.81.157:8554/ansersion");
	string RtspUri3("rtsp://192.168.81.157:8554/ansersion");
    RtspClient Client1;
    RtspClient Client2(RtspUri2);
    RtspClient Client3(RtspUri3);

	EXPECT_EQ(Client1.DoDESCRIBE(RtspUri1), RTSP_NO_ERROR);
	EXPECT_EQ(Client1.DoDESCRIBE(), RTSP_NO_ERROR);
	EXPECT_EQ(Client2.DoDESCRIBE(), RTSP_NO_ERROR);
	EXPECT_EQ(Client3.DoDESCRIBE(), RTSP_NO_ERROR);
}

TEST(rtspClient, DoSETUP_InvalidInput)
{
	string RtspUri("rtsp://127.0.0.1/ansersion");
    RtspClient Client(RtspUri);

	EXPECT_NE(Client.DoSETUP(NULL), RTSP_NO_ERROR);
}

TEST(rtspClient, DoSETUP_RegularInput)
{
	// string RtspUri("rtsp://127.0.0.1/ansersion");
	string RtspUri("rtsp://192.168.81.157:8554/ansersion");
    RtspClient Client(RtspUri);

	EXPECT_EQ(Client.DoOPTIONS(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	EXPECT_EQ(Client.DoDESCRIBE(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	EXPECT_EQ(Client.ParseSDP(), RTSP_NO_ERROR);

	EXPECT_EQ(Client.DoSETUP(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());
}

TEST(rtspClient, DoPLAY_InvalidInput)
{
	// string RtspUri("rtsp://127.0.0.1/ansersion");
	string RtspUri("rtsp://192.168.81.157:8554/ansersion");
    RtspClient Client(RtspUri);

	EXPECT_EQ(Client.DoOPTIONS(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	EXPECT_EQ(Client.DoDESCRIBE(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	EXPECT_EQ(Client.ParseSDP(), RTSP_NO_ERROR);

	EXPECT_EQ(Client.DoSETUP(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	EXPECT_EQ(Client.DoPLAY("abc"), RTSP_INVALID_MEDIA_SESSION);

	EXPECT_EQ(Client.DoTEARDOWN(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

}

TEST(rtspClient, DoPLAY_RegularInput)
{
	// string RtspUri("rtsp://127.0.0.1/ansersion");
	string RtspUri("rtsp://192.168.81.157:8554/ansersion");
    RtspClient Client(RtspUri);

	EXPECT_EQ(Client.DoOPTIONS(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	EXPECT_EQ(Client.DoDESCRIBE(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	EXPECT_EQ(Client.ParseSDP(), RTSP_NO_ERROR);

	EXPECT_EQ(Client.DoSETUP(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	printf("start PLAY\n");
	EXPECT_EQ(Client.DoPLAY("video"), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());
	EXPECT_EQ(Client.DoPLAY("audio"), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	sleep(3);
	printf("start TEARDOWN\n");
	EXPECT_EQ(Client.DoTEARDOWN("video"), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());
	EXPECT_EQ(Client.DoTEARDOWN("audio"), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());
	sleep(3);
}

TEST(rtspClient, DoPAUSE_InvalidInput)
{
	// string RtspUri("rtsp://127.0.0.1/ansersion");
	string RtspUri("rtsp://192.168.81.157:8554/ansersion");
    RtspClient Client(RtspUri);

	EXPECT_EQ(Client.DoOPTIONS(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	EXPECT_EQ(Client.DoDESCRIBE(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	EXPECT_EQ(Client.ParseSDP(), RTSP_NO_ERROR);

	EXPECT_EQ(Client.DoSETUP(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	printf("start PLAY\n");
	EXPECT_EQ(Client.DoPLAY("video"), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());
	sleep(3);
	EXPECT_EQ(Client.DoPAUSE("abc"), RTSP_INVALID_MEDIA_SESSION);

	sleep(3);
	printf("start TEARDOWN\n");
	EXPECT_EQ(Client.DoTEARDOWN("video"), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());
	sleep(3);

}

TEST(rtspClient, DoPAUSE_RegularInput)
{
	// string RtspUri("rtsp://127.0.0.1/ansersion");
	string RtspUri("rtsp://192.168.81.157:8554/ansersion");
    RtspClient Client(RtspUri);

	EXPECT_EQ(Client.DoOPTIONS(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	EXPECT_EQ(Client.DoDESCRIBE(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	EXPECT_EQ(Client.ParseSDP(), RTSP_NO_ERROR);

	EXPECT_EQ(Client.DoSETUP(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	printf("start PLAY\n");
	EXPECT_EQ(Client.DoPLAY("video"), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());
	sleep(3);
	EXPECT_EQ(Client.DoPAUSE("video"), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());
	sleep(3);
	EXPECT_EQ(Client.DoPLAY("video"), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());
	sleep(3);
	printf("start TEARDOWN\n");
	EXPECT_EQ(Client.DoTEARDOWN("video"), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());
	sleep(3);
}

TEST(rtspClient, DoGET_PARAMETER_RegularInput)
{
	// string RtspUri("rtsp://127.0.0.1/ansersion");
	string RtspUri("rtsp://192.168.81.157:8554/ansersion");
    RtspClient Client(RtspUri);

	EXPECT_EQ(Client.DoOPTIONS(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	EXPECT_EQ(Client.DoDESCRIBE(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	EXPECT_EQ(Client.ParseSDP(), RTSP_NO_ERROR);

	EXPECT_EQ(Client.DoSETUP(), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());

	printf("start PLAY\n");
	EXPECT_EQ(Client.DoPLAY("video"), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());
	sleep(3);
	EXPECT_EQ(Client.DoGET_PARAMETER("video"), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());
	sleep(3);
	printf("start TEARDOWN\n");
	EXPECT_EQ(Client.DoTEARDOWN("video"), RTSP_NO_ERROR);
	EXPECT_TRUE(Client.IsResponse_200_OK());
	sleep(3);
}


text:
package com.department.services.impl;

import com.department.exceptions.AppException;
import com.department.exceptions.AppValidationException;
import com.department.exceptions.RepositoryException;
import com.department.models.User;
import com.department.repository.UserRepository;
import com.department.repository.implHibernate.UserRepositoryImpl;
import com.department.services.UserService;
import com.department.validation.CustomValidator;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * Created on 16.04.2017.
 */
// Autoscan paths , component by service-layer
@Service
public class UserServiceImpl implements UserService {

    @Autowired
    private UserRepository userRepository; //= new UserRepositoryImpl();

    @Autowired
    private CustomValidator customValidator; //= new CustomValidator();

    @Override
    @Transactional(readOnly = true)
    public List<User> findAllEntities() throws AppException {
        return userRepository.findAll();
    }

    @Override
    @Transactional(readOnly = true)
    public User findOneEntity(Integer id) throws AppException {
        return userRepository.findOne(id);
    }

    @Override
    public User saveEntityWithValidation(User entity) throws AppException {
        validate(entity);
        return userRepository.save(entity);
    }

    @Override
    public void deleteEntityWithValidation(Integer id) throws AppException {
        userRepository.delete(id);
    }

    private void validate(Object entity) throws AppValidationException, RepositoryException {

        Map<String, String> valid = new HashMap<>();

        this.customValidator.validateEntity(entity, valid);
        if (valid.size() > 0) {
            throw new AppValidationException("element not valid for user",valid);
        }
    }
}


text:
** Android Specific Readme **

This src files substitute the ones place on the main src because those are desktop specific (related with file loading because they differ a lot on android).
This files depends on SDL 2.0, so in order to compile, you'll have to set up SDL2.0 too.
If one want to discard SDL, only have to adapt those files, and create the specific window interface like the ones used in examples/WindowManagers.


text:
<?php

	class mPattern extends CI_Model{

		/**
		 *	__construct method is a constructor method for mPattern class
		 *
		 *	__construct method is a constructor method for mPattern class
		 *	which will load a set of necessarily libraries, models, and helpers for use.
		 *
		 *	@return		void
		 */
		public function __construct(){
			parent::__construct();
			$this->load->model('mDBConnection','d');
			$this->load->model('mPatternDesc', 'pd');
		}

		/**
		 *	create_pattern() is a model function for creating a new pattern record.
		 *
		 *	create_pattern() is a model function for creating a new pattern record into the database.
		 *
		 *	@param 		array 	$data 		An array of pattern information which has keys as same as
		 *									the column name.
		 *
		 *	@return 	boolean 			A boolean status for creating process.
		 */
		public function create_pattern($data){

			/** Sets a 'condition' string for using with the database helper. */
			$condition 	= "pattern_id ='".$data["pattern_id"]."'";

			/** Calls a mDBConnection class's create method for adding a new pattern into pattern table. */
			return $this->d->create('*', $condition, 'pattern', $data);
		}

		/**
		 *	get_pattern() is a model function to get a pattern by the specified pattern ID
		 *
		 *	get_pattern() is a model function to get a pattern object by using the specified pattern ID as
		 *	a key for retrieval.
		 *
		 * 	@param 		string 	$id 		A pattern ID that is a string with the predefined format.
		 *
		 *	@return 	array/boolean 		An array of pattern object with its corresponding information,
		 *									e.g. pattern ID, pattern name, etc.
		 */
		public function get_pattern($id){

			/** Sets a 'condition' string for using with the database helper. */
			$condition 	= "pattern_id = '".$id."'";

			/** Calls a select method of mDBConnection class to get an array of pattern information */
			$pattern 	= $this->d->select('*', $condition, 'pattern', 1);

			/**
			 *	Checks whether the query result is a boolean or not. The query result will be false when
			 *	there is no pattern with the specified pattern ID in the database.
			 */
			if(is_bool($pattern)){
				return $pattern;
			}

			/** Otherwise, returns an array of retrieved pattern information (only one row). */
			return $pattern[0];
		}

		/**
		 *	get_pattern_all() is a model function to get all existing pattern in the database.
		 *
		 *	get_pattern_all() is a model function to get all existing pattern records in the database
		 *	and return it as an array which has keys as same as the column name.
		 *
		 *	@return 	array 		An array of pattern information which has keys as same as the column
		 *							name.
		 *							Example Data:
		 *							[0]		=>	['pattern_id']		=>	'P-01',
		 *									=>	['pattern_name'] 	=>	'ABC Pattern',
		 *									=>	...
		 *							...
		 */
		public function get_pattern_all(){
			$condition 	= "";

			/** Calls a select function of mDBConnection class to retrieve all pattern information. */
			$pattern 	= $this->d->select('*', $condition, 'pattern');

			/** Returns an array of pattern information */
			return $pattern;
		}

		/**
		 *	get_only_ready_pattern_no_assessed() is a model function to get some pattern that is not assessed
		 *
		 *	get_only_ready_pattern_no_assessed() is a model function to get some pattern that is not assessed
		 *	and its status is ready. This function is used in the summary section of the dashboard. It can be
		 *	configure to retrieve only the patterns of the specified pattern creator by passing pattern
		 *	developer ID to the function.
		 *
		 *	@param 		integer 	$dev_id 	An integer that indicates the specific pattern developer ID.
		 *
		 *	@return 	array 		An array of patterns information for the specified pattern developer.
		 */
		public function get_only_ready_pattern_no_assessed($dev_id = NULL){

			/** Retrieve all pattern information in the database. */
			$pat_list = $this->get_pattern_all();

			/** Checks whether the pattern list is empty or the function returns false or not*/
			if(!is_bool($pat_list)){

				/**
				 * 	If the pattern developer ID is specified, the pattern array is filtered only
				 *	the patterns that are created by the specified pattern developer only.
				 */
				if ($dev_id != NULL) {
					$pat_list 	= array_filter($pat_list, function($pat) use($dev_id){
						return ($pat['pattern_creator_id'] == $dev_id);
					});
				}

				/** If not, the array will be filtered which only the patterns that its status and assess
				 * count is zero are kept.
				 */
				return array_filter($pat_list, function($pat) {
					$cond 		= "pattern_id ='".$pat['pattern_id']."' AND desc_version =".(float)$pat['pattern_assess_version'];
					$counter 	= $this->d->select('desc_assess_count', $cond, 'pattern_description')[0]['desc_assess_count'];
					return $pat['pattern_status'] == 'Ready' AND $counter == 0;
				});

			}
		}

		/**
		 *	get_pattern_by_developer() is a model function for fetching patterns of the specified developer
		 *
		 *	get_pattern_by_developer() is a model function for fetching patterns of the specified developer by
		 *	using the input developer ID.
		 *
		 *	@param 		integer 	$dev_id 	The pattern developer ID that is an integer.
		 *
		 *	@return 	array 		An array of patterns which are corresponding to the specified developer.
		 */
		public function get_pattern_by_developer($dev_id){

			/** Sets a 'condition' string to pass to the database helper */
			$condition 	= "pattern_creator_id = ".$dev_id."";

			/** Fetches the pattern list from 'pattern' table using the database helper command */
			$pattern 	= $this->d->select('*', $condition, 'pattern', 1);
			return $pattern;
		}

		/**
		 *	get_pattern_unreach_limit_assess() is a model function for fetching an unreached-limit patterns
		 *	list.
		 *
		 *	get_pattern_unreach_limit_assess() is a model function for fetching an unreached-limit patterns
		 *	list for the specified pattern developer. The input developer ID can leave it as NULL for fetching
		 * 	all patterns without limiting the developer.
		 *
		 *	@param 		integer 	$dev_id 	The pattern developer ID that is an integer.
		 *
		 *	@return 	array 		An array of patterns which its assessment count is not exceed its limit.
		 */
		public function get_pattern_unreach_limit_assess($dev_id=NULL){

			/** Fetches all pattern in the database into an array */
			$pat_list 	= $this->get_pattern_all();

			/** Checks whether there is any pattern in the database or not. */
			if(!is_bool($pat_list)){

				/** If the developer ID is specified, filters only patterns that relate to the developer ID */
				if($dev_id != NULL){
					$pat_list 	= array_filter($pat_list, function($pat) use($dev_id){
						return ($pat['pattern_creator_id'] == $dev_id);
					});
				}

				/**
				 * 	returns an array that filters only the pattern that its assessment count is not exceed
				 *	its limit.
				 */
				return array_filter($pat_list, function($pat){
					$cond 		= "pattern_id ='".$pat['pattern_id']."' AND desc_version =".(float)$pat['pattern_assess_version'];
					$counter 	= $this->d->select('desc_assess_count', $cond, 'pattern_description')[0]['desc_assess_count'];
					return (($pat['pattern_assess_limit'] == 0)? true:($counter < $pat['pattern_assess_limit'])) AND $pat['pattern_status'] != 'Disable';
			});
			}
			else{
				return $pat_list;
			}
		}

		/**
		 *	get_pattern_reach_limit_assess() is a model function for fetching an reached-limit patterns
		 *	list.
		 *
		 *	get_pattern_reach_limit_assess() is a model function for fetching an reached-limit patterns
		 *	list for the specified pattern developer. The input developer ID can leave it as NULL for fetching
		 * 	all patterns without limiting the developer.
		 *
		 *	@param 		integer 	$dev_id 	The pattern developer ID that is an integer.
		 *
		 *	@return 	array 		An array of patterns which its assessment count is exceed its limit.
		 */
		public function get_pattern_reach_limit_assess($dev_id=NULL){

			/** Fetches all pattern in the database into an array */
			$pat_list 	= $this->get_pattern_all();

			/** Checks whether there is any pattern in the database or not. */
			if(!is_bool($pat_list)){

				/** If the developer ID is specified, filters only patterns that relate to the developer ID */
				if($dev_id != NULL){
					$pat_list 	= array_filter($pat_list, function($pat) use($dev_id){
						return ($pat['pattern_creator_id'] == $dev_id);
					});
				}

				/**
				 * 	returns an array that filters only the pattern that its assessment count is exceed
				 *	or equal to its limit.
				 */
				return array_filter($pat_list, function($pat) {

					$cond 		= "pattern_id ='".$pat['pattern_id']."' AND desc_version =".(float)$pat['pattern_assess_version'];
					$counter 	= $this->d->select('desc_assess_count', $cond, 'pattern_description')[0]['desc_assess_count'];
					return (($pat['pattern_assess_limit'] == 0)? false:($counter >= $pat['pattern_assess_limit'])) AND $pat['pattern_status'] != 'Disable';
			});
			}
			else{
				return $pat_list;
			}
		}

		/**
		 *	update_pattern() is a model function for updating pattern data in the database.
		 *
		 *	update_pattern() is a model function for updating pattern data in the database follows the data
		 *	from the input array.
		 *
		 *	@param 		array 	$data 		An array of the pattern data which has keys as same as the
		 *									column name.
		 *
		 *	@return 	boolean 			A boolean that represents the update process status.
		 */
		public function update_pattern($data){

			/** Sets a 'condition' string for the database helper. */
			$condition 		= "pattern_id ='".$data['pattern_id']."'";

			/** Calls an update command of the database helper. */
			return $this->d->update($condition, 'pattern', $data);
		}

		/**
		 *	delete_pattern() is a model function for deleting a pattern data from the database.
		 *
		 *	delete_pattern() is a model function for deleting a pattern data from the database follows the
		 *  specified pattern id.
		 *
		 *	@param 		string 		$id 	The pattern Id that is a string with predefined format.
		 *
		 *	@return 	boolean 	A boolean that represents the delete process status
		 */
		public function delete_pattern($id){

			/** Sets a 'condition' statement for the database helper. */
			$condition 	= "pattern_id ='".$id."'";

			/** Calls a 'delete' command of the database helper and stores the status. */
			$pattern 	= $this->d->delete('*', $condition, 'pattern', array('pattern_id' => $id));

			/** Checks whether there is any pattern description related to the deleted pattern or not. */
			if(!empty($this->d->select('*', $condition, 'pattern_description'))){

				/** If so, continues to delete the pattern description in the database as well. */
				$desc 	= $this->d->delete('*', $condition, 'pattern_description', array('pattern_id' => $id));
				return ($pattern AND $desc);
			}
			else{
				return $pattern;
			}

		}
	}
?>


text:
module.exports = function( config ) {

    config.set( {
        files: [
            "node_modules/jquery/dist/jquery.js",
            "bower_components/mustache.js/mustache.min.js",
            "test/setup.js",
            "dist/jquery.ands.registry-widget.min.js",
            "test/spec/*"
        ],
        frameworks: [ "qunit" ],
        autoWatch: true,

        // to avoid DISCONNECTED messages
        browserDisconnectTimeout: 10000,
        browserDisconnectTolerance: 1,
        browserNoActivityTimeout: 60000
    } );
};


text:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">

    <meta http-equiv="Content-Language" content="en-ca" />
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <link rel="stylesheet" type="text/css" href="../style.css" />
    <title><tar> Task</title>

            NAnt

          Help

          Task Reference
           <tar>

                        v0.91-alpha2

<tar>

[This is preliminary documentation and subject to change.]

 Creates a tar file from the specified filesets.

Uses #ziplib (SharpZipLib), an open source Tar/Zip/GZip library written entirely in C#.

Parameters

          Attribute
          Type
          Description
          Required

          destfile
          file
           The tar file to create.
          True

          compression

            TarCompressionMethod

           The compression method. The default is None.
          False

          includeemptydirs
          bool
           Include empty directories in the generated tar file. The default is false.
          False

          failonerror
          bool
           Determines if task failure stops the build, or is just reported. The default is true.
          False

          if
          bool
           If true then the task will be executed; otherwise, skipped. The default is true.
          False

          unless
          bool
           Opposite of if. If false then the task will be executed; otherwise, skipped. The default is false.
          False

          verbose
          bool
           Determines whether the task should report detailed build log messages. The default is false.
          False

Nested Elements:

                    <fileset>

 The set of files to be included in the archive.

                    </fileset>

Examples

 Tar all files in ${build.dir} and ${doc.dir} into a file called "backup.tar.gz", and apply gzip compression to it.

            <tar destfile="backup.tar.gz" compression="GZip">
                <fileset basedir="${bin.dir}" prefix="bin">
                    <include name="**/*" />
                </fileset>
                <fileset basedir="${doc.dir}" prefix="doc">
                    <include name="**/*" />
                </fileset>
            </tar>

Requirements

      Assembly: NAnt.CompressionTasks (0.91.3881.0)


text:
namespace Ds3.Helpers.Strategies.StreamFactory
{
    /// <summary>
    /// Create one stream and GET blobs in order without seeking
    /// </summary>
    public class ReadStreamStreamFactory : StreamFactory
    {
    }
}


text:
'use strict';

module.exports = {
  extends: 'recommended',
  rules: {
    'no-html-comments': false,
    // TODO: fix all this outdated patterns
    'no-action': 'warn',
    'no-curly-component-invocation': 'warn',
    'no-implicit-this': 'warn',
    'no-link-to-positional-params': 'warn',
  },
};


text:
<?xml version="1.0" encoding="UTF-8"?>
<folder exportedWithPermissions="false">
    <parent>/organizations/organization_1/analysis</parent>
    <name>datasources</name>
    <label>Analysis Data Sources</label>
    <description>Data sources used by Analysis</description>
    <creationDate>2015-01-14T17:45:26.639+01:00</creationDate>
    <updateDate>2014-12-18T11:01:08.765+01:00</updateDate>
    <resource>FoodmartDataSource</resource>
    <resource>FoodmartDataSourceJNDI</resource>
    <resource>SugarCRMDataSource</resource>
    <resource>SugarCRMDataSourceJNDI</resource>
</folder>


text:
using System.Threading.Tasks;

namespace Restall.Nancy.ServiceRouting.Tests.Integration.EchoService
{
	public class AsyncEchoService
	{
		public async Task<EchoResponse> ServiceMethod(EchoUrlRequest request)
		{
			await LongRunningTask.Instance();
			return new EchoResponse { TokenEcho = request.Token };
		}

		public async Task<EchoResponse> ServiceMethod(EchoFormRequest request)
		{
			await LongRunningTask.Instance();
			return new EchoResponse { TokenEcho = request.Token };
		}
	}
}


text:
<?xml version="1.0" encoding="UTF-8"?>

<rootTag>
  <Award>
    <AwardTitle>Infrastructure upgrade for the new William & Mary Herbarium</AwardTitle>
    <AwardEffectiveDate>04/01/2008</AwardEffectiveDate>
    <AwardExpirationDate>03/31/2011</AwardExpirationDate>
    <AwardAmount>85011</AwardAmount>
    <AwardInstrument>
      <Value>Standard Grant</Value>
    </AwardInstrument>
    <Organization>
      08080200
      <Directorate>
        <LongName>Direct For Biological Sciences</LongName>
      </Directorate>
      <Division>
        <LongName>Div Of Biological Infrastructure</LongName>
      </Division>
    </Organization>
    <ProgramOfficer>
      <SignBlockName>Anne Maglia</SignBlockName>
    </ProgramOfficer>
    <AbstractNarration>An award has been made to the College of William and Mary under the direction of Dr. Martha Case to acquire new herbarium cabinets and a plant dryer for the collection, and to fund the move of the herbarium into newly renovated space on campus. The plant dryer will aid in the preparation of specimens for the collection. The new cabinets will ensure protection and storage of the dried plant specimens for at least two decades. The collection of some 76,000 plant specimens, mostly from Virginia, is a regionally important collection of plants that is valuable in research, education, and resource management. Students at the college regularly use the collection in their coursework, and the school has an record of preparing students for graduate study in plant science.</AbstractNarration>
    <MinAmdLetterDate>02/29/2008</MinAmdLetterDate>
    <MaxAmdLetterDate>02/29/2008</MaxAmdLetterDate>
    <ARRAAmount/>
    <AwardID>0749252</AwardID>
    <Investigator>
      <FirstName>Martha</FirstName>
      <LastName>Case</LastName>
      <EmailAddress>macase@wm.edu</EmailAddress>
      <StartDate>02/29/2008</StartDate>
      <EndDate/>
      <RoleCode>Principal Investigator</RoleCode>
    </Investigator>
    <Institution>
      <Name>College of William and Mary</Name>
      <CityName>Williamsburg</CityName>
      <ZipCode>231878795</ZipCode>
      <PhoneNumber>7572213966</PhoneNumber>
      <StreetAddress>Office of Sponsored Programs</StreetAddress>
      <CountryName>United States</CountryName>
      <StateName>Virginia</StateName>
      <StateCode>VA</StateCode>
    </Institution>
    <ProgramElement>
      1197
      <Text>BIOLOGICAL RESEARCH COLLECTION</Text>
    </ProgramElement>
    <ProgramReference>
      9169
      <Text>BIODIVERSITY AND ECOSYSTEM DYNAMICS</Text>
    </ProgramReference>
    <ProgramReference>
      EGCH
      <Text>ENVIRONMENT AND GLOBAL CHANGE</Text>
    </ProgramReference>
  </Award>
</rootTag>


text:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using System.Globalization;
using PhotoSharingApplication.Models;

namespace PhotoSharingApplication.Controllers
{
    [ValueReporter]
    public class PhotoController : Controller
    {
        private PhotoSharingContext context = new PhotoSharingContext();

        // GET: Photo
        public ActionResult Index()
        {
            return View("Index");
        }

        [ChildActionOnly]
        public ActionResult _PhotoGallery(int number = 0)
        {
            List<Photo> photos;
            if (number == 0)
            {
                photos = context.Photos.ToList();
            }
            else
            {
                photos = (from p in context.Photos orderby p.CreatedDate descending select p).Take(number).ToList();
            }

            return PartialView("_PhotoGallery", photos);
        }

        public ActionResult Display(int id)
        {
            Photo photo = context.Photos.Find(id);
            if (photo == null)
            {
                return HttpNotFound();
            }

            return View("Display", photo);
        }

        public ActionResult Create()
        {
            Photo newPhoto = new Photo();
            newPhoto.CreatedDate = DateTime.Today;

            return View("Create", newPhoto);
        }

        [HttpPost]
        public ActionResult Create(Photo photo, HttpPostedFileBase image)
        {
            photo.CreatedDate = DateTime.Today;

            if (!ModelState.IsValid)
            {
                return View("Create", photo);
            }
            else
            {
                if (image != null)
                {
                    photo.ImageMimeType = image.ContentType;
                    photo.PhotoFile = new byte[image.ContentLength];
                    image.InputStream.Read(photo.PhotoFile, 0, image.ContentLength);
                }

                context.Photos.Add(photo);
                context.SaveChanges();
                return RedirectToAction("Index");

            }
        }

        public ActionResult Delete(int id)
        {
            Photo photo = context.Photos.Find(id);

            if (photo == null)
            {
                return HttpNotFound();
            }

            return View("Delete", photo);
        }

        [HttpPost]
        [ActionName("Delete")]
        public ActionResult DeleteConfirmed(int id)
        {
            Photo photo = context.Photos.Find(id);

            context.Photos.Remove(photo);
            context.SaveChanges();
            return RedirectToAction("Index");

        }

        public FileContentResult GetImage(int id)
        {
            Photo photo = context.Photos.Find(id);

            if (photo != null)
            {
                return File(photo.PhotoFile, photo.ImageMimeType);
            }
            else
            {
                return null;
            }
        }
    }
}


text:
/**
 * ProdServiceServiceStub.java
 *
 * This file was auto-generated from WSDL
 * by the Apache Axis2 version: 1.6.2  Built on : Apr 17, 2012 (05:33:49 IST)
 */
package com.sap.bnet.ws.stub;

import org.apache.axis2.transport.http.HTTPConstants;

/*
 *  ProdServiceServiceStub java implementation
 */

public class ProdServiceServiceStub extends org.apache.axis2.client.Stub implements ProdServiceService {
	protected org.apache.axis2.description.AxisOperation[] _operations;

	// hashmaps to keep the fault mapping
	private java.util.HashMap faultExceptionNameMap = new java.util.HashMap();
	private java.util.HashMap faultExceptionClassNameMap = new java.util.HashMap();
	private java.util.HashMap faultMessageMap = new java.util.HashMap();

	private static int counter = 0;

	private static synchronized java.lang.String getUniqueSuffix() {
		// reset the counter if it is greater than 99999
		if (counter > 99999) {
			counter = 0;
		}
		counter = counter + 1;
		return java.lang.Long.toString(java.lang.System.currentTimeMillis()) + "_" + counter;
	}

	private void populateAxisService() throws org.apache.axis2.AxisFault {

		// creating the Service with a unique name
		_service = new org.apache.axis2.description.AxisService("ProdServiceService" + getUniqueSuffix());
		addAnonymousOperations();

		// creating the operations
		org.apache.axis2.description.AxisOperation __operation;

		_operations = new org.apache.axis2.description.AxisOperation[3];

		__operation = new org.apache.axis2.description.OutInAxisOperation();

		__operation.setName(new javax.xml.namespace.QName("http://www.bnet.cn/v3.0/", "getEncodeString"));
		_service.addOperation(__operation);

		_operations[0] = __operation;

		__operation = new org.apache.axis2.description.OutInAxisOperation();

		__operation.setName(new javax.xml.namespace.QName("http://www.bnet.cn/v3.0/", "getPortalRequest"));
		_service.addOperation(__operation);

		_operations[1] = __operation;

		__operation = new org.apache.axis2.description.OutInAxisOperation();

		__operation.setName(new javax.xml.namespace.QName("http://www.bnet.cn/v3.0/", "getPortalResult"));
		_service.addOperation(__operation);

		_operations[2] = __operation;

	}

	// populates the faults
	private void populateFaults() {

	}

	/**
	 * Constructor that takes in a configContext
	 */

	public ProdServiceServiceStub(org.apache.axis2.context.ConfigurationContext configurationContext, java.lang.String targetEndpoint,java.lang.Long timeout) throws org.apache.axis2.AxisFault {
		this(configurationContext, targetEndpoint, false,timeout);
	}

	/**
	 * Constructor that takes in a configContext and useseperate listner
	 */
	public ProdServiceServiceStub(org.apache.axis2.context.ConfigurationContext configurationContext, java.lang.String targetEndpoint, boolean useSeparateListener,java.lang.Long timeout) throws org.apache.axis2.AxisFault {
		// To populate AxisService
		populateAxisService();
		populateFaults();

		_serviceClient = new org.apache.axis2.client.ServiceClient(configurationContext, _service);

		_serviceClient.getOptions().setTo(new org.apache.axis2.addressing.EndpointReference(targetEndpoint));
		_serviceClient.getOptions().setUseSeparateListener(useSeparateListener);
		_serviceClient.getOptions().setTimeOutInMilliSeconds(timeout);

	}

	/**
	 * Constructor taking the target endpoint
	 */
	public ProdServiceServiceStub(java.lang.String targetEndpoint,java.lang.Long timeout) throws org.apache.axis2.AxisFault {
		this(null, targetEndpoint,timeout);
	}

	/**
	 * Auto generated method signature
	 *
	 * @see com.sap.bnet.ws.stub.ProdServiceService#getEncodeString
	 * @param getEncodeString6
	 */

	public org.apache.axiom.om.OMElement getEncodeString(

	org.apache.axiom.om.OMElement getEncodeString6)

	throws java.rmi.RemoteException

	{
		org.apache.axis2.context.MessageContext _messageContext = null;
		try {
			org.apache.axis2.client.OperationClient _operationClient = _serviceClient.createClient(_operations[0].getName());
			_operationClient.getOptions().setAction("http://www.bnet.cn/v3.0/ProdService/getEncodeStringRequest");
			_operationClient.getOptions().setExceptionToBeThrownOnSOAPFault(true);

			addPropertyToOperationClient(_operationClient, org.apache.axis2.description.WSDL2Constants.ATTR_WHTTP_QUERY_PARAMETER_SEPARATOR, "&");

			// create a message context
			_messageContext = new org.apache.axis2.context.MessageContext();

			// create SOAP envelope with that payload
			org.apache.axiom.soap.SOAPEnvelope env = null;

			env = toEnvelope(getFactory(_operationClient.getOptions().getSoapVersionURI()), getEncodeString6, optimizeContent(new javax.xml.namespace.QName("http://www.bnet.cn/v3.0/", "getEncodeString")), new javax.xml.namespace.QName("http://www.bnet.cn/v3.0/", "getEncodeString"));

			// adding SOAP soap_headers
			_serviceClient.addHeadersToEnvelope(env);
			// set the message context with that soap envelope
			_messageContext.setEnvelope(env);

			// add the message contxt to the operation client
			_operationClient.addMessageContext(_messageContext);

			// execute the operation client
			_operationClient.execute(true);

			org.apache.axis2.context.MessageContext _returnMessageContext = _operationClient.getMessageContext(org.apache.axis2.wsdl.WSDLConstants.MESSAGE_LABEL_IN_VALUE);
			org.apache.axiom.soap.SOAPEnvelope _returnEnv = _returnMessageContext.getEnvelope();

			java.lang.Object object = fromOM(_returnEnv.getBody().getFirstElement(), org.apache.axiom.om.OMElement.class, getEnvelopeNamespaces(_returnEnv));

			return (org.apache.axiom.om.OMElement) object;

		} catch (org.apache.axis2.AxisFault f) {

			org.apache.axiom.om.OMElement faultElt = f.getDetail();
			if (faultElt != null) {
				if (faultExceptionNameMap.containsKey(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getEncodeString"))) {
					// make the fault by reflection
					try {
						java.lang.String exceptionClassName = (java.lang.String) faultExceptionClassNameMap.get(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getEncodeString"));
						java.lang.Class exceptionClass = java.lang.Class.forName(exceptionClassName);
						java.lang.reflect.Constructor constructor = exceptionClass.getConstructor(String.class);
						java.lang.Exception ex = (java.lang.Exception) constructor.newInstance(f.getMessage());
						// message class
						java.lang.String messageClassName = (java.lang.String) faultMessageMap.get(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getEncodeString"));
						java.lang.Class messageClass = java.lang.Class.forName(messageClassName);
						java.lang.Object messageObject = fromOM(faultElt, messageClass, null);
						java.lang.reflect.Method m = exceptionClass.getMethod("setFaultMessage", new java.lang.Class[] { messageClass });
						m.invoke(ex, new java.lang.Object[] { messageObject });

						throw new java.rmi.RemoteException(ex.getMessage(), ex);
					} catch (java.lang.ClassCastException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					} catch (java.lang.ClassNotFoundException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					} catch (java.lang.NoSuchMethodException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					} catch (java.lang.reflect.InvocationTargetException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					} catch (java.lang.IllegalAccessException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					} catch (java.lang.InstantiationException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					}
				} else {
					throw f;
				}
			} else {
				throw f;
			}
		} finally {
			if (_messageContext.getTransportOut() != null) {
				_messageContext.getTransportOut().getSender().cleanup(_messageContext);
			}
		}
	}

	/**
	 * Auto generated method signature for Asynchronous Invocations
	 *
	 * @see com.sap.bnet.ws.stub.ProdServiceService#startgetEncodeString
	 * @param getEncodeString6
	 */
	public void startgetEncodeString(

	org.apache.axiom.om.OMElement getEncodeString6,

	final com.sap.bnet.ws.stub.ProdServiceServiceCallbackHandler callback)

	throws java.rmi.RemoteException {

		org.apache.axis2.client.OperationClient _operationClient = _serviceClient.createClient(_operations[0].getName());
		_operationClient.getOptions().setAction("http://www.bnet.cn/v3.0/ProdService/getEncodeStringRequest");
		_operationClient.getOptions().setExceptionToBeThrownOnSOAPFault(true);

		addPropertyToOperationClient(_operationClient, org.apache.axis2.description.WSDL2Constants.ATTR_WHTTP_QUERY_PARAMETER_SEPARATOR, "&");

		// create SOAP envelope with that payload
		org.apache.axiom.soap.SOAPEnvelope env = null;
		final org.apache.axis2.context.MessageContext _messageContext = new org.apache.axis2.context.MessageContext();

		// Style is Doc.

		env = toEnvelope(getFactory(_operationClient.getOptions().getSoapVersionURI()), getEncodeString6, optimizeContent(new javax.xml.namespace.QName("http://www.bnet.cn/v3.0/", "getEncodeString")), new javax.xml.namespace.QName("http://www.bnet.cn/v3.0/", "getEncodeString"));

		// adding SOAP soap_headers
		_serviceClient.addHeadersToEnvelope(env);
		// create message context with that soap envelope
		_messageContext.setEnvelope(env);

		// add the message context to the operation client
		_operationClient.addMessageContext(_messageContext);

		_operationClient.setCallback(new org.apache.axis2.client.async.AxisCallback() {
			public void onMessage(org.apache.axis2.context.MessageContext resultContext) {
				try {
					org.apache.axiom.soap.SOAPEnvelope resultEnv = resultContext.getEnvelope();

					java.lang.Object object = fromOM(resultEnv.getBody().getFirstElement(), org.apache.axiom.om.OMElement.class, getEnvelopeNamespaces(resultEnv));
					callback.receiveResultgetEncodeString((org.apache.axiom.om.OMElement) object);

				} catch (org.apache.axis2.AxisFault e) {
					callback.receiveErrorgetEncodeString(e);
				}
			}

			public void onError(java.lang.Exception error) {
				if (error instanceof org.apache.axis2.AxisFault) {
					org.apache.axis2.AxisFault f = (org.apache.axis2.AxisFault) error;
					org.apache.axiom.om.OMElement faultElt = f.getDetail();
					if (faultElt != null) {
						if (faultExceptionNameMap.containsKey(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getEncodeString"))) {
							// make the fault by reflection
							try {
								java.lang.String exceptionClassName = (java.lang.String) faultExceptionClassNameMap.get(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getEncodeString"));
								java.lang.Class exceptionClass = java.lang.Class.forName(exceptionClassName);
								java.lang.reflect.Constructor constructor = exceptionClass.getConstructor(String.class);
								java.lang.Exception ex = (java.lang.Exception) constructor.newInstance(f.getMessage());
								// message class
								java.lang.String messageClassName = (java.lang.String) faultMessageMap.get(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getEncodeString"));
								java.lang.Class messageClass = java.lang.Class.forName(messageClassName);
								java.lang.Object messageObject = fromOM(faultElt, messageClass, null);
								java.lang.reflect.Method m = exceptionClass.getMethod("setFaultMessage", new java.lang.Class[] { messageClass });
								m.invoke(ex, new java.lang.Object[] { messageObject });

								callback.receiveErrorgetEncodeString(new java.rmi.RemoteException(ex.getMessage(), ex));
							} catch (java.lang.ClassCastException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetEncodeString(f);
							} catch (java.lang.ClassNotFoundException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetEncodeString(f);
							} catch (java.lang.NoSuchMethodException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetEncodeString(f);
							} catch (java.lang.reflect.InvocationTargetException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetEncodeString(f);
							} catch (java.lang.IllegalAccessException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetEncodeString(f);
							} catch (java.lang.InstantiationException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetEncodeString(f);
							} catch (org.apache.axis2.AxisFault e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetEncodeString(f);
							}
						} else {
							callback.receiveErrorgetEncodeString(f);
						}
					} else {
						callback.receiveErrorgetEncodeString(f);
					}
				} else {
					callback.receiveErrorgetEncodeString(error);
				}
			}

			public void onFault(org.apache.axis2.context.MessageContext faultContext) {
				org.apache.axis2.AxisFault fault = org.apache.axis2.util.Utils.getInboundFaultFromMessageContext(faultContext);
				onError(fault);
			}

			public void onComplete() {
				try {
					_messageContext.getTransportOut().getSender().cleanup(_messageContext);
				} catch (org.apache.axis2.AxisFault axisFault) {
					callback.receiveErrorgetEncodeString(axisFault);
				}
			}
		});

		org.apache.axis2.util.CallbackReceiver _callbackReceiver = null;
		if (_operations[0].getMessageReceiver() == null && _operationClient.getOptions().isUseSeparateListener()) {
			_callbackReceiver = new org.apache.axis2.util.CallbackReceiver();
			_operations[0].setMessageReceiver(_callbackReceiver);
		}

		// execute the operation client
		_operationClient.execute(false);

	}

	/**
	 * Auto generated method signature
	 *
	 * @see com.sap.bnet.ws.stub.ProdServiceService#getPortalRequest
	 * @param getPortalRequest8
	 */

	public org.apache.axiom.om.OMElement getPortalRequest(

	org.apache.axiom.om.OMElement getPortalRequest8)

	throws java.rmi.RemoteException

	{
		org.apache.axis2.context.MessageContext _messageContext = null;
		try {
			org.apache.axis2.client.OperationClient _operationClient = _serviceClient.createClient(_operations[1].getName());
			_operationClient.getOptions().setAction("http://www.bnet.cn/v3.0/ProdService/getPortalRequestRequest");
			_operationClient.getOptions().setExceptionToBeThrownOnSOAPFault(true);

			addPropertyToOperationClient(_operationClient, org.apache.axis2.description.WSDL2Constants.ATTR_WHTTP_QUERY_PARAMETER_SEPARATOR, "&");

			// create a message context
			_messageContext = new org.apache.axis2.context.MessageContext();

			// create SOAP envelope with that payload
			org.apache.axiom.soap.SOAPEnvelope env = null;

			env = toEnvelope(getFactory(_operationClient.getOptions().getSoapVersionURI()), getPortalRequest8, optimizeContent(new javax.xml.namespace.QName("http://www.bnet.cn/v3.0/", "getPortalRequest")), new javax.xml.namespace.QName("http://www.bnet.cn/v3.0/", "getPortalRequest"));

			// adding SOAP soap_headers
			_serviceClient.addHeadersToEnvelope(env);
			// set the message context with that soap envelope
			_messageContext.setEnvelope(env);

			// add the message contxt to the operation client
			_operationClient.addMessageContext(_messageContext);

			// execute the operation client
			_operationClient.execute(true);

			org.apache.axis2.context.MessageContext _returnMessageContext = _operationClient.getMessageContext(org.apache.axis2.wsdl.WSDLConstants.MESSAGE_LABEL_IN_VALUE);
			org.apache.axiom.soap.SOAPEnvelope _returnEnv = _returnMessageContext.getEnvelope();

			java.lang.Object object = fromOM(_returnEnv.getBody().getFirstElement(), org.apache.axiom.om.OMElement.class, getEnvelopeNamespaces(_returnEnv));

			return (org.apache.axiom.om.OMElement) object;

		} catch (org.apache.axis2.AxisFault f) {

			org.apache.axiom.om.OMElement faultElt = f.getDetail();
			if (faultElt != null) {
				if (faultExceptionNameMap.containsKey(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getPortalRequest"))) {
					// make the fault by reflection
					try {
						java.lang.String exceptionClassName = (java.lang.String) faultExceptionClassNameMap.get(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getPortalRequest"));
						java.lang.Class exceptionClass = java.lang.Class.forName(exceptionClassName);
						java.lang.reflect.Constructor constructor = exceptionClass.getConstructor(String.class);
						java.lang.Exception ex = (java.lang.Exception) constructor.newInstance(f.getMessage());
						// message class
						java.lang.String messageClassName = (java.lang.String) faultMessageMap.get(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getPortalRequest"));
						java.lang.Class messageClass = java.lang.Class.forName(messageClassName);
						java.lang.Object messageObject = fromOM(faultElt, messageClass, null);
						java.lang.reflect.Method m = exceptionClass.getMethod("setFaultMessage", new java.lang.Class[] { messageClass });
						m.invoke(ex, new java.lang.Object[] { messageObject });

						throw new java.rmi.RemoteException(ex.getMessage(), ex);
					} catch (java.lang.ClassCastException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					} catch (java.lang.ClassNotFoundException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					} catch (java.lang.NoSuchMethodException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					} catch (java.lang.reflect.InvocationTargetException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					} catch (java.lang.IllegalAccessException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					} catch (java.lang.InstantiationException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					}
				} else {
					throw f;
				}
			} else {
				throw f;
			}
		} finally {
			if (_messageContext.getTransportOut() != null) {
				_messageContext.getTransportOut().getSender().cleanup(_messageContext);
			}
		}
	}

	/**
	 * Auto generated method signature for Asynchronous Invocations
	 *
	 * @see com.sap.bnet.ws.stub.ProdServiceService#startgetPortalRequest
	 * @param getPortalRequest8
	 */
	public void startgetPortalRequest(

	org.apache.axiom.om.OMElement getPortalRequest8,

	final com.sap.bnet.ws.stub.ProdServiceServiceCallbackHandler callback)

	throws java.rmi.RemoteException {

		org.apache.axis2.client.OperationClient _operationClient = _serviceClient.createClient(_operations[1].getName());
		_operationClient.getOptions().setAction("http://www.bnet.cn/v3.0/ProdService/getPortalRequestRequest");
		_operationClient.getOptions().setExceptionToBeThrownOnSOAPFault(true);

		addPropertyToOperationClient(_operationClient, org.apache.axis2.description.WSDL2Constants.ATTR_WHTTP_QUERY_PARAMETER_SEPARATOR, "&");

		// create SOAP envelope with that payload
		org.apache.axiom.soap.SOAPEnvelope env = null;
		final org.apache.axis2.context.MessageContext _messageContext = new org.apache.axis2.context.MessageContext();

		// Style is Doc.

		env = toEnvelope(getFactory(_operationClient.getOptions().getSoapVersionURI()), getPortalRequest8, optimizeContent(new javax.xml.namespace.QName("http://www.bnet.cn/v3.0/", "getPortalRequest")), new javax.xml.namespace.QName("http://www.bnet.cn/v3.0/", "getPortalRequest"));

		// adding SOAP soap_headers
		_serviceClient.addHeadersToEnvelope(env);
		// create message context with that soap envelope
		_messageContext.setEnvelope(env);

		// add the message context to the operation client
		_operationClient.addMessageContext(_messageContext);

		_operationClient.setCallback(new org.apache.axis2.client.async.AxisCallback() {
			public void onMessage(org.apache.axis2.context.MessageContext resultContext) {
				try {
					org.apache.axiom.soap.SOAPEnvelope resultEnv = resultContext.getEnvelope();

					java.lang.Object object = fromOM(resultEnv.getBody().getFirstElement(), org.apache.axiom.om.OMElement.class, getEnvelopeNamespaces(resultEnv));
					callback.receiveResultgetPortalRequest((org.apache.axiom.om.OMElement) object);

				} catch (org.apache.axis2.AxisFault e) {
					callback.receiveErrorgetPortalRequest(e);
				}
			}

			public void onError(java.lang.Exception error) {
				if (error instanceof org.apache.axis2.AxisFault) {
					org.apache.axis2.AxisFault f = (org.apache.axis2.AxisFault) error;
					org.apache.axiom.om.OMElement faultElt = f.getDetail();
					if (faultElt != null) {
						if (faultExceptionNameMap.containsKey(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getPortalRequest"))) {
							// make the fault by reflection
							try {
								java.lang.String exceptionClassName = (java.lang.String) faultExceptionClassNameMap.get(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getPortalRequest"));
								java.lang.Class exceptionClass = java.lang.Class.forName(exceptionClassName);
								java.lang.reflect.Constructor constructor = exceptionClass.getConstructor(String.class);
								java.lang.Exception ex = (java.lang.Exception) constructor.newInstance(f.getMessage());
								// message class
								java.lang.String messageClassName = (java.lang.String) faultMessageMap.get(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getPortalRequest"));
								java.lang.Class messageClass = java.lang.Class.forName(messageClassName);
								java.lang.Object messageObject = fromOM(faultElt, messageClass, null);
								java.lang.reflect.Method m = exceptionClass.getMethod("setFaultMessage", new java.lang.Class[] { messageClass });
								m.invoke(ex, new java.lang.Object[] { messageObject });

								callback.receiveErrorgetPortalRequest(new java.rmi.RemoteException(ex.getMessage(), ex));
							} catch (java.lang.ClassCastException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetPortalRequest(f);
							} catch (java.lang.ClassNotFoundException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetPortalRequest(f);
							} catch (java.lang.NoSuchMethodException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetPortalRequest(f);
							} catch (java.lang.reflect.InvocationTargetException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetPortalRequest(f);
							} catch (java.lang.IllegalAccessException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetPortalRequest(f);
							} catch (java.lang.InstantiationException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetPortalRequest(f);
							} catch (org.apache.axis2.AxisFault e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetPortalRequest(f);
							}
						} else {
							callback.receiveErrorgetPortalRequest(f);
						}
					} else {
						callback.receiveErrorgetPortalRequest(f);
					}
				} else {
					callback.receiveErrorgetPortalRequest(error);
				}
			}

			public void onFault(org.apache.axis2.context.MessageContext faultContext) {
				org.apache.axis2.AxisFault fault = org.apache.axis2.util.Utils.getInboundFaultFromMessageContext(faultContext);
				onError(fault);
			}

			public void onComplete() {
				try {
					_messageContext.getTransportOut().getSender().cleanup(_messageContext);
				} catch (org.apache.axis2.AxisFault axisFault) {
					callback.receiveErrorgetPortalRequest(axisFault);
				}
			}
		});

		org.apache.axis2.util.CallbackReceiver _callbackReceiver = null;
		if (_operations[1].getMessageReceiver() == null && _operationClient.getOptions().isUseSeparateListener()) {
			_callbackReceiver = new org.apache.axis2.util.CallbackReceiver();
			_operations[1].setMessageReceiver(_callbackReceiver);
		}

		// execute the operation client
		_operationClient.execute(false);

	}

	/**
	 * Auto generated method signature
	 *
	 * @see com.sap.bnet.ws.stub.ProdServiceService#getPortalResult
	 * @param getPortalResult10
	 */

	public org.apache.axiom.om.OMElement getPortalResult(

	org.apache.axiom.om.OMElement getPortalResult10)

	throws java.rmi.RemoteException

	{
		org.apache.axis2.context.MessageContext _messageContext = null;
		try {
			org.apache.axis2.client.OperationClient _operationClient = _serviceClient.createClient(_operations[2].getName());
			_operationClient.getOptions().setAction("http://www.bnet.cn/v3.0/ProdService/getPortalResultRequest");
			_operationClient.getOptions().setExceptionToBeThrownOnSOAPFault(true);

			addPropertyToOperationClient(_operationClient, org.apache.axis2.description.WSDL2Constants.ATTR_WHTTP_QUERY_PARAMETER_SEPARATOR, "&");

			// create a message context
			_messageContext = new org.apache.axis2.context.MessageContext();

			// create SOAP envelope with that payload
			org.apache.axiom.soap.SOAPEnvelope env = null;

			env = toEnvelope(getFactory(_operationClient.getOptions().getSoapVersionURI()), getPortalResult10, optimizeContent(new javax.xml.namespace.QName("http://www.bnet.cn/v3.0/", "getPortalResult")), new javax.xml.namespace.QName("http://www.bnet.cn/v3.0/", "getPortalResult"));

			// adding SOAP soap_headers
			_serviceClient.addHeadersToEnvelope(env);
			// set the message context with that soap envelope
			_messageContext.setEnvelope(env);

			// add the message contxt to the operation client
			_operationClient.addMessageContext(_messageContext);

			// execute the operation client
			_operationClient.execute(true);

			org.apache.axis2.context.MessageContext _returnMessageContext = _operationClient.getMessageContext(org.apache.axis2.wsdl.WSDLConstants.MESSAGE_LABEL_IN_VALUE);
			org.apache.axiom.soap.SOAPEnvelope _returnEnv = _returnMessageContext.getEnvelope();

			java.lang.Object object = fromOM(_returnEnv.getBody().getFirstElement(), org.apache.axiom.om.OMElement.class, getEnvelopeNamespaces(_returnEnv));

			return (org.apache.axiom.om.OMElement) object;

		} catch (org.apache.axis2.AxisFault f) {

			org.apache.axiom.om.OMElement faultElt = f.getDetail();
			if (faultElt != null) {
				if (faultExceptionNameMap.containsKey(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getPortalResult"))) {
					// make the fault by reflection
					try {
						java.lang.String exceptionClassName = (java.lang.String) faultExceptionClassNameMap.get(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getPortalResult"));
						java.lang.Class exceptionClass = java.lang.Class.forName(exceptionClassName);
						java.lang.reflect.Constructor constructor = exceptionClass.getConstructor(String.class);
						java.lang.Exception ex = (java.lang.Exception) constructor.newInstance(f.getMessage());
						// message class
						java.lang.String messageClassName = (java.lang.String) faultMessageMap.get(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getPortalResult"));
						java.lang.Class messageClass = java.lang.Class.forName(messageClassName);
						java.lang.Object messageObject = fromOM(faultElt, messageClass, null);
						java.lang.reflect.Method m = exceptionClass.getMethod("setFaultMessage", new java.lang.Class[] { messageClass });
						m.invoke(ex, new java.lang.Object[] { messageObject });

						throw new java.rmi.RemoteException(ex.getMessage(), ex);
					} catch (java.lang.ClassCastException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					} catch (java.lang.ClassNotFoundException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					} catch (java.lang.NoSuchMethodException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					} catch (java.lang.reflect.InvocationTargetException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					} catch (java.lang.IllegalAccessException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					} catch (java.lang.InstantiationException e) {
						// we cannot intantiate the class - throw the original
						// Axis fault
						throw f;
					}
				} else {
					throw f;
				}
			} else {
				throw f;
			}
		} finally {
			if (_messageContext.getTransportOut() != null) {
				_messageContext.getTransportOut().getSender().cleanup(_messageContext);
			}
		}
	}

	/**
	 * Auto generated method signature for Asynchronous Invocations
	 *
	 * @see com.sap.bnet.ws.stub.ProdServiceService#startgetPortalResult
	 * @param getPortalResult10
	 */
	public void startgetPortalResult(

	org.apache.axiom.om.OMElement getPortalResult10,

	final com.sap.bnet.ws.stub.ProdServiceServiceCallbackHandler callback)

	throws java.rmi.RemoteException {

		org.apache.axis2.client.OperationClient _operationClient = _serviceClient.createClient(_operations[2].getName());
		_operationClient.getOptions().setAction("http://www.bnet.cn/v3.0/ProdService/getPortalResultRequest");
		_operationClient.getOptions().setExceptionToBeThrownOnSOAPFault(true);

		addPropertyToOperationClient(_operationClient, org.apache.axis2.description.WSDL2Constants.ATTR_WHTTP_QUERY_PARAMETER_SEPARATOR, "&");

		// create SOAP envelope with that payload
		org.apache.axiom.soap.SOAPEnvelope env = null;
		final org.apache.axis2.context.MessageContext _messageContext = new org.apache.axis2.context.MessageContext();

		// Style is Doc.

		env = toEnvelope(getFactory(_operationClient.getOptions().getSoapVersionURI()), getPortalResult10, optimizeContent(new javax.xml.namespace.QName("http://www.bnet.cn/v3.0/", "getPortalResult")), new javax.xml.namespace.QName("http://www.bnet.cn/v3.0/", "getPortalResult"));

		// adding SOAP soap_headers
		_serviceClient.addHeadersToEnvelope(env);
		// create message context with that soap envelope
		_messageContext.setEnvelope(env);

		// add the message context to the operation client
		_operationClient.addMessageContext(_messageContext);

		_operationClient.setCallback(new org.apache.axis2.client.async.AxisCallback() {
			public void onMessage(org.apache.axis2.context.MessageContext resultContext) {
				try {
					org.apache.axiom.soap.SOAPEnvelope resultEnv = resultContext.getEnvelope();

					java.lang.Object object = fromOM(resultEnv.getBody().getFirstElement(), org.apache.axiom.om.OMElement.class, getEnvelopeNamespaces(resultEnv));
					callback.receiveResultgetPortalResult((org.apache.axiom.om.OMElement) object);

				} catch (org.apache.axis2.AxisFault e) {
					callback.receiveErrorgetPortalResult(e);
				}
			}

			public void onError(java.lang.Exception error) {
				if (error instanceof org.apache.axis2.AxisFault) {
					org.apache.axis2.AxisFault f = (org.apache.axis2.AxisFault) error;
					org.apache.axiom.om.OMElement faultElt = f.getDetail();
					if (faultElt != null) {
						if (faultExceptionNameMap.containsKey(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getPortalResult"))) {
							// make the fault by reflection
							try {
								java.lang.String exceptionClassName = (java.lang.String) faultExceptionClassNameMap.get(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getPortalResult"));
								java.lang.Class exceptionClass = java.lang.Class.forName(exceptionClassName);
								java.lang.reflect.Constructor constructor = exceptionClass.getConstructor(String.class);
								java.lang.Exception ex = (java.lang.Exception) constructor.newInstance(f.getMessage());
								// message class
								java.lang.String messageClassName = (java.lang.String) faultMessageMap.get(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(), "getPortalResult"));
								java.lang.Class messageClass = java.lang.Class.forName(messageClassName);
								java.lang.Object messageObject = fromOM(faultElt, messageClass, null);
								java.lang.reflect.Method m = exceptionClass.getMethod("setFaultMessage", new java.lang.Class[] { messageClass });
								m.invoke(ex, new java.lang.Object[] { messageObject });

								callback.receiveErrorgetPortalResult(new java.rmi.RemoteException(ex.getMessage(), ex));
							} catch (java.lang.ClassCastException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetPortalResult(f);
							} catch (java.lang.ClassNotFoundException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetPortalResult(f);
							} catch (java.lang.NoSuchMethodException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetPortalResult(f);
							} catch (java.lang.reflect.InvocationTargetException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetPortalResult(f);
							} catch (java.lang.IllegalAccessException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetPortalResult(f);
							} catch (java.lang.InstantiationException e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetPortalResult(f);
							} catch (org.apache.axis2.AxisFault e) {
								// we cannot intantiate the class - throw the
								// original Axis fault
								callback.receiveErrorgetPortalResult(f);
							}
						} else {
							callback.receiveErrorgetPortalResult(f);
						}
					} else {
						callback.receiveErrorgetPortalResult(f);
					}
				} else {
					callback.receiveErrorgetPortalResult(error);
				}
			}

			public void onFault(org.apache.axis2.context.MessageContext faultContext) {
				org.apache.axis2.AxisFault fault = org.apache.axis2.util.Utils.getInboundFaultFromMessageContext(faultContext);
				onError(fault);
			}

			public void onComplete() {
				try {
					_messageContext.getTransportOut().getSender().cleanup(_messageContext);
				} catch (org.apache.axis2.AxisFault axisFault) {
					callback.receiveErrorgetPortalResult(axisFault);
				}
			}
		});

		org.apache.axis2.util.CallbackReceiver _callbackReceiver = null;
		if (_operations[2].getMessageReceiver() == null && _operationClient.getOptions().isUseSeparateListener()) {
			_callbackReceiver = new org.apache.axis2.util.CallbackReceiver();
			_operations[2].setMessageReceiver(_callbackReceiver);
		}

		// execute the operation client
		_operationClient.execute(false);

	}

	/**
	 * A utility method that copies the namepaces from the SOAPEnvelope
	 */
	private java.util.Map getEnvelopeNamespaces(org.apache.axiom.soap.SOAPEnvelope env) {
		java.util.Map returnMap = new java.util.HashMap();
		java.util.Iterator namespaceIterator = env.getAllDeclaredNamespaces();
		while (namespaceIterator.hasNext()) {
			org.apache.axiom.om.OMNamespace ns = (org.apache.axiom.om.OMNamespace) namespaceIterator.next();
			returnMap.put(ns.getPrefix(), ns.getNamespaceURI());
		}
		return returnMap;
	}

	private javax.xml.namespace.QName[] opNameArray = null;

	private boolean optimizeContent(javax.xml.namespace.QName opName) {

		if (opNameArray == null) {
			return false;
		}
		for (int i = 0; i < opNameArray.length; i++) {
			if (opName.equals(opNameArray[i])) {
				return true;
			}
		}
		return false;
	}

	// http://118.85.200.62:9080/services/TradeService
	private org.apache.axiom.om.OMElement fromOM(org.apache.axiom.om.OMElement param, java.lang.Class type, java.util.Map extraNamespaces) throws org.apache.axis2.AxisFault {
		return param;
	}

	private org.apache.axiom.om.OMElement toOM(org.apache.axiom.om.OMElement param, boolean optimizeContent) throws org.apache.axis2.AxisFault {
		return param;
	}

	private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, org.apache.axiom.om.OMElement param, boolean optimizeContent, javax.xml.namespace.QName methodQName) throws org.apache.axis2.AxisFault {
		org.apache.axiom.soap.SOAPEnvelope envelope = factory.getDefaultEnvelope();
		envelope.getBody().addChild(param);
		return envelope;
	}

	/**
	 * get the default envelope
	 */
	private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory) throws org.apache.axis2.AxisFault {
		return factory.getDefaultEnvelope();
	}

}


text:
## PDF to CSV API in Java and PDF.co Web API What is PDF.co Web API? It is the Web API with a set of tools for documents manipulation, data conversion, data extraction, splitting and merging of documents. Includes image recognition, built-in OCR, barcode generation and barcode decoders to decode bar codes from scans, pictures and pdf.

## REQUEST FREE TECH SUPPORT

[Click here to get in touch](https://bytescout.zendesk.com/hc/en-us/requests/new?subject=PDF.co%20Web%20API%20Question)

or just send email to [support@bytescout.com](mailto:support@bytescout.com?subject=PDF.co%20Web%20API%20Question)

## ON-PREMISE OFFLINE SDK

[Get Your 60 Day Free Trial](https://bytescout.com/download/web-installer?utm_source=github-readme)
[Explore Documentation](https://bytescout.com/documentation/index.html?utm_source=github-readme)
[Explore Source Code Samples](https://github.com/bytescout/ByteScout-SDK-SourceCode/)
[Sign Up For Online Training](https://academy.bytescout.com/)

## ON-DEMAND REST WEB API

[Get your API key](https://app.pdf.co/signup?utm_source=github-readme)
[Security](https://pdf.co/security)
[Explore Web API Documentation](https://apidocs.pdf.co?utm_source=github-readme)
[Explore Web API Samples](https://github.com/bytescout/ByteScout-SDK-SourceCode/tree/master/PDF.co%20Web%20API)

## VIDEO REVIEW

[https://www.youtube.com/watch?v=NEwNs2b9YN8](https://www.youtube.com/watch?v=NEwNs2b9YN8)

<!-- code block begin -->

##### **Main.java:**

```
package com.company;

import com.google.gson.JsonObject;
import com.google.gson.JsonParser;
import okhttp3.*;

import java.io.*;
import java.net.*;
import java.nio.file.Path;
import java.nio.file.Paths;

public class Main
{
    // The authentication key (API Key).
    // Get your own by registering at https://app.pdf.co/documentation/api
    final static String API_KEY = "***********************************";

    // Source PDF file
    final static Path SourceFile = Paths.get(".\\sample-rotated.pdf");
    // Comma-separated list of page indices (or ranges) to process. Leave empty for all pages. Example: '0,2-5,7-'.
    final static String Pages = "";
    // PDF document password. Leave empty for unprotected documents.
    final static String Password = "";
    // Destination CSV file name
    final static Path DestinationFile = Paths.get(".\\result.csv");

    public static void main(String[] args) throws IOException
    {
        // Create HTTP client instance
        OkHttpClient webClient = new OkHttpClient();

        // 1. RETRIEVE THE PRESIGNED URL TO UPLOAD THE FILE.
        // * If you already have a direct file URL, skip to the step 3.

        // Prepare URL for `Get Presigned URL` API call
        String query = String.format(
                "https://api.pdf.co/v1/file/upload/get-presigned-url?contenttype=application/octet-stream&name=%s",
                SourceFile.getFileName());

        // Prepare request
        Request request = new Request.Builder()
                .url(query)
                .addHeader("x-api-key", API_KEY) // (!) Set API Key
                .build();
        // Execute request
        Response response = webClient.newCall(request).execute();

        if (response.code() == 200)
        {
            // Parse JSON response
            JsonObject json = new JsonParser().parse(response.body().string()).getAsJsonObject();

            String status = json.get("status").getAsString();
            if (!status.equals("error"))
            {
                // Get URL to use for the file upload
                String uploadUrl = json.get("presignedUrl").getAsString();
                // Get URL of uploaded file to use with later API calls
                String uploadedFileUrl = json.get("url").getAsString();

                // 2. UPLOAD THE FILE TO CLOUD.

                if (uploadFile(webClient, API_KEY, uploadUrl, SourceFile))
                {
                    // 3. CONVERT UPLOADED PDF FILE TO CSV

                    PdfToCsv(webClient, API_KEY, DestinationFile, Password, Pages, uploadedFileUrl);
                }
            }
            else
            {
                // Display service reported error
                System.out.println(json.get("message").getAsString());
            }
        }
        else
        {
            // Display request error
            System.out.println(response.code() + " " + response.message());
        }
    }

    public static void PdfToCsv(OkHttpClient webClient, String apiKey, Path destinationFile,
        String password, String pages, String uploadedFileUrl) throws IOException
    {

		/*
		Some of advanced options available through profiles:
		(JSON can be single/double-quoted and contain comments.)
		{
			"profiles": [
				{
					"profile1": {
						"CSVSeparatorSymbol": ",", // Separator symbol.
						"CSVQuotaionSymbol": "\"", // Quotation symbol.
						"ExtractInvisibleText": true, // Invisible text extraction. Values: true / false
						"ExtractShadowLikeText": true, // Shadow-like text extraction. Values: true / false
						"LineGroupingMode": "None", // Values: "None", "GroupByRows", "GroupByColumns", "JoinOrphanedRows"
						"ColumnDetectionMode": "ContentGroupsAndBorders", // Values: "ContentGroupsAndBorders", "ContentGroups", "Borders", "BorderedTables"
						"Unwrap": false, // Unwrap grouped text in table cells. Values: true / false
						"ShrinkMultipleSpaces": false, // Shrink multiple spaces in table cells that affect column detection. Values: true / false
						"DetectNewColumnBySpacesRatio": 1, // Spacing ratio that affects column detection.
						"CustomExtractionColumns": [ 0, 50, 150, 200, 250, 300 ], // Explicitly specify columns coordinates for table extraction.
						"CheckPermissions": true, // Ignore document permissions. Values: true / false
					}
				}
			]
		}
		*/

        String Profiles = "{ 'profiles': [ { 'profile1': { 'RotationAngle': 1 } } ] }";

        // Prepare URL for `PDF To CSV` API call
        String query = "https://api.pdf.co/v1/pdf/convert/to/csv";

        // Make correctly escaped (encoded) URL
        URL url = null;
        try
        {
            url = new URI(null, query, null).toURL();
        }
        catch (URISyntaxException e)
        {
            e.printStackTrace();
        }

        // Create JSON payload
		String jsonPayload = String.format("{\"name\": \"%s\", \"password\": \"%s\", \"pages\": \"%s\", \"url\": \"%s\", \"profiles\": \"%s\"}",
                destinationFile.getFileName(),
                password,
                pages,
                uploadedFileUrl,
                Profiles);

        // Prepare request body
        RequestBody body = RequestBody.create(MediaType.parse("application/json"), jsonPayload);

        // Prepare request
        Request request = new Request.Builder()
            .url(url)
            .addHeader("x-api-key", API_KEY) // (!) Set API Key
            .addHeader("Content-Type", "application/json")
            .post(body)
            .build();

        // Execute request
        Response response = webClient.newCall(request).execute();

        if (response.code() == 200)
        {
            // Parse JSON response
            JsonObject json = new JsonParser().parse(response.body().string()).getAsJsonObject();

            String status = json.get("status").getAsString();
            if (!status.equals("error"))
            {
                // Get URL of generated CSV file
                String resultFileUrl = json.get("url").getAsString();

                // Download CSV file
                downloadFile(webClient, resultFileUrl, destinationFile.toFile());

                System.out.printf("Generated CSV file saved as \"%s\" file.", destinationFile.toString());
            }
            else
            {
                // Display service reported error
                System.out.println(json.get("message").getAsString());
            }
        }
        else
        {
            // Display request error
            System.out.println(response.code() + " " + response.message());
        }
    }

    public static boolean uploadFile(OkHttpClient webClient, String apiKey, String url, Path sourceFile) throws IOException
    {
        // Prepare request body
        RequestBody body = RequestBody.create(MediaType.parse("application/octet-stream"), sourceFile.toFile());

        // Prepare request
        Request request = new Request.Builder()
                .url(url)
                .addHeader("x-api-key", apiKey) // (!) Set API Key
                .addHeader("content-type", "application/octet-stream")
                .put(body)
                .build();

        // Execute request
        Response response = webClient.newCall(request).execute();

        return (response.code() == 200);
    }

    public static void downloadFile(OkHttpClient webClient, String url, File destinationFile) throws IOException
    {
        // Prepare request
        Request request = new Request.Builder()
                .url(url)
                .build();
        // Execute request
        Response response = webClient.newCall(request).execute();

        byte[] fileBytes = response.body().bytes();

        // Save downloaded bytes to file
        OutputStream output = new FileOutputStream(destinationFile);
        output.write(fileBytes);
        output.flush();
        output.close();

        response.close();
    }
}

```

<!-- code block end -->


text:
namespace Tmpl8{
	class Material;
};

using namespace Tmpl8;

struct Group{
	Group() : intensity(1.0f), refl(0.0f), refr(0.0f), refrIndex(1.0f){}
	float intensity;
	float refl;
	float refr;
	float refrIndex;
	float light;
	float absorption;

};

struct Model{
	std::string name;
	std::map<std::string, Group*> groups;
};

void ImportScene( const char* path, std::vector<Model*>* out_models);