This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.e6sh.beautiful.mind | |
import com.e6sh.beautiful.mind.cmd.POSCardQueryCommand | |
import org.codehaus.groovy.grails.web.metaclass.BindDynamicMethod | |
def bind = new BindDynamicMethod() | |
def cmd = new POSCardQueryCommand() | |
//cmd.properties = params |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import ch.qos.logback.core.FileAppender; | |
import ch.qos.logback.core.ConsoleAppender; | |
import org.gunn.spring.demo.AppContextFilter; | |
import ch.qos.logback.classic.encoder.PatternLayoutEncoder; | |
import static ch.qos.logback.classic.Level.DEBUG; | |
import static ch.qos.logback.classic.Level.INFO; | |
appender("FILE",FileAppender){ | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package org.gunn.osgi.web.demo; | |
import java.lang.reflect.Field; | |
import org.osgi.framework.BundleActivator; | |
import org.osgi.framework.BundleContext; | |
import org.eclipse.osgi.framework.adaptor.ClassLoaderDelegate; | |
import org.eclipse.osgi.framework.internal.core.BundleHost; | |
import org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
''' | |
Created on Oct 17, 2012 | |
@author: gengjet | |
''' | |
from mako.template import Template | |
import os | |
import re |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Name('Select-Commit') @Audit | |
select a.* from pattern [ a=CommitEvent(userName='tom') and timer:at(0, 16, *, *, *) ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import os | |
import re | |
import subprocess | |
import sys | |
modified = re.compile('^(?:M|A)(\s+)(?P<name>.*)') | |
CHECKS = [ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
from pyaudio import PyAudio, paInt16 | |
import numpy as np | |
from datetime import datetime | |
import wave | |
# 将data中的数据保存到名为filename的WAV文件中 | |
def save_wave_file(filename, data): | |
wf = wave.open(filename, 'wb') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import wx | |
import cv2.cv as cv | |
class WebcamPlayback(wx.Panel): | |
TIMER_PLAY_ID = 101 | |
def __init__(self, parent, id): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
''' | |
Created on Aug 11, 2012 | |
@author: gengjet | |
''' | |
from xml.sax import make_parser, handler | |