This file contains hidden or 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
| function throttle( fn, time ) { | |
| var t = 0; | |
| return function() { | |
| var args = arguments, ctx = this; | |
| clearTimeout(t); | |
| t = setTimeout( function() { | |
| fn.apply( ctx, args ); | |
| }, time ); | |
| }; |
This file contains hidden or 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
| dialect "java" import com.sand.sale.dao.entity.SaleDailyBatch; | |
| rule "Rule1" when | |
| $p : SaleDailyBatch( | |
| ((merId == "4000000" && termId == "000001") || (merId == "4000001" && termId == "000002")) | |
| && (cardNo matches ".*(1001|2002)") | |
| && (transAmt ((> 100 && <= 200))) ) | |
| then $p.setMustPay("yes"); end |
This file contains hidden or 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
| rule "Rule 01" | |
| when | |
| $cashflow : Cashflow( $date : date, $amount : amount ) | |
| not Cashflow( date < $date) | |
| then | |
| System.out.println("Cashflow: "+$date+" :: "+$amount); | |
| retract($cashflow); | |
| end |
This file contains hidden or 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
| <plugin> | |
| <groupId>org.apache.maven.plugins</groupId> | |
| <artifactId>maven-shade-plugin</artifactId> | |
| <version>2.3</version> | |
| <configuration> | |
| <transformers> | |
| <transformer | |
| implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer"> | |
| <resource>META-INF/spring.handlers</resource> | |
| </transformer> |
This file contains hidden or 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 main; | |
| import java.sql.*; | |
| import java.util.Properties; | |
| /** | |
| * @author: bohao | |
| */ | |
| public class Jdbb { | |
| public Connection getConn() { |
This file contains hidden or 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 service.impl; | |
| import entity.Message; | |
| import org.springframework.jdbc.core.JdbcTemplate; | |
| import org.springframework.jdbc.datasource.DriverManagerDataSource; | |
| import service.FooService; | |
| /** | |
| * Created by wang.bh | |
| */ |
This file contains hidden or 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 main; | |
| /** | |
| * @author: bohao | |
| */ | |
| public class Pad | |
| { | |
| public static String leftPad(String pass) { | |
| return String.format("%10s",pass).replace(' ', '0'); | |
| } |
This file contains hidden or 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 chap06; | |
| import java.util.concurrent.TimeUnit; | |
| /** | |
| * Created by wang.bh | |
| */ | |
| class Bag { | |
| private final String item; // <-- no final here |
This file contains hidden or 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
| # INSTALL INSTRUCTIONS: save as ~/.gdbinit | |
| # | |
| # DESCRIPTION: A user-friendly gdb configuration file. | |
| # | |
| # REVISION : 7.3 (16/04/2010) | |
| # | |
| # CONTRIBUTORS: mammon_, elaine, pusillus, mong, zhang le, l0kit, | |
| # truthix the cyberpunk, fG!, gln | |
| # | |
| # FEEDBACK: https://www.reverse-engineering.net |
This file contains hidden or 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
| int mon_backtrace(int argc, char **argv, struct M *m) { | |
| uint32_t *ebp = (uint32_t*)read_ebp(); | |
| uint32_t *base, *eip; | |
| int i; | |
| eip = ebp + 1; | |
| for (ebp = POINTTO(ebp) ; *ebp != 0 ; ebp = POINTTO(ebp)) { | |
| base = ebp + 1; | |
| printf("ebp %08x eip %08x args", *ebp, *eip); | |
| for (i = 1; i <= 5; i++) { |