text:
/*!
 * @module commonGrpc/service
 */

'use strict';

var dotProp = require('dot-prop');
var duplexify = require('duplexify');
var extend = require('extend');
var googleProtoFiles = require('google-proto-files');
var grpc = require('grpc');
var is = require('is');
var nodeutil = require('util');
var path = require('path');
var retryRequest = require('retry-request');
var Service = require('@google-cloud/common').Service;
var through = require('through2');
var util = require('@google-cloud/common').util;

/**
 * @const {object} - A map of protobuf codes to HTTP status codes.
 * @private
 */
var GRPC_ERROR_CODE_TO_HTTP = {
  0: {
    code: 200,
    message: 'OK'
  },

  1: {
    code: 499,
    message: 'Client Closed Request'
  },

  2: {
    code: 500,
    message: 'Internal Server Error'
  },

  3: {
    code: 400,
    message: 'Bad Request'
  },

  4: {
    code: 504,
    message: 'Gateway Timeout'
  },

  5: {
    code: 404,
    message: 'Not Found'
  },

  6: {
    code: 409,
    message: 'Conflict'
  },

  7: {
    code: 403,
    message: 'Forbidden'
  },

  8: {
    code: 429,
    message: 'Too Many Requests'
  },

  9: {
    code: 412,
    message: 'Precondition Failed'
  },

  10: {
    code: 409,
    message: 'Conflict'
  },

  11: {
    code: 400,
    message: 'Bad Request'
  },

  12: {
    code: 501,
    message: 'Not Implemented'
  },

  13: {
    code: 500,
    message: 'Internal Server Error'
  },

  14: {
    code: 503,
    message: 'Service Unavailable'
  },

  15: {
    code: 500,
    message: 'Internal Server Error'
  },

  16: {
    code: 401,
    message: 'Unauthorized'
  }
};

/**
 * The default configuration for all gRPC requests.
 *
 * @resource [All options]{@link https://github.com/grpc/grpc/blob/13e185419cd177b7fb552601665e43820321a96b/include/grpc/impl/codegen/grpc_types.h#L148}
 *
 * @private
 *
 * @type {object}
 */
var GRPC_REQUEST_OPTIONS = {
  // RE: https://github.com/GoogleCloudPlatform/google-cloud-node/issues/1991
  'grpc.max_send_message_length': -1, // unlimited
  'grpc.max_receive_message_length': -1, // unlimited

  // RE: https://github.com/grpc/grpc/issues/8839
  // RE: https://github.com/grpc/grpc/issues/8382
  // RE: https://github.com/GoogleCloudPlatform/google-cloud-node/issues/1991
  'grpc.initial_reconnect_backoff_ms': 5000
};

/**
 * Service is a base class, meant to be inherited from by a "service," like
 * BigQuery or Storage.
 *
 * This handles making authenticated requests by exposing a `makeReq_` function.
 *
 * @constructor
 * @alias module:common/grpc-service
 *
 * @param {object} config - Configuration object.
 * @param {string} config.baseUrl - The base URL to make API requests to.
 * @param {object} config.grpcMetadata - Metadata to send with every request.
 * @param {string[]} config.scopes - The scopes required for the request.
 * @param {string} config.service - The name of the service.
 * @param {object=} config.protoServices - Directly provide the required proto
 *     files. This is useful when a single class requires multiple services.
 * @param {object} options - [Configuration object](#/docs/?method=gcloud).
 */
function GrpcService(config, options) {
  if (global.GCLOUD_SANDBOX_ENV) {
    // gRPC has a tendency to cause our doc unit tests to fail, so we prevent
    // any calls to that library from going through.
    // Reference: https://github.com/GoogleCloudPlatform/google-cloud-node/pull/1137#issuecomment-193315047
    return global.GCLOUD_SANDBOX_ENV;
  }

  Service.call(this, config, options);

  if (config.customEndpoint) {
    this.grpcCredentials = grpc.credentials.createInsecure();
  }

  this.grpcMetadata = new grpc.Metadata();

  if (config.grpcMetadata) {
    for (var prop in config.grpcMetadata) {
      if (config.grpcMetadata.hasOwnProperty(prop)) {
        this.grpcMetadata.add(prop, config.grpcMetadata[prop]);
      }
    }
  }

  this.maxRetries = options.maxRetries;
  this.userAgent = util.getUserAgentFromPackageJson(config.packageJson);

  var apiVersion = config.apiVersion;
  var service = this.service = config.service;

  this.activeServiceMap_ = new Map();
  this.protos = {};

  var protoServices = config.protoServices;

  if (!protoServices) {
    protoServices = {};
    protoServices[service] = googleProtoFiles[service][apiVersion];
  }

  var self = this;

  Object.keys(protoServices).forEach(function(name) {
    var protoConfig = protoServices[name];
    var service = self.loadProtoFile_(protoConfig, config);

    self.protos[name] = service;

    if (protoConfig.baseUrl) {
      service.baseUrl = protoConfig.baseUrl;
    }
  });
}

nodeutil.inherits(GrpcService, Service);

/**
 * Make an authenticated request with gRPC.
 *
 * @param {object} protoOpts - The proto options.
 * @param {string} protoOpts.service - The service name.
 * @param {string} protoOpts.method - The method name.
 * @param {number=} protoOpts.timeout - After how many milliseconds should the
 *     request cancel.
 * @param {object} reqOpts - The request options.
 * @param {function=} callback - The callback function.
 */
GrpcService.prototype.request = function(protoOpts, reqOpts, callback) {
  if (global.GCLOUD_SANDBOX_ENV) {
    return global.GCLOUD_SANDBOX_ENV;
  }

  var self = this;

  if (!this.grpcCredentials) {
    // We must establish an authClient to give to grpc.
    this.getGrpcCredentials_(function(err, credentials) {
      if (err) {
        callback(err);
        return;
      }

      self.grpcCredentials = credentials;
      self.request(protoOpts, reqOpts, callback);
    });

    return;
  }

  var service = this.getService_(protoOpts);
  var metadata = this.grpcMetadata;
  var grpcOpts = extend({}, GRPC_REQUEST_OPTIONS);

  if (is.number(protoOpts.timeout)) {
    grpcOpts.deadline = GrpcService.createDeadline_(protoOpts.timeout);
  }

  try {
    reqOpts = util.decorateRequest(reqOpts, { projectId: this.projectId });
  } catch(e) {
    callback(e);
    return;
  }

  // Retains a reference to an error from the response. If the final callback is
  // executed with this as the "response", we return it to the user as an error.
  var respError;

  var retryOpts = {
    retries: this.maxRetries,
    shouldRetryFn: GrpcService.shouldRetryRequest_,

    // retry-request determines if it should retry from the incoming HTTP
    // response status. gRPC always returns an error proto message. We pass that
    // "error" into retry-request to act as the HTTP response, so it can use the
    // status code to determine if it should retry.
    request: function(_, onResponse) {
      respError = null;

      return service[protoOpts.method](
        reqOpts,
        metadata,
        grpcOpts,
        function(err, resp) {
          if (err) {
            respError = GrpcService.decorateError_(err);

            if (respError) {
              onResponse(null, respError);
              return;
            }

            onResponse(err, resp);
            return;
          }

          onResponse(null, resp);
        });
    }
  };

  return retryRequest(null, retryOpts, function(err, resp) {
    if (!err && resp === respError) {
      err = respError;
      resp = null;
    }

    callback(err, resp);
  });
};

/**
 * Make an authenticated streaming request with gRPC.
 *
 * @param {object} protoOpts - The proto options.
 * @param {string} protoOpts.service - The service.
 * @param {string} protoOpts.method - The method name.
 * @param {number=} protoOpts.timeout - After how many milliseconds should the
 *     request cancel.
 * @param {object} reqOpts - The request options.
 */
GrpcService.prototype.requestStream = function(protoOpts, reqOpts) {
  if (global.GCLOUD_SANDBOX_ENV) {
    return through.obj();
  }

  var self = this;

  if (!protoOpts.stream) {
    protoOpts.stream = through.obj();
  }

  var stream = protoOpts.stream;

  if (!this.grpcCredentials) {
    // We must establish an authClient to give to grpc.
    this.getGrpcCredentials_(function(err, credentials) {
      if (err) {
        stream.destroy(err);
        return;
      }

      self.grpcCredentials = credentials;
      self.requestStream(protoOpts, reqOpts);
    });

    return stream;
  }

  var objectMode = !!reqOpts.objectMode;

  var service = this.getService_(protoOpts);
  var grpcMetadata = this.grpcMetadata;
  var grpcOpts = extend({}, GRPC_REQUEST_OPTIONS);

  if (is.number(protoOpts.timeout)) {
    grpcOpts.deadline = GrpcService.createDeadline_(protoOpts.timeout);
  }

  try {
    reqOpts = util.decorateRequest(reqOpts, { projectId: this.projectId });
  } catch(e) {
    setImmediate(function() {
      stream.destroy(e);
    });
    return stream;
  }

  var retryOpts = {
    retries: this.maxRetries,
    objectMode: objectMode,
    shouldRetryFn: GrpcService.shouldRetryRequest_,

    request: function() {
      return service[protoOpts.method](reqOpts, grpcMetadata, grpcOpts)
        .on('metadata', function() {
          // retry-request requires a server response before it starts emitting
          // data. The closest mechanism grpc provides is a metadata event, but
          // this does not provide any kind of response status. So we're faking
          // it here with code `0` which translates to HTTP 200.
          //
          // https://github.com/GoogleCloudPlatform/google-cloud-node/pull/1444#discussion_r71812636
          var grcpStatus = GrpcService.decorateStatus_({ code: 0 });

          this.emit('response', grcpStatus);
        });
    }
  };

  return retryRequest(null, retryOpts)
    .on('error', function(err) {
      var grpcError = GrpcService.decorateError_(err);

      stream.destroy(grpcError || err);
    })
    .pipe(stream);
};

/**
 * Make an authenticated writable streaming request with gRPC.
 *
 * @param {object} protoOpts - The proto options.
 * @param {string} protoOpts.service - The service.
 * @param {string} protoOpts.method - The method name.
 * @param {number=} protoOpts.timeout - After how many milliseconds should the
 *     request cancel.
 * @param {object} reqOpts - The request options.
 */
GrpcService.prototype.requestWritableStream = function(protoOpts, reqOpts) {
  var stream = protoOpts.stream = protoOpts.stream || duplexify.obj();

  if (global.GCLOUD_SANDBOX_ENV) {
    return stream;
  }

  var self = this;

  if (!this.grpcCredentials) {
    // We must establish an authClient to give to grpc.
    this.getGrpcCredentials_(function(err, credentials) {
      if (err) {
        stream.destroy(err);
        return;
      }

      self.grpcCredentials = credentials;
      self.requestWritableStream(protoOpts, reqOpts);
    });

    return stream;
  }

  var service = this.getService_(protoOpts);
  var grpcMetadata = this.grpcMetadata;
  var grpcOpts = extend({}, GRPC_REQUEST_OPTIONS);

  if (is.number(protoOpts.timeout)) {
    grpcOpts.deadline = GrpcService.createDeadline_(protoOpts.timeout);
  }

  try {
    reqOpts = util.decorateRequest(reqOpts, { projectId: this.projectId });
  } catch (e) {
    setImmediate(function() {
      stream.destroy(e);
    });
    return stream;
  }

  var grpcStream = service[protoOpts.method](reqOpts, grpcMetadata, grpcOpts)
    .on('status', function(status) {
      var grcpStatus = GrpcService.decorateStatus_(status);
      stream.emit('response', grcpStatus || status);
    })
    .on('error', function(err) {
      var grpcError = GrpcService.decorateError_(err);
      stream.destroy(grpcError || err);
    });

  stream.setReadable(grpcStream);
  stream.setWritable(grpcStream);

  return stream;
};

