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
| // | |
| // HomeController.swift | |
| // PokeMath | |
| // | |
| // Created by Ondrej Kvasnovsky on 11/19/16. | |
| // Copyright © 2016 Ondrej Kvasnovsky. All rights reserved. | |
| // | |
| import Foundation | |
| import UIKit |
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 com.kangoapp.view.history; | |
| import java.util.ArrayDeque; | |
| import java.util.Deque; | |
| public class History<ENTITY> { | |
| private Deque<ENTITY> backStack = new ArrayDeque<>(); | |
| private Deque<ENTITY> forwardStack; | |
| private ENTITY current; |
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 com.kangoapp.view.search; | |
| import java.util.ArrayList; | |
| import java.util.List; | |
| import java.util.function.IntPredicate; | |
| import java.util.stream.IntStream; | |
| import static org.apache.commons.lang3.StringUtils.containsIgnoreCase; | |
| /** |
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
| JSON format: | |
| [ | |
| "AND", | |
| ["GE", ["column", "Price"], 10], | |
| ["EQ", ["column", "Product"], "iPhone"], | |
| ["NOT", | |
| [ | |
| "OR", | |
| ["GE", ["column", "Discount"], 1000], |
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
| enum State { | |
| A, B, C | |
| } | |
| class Test { | |
| State a() { | |
| "A" | |
| } | |
| } | |
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 com.rest.app | |
| import org.springframework.boot.SpringApplication | |
| import org.springframework.boot.autoconfigure.SpringBootApplication | |
| import org.springframework.context.annotation.ComponentScan | |
| @SpringBootApplication | |
| @ComponentScan(["com.rest"]) | |
| class RestApp { |
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
| List excludedGroovyClasses() { | |
| String srcDir = System.getProperty("user.dir") + "/src/main/groovy/" | |
| FileTree tree = fileTree(dir: 'src/main/groovy') | |
| tree.include '**/*.groovy' | |
| String immutableSign = 'import groovy.transform.Immutable' | |
| Collection excludedClasses = tree.findAll { | |
| it.text.contains(immutableSign) | |
| }.collect { |
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 init() { | |
| registerHandler(); | |
| } | |
| let eventBus; | |
| function registerHandler() { | |
| eventBus = new EventBus('http://localhost:8080/eventbus'); | |
| eventBus.onopen = function () { | |
| eventBus.registerHandler('out', function (error, message) { |
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
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <meta charset="utf-8"> | |
| <title>Vert.x with SockJS</title> | |
| <script src="//cdn.jsdelivr.net/sockjs/0.3.4/sockjs.min.js"></script> | |
| <script src="js/vertx-eventbus.js"></script> | |
| <script src="js/app.js"></script> | |
| </head> | |
| <body onload="init();"> |
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 counter; | |
| import io.vertx.core.AbstractVerticle; | |
| import io.vertx.core.eventbus.EventBus; | |
| import io.vertx.core.shareddata.SharedData; | |
| import io.vertx.ext.bridge.PermittedOptions; | |
| import io.vertx.ext.web.Router; | |
| import io.vertx.ext.web.handler.StaticHandler; | |
| import io.vertx.ext.web.handler.sockjs.BridgeOptions; | |
| import io.vertx.ext.web.handler.sockjs.SockJSHandler; |