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.yonyou.dmscloud.passengerflow.domain.model; | |
public class StateMachine { | |
ReceptionRecord context; | |
State state; | |
StateMachine(ReceptionRecord context) { | |
this.context = context; | |
this.state = State.Initial; |
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
public void ModifyInstsAndChannels(ChannelEditRequest request) | |
{ | |
var merchantInsts = _dbfd.MerchantInst.Where(mi => mi.MerchantId == request.MerchantId).ToList(); | |
var query = (from miNew in request.MerchantInsts | |
join mi in merchantInsts | |
on miNew.InstCode equals mi.InstCode into g | |
from miOld in g.DefaultIfEmpty() | |
select new { miNew, miOld }); | |
var list = query.ToList(); | |
foreach (var pair in list) |
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 main | |
import ( | |
"io" | |
"os" | |
"strings" | |
) | |
func convert(b byte) byte { | |
switch { |
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 main | |
import "fmt" | |
// fibonacci 函数会返回一个返回 int 的函数。 | |
func fibonacci() func() int { | |
n0 := 0 | |
n1 := 1 | |
return func() int { | |
n2 := n0 + n1 |
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 main | |
import "fmt" | |
// fibonacci 函数会返回一个返回 int 的函数。 | |
func fibonacci() func() int { | |
n0 := 0 | |
n1 := 1 | |
return func() int { | |
n2 := n0 + n1 |
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 main | |
import "fmt" | |
// fibonacci 函数会返回一个返回 int 的函数。 | |
func fibonacci() func() int { | |
n0 := 0 | |
n1 := 1 | |
return func() int { | |
n2 := n0 + n1 |
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
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
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
public class Order { | |
public int orderId; | |
} | |
public static class OrderService { | |
private static Order[] s_orders = new Order[3]; | |
public static Response findOrder(final int orderId) { | |
Response resp = new Response(); |
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
# old version is 3.3.2, update to 3.3.4 | |
bower update bootstrap --save |
NewerOlder