/**
 * Decode a protobuf Struct's value.
 *
 * @private
 *
 * @param {object} value - A Struct's Field message.
 * @return {*} - The decoded value.
 */
GrpcService.decodeValue_ = function(value) {
  switch (value.kind) {
    case 'structValue': {
      return GrpcService.structToObj_(value.structValue);
    }

    case 'nullValue': {
      return null;
    }

    case 'listValue': {
      return value.listValue.values.map(GrpcService.decodeValue_);
    }

    default: {
      return value[value.kind];
    }
  }
};

/**
 * Convert a raw value to a type-denoted protobuf message-friendly object.
 *
 * @private
 *
 * @param {*} value - The input value.
 * @return {*} - The encoded value.
 *
 * @example
 * ObjectToStructConverter.encodeValue('Hi');
 * // {
 * //   stringValue: 'Hello!'
 * // }
 */
GrpcService.encodeValue_ = function(value) {
  return new GrpcService.ObjectToStructConverter().encodeValue_(value);
};

/**
 * Creates a deadline.
 *
 * @private
 *
 * @param {number} timeout - Timeout in miliseconds.
 * @return {date} deadline - The deadline in Date object form.
 */
GrpcService.createDeadline_ = function(timeout) {
  return new Date(Date.now() + timeout);
};

/**
 * Checks for a grpc status code and extends the error object with additional
 * information.
 *
 * @private
 *
 * @param {error|object} err - The grpc error.
 * @return {error|null}
 */
GrpcService.decorateError_ = function(err) {
  var errorObj = is.error(err) ? err : {};

  return GrpcService.decorateGrpcResponse_(errorObj, err);
};

/**
 * Checks for a grpc status code and extends the supplied object with additional
 * information.
 *
 * @private
 *
 * @param {object} obj - The object to be extended.
 * @param {object} response - The grpc response.
 * @return {object|null}
 */
GrpcService.decorateGrpcResponse_ = function(obj, response) {
  if (response && GRPC_ERROR_CODE_TO_HTTP[response.code]) {
    var defaultResponseDetails = GRPC_ERROR_CODE_TO_HTTP[response.code];
    var message = defaultResponseDetails.message;

    if (response.message) {
      // gRPC error messages can be either stringified JSON or strings.
      try {
        message = JSON.parse(response.message).description;
      } catch(e) {
        message = response.message;
      }
    }

    return extend(true, obj, response, {
      code: defaultResponseDetails.code,
      message: message
    });
  }

  return null;
};

/**
 * Checks for grpc status code and extends the status object with additional
 * information
 *
 * @private
 * @param {object} status - The grpc status.
 * @return {object|null}
 */
GrpcService.decorateStatus_ = function(status) {
  return GrpcService.decorateGrpcResponse_({}, status);
};

/**
 * Function to decide whether or not a request retry could occur.
 *
 * @private
 *
 * @param {object} response - The request response.
 * @return {boolean} shouldRetry
 */
GrpcService.shouldRetryRequest_ = function(response) {
  return [429, 500, 502, 503].indexOf(response.code) > -1;
};

/**
 * Convert an object to a struct.
 *
 * @private
 *
 * @param {object} obj - An object to convert.
 * @param {object=} options - Configuration object.
 * @param {boolean} options.removeCircular - Remove circular references in the
 *     object with a placeholder string.
 * @param {boolean} options.stringify - Stringify un-recognized types.
 * @return {array} - The converted object.
 *
 * @example
 * GrpcService.objToStruct_({
 *   greeting: 'Hello!',
 *   favNumber: 7,
 *   friendIds: [
 *     1004,
 *     1006
 *   ],
 *   userDetails: {
 *     termsSigned: true
 *   }
 * });
 * // {
 * //   fields: {
 * //     greeting: {
 * //       stringValue: 'Hello!'
 * //     },
 * //     favNumber: {
 * //       numberValue: 7
 * //     },
 * //     friendIds: {
 * //       listValue: [
 * //         {
 * //           numberValue: 1004
 * //         },
 * //         {
 * //           numberValue: 1006
 * //         }
 * //       ]
 * //     },
 * //     userDetails: {
 * //       fields: {
 * //         termsSigned: {
 * //           booleanValue: true
 * //         }
 * //       }
 * //     }
 * //   }
 * // }
 */
GrpcService.objToStruct_ = function(obj, options) {
  return new GrpcService.ObjectToStructConverter(options).convert(obj);
};

/**
 * Condense a protobuf Struct into an object of only its values.
 *
 * @private
 *
 * @param {object} struct - A protobuf Struct message.
 * @return {object} - The simplified object.
 *
 * @example
 * GrpcService.structToObj_({
 *   fields: {
 *     name: {
 *       kind: 'stringValue',
 *       stringValue: 'Stephen'
 *     }
 *   }
 * });
 * // {
 * //   name: 'Stephen'
 * // }
 */
GrpcService.structToObj_ = function(struct) {
  var convertedObject = {};

  for (var prop in struct.fields) {
    if (struct.fields.hasOwnProperty(prop)) {
      var value = struct.fields[prop];
      convertedObject[prop] = GrpcService.decodeValue_(value);
    }
  }

  return convertedObject;
};

/**
 * To authorize requests through gRPC, we must get the raw google-auth-library
 * auth client object.
 *
 * @private
 *
 * @param {function} callback - The callback function.
 * @param {?error} callback.err - An error getting an auth client.
 */
GrpcService.prototype.getGrpcCredentials_ = function(callback) {
  var self = this;

  this.authClient.getAuthClient(function(err, authClient) {
    if (err) {
      callback(err);
      return;
    }

    var credentials = grpc.credentials.combineChannelCredentials(
      grpc.credentials.createSsl(),
      grpc.credentials.createFromGoogleCredential(authClient)
    );

    if (!self.projectId || self.projectId === '{{projectId}}') {
      self.projectId = authClient.projectId;
    }

    callback(null, credentials);
  });
};

/**
 * Loads a proto file, useful when handling multiple proto files/services
 * within a single instance of GrpcService.
 *
 * @private
 *
 * @param {object} protoConfig - The proto specific configs for this file.
 * @param {object} config - The base config for the GrpcService.
 * @return {object} protoObject - The loaded proto object.
 */
GrpcService.prototype.loadProtoFile_ = function(protoConfig, config) {
  var rootDir = googleProtoFiles('..');

  var grpcOpts = {
    binaryAsBase64: true,
    convertFieldsToCamelCase: true
  };

  if (is.string(protoConfig)) {
    protoConfig = {
      path: protoConfig
    };
  }

  var services = grpc.load({
    root: rootDir,
    file: path.relative(rootDir, protoConfig.path)
  }, 'proto', grpcOpts);

  var serviceName = protoConfig.service || config.service;
  var apiVersion = protoConfig.apiVersion || config.apiVersion;
  var service = dotProp.get(services.google, serviceName);

  return service[apiVersion] || service;
};

/**
 * Retrieves the service object used to make the grpc requests.
 *
 * @private
 *
 * @param {object} protoOpts - The proto options.
 * @return {object} service - The proto service.
 */
GrpcService.prototype.getService_ = function(protoOpts) {
  var proto;

  if (this.protos[protoOpts.service]) {
    proto = this.protos[protoOpts.service];
  } else {
    proto = this.protos[this.service];
  }

  var service = this.activeServiceMap_.get(protoOpts.service);

  if (!service) {
    service = new proto[protoOpts.service](
      proto.baseUrl || this.baseUrl,
      this.grpcCredentials,
      { 'grpc.primary_user_agent': this.userAgent }
    );

    this.activeServiceMap_.set(protoOpts.service, service);
  }

  return service;
};

/**
 * A class that can be used to convert an object to a struct. Optionally this
 * class can be used to erase/throw on circular references during conversion.
 *
 * @private
 *
 * @param {object=} options - Configuration object.
 * @param {boolean} options.removeCircular - Remove circular references in the
 *     object with a placeholder string. (Default: `false`)
 * @param {boolean} options.stringify - Stringify un-recognized types. (Default:
 *     `false`)
 */
function ObjectToStructConverter(options) {
  options = options || {};

  this.seenObjects = new Set();
  this.removeCircular = options.removeCircular === true;
  this.stringify = options.stringify === true;
}

/**
 * Begin the conversion process from a JS object to an encoded gRPC Value
 * message.
 *
 * @param {*} value - The input value.
 * @return {object} - The encoded value.
 *
 * @example
 * ObjectToStructConverter.convert({
 *   aString: 'Hi'
 * });
 * // {
 * //   fields: {
 * //     aString: {
 * //       stringValue: 'Hello!'
 * //     }
 * //   }
 * // }
 */
ObjectToStructConverter.prototype.convert = function(obj) {
  var convertedObject = {
    fields: {}
  };

  this.seenObjects.add(obj);

  for (var prop in obj) {
    if (obj.hasOwnProperty(prop)) {
      var value = obj[prop];

      if (is.undefined(value)) {
        continue;
      }

      convertedObject.fields[prop] = this.encodeValue_(value);
    }
  }

  this.seenObjects.delete(obj);

  return convertedObject;
};

/**
 * Convert a raw value to a type-denoted protobuf message-friendly object.
 *
 * @private
 *
 * @param {*} value - The input value.
 * @return {*} - The encoded value.
 *
 * @example
 * ObjectToStructConverter.encodeValue('Hi');
 * // {
 * //   stringValue: 'Hello!'
 * // }
 */
ObjectToStructConverter.prototype.encodeValue_ = function(value) {
  var convertedValue;

  if (is.null(value)) {
    convertedValue = {
      nullValue: 0
    };
  } else if (is.number(value)) {
    convertedValue = {
      numberValue: value
    };
  } else if (is.string(value)) {
    convertedValue = {
      stringValue: value
    };
  } else if (is.boolean(value)) {
    convertedValue = {
      boolValue: value
    };
  } else if (Buffer.isBuffer(value)) {
    convertedValue = {
      blobValue: value
    };
  } else if (is.object(value)) {
    if (this.seenObjects.has(value)) {
      // Circular reference.
      if (!this.removeCircular) {
        throw new Error([
          'This object contains a circular reference. To automatically',
          'remove it, set the `removeCircular` option to true.'
        ].join(' '));
      }
      convertedValue = {
        stringValue: '[Circular]'
      };
    } else {
      convertedValue = {
        structValue: this.convert(value)
      };
    }
  } else if (is.array(value)) {
    convertedValue = {
      listValue: {
        values: value.map(this.encodeValue_.bind(this))
      }
    };
  } else {
    if (!this.stringify) {
      throw new Error('Value of type ' + typeof value + ' not recognized.');
    }

    convertedValue = {
      stringValue: String(value)
    };
  }

  return convertedValue;
};

module.exports = GrpcService;
module.exports.GRPC_ERROR_CODE_TO_HTTP = GRPC_ERROR_CODE_TO_HTTP;
module.exports.GRPC_REQUEST_OPTIONS = GRPC_REQUEST_OPTIONS;
module.exports.ObjectToStructConverter = ObjectToStructConverter;


text:
[![Maven Central](https://img.shields.io/maven-central/v/io.codegen.jso-builder/jso-builder-processor.svg)](https://mvnrepository.com/artifact/io.codegen.jso-builder/jso-builder-processor)
[![Travis](https://img.shields.io/travis/codegen-io/jso-builder.svg)](https://travis-ci.org/codegen-io/jso-builder)

The JSO Builder project enables one to automatically generate builder classes from GWT JsInterop
JavaScript objects. The builder classes are compatible with GWT and allow the creation of unit
tests in a JVM environment.

## Usage

```java
// Define a concrete class annotated as a native JsType object
@JsType(isNative = true, namespace = JsPackage.GLOBAL, name = "Object")
public class Value {

    // Each member can be set using a corresponding with* method in the builder
    String property;
    int number;

    // The JsBuilder annotation will trigger the processor and generate ValueJSOBuilder
    // which our builder will inherit in order to expose it's methods
    @JsBuilder
    public static class Builder extends ValueJSOBuilder {}

    // The generated builder allows serializing the JavaScript object to JSON
    // from both a GWT application and a JRE environment like a unit test
    @JsOverlay
    public String toJSON() {
        return Builder.toJSON(this);
    }

}

// Use the generated builder to create our Value
Value value =
    new Value.Builder()
        .withProperty("one")
        .withNumber(2)
        .build();

// Serialize the Value to JSON
value.toJSON();
```

## Installation

You will need to include `jso-builder-annotations-x.y.z.jar` in your build classpath at compile
time and add `jso-builder-processor-x.y.z.jar` to the annotation path in order to activate the
annotation processor and generate the builder implementations.

### Maven

In a Maven project, include the `jso-builder-annotations` artifact in the dependencies section
of your `pom.xml` and the `jso-builder-processor` artifact as an `annotationProcessorPaths`
value of the `maven-compiler-plugin`:

```xml
<dependencies>
  <dependency>
    <groupId>io.codegen.jso-builder</groupId>
    <artifactId>jso-builder-annotations</artifactId>
    <version>x.y.z</version>
  </dependency>
</dependencies>
<build>
  <plugins>
    <plugin>
      <groupId>org.apache.maven.plugins</groupId>
      <artifactId>maven-compiler-plugin</artifactId>
      <version>3.6.1</version>
      <configuration>
        <annotationProcessorPaths>
          <path>
            <groupId>io.codegen.jso-builder</groupId>
            <artifactId>jso-builder-processor</artifactId>
            <version>x.y.z</version>
          </path>
        </annotationProcessorPaths>
      </configuration>
    </plugin>
  </plugins>
</build>
```

redpajama_set_name: RedPajamaGithub


text:
'use strict';

const React = require('React');
const RelayPropTypes = require('../../classic/container/RelayPropTypes');
const RelayRoute = require('../../classic/route/RelayRoute');
const RelayStore = require('../../classic/store/RelayStore');

// Dummy Route
/* $FlowFixMe(>=0.54.0) This comment suppresses an error
 * found when Flow v0.54 was deployed. To see the error delete this comment and
 * run Flow. */
class QueryConfig extends RelayRoute {}
QueryConfig.routeName = 'ForceRelayClassicContextRoute';
QueryConfig.queries = {};

/**
 * This wrapper will provide dummy RelayContainer context to it's children. It
 * should only be used as a wrapper around RelayContainers that have not been
 * converted to one of the compatibility container and are not fetching data.
 */
class ForceRelayClassicContext extends React.Component<$FlowFixMeProps> {
  static childContextTypes = {
    relay: RelayPropTypes.ClassicRelay,
    route: RelayPropTypes.QueryConfig.isRequired,
  };

  getChildContext() {
    return {
      relay: {
        environment: RelayStore,
        variables: {},
      },
      route: new QueryConfig(),
    };
  }
  render(): React.Node {
    return this.props.children;
  }
}

module.exports = ForceRelayClassicContext;


text:
'use strict';

/**
 * Module dependencies.
 */
var mongoose = require('mongoose'),
	Schema = mongoose.Schema;

/**
 * Job Schema
 */
var JobSchema = new Schema({
	created: {
		type: Date,
		default: Date.now
	},
	title: {
		type: String,
		default: '',
		trim: true,
		required: 'Title cannot be blank'
	},
	companyName: {
		type: String,
		default: '',
		trim: true,
		required: 'Company Name cannot be blank'
	},
	type: {
		type: String,
		default: '',
		trim: true
	},
	category: {
		type: String,
		default: '',
		trim: true
	},
	content: {
		type: String,
		default: '',
		trim: true
	},
	candidates: [{
		type: Schema.ObjectId,
		ref: 'User'
	}],
	user: {
		type: Schema.ObjectId,
		ref: 'User'
	}
});

mongoose.model('Job', JobSchema);


text:
package com.facebook.buck.apple.toolchain.impl;

import static org.hamcrest.Matchers.anEmptyMap;
import static org.hamcrest.Matchers.is;
import static org.hamcrest.Matchers.not;
import static org.junit.Assert.fail;
import static org.junit.Assume.assumeThat;

import com.facebook.buck.apple.AppleConfig;
import com.facebook.buck.apple.toolchain.AppleDeveloperDirectoryProvider;
import com.facebook.buck.apple.toolchain.AppleSdk;
import com.facebook.buck.apple.toolchain.AppleSdkLocation;
import com.facebook.buck.apple.toolchain.AppleSdkPaths;
import com.facebook.buck.apple.toolchain.AppleToolchain;
import com.facebook.buck.apple.toolchain.AppleToolchainProvider;
import com.facebook.buck.config.BuckConfig;
import com.facebook.buck.config.FakeBuckConfig;
import com.facebook.buck.core.exceptions.HumanReadableException;
import com.facebook.buck.io.ExecutableFinder;
import com.facebook.buck.io.filesystem.ProjectFilesystem;
import com.facebook.buck.rules.keys.config.TestRuleKeyConfigurationFactory;
import com.facebook.buck.testutil.FakeProjectFilesystem;
import com.facebook.buck.testutil.TemporaryPaths;
import com.facebook.buck.testutil.integration.ProjectWorkspace;
import com.facebook.buck.testutil.integration.TestDataHelper;
import com.facebook.buck.toolchain.ToolchainCreationContext;
import com.facebook.buck.toolchain.ToolchainProvider;
import com.facebook.buck.toolchain.impl.ToolchainProviderBuilder;
import com.facebook.buck.util.Console;
import com.facebook.buck.util.DefaultProcessExecutor;
import com.facebook.buck.util.ProcessExecutor;
import com.facebook.buck.util.environment.Platform;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableMap;
import java.io.IOException;
import java.nio.file.Path;
import java.util.Optional;
import org.hamcrest.Matchers;
import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.ExpectedException;

public class AppleCxxPlatformsProviderFactoryTest {
  @Rule public TemporaryPaths temp = new TemporaryPaths();
  @Rule public ExpectedException thrown = ExpectedException.none();

  @Test
  public void testPlatformConflicts() throws IOException {
    assumeThat(Platform.detect(), is(Platform.MACOS));

    ProjectWorkspace workspace =
        TestDataHelper.createProjectWorkspaceForScenario(this, "platform-conflict", temp);
    workspace.setUp();
    Path root = workspace.getPath("Platforms");

    BuckConfig buckConfig = FakeBuckConfig.builder().build();

    ToolchainProviderBuilder toolchainProviderBuilder = new ToolchainProviderBuilder();

    ProjectFilesystem projectFilesystem = new FakeProjectFilesystem();

    ProcessExecutor processExecutor = new DefaultProcessExecutor(Console.createNullConsole());

    ToolchainCreationContext toolchainCreationContext =
        ToolchainCreationContext.of(
            ImmutableMap.of(),
            buckConfig,
            projectFilesystem,
            processExecutor,
            new ExecutableFinder(),
            TestRuleKeyConfigurationFactory.create());

    Optional<Path> appleDeveloperDir =
        new AppleDeveloperDirectoryProviderFactory()
            .createToolchain(toolchainProviderBuilder.build(), toolchainCreationContext)
            .map(AppleDeveloperDirectoryProvider::getAppleDeveloperDirectory);

    ImmutableMap<String, AppleToolchain> appleToolchains =
        AppleToolchainDiscovery.discoverAppleToolchains(appleDeveloperDir, ImmutableList.of());

    assumeThat(appleToolchains, is(not(anEmptyMap())));

    ImmutableMap<AppleSdk, AppleSdkPaths> appleSdkPaths =
        AppleSdkDiscovery.discoverAppleSdkPaths(
            appleDeveloperDir,
            ImmutableList.of(root),
            appleToolchains,
            buckConfig.getView(AppleConfig.class));

    assumeThat(appleSdkPaths, is(not(anEmptyMap())));

    ToolchainProvider toolchainProvider =
        toolchainProviderBuilder
            .withToolchain(AppleSdkLocation.DEFAULT_NAME, AppleSdkLocation.of(appleSdkPaths))
            .withToolchain(
                AppleToolchainProvider.DEFAULT_NAME, AppleToolchainProvider.of(appleToolchains))
            .build();

    thrown.expect(HumanReadableException.class);
    thrown.expectMessage(
        Matchers.containsString(
            "There are two conflicting SDKs providing the same platform \"macosx-i386\":\n"));

    new AppleCxxPlatformsProviderFactory()
        .createToolchain(toolchainProvider, toolchainCreationContext);

    fail("AppleCxxPlatformsProviderFactory.createToolchain should fail");
  }
}


text:
from __future__ import unicode_literals

from django.db import connection, migrations

def add_trigram_indexes(apps, schema_editor):
    with connection.cursor() as cursor:
        cursor.execute("CREATE EXTENSION pg_trgm;")
        cursor.execute(
            "CREATE INDEX case_reference_trgm_idx ON " "legalaid_case USING gist (UPPER(reference) gist_trgm_ops);"
        )
        cursor.execute(
            "CREATE INDEX case_search_field_trgm_idx ON "
            "legalaid_case USING gist (UPPER(search_field) gist_trgm_ops);"
        )
        cursor.execute(
            "CREATE INDEX case_laa_reference_trgm_idx ON "
            "legalaid_case USING gist (UPPER(text(laa_reference)) gist_trgm_ops);"
        )
        cursor.execute(
            "CREATE INDEX personaldetails_full_name_trgm_idx ON "
            "legalaid_personaldetails USING gist (UPPER(full_name) gist_trgm_ops);"
        )
        cursor.execute(
            "CREATE INDEX personaldetails_street_trgm_idx ON "
            "legalaid_personaldetails USING gist (UPPER(street) gist_trgm_ops);"
        )
        cursor.execute(
            "CREATE INDEX personaldetails_postcode_trgm_idx ON "
            "legalaid_personaldetails USING gist (UPPER(postcode) gist_trgm_ops);"
        )
        cursor.execute(
            "CREATE INDEX personaldetails_search_field_trgm_idx ON "
            "legalaid_personaldetails USING gist (UPPER(search_field) gist_trgm_ops);"
        )

def remove_trigram_indexes(apps, schema_editor):
    with connection.cursor() as cursor:
        cursor.execute("DROP INDEX case_reference_trgm_idx;")
        cursor.execute("DROP INDEX case_search_field_trgm_idx;")
        cursor.execute("DROP INDEX case_laa_reference_trgm_idx;")
        cursor.execute("DROP INDEX personaldetails_full_name_trgm_idx;")
        cursor.execute("DROP INDEX personaldetails_street_trgm_idx;")
        cursor.execute("DROP INDEX personaldetails_postcode_trgm_idx;")
        cursor.execute("DROP INDEX personaldetails_search_field_trgm_idx;")
        cursor.execute("DROP EXTENSION pg_trgm;")

class Migration(migrations.Migration):

    dependencies = [("legalaid", "0017_case_is_urgent")]

    operations = [migrations.RunPython(add_trigram_indexes, remove_trigram_indexes)]


text:
#ifndef MODULES_AUDIO_DEVICE_WIN_CORE_AUDIO_OUTPUT_WIN_H_
#define MODULES_AUDIO_DEVICE_WIN_CORE_AUDIO_OUTPUT_WIN_H_

#include <memory>
#include <string>

#include BOSS_WEBRTC_U_modules__audio_device__win__audio_device_module_win_h //original-code:"modules/audio_device/win/audio_device_module_win.h"
#include BOSS_WEBRTC_U_modules__audio_device__win__core_audio_base_win_h //original-code:"modules/audio_device/win/core_audio_base_win.h"

namespace webrtc {

class AudioDeviceBuffer;
class FineAudioBuffer;

namespace webrtc_win {

// Windows specific AudioOutput implementation using a CoreAudioBase class where
// an output direction is set at construction. Supports render device handling
// and streaming of decoded audio from a WebRTC client to the native audio
// layer.
class CoreAudioOutput final : public CoreAudioBase, public AudioOutput {
 public:
  CoreAudioOutput();
  ~CoreAudioOutput() override;

  // AudioOutput implementation.
  int Init() override;
  int Terminate() override;
  int NumDevices() const override;
  int SetDevice(int index) override;
  int SetDevice(AudioDeviceModule::WindowsDeviceType device) override;
  int DeviceName(int index, std::string* name, std::string* guid) override;
  void AttachAudioBuffer(AudioDeviceBuffer* audio_buffer) override;
  bool PlayoutIsInitialized() const override;
  int InitPlayout() override;
  int StartPlayout() override;
  int StopPlayout() override;
  bool Playing() override;
  int VolumeIsAvailable(bool* available) override;

  CoreAudioOutput(const CoreAudioOutput&) = delete;
  CoreAudioOutput& operator=(const CoreAudioOutput&) = delete;

 private:
  bool OnDataCallback(uint64_t device_frequency);
  int EstimateOutputLatencyMillis(uint64_t device_frequency);

  std::unique_ptr<FineAudioBuffer> fine_audio_buffer_;
  Microsoft::WRL::ComPtr<IAudioRenderClient> audio_render_client_;
  uint64_t num_frames_written_ = 0;
};

}  // namespace webrtc_win
}  // namespace webrtc

#endif  // MODULES_AUDIO_DEVICE_WIN_CORE_AUDIO_OUTPUT_WIN_H_


text:
using System;
using System.Collections;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Threading;
using System.Windows.Forms;
using DevExpress.XtraEditors;

using CPTT.BusinessFacade;

namespace CPTT.WinUI.Panels
{
	/// <summary>
	/// Summary description for PhoneNum.
	/// </summary>
	public class PhoneNum : DevExpress.XtraEditors.XtraUserControl
	{
		private DevExpress.Utils.Frames.NotePanel notePanel_DutyDetailsTitle;
		private DevExpress.XtraEditors.GroupControl groupControl2;
		private DevExpress.XtraEditors.TextEdit textEdit_Send_StuName;
		private DevExpress.XtraEditors.ComboBoxEdit comboBoxEdit_Send_StuClass;
		private DevExpress.XtraEditors.ComboBoxEdit comboBoxEdit_Send_StuGrade;
		private DevExpress.XtraEditors.TextEdit textEdit_Send_StuNumber;
		private DevExpress.Utils.Frames.NotePanel notePanel_Send_StuNumber;
		private DevExpress.Utils.Frames.NotePanel notePanel_Send_StuClass;
		private DevExpress.Utils.Frames.NotePanel notePanel_Send_StuGrade;
		private DevExpress.Utils.Frames.NotePanel notePanel_Send_StuName;
		private DevExpress.XtraEditors.GroupControl groupControl1;
		private DevExpress.XtraEditors.SimpleButton simpleButton_EditPhoneNum;
		/// <summary>
		/// Required designer variable.
		/// </summary>
		private System.ComponentModel.Container components = null;

		private GetStuInfoByCondition getStuInfoByCondition;
		private DevExpress.XtraGrid.GridControl gridControl1;
		private DevExpress.XtraGrid.Views.Grid.GridView gridView1;
		private string getGradeNumberFromCombo = "0";
		private DataSet StuList;
		private DevExpress.XtraGrid.Columns.GridColumn gridColumn1;
		private DevExpress.XtraGrid.Columns.GridColumn gridColumn2;
		private DevExpress.XtraGrid.Columns.GridColumn gridColumn3;
		private DevExpress.XtraGrid.Columns.GridColumn gridColumn4;
		private DevExpress.XtraGrid.Columns.GridColumn gridColumn5;
		private DevExpress.XtraEditors.GroupControl groupControl3;
		private DevExpress.XtraEditors.GroupControl groupControl4;
		private DevExpress.XtraEditors.SimpleButton simpleButton2;
		private DevExpress.Utils.Frames.NotePanel notePanel1;
		private DevExpress.Utils.Frames.NotePanel notePanel2;
		private DevExpress.XtraEditors.TextEdit textEdit1;
		private DevExpress.XtraEditors.TextEdit textEdit2;
		private DevExpress.XtraGrid.GridControl gridControl2;
		private DevExpress.XtraGrid.Views.Grid.GridView gridView2;
		private DevExpress.XtraGrid.Columns.GridColumn gridColumn6;
		private DevExpress.XtraGrid.Columns.GridColumn gridColumn7;
		private DevExpress.XtraGrid.Columns.GridColumn gridColumn8;
		private DataView StuView;

		public PhoneNum()
		{
			// This call is required by the Windows.Forms Form Designer.
			InitializeComponent();

			// TODO: Add any initialization after the InitForm call

			getStuInfoByCondition = new GetStuInfoByCondition();

			StuList = new CardInfoSystem().GetStuCardInfoList();//ѧÉú¿¨

			if(Thread.CurrentPrincipal.Identity.Name.ToLower()=="admin")
				return;

			DataSet TeaDept = new RolesSystem().GetRolesDuty(Convert.ToInt32(Thread.CurrentPrincipal.Identity.Name));

			string rowFilter = string.Empty;

			if(!Thread.CurrentPrincipal.IsInRole("Ô°³¤")
				&&!Thread.CurrentPrincipal.IsInRole("񜫭"))
			{
				rowFilter = rowFilter + "info_gradeName = '"
					+TeaDept.Tables[0].Rows[0][0].ToString()+"'";
				rowFilter = rowFilter + " and info_className = '"
					+TeaDept.Tables[0].Rows[0][1].ToString()+"'";
			}

			StuView = StuList.Tables[0].DefaultView;
			StuView.RowFilter = rowFilter;

			gridControl1.DataSource = StuView;

			comboBoxEdit_Send_StuGrade.Properties.Items.Clear();
			comboBoxEdit_Send_StuGrade.Properties.Items.AddRange(new object[]{"È«²¿"});
			comboBoxEdit_Send_StuGrade.SelectedItem = "È«²¿";
			foreach(DataRow getGradeList in getStuInfoByCondition.getGradeInfo("","").Tables[0].Rows)
			{
				comboBoxEdit_Send_StuGrade.Properties.Items.AddRange(
					new object[]{getGradeList[1].ToString()});
			}
		}

		/// <summary>
		/// Clean up any resources being used.
		/// </summary>
		protected override void Dispose( bool disposing )
		{
			if( disposing )
			{
				if(components != null)
				{
					components.Dispose();
				}
			}
			base.Dispose( disposing );
		}

		#region Component Designer generated code
		/// <summary>
		/// Required method for Designer support - do not modify
		/// the contents of this method with the code editor.
		/// </summary>
		private void InitializeComponent()
		{
			this.notePanel_DutyDetailsTitle = new DevExpress.Utils.Frames.NotePanel();
			this.groupControl2 = new DevExpress.XtraEditors.GroupControl();
			this.textEdit_Send_StuName = new DevExpress.XtraEditors.TextEdit();
			this.comboBoxEdit_Send_StuClass = new DevExpress.XtraEditors.ComboBoxEdit();
			this.comboBoxEdit_Send_StuGrade = new DevExpress.XtraEditors.ComboBoxEdit();
			this.textEdit_Send_StuNumber = new DevExpress.XtraEditors.TextEdit();
			this.notePanel_Send_StuNumber = new DevExpress.Utils.Frames.NotePanel();
			this.notePanel_Send_StuClass = new DevExpress.Utils.Frames.NotePanel();
			this.notePanel_Send_StuGrade = new DevExpress.Utils.Frames.NotePanel();
			this.notePanel_Send_StuName = new DevExpress.Utils.Frames.NotePanel();
			this.groupControl1 = new DevExpress.XtraEditors.GroupControl();
			this.groupControl3 = new DevExpress.XtraEditors.GroupControl();
			this.simpleButton_EditPhoneNum = new DevExpress.XtraEditors.SimpleButton();
			this.notePanel1 = new DevExpress.Utils.Frames.NotePanel();
			this.notePanel2 = new DevExpress.Utils.Frames.NotePanel();
			this.textEdit1 = new DevExpress.XtraEditors.TextEdit();
			this.textEdit2 = new DevExpress.XtraEditors.TextEdit();
			this.gridControl1 = new DevExpress.XtraGrid.GridControl();
			this.gridView1 = new DevExpress.XtraGrid.Views.Grid.GridView();
			this.gridColumn1 = new DevExpress.XtraGrid.Columns.GridColumn();
			this.gridColumn2 = new DevExpress.XtraGrid.Columns.GridColumn();
			this.gridColumn3 = new DevExpress.XtraGrid.Columns.GridColumn();
			this.gridColumn4 = new DevExpress.XtraGrid.Columns.GridColumn();
			this.gridColumn5 = new DevExpress.XtraGrid.Columns.GridColumn();
			this.groupControl4 = new DevExpress.XtraEditors.GroupControl();
			this.gridControl2 = new DevExpress.XtraGrid.GridControl();
			this.gridView2 = new DevExpress.XtraGrid.Views.Grid.GridView();
			this.gridColumn6 = new DevExpress.XtraGrid.Columns.GridColumn();
			this.gridColumn7 = new DevExpress.XtraGrid.Columns.GridColumn();
			this.gridColumn8 = new DevExpress.XtraGrid.Columns.GridColumn();
			this.simpleButton2 = new DevExpress.XtraEditors.SimpleButton();
			((System.ComponentModel.ISupportInitialize)(this.groupControl2)).BeginInit();
			this.groupControl2.SuspendLayout();
			((System.ComponentModel.ISupportInitialize)(this.textEdit_Send_StuName.Properties)).BeginInit();
			((System.ComponentModel.ISupportInitialize)(this.comboBoxEdit_Send_StuClass.Properties)).BeginInit();
			((System.ComponentModel.ISupportInitialize)(this.comboBoxEdit_Send_StuGrade.Properties)).BeginInit();
			((System.ComponentModel.ISupportInitialize)(this.textEdit_Send_StuNumber.Properties)).BeginInit();
			((System.ComponentModel.ISupportInitialize)(this.groupControl1)).BeginInit();
			this.groupControl1.SuspendLayout();
			((System.ComponentModel.ISupportInitialize)(this.groupControl3)).BeginInit();
			this.groupControl3.SuspendLayout();
			((System.ComponentModel.ISupportInitialize)(this.textEdit1.Properties)).BeginInit();
			((System.ComponentModel.ISupportInitialize)(this.textEdit2.Properties)).BeginInit();
			((System.ComponentModel.ISupportInitialize)(this.gridControl1)).BeginInit();
			((System.ComponentModel.ISupportInitialize)(this.gridView1)).BeginInit();
			((System.ComponentModel.ISupportInitialize)(this.groupControl4)).BeginInit();
			this.groupControl4.SuspendLayout();
			((System.ComponentModel.ISupportInitialize)(this.gridControl2)).BeginInit();
			((System.ComponentModel.ISupportInitialize)(this.gridView2)).BeginInit();
			this.SuspendLayout();
			//
			// notePanel_DutyDetailsTitle
			//
			this.notePanel_DutyDetailsTitle.BackColor = System.Drawing.Color.LightGoldenrodYellow;
			this.notePanel_DutyDetailsTitle.Dock = System.Windows.Forms.DockStyle.Top;
			this.notePanel_DutyDetailsTitle.ForeColor = System.Drawing.Color.Gray;
			this.notePanel_DutyDetailsTitle.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical;
			this.notePanel_DutyDetailsTitle.Location = new System.Drawing.Point(0, 0);
			this.notePanel_DutyDetailsTitle.MaxRows = 5;
			this.notePanel_DutyDetailsTitle.Name = "notePanel_DutyDetailsTitle";
			this.notePanel_DutyDetailsTitle.ParentAutoHeight = true;
			this.notePanel_DutyDetailsTitle.Size = new System.Drawing.Size(584, 23);
			this.notePanel_DutyDetailsTitle.TabIndex = 14;
			this.notePanel_DutyDetailsTitle.TabStop = false;
			this.notePanel_DutyDetailsTitle.Text = "²é¿´±à¼ºÅÂë²¾";
			//
			// groupControl2
			//
			this.groupControl2.AppearanceCaption.Font = new System.Drawing.Font("Tahoma", 9F, System.Drawing.FontStyle.Bold);
			this.groupControl2.AppearanceCaption.ForeColor = System.Drawing.Color.DarkOrange;
			this.groupControl2.AppearanceCaption.Options.UseFont = true;
			this.groupControl2.AppearanceCaption.Options.UseForeColor = true;
			this.groupControl2.Controls.Add(this.textEdit_Send_StuName);
			this.groupControl2.Controls.Add(this.comboBoxEdit_Send_StuClass);
			this.groupControl2.Controls.Add(this.comboBoxEdit_Send_StuGrade);
			this.groupControl2.Controls.Add(this.textEdit_Send_StuNumber);
			this.groupControl2.Controls.Add(this.notePanel_Send_StuNumber);
			this.groupControl2.Controls.Add(this.notePanel_Send_StuClass);
			this.groupControl2.Controls.Add(this.notePanel_Send_StuGrade);
			this.groupControl2.Controls.Add(this.notePanel_Send_StuName);
			this.groupControl2.Dock = System.Windows.Forms.DockStyle.Top;
			this.groupControl2.Location = new System.Drawing.Point(0, 23);
			this.groupControl2.Name = "groupControl2";
			this.groupControl2.Size = new System.Drawing.Size(584, 81);
			this.groupControl2.TabIndex = 22;
			this.groupControl2.Text = "²éÕÒÌõ¼þ";
			//
			// textEdit_Send_StuName
			//
			this.textEdit_Send_StuName.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
			this.textEdit_Send_StuName.EditValue = "";
			this.textEdit_Send_StuName.Location = new System.Drawing.Point(96, 32);
			this.textEdit_Send_StuName.Name = "textEdit_Send_StuName";
			this.textEdit_Send_StuName.Size = new System.Drawing.Size(56, 23);
			this.textEdit_Send_StuName.TabIndex = 40;
			this.textEdit_Send_StuName.EditValueChanged += new System.EventHandler(this.textEdit_Send_StuName_EditValueChanged);
			//
			// comboBoxEdit_Send_StuClass
			//
			this.comboBoxEdit_Send_StuClass.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
			this.comboBoxEdit_Send_StuClass.EditValue = "È«²¿";
			this.comboBoxEdit_Send_StuClass.Location = new System.Drawing.Point(494, 32);
			this.comboBoxEdit_Send_StuClass.Name = "comboBoxEdit_Send_StuClass";
			//
			// comboBoxEdit_Send_StuClass.Properties
			//
			this.comboBoxEdit_Send_StuClass.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
																															   new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)});
			this.comboBoxEdit_Send_StuClass.Properties.Items.AddRange(new object[] {
																					   "È«²¿"});
			this.comboBoxEdit_Send_StuClass.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.DisableTextEditor;
			this.comboBoxEdit_Send_StuClass.Size = new System.Drawing.Size(64, 23);
			this.comboBoxEdit_Send_StuClass.TabIndex = 39;
			this.comboBoxEdit_Send_StuClass.SelectedIndexChanged += new System.EventHandler(this.comboBoxEdit_Send_StuClass_SelectedIndexChanged);
			//
			// comboBoxEdit_Send_StuGrade
			//
			this.comboBoxEdit_Send_StuGrade.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
			this.comboBoxEdit_Send_StuGrade.EditValue = "È«²¿";
			this.comboBoxEdit_Send_StuGrade.Location = new System.Drawing.Point(356, 32);
			this.comboBoxEdit_Send_StuGrade.Name = "comboBoxEdit_Send_StuGrade";
			//
			// comboBoxEdit_Send_StuGrade.Properties
			//
			this.comboBoxEdit_Send_StuGrade.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
																															   new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)});
			this.comboBoxEdit_Send_StuGrade.Properties.Items.AddRange(new object[] {
																					   "È«²¿"});
			this.comboBoxEdit_Send_StuGrade.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.DisableTextEditor;
			this.comboBoxEdit_Send_StuGrade.Size = new System.Drawing.Size(64, 23);
			this.comboBoxEdit_Send_StuGrade.TabIndex = 38;
			this.comboBoxEdit_Send_StuGrade.SelectedIndexChanged += new System.EventHandler(this.comboBoxEdit_Send_StuGrade_SelectedIndexChanged);
			//
			// textEdit_Send_StuNumber
			//
			this.textEdit_Send_StuNumber.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
			this.textEdit_Send_StuNumber.EditValue = "";
			this.textEdit_Send_StuNumber.Location = new System.Drawing.Point(226, 32);
			this.textEdit_Send_StuNumber.Name = "textEdit_Send_StuNumber";
			//
			// textEdit_Send_StuNumber.Properties
			//
			this.textEdit_Send_StuNumber.Properties.Mask.EditMask = "d4";
			this.textEdit_Send_StuNumber.Properties.Mask.MaskType = DevExpress.XtraEditors.Mask.MaskType.Numeric;
			this.textEdit_Send_StuNumber.Size = new System.Drawing.Size(56, 23);
			this.textEdit_Send_StuNumber.TabIndex = 37;
			this.textEdit_Send_StuNumber.EditValueChanged += new System.EventHandler(this.textEdit_Send_StuNumber_EditValueChanged);
			//
			// notePanel_Send_StuNumber
			//
			this.notePanel_Send_StuNumber.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
			this.notePanel_Send_StuNumber.BackColor = System.Drawing.Color.FromArgb(((System.Byte)(224)), ((System.Byte)(224)), ((System.Byte)(224)));
			this.notePanel_Send_StuNumber.BackColor2 = System.Drawing.Color.DarkGray;
			this.notePanel_Send_StuNumber.Font = new System.Drawing.Font("Tahoma", 8F);
			this.notePanel_Send_StuNumber.ForeColor = System.Drawing.Color.Black;
			this.notePanel_Send_StuNumber.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical;
			this.notePanel_Send_StuNumber.Location = new System.Drawing.Point(157, 32);
			this.notePanel_Send_StuNumber.MaxRows = 5;
			this.notePanel_Send_StuNumber.Name = "notePanel_Send_StuNumber";
			this.notePanel_Send_StuNumber.ParentAutoHeight = true;
			this.notePanel_Send_StuNumber.Size = new System.Drawing.Size(64, 22);
			this.notePanel_Send_StuNumber.TabIndex = 36;
			this.notePanel_Send_StuNumber.TabStop = false;
			this.notePanel_Send_StuNumber.Text = "ѧ  ºÅ:";
			//
			// notePanel_Send_StuClass
			//
			this.notePanel_Send_StuClass.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
			this.notePanel_Send_StuClass.BackColor = System.Drawing.Color.FromArgb(((System.Byte)(224)), ((System.Byte)(224)), ((System.Byte)(224)));
			this.notePanel_Send_StuClass.BackColor2 = System.Drawing.Color.DarkGray;
			this.notePanel_Send_StuClass.Font = new System.Drawing.Font("Tahoma", 8F);
			this.notePanel_Send_StuClass.ForeColor = System.Drawing.Color.Black;
			this.notePanel_Send_StuClass.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical;
			this.notePanel_Send_StuClass.Location = new System.Drawing.Point(425, 32);
			this.notePanel_Send_StuClass.MaxRows = 5;
			this.notePanel_Send_StuClass.Name = "notePanel_Send_StuClass";
			this.notePanel_Send_StuClass.ParentAutoHeight = true;
			this.notePanel_Send_StuClass.Size = new System.Drawing.Size(64, 22);
			this.notePanel_Send_StuClass.TabIndex = 35;
			this.notePanel_Send_StuClass.TabStop = false;
			this.notePanel_Send_StuClass.Text = "°à  ¼¶:";
			//
			// notePanel_Send_StuGrade
			//
			this.notePanel_Send_StuGrade.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
			this.notePanel_Send_StuGrade.BackColor = System.Drawing.Color.FromArgb(((System.Byte)(224)), ((System.Byte)(224)), ((System.Byte)(224)));
			this.notePanel_Send_StuGrade.BackColor2 = System.Drawing.Color.DarkGray;
			this.notePanel_Send_StuGrade.Font = new System.Drawing.Font("Tahoma", 8F);
			this.notePanel_Send_StuGrade.ForeColor = System.Drawing.Color.Black;
			this.notePanel_Send_StuGrade.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical;
			this.notePanel_Send_StuGrade.Location = new System.Drawing.Point(287, 32);
			this.notePanel_Send_StuGrade.MaxRows = 5;
			this.notePanel_Send_StuGrade.Name = "notePanel_Send_StuGrade";
			this.notePanel_Send_StuGrade.ParentAutoHeight = true;
			this.notePanel_Send_StuGrade.Size = new System.Drawing.Size(64, 22);
			this.notePanel_Send_StuGrade.TabIndex = 34;
			this.notePanel_Send_StuGrade.TabStop = false;
			this.notePanel_Send_StuGrade.Text = "Äê  ¼¶:";
			//
			// notePanel_Send_StuName
			//
			this.notePanel_Send_StuName.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
			this.notePanel_Send_StuName.BackColor = System.Drawing.Color.FromArgb(((System.Byte)(224)), ((System.Byte)(224)), ((System.Byte)(224)));
			this.notePanel_Send_StuName.BackColor2 = System.Drawing.Color.DarkGray;
			this.notePanel_Send_StuName.Font = new System.Drawing.Font("Tahoma", 8F);
			this.notePanel_Send_StuName.ForeColor = System.Drawing.Color.Black;
			this.notePanel_Send_StuName.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical;
			this.notePanel_Send_StuName.Location = new System.Drawing.Point(27, 32);
			this.notePanel_Send_StuName.MaxRows = 5;
			this.notePanel_Send_StuName.Name = "notePanel_Send_StuName";
			this.notePanel_Send_StuName.ParentAutoHeight = true;
			this.notePanel_Send_StuName.Size = new System.Drawing.Size(64, 22);
			this.notePanel_Send_StuName.TabIndex = 33;
			this.notePanel_Send_StuName.TabStop = false;
			this.notePanel_Send_StuName.Text = "ÐÕ  Ãû:";
			//
			// groupControl1
			//
			this.groupControl1.AppearanceCaption.Font = new System.Drawing.Font("Tahoma", 9F, System.Drawing.FontStyle.Bold);
			this.groupControl1.AppearanceCaption.ForeColor = System.Drawing.Color.DarkOrange;
			this.groupControl1.AppearanceCaption.Options.UseFont = true;
			this.groupControl1.AppearanceCaption.Options.UseForeColor = true;
			this.groupControl1.Controls.Add(this.groupControl3);
			this.groupControl1.Controls.Add(this.gridControl1);
			this.groupControl1.Controls.Add(this.groupControl4);
			this.groupControl1.Dock = System.Windows.Forms.DockStyle.Fill;
			this.groupControl1.Location = new System.Drawing.Point(0, 104);
			this.groupControl1.Name = "groupControl1";
			this.groupControl1.Size = new System.Drawing.Size(584, 384);
			this.groupControl1.TabIndex = 23;
			this.groupControl1.Text = "±à¼ºÅÂë²¾";
			//
			// groupControl3
			//
			this.groupControl3.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
				| System.Windows.Forms.AnchorStyles.Right)));
			this.groupControl3.Controls.Add(this.simpleButton_EditPhoneNum);
			this.groupControl3.Controls.Add(this.notePanel1);
			this.groupControl3.Controls.Add(this.notePanel2);
			this.groupControl3.Controls.Add(this.textEdit1);
			this.groupControl3.Controls.Add(this.textEdit2);
			this.groupControl3.Location = new System.Drawing.Point(232, 24);
			this.groupControl3.Name = "groupControl3";
			this.groupControl3.Size = new System.Drawing.Size(336, 160);
			this.groupControl3.TabIndex = 24;
			this.groupControl3.Text = "¶ÔÑ¡¶¨Ñ§ÉúÐÂÔöºÅÂë";
			//
			// simpleButton_EditPhoneNum
			//
			this.simpleButton_EditPhoneNum.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
			this.simpleButton_EditPhoneNum.Location = new System.Drawing.Point(240, 120);
			this.simpleButton_EditPhoneNum.Name = "simpleButton_EditPhoneNum";
			this.simpleButton_EditPhoneNum.Size = new System.Drawing.Size(72, 24);
			this.simpleButton_EditPhoneNum.TabIndex = 22;
			this.simpleButton_EditPhoneNum.Text = "ÐÂÔö";
			this.simpleButton_EditPhoneNum.Click += new System.EventHandler(this.simpleButton_EditPhoneNum_Click);
			//
			// notePanel1
			//
			this.notePanel1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
			this.notePanel1.BackColor = System.Drawing.Color.FromArgb(((System.Byte)(224)), ((System.Byte)(224)), ((System.Byte)(224)));
			this.notePanel1.BackColor2 = System.Drawing.Color.DarkGray;
			this.notePanel1.Font = new System.Drawing.Font("Tahoma", 8F);
			this.notePanel1.ForeColor = System.Drawing.Color.Black;
			this.notePanel1.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical;
			this.notePanel1.Location = new System.Drawing.Point(32, 40);
			this.notePanel1.MaxRows = 5;
			this.notePanel1.Name = "notePanel1";
			this.notePanel1.ParentAutoHeight = true;
			this.notePanel1.Size = new System.Drawing.Size(128, 22);
			this.notePanel1.TabIndex = 34;
			this.notePanel1.TabStop = false;
			this.notePanel1.Text = "³ÖÓÐÊÖ»ú¼Ò³¤ÐÕÃû:";
			//
			// notePanel2
			//
			this.notePanel2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
			this.notePanel2.BackColor = System.Drawing.Color.FromArgb(((System.Byte)(224)), ((System.Byte)(224)), ((System.Byte)(224)));
			this.notePanel2.BackColor2 = System.Drawing.Color.DarkGray;
			this.notePanel2.Font = new System.Drawing.Font("Tahoma", 8F);
			this.notePanel2.ForeColor = System.Drawing.Color.Black;
			this.notePanel2.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical;
			this.notePanel2.Location = new System.Drawing.Point(32, 80);
			this.notePanel2.MaxRows = 5;
			this.notePanel2.Name = "notePanel2";
			this.notePanel2.ParentAutoHeight = true;
			this.notePanel2.Size = new System.Drawing.Size(128, 22);
			this.notePanel2.TabIndex = 34;
			this.notePanel2.TabStop = false;
			this.notePanel2.Text = "×¢²á·þÎñÊÖ»úºÅÂë:";
			//
			// textEdit1
			//
			this.textEdit1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
			this.textEdit1.EditValue = "";
			this.textEdit1.Location = new System.Drawing.Point(168, 40);
			this.textEdit1.Name = "textEdit1";
			this.textEdit1.Size = new System.Drawing.Size(136, 23);
			this.textEdit1.TabIndex = 37;
			//
			// textEdit2
			//
			this.textEdit2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
			this.textEdit2.EditValue = "";
			this.textEdit2.Location = new System.Drawing.Point(168, 80);
			this.textEdit2.Name = "textEdit2";
			this.textEdit2.Size = new System.Drawing.Size(136, 23);
			this.textEdit2.TabIndex = 37;
			this.textEdit2.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.textEdit2_KeyPress);
			//
			// gridControl1
			//
			this.gridControl1.Dock = System.Windows.Forms.DockStyle.Left;
			//
			// gridControl1.EmbeddedNavigator
			//
			this.gridControl1.EmbeddedNavigator.Name = "";
			this.gridControl1.Location = new System.Drawing.Point(3, 18);
			this.gridControl1.MainView = this.gridView1;
			this.gridControl1.Name = "gridControl1";
			this.gridControl1.Size = new System.Drawing.Size(221, 363);
			this.gridControl1.TabIndex = 23;
			this.gridControl1.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] {
																										this.gridView1});
			//
			// gridView1
			//
			this.gridView1.Columns.AddRange(new DevExpress.XtraGrid.Columns.GridColumn[] {
																							 this.gridColumn1,
																							 this.gridColumn2,
																							 this.gridColumn3,
																							 this.gridColumn4,
																							 this.gridColumn5});
			this.gridView1.GridControl = this.gridControl1;
			this.gridView1.Name = "gridView1";
			this.gridView1.OptionsBehavior.Editable = false;
			this.gridView1.OptionsCustomization.AllowFilter = false;
			this.gridView1.OptionsCustomization.AllowGroup = false;
			this.gridView1.OptionsView.ShowFilterPanel = false;
			this.gridView1.OptionsView.ShowFooter = true;
			this.gridView1.OptionsView.ShowGroupPanel = false;
			this.gridView1.FocusedRowChanged += new DevExpress.XtraGrid.Views.Base.FocusedRowChangedEventHandler(this.gridView1_FocusedRowChanged);
			//
			// gridColumn1
			//
			this.gridColumn1.Caption = "ѧºÅ";
			this.gridColumn1.FieldName = "info_stuNumber";
			this.gridColumn1.Name = "gridColumn1";
			this.gridColumn1.Visible = true;
			this.gridColumn1.VisibleIndex = 0;
			//
			// gridColumn2
			//
			this.gridColumn2.Caption = "ÐÕÃû";
			this.gridColumn2.FieldName = "info_stuName";
			this.gridColumn2.Name = "gridColumn2";
			this.gridColumn2.Visible = true;
			this.gridColumn2.VisibleIndex = 1;
			//
			// gridColumn3
			//
			this.gridColumn3.Caption = "Ä꼶";
			this.gridColumn3.FieldName = "info_gradeName";
			this.gridColumn3.Name = "gridColumn3";
			this.gridColumn3.Visible = true;
			this.gridColumn3.VisibleIndex = 2;
			//
			// gridColumn4
			//
			this.gridColumn4.Caption = "°à¼¶";
			this.gridColumn4.FieldName = "info_className";
			this.gridColumn4.Name = "gridColumn4";
			this.gridColumn4.Visible = true;
			this.gridColumn4.VisibleIndex = 3;
			//
			// gridColumn5
			//
			this.gridColumn5.Caption = "gridColumn5";
			this.gridColumn5.FieldName = "info_stuID";
			this.gridColumn5.Name = "gridColumn5";
			//
			// groupControl4
			//
			this.groupControl4.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
				| System.Windows.Forms.AnchorStyles.Left)
				| System.Windows.Forms.AnchorStyles.Right)));
			this.groupControl4.Controls.Add(this.gridControl2);
			this.groupControl4.Controls.Add(this.simpleButton2);
			this.groupControl4.Location = new System.Drawing.Point(232, 192);
			this.groupControl4.Name = "groupControl4";
			this.groupControl4.Size = new System.Drawing.Size(336, 184);
			this.groupControl4.TabIndex = 24;
			this.groupControl4.Text = "ÏÔʾѡ¶¨Ñ§ÉúÒÑÌí¼ÓºÅÂë";
			//
			// gridControl2
			//
			this.gridControl2.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
				| System.Windows.Forms.AnchorStyles.Left)));
			//
			// gridControl2.EmbeddedNavigator
			//
			this.gridControl2.EmbeddedNavigator.Name = "";
			this.gridControl2.Location = new System.Drawing.Point(3, 56);
			this.gridControl2.MainView = this.gridView2;
			this.gridControl2.Name = "gridControl2";
			this.gridControl2.Size = new System.Drawing.Size(346, 128);
			this.gridControl2.TabIndex = 22;
			this.gridControl2.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] {
																										this.gridView2});
			//
			// gridView2
			//
			this.gridView2.Columns.AddRange(new DevExpress.XtraGrid.Columns.GridColumn[] {
																							 this.gridColumn6,
																							 this.gridColumn7,
																							 this.gridColumn8});
			this.gridView2.GridControl = this.gridControl2;
			this.gridView2.Name = "gridView2";
			this.gridView2.OptionsBehavior.Editable = false;
			this.gridView2.OptionsCustomization.AllowFilter = false;
			this.gridView2.OptionsCustomization.AllowGroup = false;
			this.gridView2.OptionsView.ShowFilterPanel = false;
			this.gridView2.OptionsView.ShowFooter = true;
			this.gridView2.OptionsView.ShowGroupPanel = false;
			//
			// gridColumn6
			//
			this.gridColumn6.Caption = "³ÖÓÐÊÖ»ú¼Ò³¤ÐÕÃû";
			this.gridColumn6.FieldName = "familial_name";
			this.gridColumn6.Name = "gridColumn6";
			this.gridColumn6.Visible = true;
			this.gridColumn6.VisibleIndex = 0;
			//
			// gridColumn7
			//
			this.gridColumn7.Caption = "×¢²áÊÖ»úºÅÂë";
			this.gridColumn7.FieldName = "mobilePhone_number";
			this.gridColumn7.Name = "gridColumn7";
			this.gridColumn7.Visible = true;
			this.gridColumn7.VisibleIndex = 1;
			//
			// gridColumn8
			//
			this.gridColumn8.Caption = "gridColumn8";
			this.gridColumn8.FieldName = "smsInfo_id";
			this.gridColumn8.Name = "gridColumn8";
			//
			// simpleButton2
			//
			this.simpleButton2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
			this.simpleButton2.Location = new System.Drawing.Point(240, 16);
			this.simpleButton2.Name = "simpleButton2";
			this.simpleButton2.Size = new System.Drawing.Size(72, 24);
			this.simpleButton2.TabIndex = 21;
			this.simpleButton2.Text = "ɾ³ý";
			this.simpleButton2.Click += new System.EventHandler(this.simpleButton2_Click);
			//
			// PhoneNum
			//
			this.Appearance.BackColor = System.Drawing.Color.WhiteSmoke;
			this.Appearance.Options.UseBackColor = true;
			this.Controls.Add(this.groupControl1);
			this.Controls.Add(this.groupControl2);
			this.Controls.Add(this.notePanel_DutyDetailsTitle);
			this.Name = "PhoneNum";
			this.Size = new System.Drawing.Size(584, 488);
			((System.ComponentModel.ISupportInitialize)(this.groupControl2)).EndInit();
			this.groupControl2.ResumeLayout(false);
			((System.ComponentModel.ISupportInitialize)(this.textEdit_Send_StuName.Properties)).EndInit();
			((System.ComponentModel.ISupportInitialize)(this.comboBoxEdit_Send_StuClass.Properties)).EndInit();
			((System.ComponentModel.ISupportInitialize)(this.comboBoxEdit_Send_StuGrade.Properties)).EndInit();
			((System.ComponentModel.ISupportInitialize)(this.textEdit_Send_StuNumber.Properties)).EndInit();
			((System.ComponentModel.ISupportInitialize)(this.groupControl1)).EndInit();
			this.groupControl1.ResumeLayout(false);
			((System.ComponentModel.ISupportInitialize)(this.groupControl3)).EndInit();
			this.groupControl3.ResumeLayout(false);
			((System.ComponentModel.ISupportInitialize)(this.textEdit1.Properties)).EndInit();
			((System.ComponentModel.ISupportInitialize)(this.textEdit2.Properties)).EndInit();
			((System.ComponentModel.ISupportInitialize)(this.gridControl1)).EndInit();
			((System.ComponentModel.ISupportInitialize)(this.gridView1)).EndInit();
			((System.ComponentModel.ISupportInitialize)(this.groupControl4)).EndInit();
			this.groupControl4.ResumeLayout(false);
			((System.ComponentModel.ISupportInitialize)(this.gridControl2)).EndInit();
			((System.ComponentModel.ISupportInitialize)(this.gridView2)).EndInit();
			this.ResumeLayout(false);

		}
		#endregion

		#region load student into
		private void comboBoxEdit_Send_StuGrade_SelectedIndexChanged(object sender, System.EventArgs e)
		{
			comboBoxEdit_Send_StuClass.Properties.Items.Clear();
			comboBoxEdit_Send_StuClass.Properties.Items.AddRange(new object[]{"È«²¿"});
			comboBoxEdit_Send_StuClass.SelectedItem = "È«²¿";
			if(getStuInfoByCondition.getGradeInfo(comboBoxEdit_Send_StuGrade.SelectedItem.ToString(),"").Tables[0].Rows.Count > 0)
			{
				//¸ù¾ÝÄ꼶ѡÔñ»ñÈ¡Ä꼶±àºÅ
				getGradeNumberFromCombo = getStuInfoByCondition.getGradeInfo(
					comboBoxEdit_Send_StuGrade.SelectedItem.ToString(),"").Tables[0].Rows[0][0].ToString();
				foreach(DataRow getClassList in getStuInfoByCondition.getClassInfo("","",
					getGradeNumberFromCombo).Tables[0].Rows)
				{
					comboBoxEdit_Send_StuClass.Properties.Items.AddRange(
						new object[]{getClassList[1].ToString()});
				}
			}

			//¸ù¾ÝÄ꼶²éѯËùÑ¡ÐÅÏ¢
			if(!comboBoxEdit_Send_StuGrade.SelectedItem.ToString().Equals("È«²¿"))
			{
				SelectStuCardInfo(textEdit_Send_StuName.Text.Trim(),textEdit_Send_StuNumber.Text.Trim(),
					comboBoxEdit_Send_StuGrade.SelectedItem.ToString().Trim(), comboBoxEdit_Send_StuClass
					.SelectedItem.ToString().Trim());
			}
			else
			{
				SelectStuCardInfo(textEdit_Send_StuName.Text.Trim(),textEdit_Send_StuNumber.Text.Trim(),
					string.Empty,comboBoxEdit_Send_StuClass.SelectedItem.ToString().Trim());
			}
		}

		private void comboBoxEdit_Send_StuClass_SelectedIndexChanged(object sender, System.EventArgs e)
		{
			if(!comboBoxEdit_Send_StuClass.SelectedItem.ToString().Equals("È«²¿"))
			{
				SelectStuCardInfo(textEdit_Send_StuName.Text.Trim(),textEdit_Send_StuNumber.Text.Trim(),
					comboBoxEdit_Send_StuGrade.SelectedItem.ToString().Trim(), comboBoxEdit_Send_StuClass
					.SelectedItem.ToString().Trim());
			}
			else
			{
				SelectStuCardInfo(textEdit_Send_StuName.Text.Trim(),textEdit_Send_StuNumber.Text.Trim(),
					comboBoxEdit_Send_StuGrade.SelectedItem.ToString().Trim(),string.Empty);
			}
		}

		private void textEdit_Send_StuName_EditValueChanged(object sender, System.EventArgs e)
		{
			if(StuView!=null)
			{
				SelectStuCardInfo(textEdit_Send_StuName.Text.Trim(),textEdit_Send_StuNumber.Text.Trim(),
					comboBoxEdit_Send_StuGrade.SelectedItem.ToString().Trim(), comboBoxEdit_Send_StuClass
					.SelectedItem.ToString().Trim());
			}
		}

		private void textEdit_Send_StuNumber_EditValueChanged(object sender, System.EventArgs e)
		{
			if(StuView!=null)
			{
				SelectStuCardInfo(textEdit_Send_StuName.Text.Trim(),textEdit_Send_StuNumber.Text.Trim(),
					comboBoxEdit_Send_StuGrade.SelectedItem.ToString().Trim(), comboBoxEdit_Send_StuClass
					.SelectedItem.ToString().Trim());
			}
		}

		//¹ýÂËDataView
		private void SelectStuCardInfo(string name,string id,string grade,string className)
		{
			string rowFilter = string.Empty;

			DataSet TeaDept = new RolesSystem().GetRolesDuty(Convert.ToInt32(Thread.CurrentPrincipal.Identity.Name));

			if(!Thread.CurrentPrincipal.IsInRole("Ô°³¤")
				&&!Thread.CurrentPrincipal.IsInRole("񜫭"))
			{
				rowFilter = "info_stuName like '%"+name+"%'";
				rowFilter = rowFilter + " and info_gradeName = '"
					+TeaDept.Tables[0].Rows[0][0].ToString()+"'";

				rowFilter = rowFilter + " and info_className = '"
					+TeaDept.Tables[0].Rows[0][1].ToString()+"'";

				if(id.Length==4)
				{
					rowFilter += " and info_stuNumber="+id;
				}
			}
			else
			{
				rowFilter = "info_stuName like '%"+name+"%'";

				if(grade.Equals("È«²¿"))
				{
					rowFilter = rowFilter + " and info_gradeName like '%'";
				}
				else
				{
					rowFilter = rowFilter + " and info_gradeName like '%"+
						grade+"%'";
				}

				if(className.Equals("È«²¿"))
				{
					rowFilter = rowFilter + " and info_className like '%'";
				}
				else
				{
					rowFilter = rowFilter + " and info_className like '%"+className+"%'";
				}

				if(id.Length==4)
				{
					rowFilter += " and info_stuNumber="+id;
				}
			}

			StuView.RowFilter = rowFilter;
			gridControl1.DataSource = StuView;

			if(gridView1.RowCount==0)
				return;

			string selectedStuID = (gridView1.GetDataRow(gridView1.GetSelectedRows()[0])["info_stuID"]).ToString();
			DisplayStuPhoneNum(selectedStuID);
		}

		private void gridView1_FocusedRowChanged(object sender, DevExpress.XtraGrid.Views.Base.FocusedRowChangedEventArgs e)
		{
			string selectedStuID = (gridView1.GetDataRow(gridView1.GetSelectedRows()[0])["info_stuID"]).ToString();
			DisplayStuPhoneNum(selectedStuID);
		}

		private void DisplayStuPhoneNum(string stuID)
		{
			DataSet stuPhoneNum = new SMSInfoSystem().GetStuPhoneNum(stuID);
			gridControl2.DataSource = stuPhoneNum.Tables[0];
		}
		#endregion

		#region add new Phone number
		private void simpleButton_EditPhoneNum_Click(object sender, System.EventArgs e)
		{
			if(gridView1.GetSelectedRows().Length==0)
			{
				MessageBox.Show("ÇëÏÈÑ¡¶¨Ò»¸öÒªÌí¼ÓµÄѧÉú.","ϵͳÐÅÏ¢!",
					MessageBoxButtons.OK,MessageBoxIcon.Information);
				return;
			}

			if(textEdit1.Text.Trim()==string.Empty||
				textEdit2.Text.Trim()==string.Empty
				||textEdit2.Text.Trim().Length!=11)
			{
				MessageBox.Show("¼Ò³¤ÐÕÃûºÍºÅÂë±ØÐëÌîд.","ϵͳÐÅÏ¢!",
					MessageBoxButtons.OK,MessageBoxIcon.Information);
				return;
			}

			string stuid = gridView1.GetDataRow(gridView1.GetSelectedRows()[0])["info_stuID"].ToString();
			string familialName = textEdit1.Text.Trim();
			string mobilePhoneNum = textEdit2.Text.Trim();
			string stuGrade = gridView1.GetDataRow(gridView1.GetSelectedRows()[0])["info_gradeName"].ToString();
			string stuClass = gridView1.GetDataRow(gridView1.GetSelectedRows()[0])["info_className"].ToString();

			if(new SMSInfoSystem().InsertSMSPhoneNum(stuid,familialName,mobilePhoneNum,
				stuGrade,stuClass)>0)
			{
				DisplayStuPhoneNum(stuid);
				textEdit1.Text = string.Empty;
				textEdit1.Text = string.Empty;
				MessageBox.Show("²åÈë³É¹¦.","ϵͳÐÅÏ¢!",
					MessageBoxButtons.OK,MessageBoxIcon.Information);
			}
		}
		#endregion

		#region delete Phone number
		private void simpleButton2_Click(object sender, System.EventArgs e)
		{
			if(gridView2.RowCount==0)
			{
				MessageBox.Show("ÇëÏÈÑ¡¶¨Ò»¸öҪɾ³ýµÄѧÉúºÅÂë.","ϵͳÐÅÏ¢!",
					MessageBoxButtons.OK,MessageBoxIcon.Information);
				return;
			}

			int smsInfo_id = Convert.ToInt32(gridView2.GetDataRow(gridView2.GetSelectedRows()[0])["smsInfo_id"]);

			if(new SMSInfoSystem().DeleteSMSPhoneNum(smsInfo_id)>0)
			{
				gridView2.DeleteRow(gridView2.GetSelectedRows()[0]);
				MessageBox.Show("ɾ³ý³É¹¦.","ϵͳÐÅÏ¢!",
					MessageBoxButtons.OK,MessageBoxIcon.Information);
			}
		}
		#endregion

		#region validate the mobile phone number
		private void textEdit2_KeyPress(object sender, System.Windows.Forms.KeyPressEventArgs e)
		{
			if(!Char.IsDigit(e.KeyChar)&&!Char.IsControl(e.KeyChar))
			{
				MessageBox.Show("ÇëÊäÈëÕýÈ·µÄ11λÊÖ»úºÅÂë!","³ö´íÁË!",
					MessageBoxButtons.OK,MessageBoxIcon.Information);
				e.Handled = true;
			}

			if(textEdit2.Text.Trim().Length>10)
			{
				MessageBox.Show("ÇëÊäÈëÕýÈ·µÄ11λÊÖ»úºÅÂë!","³ö´íÁË!",
					MessageBoxButtons.OK,MessageBoxIcon.Information);
				e.Handled = true;
			}
		}
		#endregion

	}
}


text:
package com.github.mauricio.async.db.mysql.binary.encoder

import io.netty.buffer.ByteBuf
import org.joda.time.{LocalDateTime, DateTime}
import com.github.mauricio.async.db.mysql.column.ColumnTypes

object SQLTimestampEncoder extends BinaryEncoder {
  def encode(value: Any, buffer: ByteBuf) = {
    val date = value.asInstanceOf[java.sql.Timestamp]
    LocalDateTimeEncoder.encode(new LocalDateTime(date.getTime), buffer)
  }

  def encodesTo: Int = ColumnTypes.FIELD_TYPE_TIMESTAMP
}


text:
// options for all high level API functions.
function defaultOptions() {
  return {
    logHl: true, // log this high level action
    logLl: false, // log lower level actions
    passHl: true, // is high level action increase pass counter
    passLl: false, // is low level actions increase pass counter
    passLlPrinting: true,
  };
}

/**
 * Wraps some generator for high level actions.
 * @param gen
 * @param msg
 * @param options
 */
export function* wrapGenerator(gen: Function, msg: string, options: any) {
  const opts = gT.commonMiscUtils.mergeOptions(options, defaultOptions);

  if (opts.logHl) {
    gT.l.println(`BEGIN: "${msg}"`);
  }

  // In case of fail, the state will be restored before next test.
  const oldLogLl = gT.lL.setDefaultLlLogAction(opts.logLl);
  const oldPassLl = gT.lL.setLlPassCounting(opts.passLl);
  const oldPassLlPrinting = gT.lL.setLlPassPrinting(opts.passLlPrinting);

  const res = yield* gen();

  gT.lL.setDefaultLlLogAction(oldLogLl);
  gT.lL.setLlPassCounting(oldPassLl);
  gT.lL.setLlPassPrinting(oldPassLlPrinting);

  if (opts.logHl) {
    gT.l.println(`END: "${msg}"`);
  }

  if (opts.passHl) {
    gIn.tInfo.addPassForce();
  }

  return res;
}

export async function wrapAsync(func: Function, msg: string, options: any) {
  const opts = gT.commonMiscUtils.mergeOptions(options, defaultOptions);

  if (opts.logHl) {
    gT.l.println(`BEGIN: "${msg}"`);
  }

  // In case of fail, the state will be restored before next test.
  const oldLogLl = gT.lL.setDefaultLlLogAction(opts.logLl);
  const oldPassLl = gT.lL.setLlPassCounting(opts.passLl);
  const oldPassLlPrinting = gT.lL.setLlPassPrinting(opts.passLlPrinting);

  const res = await func();

  gT.lL.setDefaultLlLogAction(oldLogLl);
  gT.lL.setLlPassCounting(oldPassLl);
  gT.lL.setLlPassPrinting(oldPassLlPrinting);

  if (opts.logHl) {
    gT.l.println(`END: "${msg}"`);
  }

  if (opts.passHl) {
    gIn.tInfo.addPassForce();
  }

  return res;
}


text:
package main

// void start(void);
import "C"

func init() {
	register("CgoExternalThreadPanic", CgoExternalThreadPanic)
}

func CgoExternalThreadPanic() {
	C.start()
	select {}
}

//export gopanic
func gopanic() {
	panic("BOOM")
}


text:
'use strict';

var isImplemented = require('../../../../array/#/slice/is-implemented');

module.exports = function (a) {
  a(isImplemented(), true);
};

//# sourceMappingURL=implement-compiled.js.map


text:
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.config;

/**
 * Superclass for all leaf nodes in a {@link ConfigInstance}.
 * <p>
 * Subclasses represent leaf nodes with different types. These
 * implementations should implement method value() with return-value
 * corresponding to the actual type.
 *
 */
public abstract class LeafNode<T> extends Node implements Cloneable {

    protected boolean initialized;
    protected T value;

    /**
     * Creates a new, uninitialized LeafNode
     */
    protected LeafNode() {
        initialized = false;
    }

    /**
     * Creates a new LeafNode.
     *
     * @param initialized true if this node is initialized.
     */
    protected LeafNode(boolean initialized) {
        this.initialized = initialized;
    }

    public T value() {
        return value;
    }

    /**
     * Subclasses must implement this, in compliance with the rules given in the return tag.
     *
     * @return the String representation of the node value, or the string "(null)" if the value is null.
     */
    public abstract String toString();

    /**
     * Subclasses must implement this, in compliance with the rules given in the return tag.
     *
     * @return the String representation of the node value, or the 'null' object if the node value is null.
     */
    public abstract String getValue();

    /**
     * Sets the value based on a string representation. Returns false if the value could
     * not be set from the given string.
     * TODO: return void (see doSetValue)
     *
     * @param value the value to set
     * @return true on success, false otherwise
     * @throws IllegalArgumentException when value is null
     */
    protected final boolean setValue(String value) {
        if (value == null)
            throw new IllegalArgumentException("Null value is not allowed");
        return doSetValue(value);
    }

    // TODO: should throw exception instead of return false.
    protected abstract boolean doSetValue(String value);

    /**
     * This method is meant for internal use in the configuration
     * system. Overrides Object.clone().
     *
     * @return a new instance similar to this object.
     */
    @Override
    protected LeafNode<?> clone() {
        try {
            return (LeafNode<?>) super.clone();
        } catch (CloneNotSupportedException e) {
            throw new ConfigurationRuntimeException(e);
        }
    }

    @Override
    public boolean equals(Object o) {
        if (! (o instanceof LeafNode<?> other)) return false;

        return value == null ? other.value == null :  value().equals(other.value);
    }

    @Override
    public int hashCode() {
        return (value == null) ? 0 : value.hashCode();
    }

    void serialize(String name, Serializer serializer) {
        serializer.serialize(name, getValue());
    }

    void serialize(Serializer serializer) {
        serializer.serialize(getValue());
    }

}


text:
@extends('voyager::master')

@section('css')
    <link rel="stylesheet" type="text/css" href="{{ config('voyager.assets_path') }}/css/nestable.css">
@stop

@section('page_header')

        Menu Builder ({{ $menu->name }})

 New Menu Item

@stop

@section('page_header_actions')

@stop

@section('content')

Drag and drop the menu Items below to re-arrange
                            them.

                            <?= Menu::display($menu->name, 'admin'); ?>

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

 Are you sure you want to delete this menu
                        item?

                    <form action="{{ route('voyager.dashboard') }}/menu/delete_menu_item" id="delete_form"
                          method="POST">
                        <input type="hidden" name="_method" value="DELETE">
                        <input type="hidden" name="_token" value="{{ csrf_token() }}">
                        <input type="submit" class="btn btn-danger pull-right delete-confirm"
                               value="Yes, Delete This Menu Item">
                    </form>
                    <button type="button" class="btn btn-default pull-right" data-dismiss="modal">Cancel</button>

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

 Create a New Menu Item

                <form action="{{ route('voyager.menu.add_item') }}" id="delete_form" method="POST">

                        Title of the Menu Item
                        <input type="text" class="form-control" name="title" placeholder="Title">

                        URL for the Menu Item
                        <input type="text" class="form-control" name="url" placeholder="URL">

                        Font Icon class for the Menu Item (Use a Voyager Font Class)
                        <input type="text" class="form-control" name="icon_class"
                               placeholder="Icon Class (optional)">

                        Color in RGB or hex (optional)
                        <input type="color" class="form-control" name="color"
                               placeholder="Color (ex. #ffffff or rgb(255, 255, 255)">

                        Open In
                        <select id="edit_target" class="form-control" name="target">
                            <option value="_self">Same Tab/Window</option>
                            <option value="_blank">New Tab/Window</option>
                        </select>
                        <input type="hidden" name="menu_id" value="{{ $menu->id }}">

                    <input type="hidden" name="_token" value="{{ csrf_token() }}">

                        <input type="submit" class="btn btn-success pull-right delete-confirm" value="Add New Item">
                        <button type="button" class="btn btn-default pull-right" data-dismiss="modal">Cancel</button>

                </form>

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

 Edit Menu Item

                <form action="{{ route('voyager.menu.update_menu_item') }}" id="edit_form" method="POST">

                        Title of the Menu Item
                        <input type="text" class="form-control" id="edit_title" name="title" placeholder="Title">

                        URL for the Menu Item
                        <input type="text" class="form-control" id="edit_url" name="url" placeholder="URL">

                        Font Icon class for the Menu Item
                        <input type="text" class="form-control" id="edit_icon_class" name="icon_class"
                               placeholder="Icon Class (optional)">

                        Color in RGB or hex (optional)
                        <input type="color" class="form-control" id="edit_color" name="color"
                               placeholder="Color (ex. #ffffff or rgb(255, 255, 255)">

                        Open In
                        <select id="edit_target" class="form-control" name="target">
                            <option value="_self" selected="selected">Same Tab/Window</option>
                            <option value="_blank">New Tab/Window</option>
                        </select>
                        <input type="hidden" name="id" id="edit_id" value="">

                    <input type="hidden" name="_token" value="{{ csrf_token() }}">
                    <input type="hidden" name="_method" value="PUT">

                        <input type="submit" class="btn btn-success pull-right delete-confirm" value="Update">
                        <button type="button" class="btn btn-default pull-right" data-dismiss="modal">Cancel</button>

                </form>

@stop

@section('javascript')

@stop


text:
CREATE DATABASE  IF NOT EXISTS `ejercicio27` /*!40100 DEFAULT CHARACTER SET utf8 */;
USE `ejercicio27`;
-- MySQL dump 10.13  Distrib 5.6.13, for osx10.6 (i386)
--
-- Host: 127.0.0.1    Database: ejercicio27
-- ------------------------------------------------------
-- Server version	5.6.21

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

--
-- Table structure for table `paginas`
--

DROP TABLE IF EXISTS `paginas`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `paginas` (
  `codigo` int(11) NOT NULL AUTO_INCREMENT,
  `titulo` varchar(45) DEFAULT NULL,
  `usuario` varchar(10) DEFAULT NULL,
  PRIMARY KEY (`codigo`),
  KEY `usuario_idx` (`usuario`),
  CONSTRAINT `usuario` FOREIGN KEY (`usuario`) REFERENCES `usuarios` (`login`) ON DELETE NO ACTION ON UPDATE NO ACTION
) ENGINE=InnoDB AUTO_INCREMENT=12 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `paginas`
--

LOCK TABLES `paginas` WRITE;
/*!40000 ALTER TABLE `paginas` DISABLE KEYS */;
INSERT INTO `paginas` VALUES (6,'Nueva pagina','oihane'),(8,'Nueva pagina 2','oihane'),(10,'Prueba','oihane'),(11,'Prueba','oihane');
/*!40000 ALTER TABLE `paginas` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `recursos`
--

DROP TABLE IF EXISTS `recursos`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `recursos` (
  `codigo` int(11) NOT NULL AUTO_INCREMENT,
  `contenido` longtext,
  `url` varchar(45) DEFAULT NULL,
  `cod_pagina` int(11) DEFAULT NULL,
  PRIMARY KEY (`codigo`),
  KEY `cod_pagina_idx` (`cod_pagina`),
  CONSTRAINT `cod_pagina` FOREIGN KEY (`cod_pagina`) REFERENCES `paginas` (`codigo`) ON DELETE NO ACTION ON UPDATE NO ACTION
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `recursos`
--

LOCK TABLES `recursos` WRITE;
/*!40000 ALTER TABLE `recursos` DISABLE KEYS */;
INSERT INTO `recursos` VALUES (5,'Primera frase',NULL,6),(6,'Segunda frase',NULL,6),(7,NULL,'2014-11-19 18.42.45.jpg',6),(8,'Tercera frase',NULL,6),(9,NULL,'2014-11-19 18.42.47.jpg',6),(10,'Cuarta frase despues de imagen',NULL,6);
/*!40000 ALTER TABLE `recursos` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `usuarios`
--

DROP TABLE IF EXISTS `usuarios`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `usuarios` (
  `login` varchar(10) NOT NULL,
  `password` varchar(10) NOT NULL,
  `nombre` varchar(45) DEFAULT NULL,
  PRIMARY KEY (`login`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `usuarios`
--

LOCK TABLES `usuarios` WRITE;
/*!40000 ALTER TABLE `usuarios` DISABLE KEYS */;
INSERT INTO `usuarios` VALUES ('oihane','oihane','Oihane García');
/*!40000 ALTER TABLE `usuarios` ENABLE KEYS */;
UNLOCK TABLES;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

-- Dump completed on 2014-12-18 12:40:11


text:
import nose
from skbeam.testing.noseclasses import KnownFailure

plugins = [KnownFailure]
# env = {"NOSE_WITH_COVERAGE": 1,
#        'NOSE_COVER_PACKAGE': 'skbeam',
#        'NOSE_COVER_HTML': 1}
env = {}
# Nose doesn't automatically instantiate all of the plugins in the
# child processes, so we have to provide the multiprocess plugin with
# a list.
from nose.plugins import multiprocess
multiprocess._instantiate_plugins = plugins

def run():

    nose.main(addplugins=[x() for x in plugins], env=env)

if __name__ == '__main__':
    run()