id
int64
1
49k
buggy
stringlengths
34
37.5k
fixed
stringlengths
2
37k
10,201
} public FluentSelects selects(By by) { MultipleResult multiple = multiple(by, "select"); return newFluentSelects(multiple.getResult(), multiple.getCtx()); } <BUG>public FluentWebElement h1() { </BUG> SingleResult single = single(tagName("h1"), "h1"); return newFluentWebElement(delegate, single.getResult(), single.getCtx()); }
protected BaseFluentWebElements spans() { return newFluentWebElements(multiple(tagName("span"), "span"));
10,202
import java.util.Date; import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.TimeZone; <BUG>import java.util.Locale; import org.zkoss.util.Dates;</BUG> import org.zkoss.util.Locales; import org.zkoss.util.TimeZones; import org.zkoss.text.DateFormats;
import org.zkoss.lang.Objects; import org.zkoss.util.Dates;
10,203
private boolean _btnVisible = true, _lenient = true, _dtzonesReadonly = false; static { addClientEvent(Datebox.class, "onTimeZoneChange", CE_IMPORTANT|CE_DUPLICATE_IGNORE); } public Datebox() { <BUG>setFormat(getDefaultFormat()); setCols(11);</BUG> } public Datebox(Date date) throws WrongValueException { this();
setFormat(""); setCols(11);
10,204
} protected String getDefaultFormat() { return DateFormats.getDateFormat(DateFormat.DEFAULT, _locale, DEFAULT_FORMAT); } protected String getLocalizedFormat() { <BUG>String format = getFormat(); if (format == null) format = getDefaultFormat(); return new SimpleDateFormat(format, </BUG> _locale != null ? _locale: Locales.getCurrent()).toLocalizedPattern();
public Datebox() { setFormat(""); setCols(11); public Datebox(Date date) throws WrongValueException { this(); setValue(date); return new SimpleDateFormat(getRealFormat(),
10,205
return new Date(((Date) value).getTime() + TimeZones.getCurrent().getRawOffset() - _tzone.getRawOffset()); } protected Object coerceFromString(String value) throws WrongValueException { if (value == null || value.length() == 0) return null; <BUG>final String fmt = getFormat(); </BUG> final DateFormat df = getDateFormat(fmt); df.setLenient(_lenient); final Date date;
final String fmt = getRealFormat();
10,206
MZul.DATE_REQUIRED, new Object[] { value, fmt })); } return date; } protected String coerceToString(Object value) { <BUG>final DateFormat df = getDateFormat(getFormat()); </BUG> return value != null ? df.format((Date) value) : ""; } protected DateFormat getDateFormat(String fmt) {
final DateFormat df = getDateFormat(getRealFormat());
10,207
public class Timebox extends FormatInputElement implements org.zkoss.zul.api.Timebox { private Locale _locale; private boolean _btnVisible = true; public Timebox() { setCols(5); <BUG>setFormat(getDefaultFormat()); }</BUG> public Timebox(Date date) throws WrongValueException { this(); setValue(date);
setFormat(""); }
10,208
new Object[] {value, fmt})); } return date; } protected String coerceToString(Object value) { <BUG>final DateFormat df = getDateFormat(getFormat()); </BUG> return value != null ? df.format((Date) value) : ""; } protected DateFormat getDateFormat(String fmt) {
final DateFormat df = getDateFormat(getRealFormat());
10,209
CallFuture(Call call, int priority, Span span) { this.call = call; this.priority = priority; this.span = span; } <BUG>} private enum WaitForWorkResult { READ_RESPONSE, CALLER_SHOULD_CLOSE, CLOSED</BUG> }
[DELETED]
10,210
expectedCall = (call != null && !call.done); if (!expectedCall) { int readSoFar = IPCUtil.getTotalSizeWhenWrittenDelimited(responseHeader); int whatIsLeftToRead = totalSize - readSoFar; IOUtils.skipFully(in, whatIsLeftToRead); <BUG>return false; }</BUG> if (responseHeader.hasException()) { ExceptionResponse exceptionResponse = responseHeader.getException(); RemoteException re = createRemoteException(exceptionResponse);
return; }
10,211
if (responseHeader.hasException()) { ExceptionResponse exceptionResponse = responseHeader.getException(); RemoteException re = createRemoteException(exceptionResponse); call.setException(re); if (isFatalConnectionException(exceptionResponse)) { <BUG>return markClosed(re); }</BUG> } else { Message value = null; if (call.responseDefaultType != null) {
}
10,212
if (LOG.isTraceEnabled()) { LOG.trace(getName() + ": marking at should close, reason: " + e.getMessage()); } if (callSender != null) { callSender.close(); <BUG>} } return ret;</BUG> } protected synchronized void cleanupCalls(boolean allCalls) {
notifyAll();
10,213
this(conf, clusterId, NetUtils.getDefaultSocketFactory(conf), localAddr); } @Override public void close() { if (LOG.isDebugEnabled()) LOG.debug("Stopping rpc client"); <BUG>if (!running.compareAndSet(true, false)) return; synchronized (connections) {</BUG> for (Connection conn : connections.values()) { conn.interrupt(); if (conn.callSender != null) {
Set<Connection> connsToClose = null; synchronized (connections) {
10,214
package org.apache.cxf.staxutils.validation; import java.util.Map; <BUG>import java.util.TreeMap; import java.util.logging.Logger;</BUG> import javax.xml.XMLConstants; import javax.xml.stream.XMLStreamException; import javax.xml.stream.XMLStreamReader;
import java.util.logging.Level; import java.util.logging.Logger;
10,215
import javax.xml.stream.XMLStreamException; import javax.xml.stream.XMLStreamReader; import javax.xml.stream.XMLStreamWriter; import org.w3c.dom.Element; import org.apache.cxf.common.i18n.Message; <BUG>import org.apache.cxf.common.logging.LogUtils; import org.apache.cxf.interceptor.Fault;</BUG> import org.apache.cxf.service.model.SchemaInfo; import org.apache.cxf.service.model.ServiceInfo; import org.apache.cxf.staxutils.DepthXMLStreamReader;
import org.apache.cxf.endpoint.Endpoint; import org.apache.cxf.interceptor.Fault;
10,216
} EmbeddedSchema embeddedSchema = new EmbeddedSchema(schemaSystemId, serialized); sources.put(sch.getTargetNamespace(), embeddedSchema); } W3CMultiSchemaFactory factory = new W3CMultiSchemaFactory(); <BUG>XMLValidationSchema vs; vs = factory.loadSchemas(null, sources); return vs; } } </BUG>
final XMLStreamReader2 reader2 = (XMLStreamReader2)effectiveReader; XMLValidationSchema vs = getValidator(endpoint, serviceInfo); if (vs == null) { return false;
10,217
import java.util.logging.Level; import java.util.logging.Logger; import javax.xml.stream.XMLStreamException; import javax.xml.stream.XMLStreamReader; import javax.xml.stream.XMLStreamWriter; <BUG>import org.apache.cxf.common.logging.LogUtils; import org.apache.cxf.service.model.ServiceInfo;</BUG> public class WoodstoxValidationImpl { private static final Logger LOG = LogUtils.getL7dLogger(WoodstoxValidationImpl.class); private Stax2ValidationUtils utils;
import org.apache.cxf.endpoint.Endpoint; import org.apache.cxf.service.model.ServiceInfo;
10,218
throw new IllegalArgumentException("Can't save an empty KnowledgeBase."); } dbc.saveObject("modelParameters", modelParameters); dbc.saveObject("trainingParameters", trainingParameters); } <BUG>public void load() { </BUG> if(!isInitialized()) { modelParameters = dbc.loadObject("modelParameters", mpClass); trainingParameters = dbc.loadObject("trainingParameters", tpClass);
public void init() {
10,219
modelParameters.setCols(components.getColumnDimension()); modelParameters.setEigenValues(eigenValues); modelParameters.setComponents(components.getData()); } @Override <BUG>protected void filterFeatures(Dataframe dataset) { </BUG> ModelParameters modelParameters = knowledgeBase.getModelParameters(); Map<Object, Integer> featureIds= modelParameters.getFeatureIds(); Map<Integer, Integer> recordIdsReference = new HashMap<>();
protected void _transform(Dataframe dataset) {
10,220
mlregressor.close(); mlregressor = null; super.close(); } @Override <BUG>protected void _predictDataset(Dataframe newData) { loadRegressor();</BUG> mlregressor.predict(newData); } @Override
protected void _predict(Dataframe newData) { loadRegressor();
10,221
testDataset.delete(); return r; } public ClassificationMetrics validate(Dataframe testDataset) { logger.info("validate()"); <BUG>knowledgeBase.load(); </BUG> preprocessTestDataset(testDataset); modeler.predict(testDataset); ClassificationMetrics vm = new ClassificationMetrics(testDataset);
knowledgeBase.init();
10,222
modeler.predict(testDataset); ClassificationMetrics vm = new ClassificationMetrics(testDataset); return vm; } public ClassificationMetrics validate(Map<Object, URI> datasets) { <BUG>knowledgeBase.load(); </BUG> TextClassifier.TrainingParameters trainingParameters = knowledgeBase.getTrainingParameters(); Dataframe testDataset = Dataframe.Builder.parseTextFiles( datasets,
knowledgeBase.init();
10,223
public Modeler(String dbName, Configuration conf) { super(dbName, conf, Modeler.ModelParameters.class, Modeler.TrainingParameters.class); } public void predict(Dataframe newData) { logger.info("predict()"); <BUG>knowledgeBase.load(); </BUG> Modeler.TrainingParameters trainingParameters = knowledgeBase.getTrainingParameters(); Configuration conf = knowledgeBase.getConf(); Class dtClass = trainingParameters.getDataTransformerClass();
knowledgeBase.init();
10,224
import com.datumbox.framework.core.utilities.text.tokenizers.WhitespaceTokenizer; import java.util.*; import java.util.regex.Matcher; import java.util.regex.Pattern; public class ReadabilityStatistics { <BUG>private static final Set<String> DALECHALL_WORDLIST = Collections.unmodifiableSet(new HashSet<>(Arrays.asList("a", "able", "aboard", "about", "above", "absent", "accept", "accident", "account", "ache", "aching", "acorn", "acre", "across", "act", "acts", "add", "address", "admire", "adventure", "afar", "afraid", "after", "afternoon", "afterward", "afterwards", "again", "against", "age", "aged", "ago", "agree", "ah", "ahead", "aid", "aim", "air", "airfield", "airplane", "airport", "airship", "airy", "alarm", "alike", "alive", "all", "alley", "alligator", "allow", "almost", "alone", "along", "aloud", "already", "also", "always", "am", "America", "American", "among", "amount", "an", "and", "angel", "anger", "angry", "animal", "another", "answer", "ant", "any", "anybody", "anyhow", "anyone", "anything", "anyway", "anywhere", "apart", "apartment", "ape", "apiece", "appear", "apple", "April", "apron", "are", "aren\'t", "arise", "arithmetic", "arm", "armful", "army", "arose", "around", "arrange", "arrive", "arrived", "arrow", "art", "artist", "as", "ash", "ashes", "aside", "ask", "asleep", "at", "ate", "attack", "attend", "attention", "August", "aunt", "author", "auto", "automobile", "autumn", "avenue", "awake", "awaken", "away", "awful", "awfully", "awhile", "ax", "axe", "baa", "babe", "babies", "back", "background", "backward", "backwards", "bacon", "bad", "badge", "badly", "bag", "bake", "baker", "bakery", "baking", "ball", "balloon", "banana", "band", "bandage", "bang", "banjo", "bank", "banker", "bar", "barber", "bare", "barefoot", "barely", "bark", "barn", "barrel", "base", "baseball", "basement", "basket", "bat", "batch", "bath", "bathe", "bathing", "bathroom", "bathtub", "battle", "battleship", "bay", "be", "beach", "bead", "beam", "bean", "bear", "beard", "beast", "beat", "beating", "beautiful", "beautify", "beauty", "became", "because", "become", "becoming", "bed", "bedbug", "bedroom", "bedspread", "bedtime", "bee", "beech", "beef", "beefsteak", "beehive", "been", "beer", "beet", "before", "beg", "began", "beggar", "begged", "begin", "beginning", "begun", "behave", "behind", "being", "believe", "bell", "belong", "below", "belt", "bench", "bend", "beneath", "bent", "berries", "berry", "beside", "besides", "best", "bet", "better", "between", "bib", "bible", "bicycle", "bid", "big", "bigger", "bill", "billboard", "bin", "bind", "bird", "birth", "birthday", "biscuit", "bit", "bite", "biting", "bitter", "black", "blackberry", "blackbird", "blackboard", "blackness", "blacksmith", "blame", "blank", "blanket", "blast", "blaze", "bleed", "bless", "blessing", "blew", "blind", "blindfold", "blinds", "block", "blood", "bloom", "blossom", "blot", "blow", "blue", "blueberry", "bluebird", "blush", "board", "boast", "boat", "bob", "bobwhite", "bodies", "body", "boil", "boiler", "bold", "bone", "bonnet", "boo", "book", "bookcase", "bookkeeper", "boom", "boot", "born", "borrow", "boss", "both", "bother", "bottle", "bottom", "bought", "bounce", "bow", "bowl", "bow-wow", "box", "boxcar", "boxer", "boxes", "boy", "boyhood", "bracelet", "brain", "brake", "bran", "branch", "brass", "brave", "bread", "break", "breakfast", "breast", "breath", "breathe", "breeze", "brick", "bride", "bridge", "bright", "brightness", "bring", "broad", "broadcast", "broke", "broken", "brook", "broom", "brother", "brought", "brown", "brush", "bubble", "bucket", "buckle", "bud", "buffalo", "bug", "buggy", "build", "building", "built", "bulb", "bull", "bullet", "bum", "bumblebee", "bump", "bun", "bunch", "bundle", "bunny", "burn", "burst", "bury", "bus", "bush", "bushel", "business", "busy", "but", "butcher", "butt", "butter", "buttercup", "butterfly", "buttermilk", "butterscotch", "button", "buttonhole", "buy", "buzz", "by", "bye", "cab", "cabbage", "cabin", "cabinet", "cackle", "cage", "cake", "calendar", "calf", "call", "caller", "calling", "came", "camel", "camp", "campfire", "can", "canal", "canary", "candle", "candlestick", "candy", "cane", "cannon", "cannot", "canoe", "can\'t", "canyon", "cap", "cape", "capital", "captain", "car", "card", "cardboard", "care", "careful", "careless", "carelessness", "carload", "carpenter", "carpet", "carriage", "carrot", "carry", "cart", "carve", "case", "cash", "cashier", "castle", "cat", "catbird", "catch", "catcher", "caterpillar", "catfish", "catsup", "cattle", "caught", "cause", "cave", "ceiling", "cell", "cellar", "cent", "center", "cereal", "certain", "certainly", "chain", "chair", "chalk", "champion", "chance", "change", "chap", "charge", "charm", "chart", "chase", "chatter", "cheap", "cheat", "check", "checkers", "cheek", "cheer", "cheese", "cherry", "chest", "chew", "chick", "chicken", "chief", "child", "childhood", "children", "chill", "chilly", "chimney", "chin", "china", "chip", "chipmunk", "chocolate", "choice", "choose", "chop", "chorus", "chose", "chosen", "christen", "Christmas", "church", "churn", "cigarette", "circle", "circus", "citizen", "city", "clang", "clap", "class", "classmate", "classroom", "claw", "clay", "clean", "cleaner", "clear", "clerk", "clever", "click", "cliff", "climb", "clip", "cloak", "clock", "close", "closet", "cloth", "clothes", "clothing", "cloud", "cloudy", "clover", "clown", "club", "cluck", "clump", "coach", "coal", "coast", "coat", "cob", "cobbler", "cocoa", "coconut", "cocoon", "cod", "codfish", "coffee", "coffeepot", "coin", "cold", "collar", "college", "color", "colored", "colt", "column", "comb", "come", "comfort", "comic", "coming", "company", "compare", "conductor", "cone", "connect", "coo", "cook", "cooked", "cooking", "cookie", "cookies", "cool", "cooler", "coop", "copper", "copy", "cord", "cork", "corn", "corner", "correct", "cost", "cot", "cottage", "cotton", "couch", "cough", "could", "couldn\'t", "count", "counter", "country", "county", "course", "court", "cousin", "cover", "cow", "coward", "cowardly", "cowboy", "cozy", "crab", "crack", "cracker", "cradle", "cramps", "cranberry", "crank", "cranky", "crash", "crawl", "crazy", "cream", "creamy", "creek", "creep", "crept", "cried", "croak", "crook", "crooked", "crop", "cross", "crossing", "cross-eyed", "crow", "crowd", "crowded", "crown", "cruel", "crumb", "crumble", "crush", "crust", "cry", "cries", "cub", "cuff", "cup", "cuff", "cup", "cupboard", "cupful", "cure", "curl", "curly", "curtain", "curve", "cushion", "custard", "customer", "cut", "cute", "cutting", "dab", "dad", "daddy", "daily", "dairy", "daisy", "dam", "damage", "dame", "damp", "dance", "dancer", "dancing", "dandy", "danger", "dangerous", "dare", "dark", "darkness", "darling", "darn", "dart", "dash", "date", "daughter", "dawn", "day", "daybreak", "daytime", "dead", "deaf", "deal", "dear", "death", "December", "decide", "deck", "deed", "deep", "deer", "defeat", "defend", "defense", "delight", "den", "dentist", "depend", "deposit", "describe", "desert", "deserve", "desire", "desk", "destroy", "devil", "dew", "diamond", "did", "didn\'t", "die", "died", "dies", "difference", "different", "dig", "dim", "dime", "dine", "ding-dong", "dinner", "dip", "direct", "direction", "dirt", "dirty", "discover", "dish", "dislike", "dismiss", "ditch", "dive", "diver", "divide", "do", "dock", "doctor", "does", "doesn\'t", "dog", "doll", "dollar", "dolly", "done", "donkey", "don\'t", "door", "doorbell", "doorknob", "doorstep", "dope", "dot", "double", "dough", "dove", "down", "downstairs", "downtown", "dozen", "drag", "drain", "drank", "draw", "drawer", "draw", "drawing", "dream", "dress", "dresser", "dressmaker", "drew", "dried", "drift", "drill", "drink", "drip", "drive", "driven", "driver", "drop", "drove", "drown", "drowsy", "drub", "drum", "drunk", "dry", "duck", "due", "dug", "dull", "dumb", "dump", "during", "dust", "dusty", "duty", "dwarf", "dwell", "dwelt", "dying", "each", "eager", "eagle", "ear", "early", "earn", "earth", "east", "eastern", "easy", "eat", "eaten", "edge", "egg", "eh", "eight", "eighteen", "eighth", "eighty", "either", "elbow", "elder", "eldest", "electric", "electricity", "elephant", "eleven", "elf", "elm", "else", "elsewhere", "empty", "end", "ending", "enemy", "engine", "engineer", "English", "enjoy", "enough", "enter", "envelope", "equal", "erase", "eraser", "errand", "escape", "eve", "even", "evening", "ever", "every", "everybody", "everyday", "everyone", "everything", "everywhere", "evil", "exact", "except", "exchange", "excited", "exciting", "excuse", "exit", "expect", "explain", "extra", "eye", "eyebrow", "fable", "face", "facing", "fact", "factory", "fail", "faint", "fair", "fairy", "faith", "fake", "fall", "false", "family", "fan", "fancy", "far", "faraway", "fare", "farmer", "farm", "farming", "far-off", "farther", "fashion", "fast", "fasten", "fat", "father", "fault", "favor", "favorite", "fear", "feast", "feather", "February", "fed", "feed", "feel", "feet", "fell", "fellow", "felt", "fence", "fever", "few", "fib", "fiddle", "field", "fife", "fifteen", "fifth", "fifty", "fig", "fight", "figure", "file", "fill", "film", "finally", "find", "fine", "finger", "finish", "fire", "firearm", "firecracker", "fireplace", "fireworks", "firing", "first", "fish", "fisherman", "fist", "fit", "fits", "five", "fix", "flag", "flake", "flame", "flap", "flash", "flashlight", "flat", "flea", "flesh", "flew", "flies", "flight", "flip", "flip-flop", "float", "flock", "flood", "floor", "flop", "flour", "flow", "flower", "flowery", "flutter", "fly", "foam", "fog", "foggy", "fold", "folks", "follow", "following", "fond", "food", "fool", "foolish", "foot", "football", "footprint", "for", "forehead", "forest", "forget", "forgive", "forgot", "forgotten", "fork", "form", "fort", "forth", "fortune", "forty", "forward", "fought", "found", "fountain", "four", "fourteen", "fourth", "fox", "frame", "free", "freedom", "freeze", "freight", "French", "fresh", "fret", "Friday", "fried", "friend", "friendly", "friendship", "frighten", "frog", "from", "front", "frost", "frown", "froze", "fruit", "fry", "fudge", "fuel", "full", "fully", "fun", "funny", "fur", "furniture", "further", "fuzzy", "gain", "gallon", "gallop", "game", "gang", "garage", "garbage", "garden", "gas", "gasoline", "gate", "gather", "gave", "gay", "gear", "geese", "general", "gentle", "gentleman", "gentlemen", "geography", "get", "getting", "giant", "gift", "gingerbread", "girl", "give", "given", "giving", "glad", "gladly", "glance", "glass", "glasses", "gleam", "glide", "glory", "glove", "glow", "glue", "go", "going", "goes", "goal", "goat", "gobble", "God", "god", "godmother", "gold", "golden", "goldfish", "golf", "gone", "good", "goods", "goodbye", "good-by", "goodbye", "good-bye", "good-looking", "goodness", "goody", "goose", "gooseberry", "got", "govern", "government", "gown", "grab", "gracious", "grade", "grain", "grand", "grandchild", "grandchildren", "granddaughter", "grandfather", "grandma", "grandmother", "grandpa", "grandson", "grandstand", "grape", "grapes", "grapefruit", "grass", "grasshopper", "grateful", "grave", "gravel", "graveyard", "gravy", "gray", "graze", "grease", "great", "green", "greet", "grew", "grind", "groan", "grocery", "ground", "group", "grove", "grow", "guard", "guess", "guest", "guide", "gulf", "gum", "gun", "gunpowder", "guy", "ha", "habit", "had", "hadn\'t", "hail", "hair", "haircut", "hairpin", "half", "hall", "halt", "ham", "hammer", "hand", "handful", "handkerchief", "handle", "handwriting", "hang", "happen", "happily", "happiness", "happy", "harbor", "hard", "hardly", "hardship", "hardware", "hare", "hark", "harm", "harness", "harp", "harvest", "has", "hasn\'t", "haste", "hasten", "hasty", "hat", "hatch", "hatchet", "hate", "haul", "have", "haven\'t", "having", "hawk", "hay", "hayfield", "haystack", "he", "head", "headache", "heal", "health", "healthy", "heap", "hear", "hearing", "heard", "heart", "heat", "heater", "heaven", "heavy", "he\'d", "heel", "height", "held", "hell", "he\'ll", "hello", "helmet", "help", "helper", "helpful", "hem", "hen", "henhouse", "her", "hers", "herd", "here", "here\'s", "hero", "herself", "he\'s", "hey", "hickory", "hid", "hidden", "hide", "high", "highway", "hill", "hillside", "hilltop", "hilly", "him", "himself", "hind", "hint", "hip", "hire", "his", "hiss", "history", "hit", "hitch", "hive", "ho", "hoe", "hog", "hold", "holder", "hole", "holiday", "hollow", "holy", "home", "homely", "homesick", "honest", "honey", "honeybee", "honeymoon", "honk", "honor", "hood", "hoof", "hook", "hoop", "hop", "hope", "hopeful", "hopeless", "horn", "horse", "horseback", "horseshoe", "hose", "hospital", "host", "hot", "hotel", "hound", "hour", "house", "housetop", "housewife", "housework", "how", "however", "howl", "hug", "huge", "hum", "humble", "hump", "hundred", "hung", "hunger", "hungry", "hunk", "hunt", "hunter", "hurrah", "hurried", "hurry", "hurt", "husband", "hush", "hut", "hymn", "I", "ice", "icy", "I\'d", "idea", "ideal", "if", "ill", "I\'ll", "I\'m", "important", "impossible", "improve", "in", "inch", "inches", "income", "indeed", "Indian", "indoors", "ink", "inn", "insect", "inside", "instant", "instead", "insult", "intend", "interested", "interesting", "into", "invite", "iron", "is", "island", "isn\'t", "it", "its", "it\'s", "itself", "I\'ve", "ivory", "ivy", "jacket", "jacks", "jail", "jam", "January", "jar", "jaw", "jay", "jelly", "jellyfish", "jerk", "jig", "job", "jockey", "join", "joke", "joking", "jolly", "journey", "joy", "joyful", "joyous", "judge", "jug", "juice", "juicy", "July", "jump", "June", "junior", "junk", "just", "keen", "keep", "kept", "kettle", "key", "kick", "kid", "kill", "killed", "kind", "kindly", "kindness", "king", "kingdom", "kiss", "kitchen", "kite", "kitten", "kitty", "knee", "kneel", "knew", "knife", "knit", "knives", "knob", "knock", "knot", "know", "known", "lace", "lad", "ladder", "ladies", "lady", "laid", "lake", "lamb", "lame", "lamp", "land", "lane", "language", "lantern", "lap", "lard", "large", "lash", "lass", "last", "late", "laugh", "laundry", "law", "lawn", "lawyer", "lay", "lazy", "lead", "leader", "leaf", "leak", "lean", "leap", "learn", "learned", "least", "leather", "leave", "leaving", "led", "left", "leg", "lemon", "lemonade", "lend", "length", "less", "lesson", "let", "let\'s", "letter", "letting", "lettuce", "level", "liberty", "library", "lice", "lick", "lid", "lie", "life", "lift", "light", "lightness", "lightning", "like", "likely", "liking", "lily", "limb", "lime", "limp", "line", "linen", "lion", "lip", "list", "listen", "lit", "little", "live", "lives", "lively", "liver", "living", "lizard", "load", "loaf", "loan", "loaves", "lock", "locomotive", "log", "lone", "lonely", "lonesome", "long", "look", "lookout", "loop", "loose", "lord", "lose", "loser", "loss", "lost", "lot", "loud", "love", "lovely", "lover", "low", "luck", "lucky", "lumber", "lump", "lunch", "lying", "ma", "machine", "machinery", "mad", "made", "magazine", "magic", "maid", "mail", "mailbox", "mailman", "major", "make", "making", "male", "mama", "mamma", "man", "manager", "mane", "manger", "many", "map", "maple", "marble", "march", "March", "mare", "mark", "market", "marriage", "married", "marry", "mask", "mast", "master", "mat", "match", "matter", "mattress", "may", "May", "maybe", "mayor", "maypole", "me", "meadow", "meal", "mean", "means", "meant", "measure", "meat", "medicine", "meet", "meeting", "melt", "member", "men", "mend", "meow", "merry", "mess", "message", "met", "metal", "mew", "mice", "middle", "midnight", "might", "mighty", "mile", "milk", "milkman", "mill", "miler", "million", "mind", "mine", "miner", "mint", "minute", "mirror", "mischief", "miss", "Miss", "misspell", "mistake", "misty", "mitt", "mitten", "mix", "moment", "Monday", "money", "monkey", "month", "moo", "moon", "moonlight", "moose", "mop", "more", "morning", "morrow", "moss", "most", "mostly", "mother", "motor", "mount", "mountain", "mouse", "mouth", "move", "movie", "movies", "moving", "mow", "Mr.", "Mrs.", "much", "mud", "muddy", "mug", "mule", "multiply", "murder", "music", "must", "my", "myself", "nail", "name", "nap", "napkin", "narrow", "nasty", "naughty", "navy", "near", "nearby", "nearly", "neat", "neck", "necktie", "need", "needle", "needn\'t", "Negro", "neighbor", "neighborhood", "neither", "nerve", "nest", "net", "never", "nevermore", "new", "news", "newspaper", "next", "nibble", "nice", "nickel", "night", "nightgown", "nine", "nineteen", "ninety", "no", "nobody", "nod", "noise", "noisy", "none", "noon", "nor", "north", "northern", "nose", "not", "note", "nothing", "notice", "November", "now", "nowhere", "number", "nurse", "nut", "oak", "oar", "oatmeal", "oats", "obey", "ocean", "o\'clock", "October", "odd", "of", "off", "offer", "office", "officer", "often", "oh", "oil", "old", "old-fashioned", "on", "once", "one", "onion", "only", "onward", "open", "or", "orange", "orchard", "order", "ore", "organ", "other", "otherwise", "ouch", "ought", "our", "ours", "ourselves", "out", "outdoors", "outfit", "outlaw", "outline", "outside", "outward", "oven", "over", "overalls", "overcoat", "overeat", "overhead", "overhear", "overnight", "overturn", "owe", "owing", "owl", "own", "owner", "ox", "pa", "pace", "pack", "package", "pad", "page", "paid", "pail", "pain", "painful", "paint", "painter", "painting", "pair", "pal", "palace", "pale", "pan", "pancake", "pane", "pansy", "pants", "papa", "paper", "parade", "pardon", "parent", "park", "part", "partly", "partner", "party", "pass", "passenger", "past", "paste", "pasture", "pat", "patch", "path", "patter", "pave", "pavement", "paw", "pay", "payment", "pea", "peas", "peace", "peaceful", "peach", "peaches", "peak", "peanut", "pear", "pearl", "peck", "peek", "peel", "peep", "peg", "pen", "pencil", "penny", "people", "pepper", "peppermint", "perfume", "perhaps", "person", "pet", "phone", "piano", "pick", "pickle", "picnic", "picture", "pie", "piece", "pig", "pigeon", "piggy", "pile", "pill", "pillow", "pin", "pine", "pineapple", "pink", "pint", "pipe", "pistol", "pit", "pitch", "pitcher", "pity", "place", "plain", "plan", "plane", "plant", "plate", "platform", "platter", "play", "player", "playground", "playhouse", "playmate", "plaything", "pleasant", "please", "pleasure", "plenty", "plow", "plug", "plum", "pocket", "pocketbook", "poem", "point", "poison", "poke", "pole", "police", "policeman", "polish", "polite", "pond", "ponies", "pony", "pool", "poor", "pop", "popcorn", "popped", "porch", "pork", "possible", "post", "postage", "postman", "pot", "potato", "potatoes", "pound", "pour", "powder", "power", "powerful", "praise", "pray", "prayer", "prepare", "present", "pretty", "price", "prick", "prince", "princess", "print", "prison", "prize", "promise", "proper", "protect", "proud", "prove", "prune", "public", "puddle", "puff", "pull", "pump", "pumpkin", "punch", "punish", "pup", "pupil", "puppy", "pure", "purple", "purse", "push", "puss", "pussy", "pussycat", "put", "putting", "puzzle", "quack", "quart", "quarter", "queen", "queer", "question", "quick", "quickly", "quiet", "quilt", "quit", "quite", "rabbit", "race", "rack", "radio", "radish", "rag", "rail", "railroad", "railway", "rain", "rainy", "rainbow", "raise", "raisin", "rake", "ram", "ran", "ranch", "rang", "rap", "rapidly", "rat", "rate", "rather", "rattle", "raw", "ray", "reach", "read", "reader", "reading", "ready", "real", "really", "reap", "rear", "reason", "rebuild", "receive", "recess", "record", "red", "redbird", "redbreast", "refuse", "reindeer", "rejoice", "remain", "remember", "remind", "remove", "rent", "repair", "repay", "repeat", "report", "rest", "return", "review", "reward", "rib", "ribbon", "rice", "rich", "rid", "riddle", "ride", "rider", "riding", "right", "rim", "ring", "rip", "ripe", "rise", "rising", "river", "road", "roadside", "roar", "roast", "rob", "robber", "robe", "robin", "rock", "rocky", "rocket", "rode", "roll", "roller", "roof", "room", "rooster", "root", "rope", "rose", "rosebud", "rot", "rotten", "rough", "round", "route", "row", "rowboat", "royal", "rub", "rubbed", "rubber", "rubbish", "rug", "rule", "ruler", "rumble", "run", "rung", "runner", "running", "rush", "rust", "rusty", "rye", "sack", "sad", "saddle", "sadness", "safe", "safety", "said", "sail", "sailboat", "sailor", "saint", "salad", "sale", "salt", "same", "sand", "sandy", "sandwich", "sang", "sank", "sap", "sash", "sat", "satin", "satisfactory", "Saturday", "sausage", "savage", "save", "savings", "saw", "say", "scab", "scales", "scare", "scarf", "school", "schoolboy", "schoolhouse", "schoolmaster", "schoolroom", "scorch", "score", "scrap", "scrape", "scratch", "scream", "screen", "screw", "scrub", "sea", "seal", "seam", "search", "season", "seat", "second", "secret", "see", "seeing", "seed", "seek", "seem", "seen", "seesaw", "select", "self", "selfish", "sell", "send", "sense", "sent", "sentence", "separate", "September", "servant", "serve", "service", "set", "setting", "settle", "settlement", "seven", "seventeen", "seventh", "seventy", "several", "sew", "shade", "shadow", "shady", "shake", "shaker", "shaking", "shall", "shame", "shan\'t", "shape", "share", "sharp", "shave", "she", "she\'d", "she\'ll", "she\'s", "shear", "shears", "shed", "sheep", "sheet", "shelf", "shell", "shepherd", "shine", "shining", "shiny", "ship", "shirt", "shock", "shoe", "shoemaker", "shone", "shook", "shoot", "shop", "shopping", "shore", "short", "shot", "should", "shoulder", "shouldn\'t", "shout", "shovel", "show", "shower", "shut", "shy", "sick", "sickness", "side", "sidewalk", "sideways", "sigh", "sight", "sign", "silence", "silent", "silk", "sill", "silly", "silver", "simple", "sin", "since", "sing", "singer", "single", "sink", "sip", "sir", "sis", "sissy", "sister", "sit", "sitting", "six", "sixteen", "sixth", "sixty", "size", "skate", "skater", "ski", "skin", "skip", "skirt", "sky", "slam", "slap", "slate", "slave", "sled", "sleep", "sleepy", "sleeve", "sleigh", "slept", "slice", "slid", "slide", "sling", "slip", "slipped", "slipper", "slippery", "slit", "slow", "slowly", "sly", "smack", "small", "smart", "smell", "smile", "smoke", "smooth", "snail", "snake", "snap", "snapping", "sneeze", "snow", "snowy", "snowball", "snowflake", "snuff", "snug", "so", "soak", "soap", "sob", "socks", "sod", "soda", "sofa", "soft", "soil", "sold", "soldier", "sole", "some", "somebody", "somehow", "someone", "something", "sometime", "sometimes", "somewhere", "son", "song", "soon", "sore", "sorrow", "sorry", "sort", "soul", "sound", "soup", "sour", "south", "southern", "space", "spade", "spank", "sparrow", "speak", "speaker", "spear", "speech", "speed", "spell", "spelling", "spend", "spent", "spider", "spike", "spill", "spin", "spinach", "spirit", "spit", "splash", "spoil", "spoke", "spook", "spoon", "sport", "spot", "spread", "spring", "springtime", "sprinkle", "square", "squash", "squeak", "squeeze", "squirrel", "stable", "stack", "stage", "stair", "stall", "stamp", "stand", "star", "stare", "start", "starve", "state", "station", "stay", "steak", "steal", "steam", "steamboat", "steamer", "steel", "steep", "steeple", "steer", "stem", "step", "stepping", "stick", "sticky", "stiff", "still", "stillness", "sting", "stir", "stitch", "stock", "stocking", "stole", "stone", "stood", "stool", "stoop", "stop", "stopped", "stopping", "store", "stork", "stories", "storm", "stormy", "story", "stove", "straight", "strange", "stranger", "strap", "straw", "strawberry", "stream", "street", "stretch", "string", "strip", "stripes", "strong", "stuck", "study", "stuff", "stump", "stung", "subject", "such", "suck", "sudden", "suffer", "sugar", "suit", "sum", "summer", "sun", "Sunday", "sunflower", "sung", "sunk", "sunlight", "sunny", "sunrise", "sunset", "sunshine", "supper", "suppose", "sure", "surely", "surface", "surprise", "swallow", "swam", "swamp", "swan", "swat", "swear", "sweat", "sweater", "sweep", "sweet", "sweetness", "sweetheart", "swell", "swept", "swift", "swim", "swimming", "swing", "switch", "sword", "swore", "table", "tablecloth", "tablespoon", "tablet", "tack", "tag", "tail", "tailor", "take", "taken", "taking", "tale", "talk", "talker", "tall", "tame", "tan", "tank", "tap", "tape", "tar", "tardy", "task", "taste", "taught", "tax", "tea", "teach", "teacher", "team", "tear", "tease", "teaspoon", "teeth", "telephone", "tell", "temper", "ten", "tennis", "tent", "term", "terrible", "test", "than", "thank", "thanks", "thankful", "Thanksgiving", "that", "that\'s", "the", "theater", "thee", "their", "them", "then", "there", "these", "they", "they\'d", "they\'ll", "they\'re", "they\'ve", "thick", "thief", "thimble", "thin", "thing", "think", "third", "thirsty", "thirteen", "thirty", "this", "thorn", "those", "though", "thought", "thousand", "thread", "three", "threw", "throat", "throne", "through", "throw", "thrown", "thumb", "thunder", "Thursday", "thy", "tick", "ticket", "tickle", "tie", "tiger", "tight", "till", "time", "tin", "tinkle", "tiny", "tip", "tiptoe", "tire", "tired", "title", "to", "toad", "toadstool", "toast", "tobacco", "today", "toe", "together", "toilet", "told", "tomato", "tomorrow", "ton", "tone", "tongue", "tonight", "too", "took", "tool", "toot", "tooth", "toothbrush", "toothpick", "top", "tore", "torn", "toss", "touch", "tow", "toward", "towards", "towel", "tower", "town", "toy", "trace", "track", "trade", "train", "tramp", "trap", "tray", "treasure", "treat", "tree", "trick", "tricycle", "tried", "trim", "trip", "trolley", "trouble", "truck", "true", "truly", "trunk", "trust", "truth", "try", "tub", "Tuesday", "tug", "tulip", "tumble", "tune", "tunnel", "turkey", "turn", "turtle", "twelve", "twenty", "twice", "twig", "twin", "two", "ugly", "umbrella", "uncle", "under", "understand", "underwear", "undress", "unfair", "unfinished", "unfold", "unfriendly", "unhappy", "unhurt", "uniform", "United", "States", "unkind", "unknown", "unless", "unpleasant", "until", "unwilling", "up", "upon", "upper", "upset", "upside", "upstairs", "uptown", "upward", "us", "use", "used", "useful", "valentine", "valley", "valuable", "value", "vase", "vegetable", "velvet", "very", "vessel", "victory", "view", "village", "vine", "violet", "visit", "visitor", "voice", "vote", "wag", "wagon", "waist", "wait", "wake", "waken", "walk", "wall", "walnut", "want", "war", "warm", "warn", "was", "wash", "washer", "washtub", "wasn\'t", "waste", "watch", "watchman", "water", "watermelon", "waterproof", "wave", "wax", "way", "wayside", "we", "weak", "weakness", "weaken", "wealth", "weapon", "wear", "weary", "weather", "weave", "web", "we\'d", "wedding", "Wednesday", "wee", "weed", "week", "we\'ll", "weep", "weigh", "welcome", "well", "went", "were", "we\'re", "west", "western", "wet", "we\'ve", "whale", "what", "what\'s", "wheat", "wheel", "when", "whenever", "where", "which", "while", "whip", "whipped", "whirl", "whisky", "whiskey", "whisper", "whistle", "white", "who", "who\'d", "whole", "who\'ll", "whom", "who\'s", "whose", "why", "wicked", "wide", "wife", "wiggle", "wild", "wildcat", "will", "willing", "willow", "win", "wind", "windy", "windmill", "window", "wine", "wing", "wink", "winner", "winter", "wipe", "wire", "wise", "wish", "wit", "witch", "with", "without", "woke", "wolf", "woman", "women", "won", "wonder", "wonderful", "won\'t", "wood", "wooden", "woodpecker", "woods", "wool", "woolen", "word", "wore", "work", "worker", "workman", "world", "worm", "worn", "worry", "worse", "worst", "worth", "would", "wouldn\'t", "wound", "wove", "wrap", "wrapped", "wreck", "wren", "wring", "write", "writing", "written", "wrong", "wrote", "wrung", "yard", "yarn", "year", "yell", "yellow", "yes", "yesterday", "yet", "yolk", "yonder", "you", "you\'d", "you\'ll", "young", "youngster", "your", "yours", "you\'re", "yourself", "yourselves"))); private static final Set<String> SPACHE_WORDLIST = Collections.unmodifiableSet(new HashSet<>(Arrays.asList("a", "able", "about", "above", "across", "act", "add", "afraid", "after", "afternoon", "again", "against", "ago", "air", "airplane", "alarm", "all", "almost", "alone", "along", "already", "also", "always", "am", "among", "an", "and", "angry", "animal", "another", "answer", "any", "anyone", "appear", "apple", "are", "arm", "around", "arrow", "as", "ask", "asleep", "at", "ate", "attention", "aunt", "awake", "away", "b", "baby", "back", "bad", "bag", "ball", "balloon", "bang", "bank", "bark", "barn", "basket", "be", "bean", "bear", "beat", "beautiful", "became", "because", "become", "bed", "bee", "been", "before", "began", "begin", "behind", "believe", "bell", "belong", "bend", "bent", "beside", "best", "better", "between", "big", "bird", "birthday", "bit", "bite", "black", "blanket", "blew", "block", "blow", "blue", "board", "boat", "book", "boot", "born", "borrow", "both", "bother", "bottle", "bottom", "bought", "bow", "box", "boy", "branch", "brave", "bread", "break", "breakfast", "breath", "brick", "bridge", "bright", "bring", "broke", "broken", "brother", "brought", "brown", "brush", "build", "bump", "burn", "bus", "busy", "but", "butter", "button", "buy", "by", "c", "cabin", "cage", "cake", "call", "came", "camp", "can", "candle", "candy", "can\'t", "cap", "captain", "car", "card", "care", "careful", "carrot", "carry", "case", "castle", "cat", "catch", "cattle", "caught", "cause", "cent", "certain", "chair", "chance", "change", "chase", "chicken", "chief", "child", "children", "church", "circle", "circus", "city", "clap", "clean", "clever", "cliff", "climb", "clock", "close", "cloth", "clothes", "clown", "coat", "cold", "color", "come", "comfortable", "company", "contest", "continue", "cook", "cool", "corner", "could", "count", "country", "course", "cover", "cow", "crawl", "cream", "cry", "cup", "curtain", "cut", "d", "Dad", "dance", "danger", "dangerous", "dark", "dash", "daughter", "day", "dear", "decide", "deep", "desk", "did", "didn\'t", "die", "different", "dig", "dinner", "direction", "disappear", "disappoint", "discover", "distance", "do", "doctor", "does", "dog", "dollar", "done", "don\'t", "door", "down", "dragon", "dream", "dress", "drink", "drive", "drop", "drove", "dry", "duck", "during", "dust", "e", "each", "eager", "ear", "early", "earn", "earth", "easy", "eat", "edge", "egg", "eight", "eighteen", "either", "elephant", "else", "empty", "end", "enemy", "enough", "enter", "even", "ever", "every", "everything", "exact", "except", "excite", "exclaim", "explain", "eye", "face", "fact", "fair", "fall", "family", "far", "farm", "farmer", "farther", "fast", "fat", "father", "feather", "feed", "feel", "feet", "fell", "fellow", "felt", "fence", "few", "field", "fierce", "fight", "figure", "fill", "final", "find", "fine", "finger", "finish", "fire", "first", "fish", "five", "flag", "flash", "flat", "flew", "floor", "flower", "fly", "follow", "food", "for", "forest", "forget", "forth", "found", "four", "fourth", "fox", "fresh", "friend", "frighten", "frog", "from", "front", "fruit", "full", "fun", "funny", "fur", "g", "game", "garden", "gasp", "gate", "gave", "get", "giant", "gift", "girl", "give", "glad", "glass", "go", "goat", "gone", "good", "got", "grandfather", "grandmother", "grass", "gray", "great", "green", "grew", "grin", "ground", "group", "grow", "growl", "guess", "gun", "h", "had", "hair", "half", "hall", "hand", "handle", "hang", "happen", "happiness", "happy", "hard", "harm", "has", "hat", "hate", "have", "he", "head", "hear", "heard", "heavy", "held", "hello", "help", "hen", "her", "here", "herself", "he\'s", "hid", "hide", "high", "hill", "him", "himself", "his", "hit", "hold", "hole", "holiday", "home", "honey", "hop", "horn", "horse", "hot", "hour", "house", "how", "howl", "hum", "hundred", "hung", "hungry", "hunt", "hurry", "hurt", "husband", "i", "I", "ice", "idea", "if", "I\'ll", "I\'m", "imagine", "important", "in", "inch", "indeed", "inside", "instead", "into", "invite", "is", "it", "it\'s", "its", "j", "jacket", "jar", "jet", "job", "join", "joke", "joy", "jump", "just", "k", "keep", "kept", "key", "kick", "kill", "kind", "king", "kitchen", "kitten", "knee", "knew", "knock", "know", "l", "ladder", "lady", "laid", "lake", "land", "large", "last", "late", "laugh", "lay", "lazy", "lead", "leap", "learn", "least", "leave", "left", "leg", "less", "let", "let\'s", "letter", "lick", "lift", "light", "like", "line", "lion", "list", "listen", "little", "live", "load", "long", "look", "lost", "lot", "loud", "love", "low", "luck", "lump", "lunch", "m", "machine", "made", "magic", "mail", "make", "man", "many", "march", "mark", "market", "master", "matter", "may", "maybe", "me", "mean", "meant", "meat", "meet", "melt", "men", "merry", "met", "middle", "might", "mile", "milk", "milkman", "mind", "mine", "minute", "miss", "mistake", "moment", "money", "monkey", "month", "more", "morning", "most", "mother", "mountain", "mouse", "mouth", "move", "much", "mud", "music", "must", "my", "n", "name", "near", "neck", "need", "needle", "neighbor", "neighborhood", "nest", "never", "new", "next", "nibble", "nice", "night", "nine", "no", "nod", "noise", "none", "north", "nose", "not", "note", "nothing", "notice", "now", "number", "o", "ocean", "of", "off", "offer", "often", "oh", "old", "on", "once", "one", "only", "open", "or", "orange", "order", "other", "our", "out", "outside", "over", "owl", "own", "p", "pack", "paid", "pail", "paint", "pair", "palace", "pan", "paper", "parade", "parent", "park", "part", "party", "pass", "past", "pasture", "path", "paw", "pay", "peanut", "peek", "pen", "penny", "people", "perfect", "perhaps", "person", "pet", "pick", "picnic", "picture", "pie", "piece", "pig", "pile", "pin", "place", "plan", "plant", "play", "pleasant", "please", "plenty", "plow", "picket", "point", "poke", "pole", "policeman", "pond", "poor", "pop", "postman", "pot", "potato", "pound", "pour", "practice", "prepare", "present", "pretend", "pretty", "princess", "prize", "probably", "problem", "promise", "protect", "proud", "puff", "pull", "puppy", "push", "put", "q", "queen", "queer", "quick", "quiet", "quite", "r", "rabbit", "raccoon", "race", "radio", "rag", "rain", "raise", "ran", "ranch", "rang", "reach", "read", "ready", "real", "red", "refuse", "remember", "reply", "rest", "return", "reward", "rich", "ride", "right", "ring", "river", "road", "roar", "rock", "rode", "roll", "roof", "room", "rope", "round", "row", "rub", "rule", "run", "rush", "s", "sad", "safe", "said", "sail", "sale", "salt", "same", "sand", "sang", "sat", "save", "saw", "say", "scare", "school", "scold", "scratch", "scream", "sea", "seat", "second", "secret", "see", "seed", "seem", "seen", "sell", "send", "sent", "seven", "several", "sew", "shadow", "shake", "shall", "shape", "she", "sheep", "shell", "shine", "ship", "shoe", "shone", "shook", "shoot", "shop", "shore", "short", "shot", "should", "show", "sick", "side", "sight", "sign", "signal", "silent", "silly", "silver", "since", "sing", "sister", "sit", "six", "size", "skip", "sky", "sled", "sleep", "slid", "slide", "slow", "small", "smart", "smell", "smile", "smoke", "snap", "sniff", "snow", "so", "soft", "sold", "some", "something", "sometimes", "son", "song", "soon", "sorry", "sound", "speak", "special", "spend", "spill", "splash", "spoke", "spot", "spread", "spring", "squirrel", "stand", "star", "start", "station", "stay", "step", "stick", "still", "stone", "stood", "stop", "store", "story", "straight", "strange", "street", "stretch", "strike", "strong", "such", "sudden", "sugar", "suit", "summer", "sun", "supper", "suppose", "sure", "surprise", "swallow", "sweet", "swim", "swing", "t", "table", "tail", "take", "talk", "tall", "tap", "taste", "teach", "teacher", "team", "tear", "teeth", "telephone", "tell", "ten", "tent", "than", "thank", "that", "that\'s", "the", "their", "them", "then", "there", "these", "they", "thick", "thin", "thing", "think", "third", "this", "those", "though", "thought", "three", "threw", "through", "throw", "tie", "tiger", "tight", "time", "tiny", "tip", "tire", "to", "today", "toe", "together", "told", "tomorrow", "too", "took", "tooth", "top", "touch", "toward", "tower", "town", "toy", "track", "traffic", "train", "trap", "tree", "trick", "trip", "trot", "truck", "true", "trunk", "try", "turkey", "turn", "turtle", "twelve", "twin", "two", "u", "ugly", "uncle", "under", "unhappy", "until", "up", "upon", "upstairs", "us", "use", "usual", "v", "valley", "vegetable", "very", "village", "visit", "voice", "w", "wag", "wagon", "wait", "wake", "walk", "want", "war", "warm", "was", "wash", "waste", "watch", "water", "wave", "way", "we", "wear", "weather", "week", "well", "went", "were", "wet", "what", "wheel", "when", "where", "which", "while", "whisper", "whistle", "white", "who", "whole", "whose", "why", "wide", "wife", "will", "win", "wind", "window", "wing", "wink", "winter", "wire", "wise", "wish", "with", "without", "woke", "wolf", "woman", "women", "wonder", "won\'t", "wood", "word", "wore", "work", "world", "worm", "worry", "worth", "would", "wrong", "x", "y", "yard", "year", "yell", "yellow", "yes", "yet", "you", "young", "your", "z", "zoo"))); </BUG> private static final List<String> SUB_SYLLABLES = Collections.unmodifiableList(Arrays.asList("cial", "tia", "cius", "cious", "giu", "ion", "iou", "sia$", "[^aeiuoyt]{2,}ed$", ".ely$", "[cg]h?e[rsd]?$", "rved?$", "[aeiouy][dt]es?$", "[aeiouy][^aeiouydt]e[rsd]?$", "[aeiouy]rse$"));
private static final Set<String> DALECHALL_WORDLIST = Collections.unmodifiableSet(new HashSet<>(Arrays.asList("a", "able", "aboard", "about", "above", "absent", "accept", "accident", "account", "ache", "aching", "acorn", "acre", "across", "act", "acts", "add", "address", "admire", "adventure", "afar", "afraid", "after", "afternoon", "afterward", "afterwards", "again", "against", "age", "aged", "ago", "agree", "ah", "ahead", "aid", "aim", "air", "airfield", "airplane", "airport", "airship", "airy", "alarm", "alike", "alive", "all", "alley", "alligator", "allow", "almost", "alone", "along", "aloud", "already", "also", "always", "am", "America", "American", "among", "amount", "an", "and", "angel", "anger", "angry", "animal", "another", "answer", "ant", "any", "anybody", "anyhow", "anyone", "anything", "anyway", "anywhere", "apart", "apartment", "ape", "apiece", "appear", "apple", "April", "apron", "are", "aren\'t", "arise", "arithmetic", "arm", "armful", "army", "arose", "around", "arrange", "arrive", "arrived", "arrow", "art", "artist", "as", "ash", "ashes", "aside", "ask", "asleep", "at", "ate", "attack", "attend", "attention", "August", "aunt", "author", "auto", "automobile", "autumn", "avenue", "awake", "awaken", "away", "awful", "awfully", "awhile", "ax", "axe", "baa", "babe", "babies", "back", "background", "backward", "backwards", "bacon", "bad", "badge", "badly", "bag", "bake", "baker", "bakery", "baking", "ball", "balloon", "banana", "band", "bandage", "bang", "banjo", "bank", "banker", "bar", "barber", "bare", "barefoot", "barely", "bark", "barn", "barrel", "base", "baseball", "basement", "basket", "bat", "batch", "bath", "bathe", "bathing", "bathroom", "bathtub", "battle", "battleship", "bay", "be", "beach", "bead", "beam", "bean", "bear", "beard", "beast", "beat", "beating", "beautiful", "beautify", "beauty", "became", "because", "become", "becoming", "bed", "bedbug", "bedroom", "bedspread", "bedtime", "bee", "beech", "beef", "beefsteak", "beehive", "been", "beer", "beet", "before", "beg", "began", "beggar", "begged", "begin", "beginning", "begun", "behave", "behind", "being", "believe", "bell", "belong", "below", "belt", "bench", "bend", "beneath", "bent", "berries", "berry", "beside", "besides", "best", "bet", "better", "between", "bib", "bible", "bicycle", "bid", "big", "bigger", "bill", "billboard", "bin", "bind", "bird", "birth", "birthday", "biscuit", "bit", "bite", "biting", "bitter", "black", "blackberry", "blackbird", "blackboard", "blackness", "blacksmith", "blame", "blank", "blanket", "blast", "blaze", "bleed", "bless", "blessing", "blew", "blind", "blindfold", "blinds", "block", "blood", "bloom", "blossom", "blot", "blow", "blue", "blueberry", "bluebird", "blush", "board", "boast", "boat", "bob", "bobwhite", "bodies", "body", "boil", "boiler", "bold", "bone", "bonnet", "boo", "book", "bookcase", "bookkeeper", "boom", "boot", "born", "borrow", "boss", "both", "bother", "bottle", "bottom", "bought", "bounce", "bow", "bowl", "bow-wow", "box", "boxcar", "boxer", "boxes", "boy", "boyhood", "bracelet", "brain", "brake", "bran", "branch", "brass", "brave", "bread", "break", "breakfast", "breast", "breath", "breathe", "breeze", "brick", "bride", "bridge", "bright", "brightness", "bring", "broad", "broadcast", "broke", "broken", "brook", "broom", "brother", "brought", "brown", "brush", "bubble", "bucket", "buckle", "bud", "buffalo", "bug", "buggy", "build", "building", "built", "bulb", "bull", "bullet", "bum", "bumblebee", "bump", "bun", "bunch", "bundle", "bunny", "burn", "burst", "bury", "bus", "bush", "bushel", "business", "busy", "but", "butcher", "butt", "butter", "buttercup", "butterfly", "buttermilk", "butterscotch", "button", "buttonhole", "buy", "buzz", "by", "bye", "cab", "cabbage", "cabin", "cabinet", "cackle", "cage", "cake", "calendar", "calf", "call", "caller", "calling", "came", "camel", "camp", "campfire", "can", "canal", "canary", "candle", "candlestick", "candy", "cane", "cannon", "cannot", "canoe", "can\'t", "canyon", "cap", "cape", "capital", "captain", "car", "card", "cardboard", "care", "careful", "careless", "carelessness", "carload", "carpenter", "carpet", "carriage", "carrot", "carry", "cart", "carve", "case", "cash", "cashier", "castle", "cat", "catbird", "catch", "catcher", "caterpillar", "catfish", "catsup", "cattle", "caught", "cause", "cave", "ceiling", "cell", "cellar", "cent", "center", "cereal", "certain", "certainly", "chain", "chair", "chalk", "champion", "chance", "change", "chap", "charge", "charm", "chart", "chase", "chatter", "cheap", "cheat", "check", "checkers", "cheek", "cheer", "cheese", "cherry", "chest", "chew", "chick", "chicken", "chief", "child", "childhood", "children", "chill", "chilly", "chimney", "chin", "china", "chip", "chipmunk", "chocolate", "choice", "choose", "chop", "chorus", "chose", "chosen", "christen", "Christmas", "church", "churn", "cigarette", "circle", "circus", "citizen", "city", "clang", "clap", "class", "classmate", "classroom", "claw", "clay", "clean", "cleaner", "clear", "clerk", "clever", "click", "cliff", "climb", "clip", "cloak", "clock", "close", "closet", "cloth", "clothes", "clothing", "cloud", "cloudy", "clover", "clown", "club", "cluck", "clump", "coach", "coal", "coast", "coat", "cob", "cobbler", "cocoa", "coconut", "cocoon", "cod", "codfish", "coffee", "coffeepot", "coin", "cold", "collar", "college", "color", "colored", "colt", "column", "comb", "come", "comfort", "comic", "coming", "company", "compare", "conductor", "cone", "connect", "coo", "cook", "cooked", "cooking", "cookie", "cookies", "cool", "cooler", "coop", "copper", "copy", "cord", "cork", "corn", "corner", "correct", "cost", "cot", "cottage", "cotton", "couch", "cough", "could", "couldn\'t", "count", "counter", "country", "county", "course", "court", "cousin", "cover", "cow", "coward", "cowardly", "cowboy", "cozy", "crab", "crack", "cracker", "cradle", "cramps", "cranberry", "crank", "cranky", "crash", "crawl", "crazy", "cream", "creamy", "creek", "creep", "crept", "cried", "croak", "crook", "crooked", "crop", "cross", "crossing", "cross-eyed", "crow", "crowd", "crowded", "crown", "cruel", "crumb", "crumble", "crush", "crust", "cry", "cries", "cub", "cuff", "cup", "cuff", "cup", "cupboard", "cupful", "cure", "curl", "curly", "curtain", "curve", "cushion", "custard", "customer", "cut", "cute", "cutting", "dab", "dad", "daddy", "daily", "dairy", "daisy", "dam", "damage", "dame", "damp", "dance", "dancer", "dancing", "dandy", "danger", "dangerous", "dare", "dark", "darkness", "darling", "darn", "dart", "dash", "date", "daughter", "dawn", "day", "daybreak", "daytime", "dead", "deaf", "deal", "dear", "death", "December", "decide", "deck", "deed", "deep", "deer", "defeat", "defend", "defense", "delight", "den", "dentist", "depend", "deposit", "describe", "desert", "deserve", "desire", "desk", "destroy", "devil", "dew", "diamond", "did", "didn\'t", "die", "died", "dies", "difference", "different", "dig", "dim", "dime", "dine", "ding-dong", "dinner", "dip", "direct", "direction", "dirt", "dirty", "discover", "dish", "dislike", "dismiss", "ditch", "dive", "diver", "divide", "do", "dock", "doctor", "does", "doesn\'t", "dog", "doll", "dollar", "dolly", "done", "donkey", "don\'t", "door", "doorbell", "doorknob", "doorstep", "dope", "dot", "double", "dough", "dove", "down", "downstairs", "downtown", "dozen", "drag", "drain", "drank", "draw", "drawer", "draw", "drawing", "dream", "dress", "dresser", "dressmaker", "drew", "dried", "drift", "drill", "drink", "drip", "drive", "driven", "driver", "drop", "drove", "drown", "drowsy", "drub", "drum", "drunk", "dry", "duck", "due", "dug", "dull", "dumb", "dump", "during", "dust", "dusty", "duty", "dwarf", "dwell", "dwelt", "dying", "each", "eager", "eagle", "ear", "early", "earn", "earth", "east", "eastern", "easy", "eat", "eaten", "edge", "egg", "eh", "eight", "eighteen", "eighth", "eighty", "either", "elbow", "elder", "eldest", "electric", "electricity", "elephant", "eleven", "elf", "elm", "else", "elsewhere", "empty", "end", "ending", "enemy", "engine", "engineer", "English", "enjoy", "enough", "enter", "envelope", "equal", "erase", "eraser", "errand", "escape", "eve", "even", "evening", "ever", "every", "everybody", "everyday", "everyone", "everything", "everywhere", "evil", "exact", "except", "exchange", "excited", "exciting", "excuse", "exit", "expect", "explain", "extra", "eye", "eyebrow", "fable", "face", "facing", "fact", "factory", "fail", "faint", "fair", "fairy", "faith", "fake", "fall", "false", "family", "fan", "fancy", "far", "faraway", "fare", "farmer", "farm", "farming", "far-off", "farther", "fashion", "fast", "fasten", "fat", "father", "fault", "favor", "favorite", "fear", "feast", "feather", "February", "fed", "feed", "feel", "feet", "fell", "fellow", "felt", "fence", "fever", "few", "fib", "fiddle", "field", "fife", "fifteen", "fifth", "fifty", "fig", "fight", "figure", "file", "fill", "film", "finally", "find", "fine", "finger", "finish", "fire", "firearm", "firecracker", "fireplace", "fireworks", "firing", "first", "fish", "fisherman", "fist", "fit", "fits", "five", "fix", "flag", "flake", "flame", "flap", "flash", "flashlight", "flat", "flea", "flesh", "flew", "flies", "flight", "flip", "flip-flop", "float", "flock", "flood", "floor", "flop", "flour", "flow", "flower", "flowery", "flutter", "fly", "foam", "fog", "foggy", "fold", "folks", "follow", "following", "fond", "food", "fool", "foolish", "foot", "football", "footprint", "for", "forehead", "forest", "forget", "forgive", "forgot", "forgotten", "fork", "form", "fort", "forth", "fortune", "forty", "forward", "fought", "found", "fountain", "four", "fourteen", "fourth", "fox", "frame", "free", "freedom", "freeze", "freight", "French", "fresh", "fret", "Friday", "fried", "friend", "friendly", "friendship", "frighten", "frog", "from", "front", "frost", "frown", "froze", "fruit", "fry", "fudge", "fuel", "full", "fully", "fun", "funny", "fur", "furniture", "further", "fuzzy", "gain", "gallon", "gallop", "game", "gang", "garage", "garbage", "garden", "gas", "gasoline", "gate", "gather", "gave", "gay", "gear", "geese", "general", "gentle", "gentleman", "gentlemen", "geography", "get", "getting", "giant", "gift", "gingerbread", "girl", "give", "given", "giving", "glad", "gladly", "glance", "glass", "glasses", "gleam", "glide", "glory", "glove", "glow", "glue", "go", "going", "goes", "goal", "goat", "gobble", "God", "god", "godmother", "gold", "golden", "goldfish", "golf", "gone", "good", "goods", "goodbye", "good-by", "goodbye", "good-bye", "good-looking", "goodness", "goody", "goose", "gooseberry", "got", "govern", "government", "gown", "grab", "gracious", "grade", "grain", "grand", "grandchild", "grandchildren", "granddaughter", "grandfather", "grandma", "grandmother", "grandpa", "grandson", "grandstand", "grape", "grapes", "grapefruit", "grass", "grasshopper", "grateful", "grave", "gravel", "graveyard", "gravy", "gray", "graze", "grease", "great", "green", "greet", "grew", "grind", "groan", "grocery", "ground", "group", "grove", "grow", "guard", "guess", "guest", "guide", "gulf", "gum", "gun", "gunpowder", "guy", "ha", "habit", "had", "hadn\'t", "hail", "hair", "haircut", "hairpin", "half", "hall", "halt", "ham", "hammer", "hand", "handful", "handkerchief", "handle", "handwriting", "hang", "happen", "happily", "happiness", "happy", "harbor", "hard", "hardly", "hardship", "hardware", "hare", "hark", "harm", "harness", "harp", "harvest", "has", "hasn\'t", "haste", "hasten", "hasty", "hat", "hatch", "hatchet", "hate", "haul", "have", "haven\'t", "having", "hawk", "hay", "hayfield", "haystack", "he", "head", "headache", "heal", "health", "healthy", "heap", "hear", "hearing", "heard", "heart", "heat", "heater", "heaven", "heavy", "he\'d", "heel", "height", "held", "hell", "he\'ll", "hello", "helmet", "help", "helper", "helpful", "hem", "hen", "henhouse", "her", "hers", "herd", "here", "here\'s", "hero", "herself", "he\'s", "hey", "hickory", "hid", "hidden", "hide", "high", "highway", "hill", "hillside", "hilltop", "hilly", "him", "himself", "hind", "hint", "hip", "hire", "his", "hiss", "history", "hit", "hitch", "hive", "ho", "hoe", "hog", "hold", "holder", "hole", "holiday", "hollow", "holy", "home", "homely", "homesick", "honest", "honey", "honeybee", "honeymoon", "honk", "honor", "hood", "hoof", "hook", "hoop", "hop", "hope", "hopeful", "hopeless", "horn", "horse", "horseback", "horseshoe", "hose", "hospital", "host", "hot", "hotel", "hound", "hour", "house", "housetop", "housewife", "housework", "how", "however", "howl", "hug", "huge", "hum", "humble", "hump", "hundred", "hung", "hunger", "hungry", "hunk", "hunt", "hunter", "hurrah", "hurried", "hurry", "hurt", "husband", "hush", "hut", "hymn", "I", "ice", "icy", "I\'d", "idea", "ideal", "if", "ill", "I\'ll", "I\'m", "important", "impossible", "improve", "in", "inch", "inches", "income", "indeed", "Indian", "indoors", "ink", "inn", "insect", "inside", "instant", "instead", "insult", "intend", "interested", "interesting", "into", "invite", "iron", "is", "island", "isn\'t", "it", "its", "it\'s", "itself", "I\'ve", "ivory", "ivy", "jacket", "jacks", "jail", "jam", "January", "jar", "jaw", "jay", "jelly", "jellyfish", "jerk", "jig", "job", "jockey", "join", "joke", "joking", "jolly", "journey", "joy", "joyful", "joyous", "judge", "jug", "juice", "juicy", "July", "jump", "June", "junior", "junk", "just", "keen", "keep", "kept", "kettle", "key", "kick", "kid", "kill", "killed", "kind", "kindly", "kindness", "king", "kingdom", "kiss", "kitchen", "kite", "kitten", "kitty", "knee", "kneel", "knew", "knife", "knit", "knives", "knob", "knock", "knot", "know", "known", "lace", "lad", "ladder", "ladies", "lady", "laid", "lake", "lamb", "lame", "lamp", "land", "lane", "language", "lantern", "lap", "lard", "large", "lash", "lass", "last", "late", "laugh", "laundry", "law", "lawn", "lawyer", "lay", "lazy", "lead", "leader", "leaf", "leak", "lean", "leap", "learn", "learned", "least", "leather", "leave", "leaving", "led", "left", "leg", "lemon", "lemonade", "lend", "length", "less", "lesson", "let", "let\'s", "letter", "letting", "lettuce", "level", "liberty", "library", "lice", "lick", "lid", "lie", "life", "lift", "light", "lightness", "lightning", "like", "likely", "liking", "lily", "limb", "lime", "limp", "line", "linen", "lion", "lip", "list", "listen", "lit", "little", "live", "lives", "lively", "liver", "living", "lizard", "init", "loaf", "loan", "loaves", "lock", "locomotive", "log", "lone", "lonely", "lonesome", "long", "look", "lookout", "loop", "loose", "lord", "lose", "loser", "loss", "lost", "lot", "loud", "love", "lovely", "lover", "low", "luck", "lucky", "lumber", "lump", "lunch", "lying", "ma", "machine", "machinery", "mad", "made", "magazine", "magic", "maid", "mail", "mailbox", "mailman", "major", "make", "making", "male", "mama", "mamma", "man", "manager", "mane", "manger", "many", "map", "maple", "marble", "march", "March", "mare", "mark", "market", "marriage", "married", "marry", "mask", "mast", "master", "mat", "match", "matter", "mattress", "may", "May", "maybe", "mayor", "maypole", "me", "meadow", "meal", "mean", "means", "meant", "measure", "meat", "medicine", "meet", "meeting", "melt", "member", "men", "mend", "meow", "merry", "mess", "message", "met", "metal", "mew", "mice", "middle", "midnight", "might", "mighty", "mile", "milk", "milkman", "mill", "miler", "million", "mind", "mine", "miner", "mint", "minute", "mirror", "mischief", "miss", "Miss", "misspell", "mistake", "misty", "mitt", "mitten", "mix", "moment", "Monday", "money", "monkey", "month", "moo", "moon", "moonlight", "moose", "mop", "more", "morning", "morrow", "moss", "most", "mostly", "mother", "motor", "mount", "mountain", "mouse", "mouth", "move", "movie", "movies", "moving", "mow", "Mr.", "Mrs.", "much", "mud", "muddy", "mug", "mule", "multiply", "murder", "music", "must", "my", "myself", "nail", "name", "nap", "napkin", "narrow", "nasty", "naughty", "navy", "near", "nearby", "nearly", "neat", "neck", "necktie", "need", "needle", "needn\'t", "Negro", "neighbor", "neighborhood", "neither", "nerve", "nest", "net", "never", "nevermore", "new", "news", "newspaper", "next", "nibble", "nice", "nickel", "night", "nightgown", "nine", "nineteen", "ninety", "no", "nobody", "nod", "noise", "noisy", "none", "noon", "nor", "north", "northern", "nose", "not", "note", "nothing", "notice", "November", "now", "nowhere", "number", "nurse", "nut", "oak", "oar", "oatmeal", "oats", "obey", "ocean", "o\'clock", "October", "odd", "of", "off", "offer", "office", "officer", "often", "oh", "oil", "old", "old-fashioned", "on", "once", "one", "onion", "only", "onward", "open", "or", "orange", "orchard", "order", "ore", "organ", "other", "otherwise", "ouch", "ought", "our", "ours", "ourselves", "out", "outdoors", "outfit", "outlaw", "outline", "outside", "outward", "oven", "over", "overalls", "overcoat", "overeat", "overhead", "overhear", "overnight", "overturn", "owe", "owing", "owl", "own", "owner", "ox", "pa", "pace", "pack", "package", "pad", "page", "paid", "pail", "pain", "painful", "paint", "painter", "painting", "pair", "pal", "palace", "pale", "pan", "pancake", "pane", "pansy", "pants", "papa", "paper", "parade", "pardon", "parent", "park", "part", "partly", "partner", "party", "pass", "passenger", "past", "paste", "pasture", "pat", "patch", "path", "patter", "pave", "pavement", "paw", "pay", "payment", "pea", "peas", "peace", "peaceful", "peach", "peaches", "peak", "peanut", "pear", "pearl", "peck", "peek", "peel", "peep", "peg", "pen", "pencil", "penny", "people", "pepper", "peppermint", "perfume", "perhaps", "person", "pet", "phone", "piano", "pick", "pickle", "picnic", "picture", "pie", "piece", "pig", "pigeon", "piggy", "pile", "pill", "pillow", "pin", "pine", "pineapple", "pink", "pint", "pipe", "pistol", "pit", "pitch", "pitcher", "pity", "place", "plain", "plan", "plane", "plant", "plate", "platform", "platter", "play", "player", "playground", "playhouse", "playmate", "plaything", "pleasant", "please", "pleasure", "plenty", "plow", "plug", "plum", "pocket", "pocketbook", "poem", "point", "poison", "poke", "pole", "police", "policeman", "polish", "polite", "pond", "ponies", "pony", "pool", "poor", "pop", "popcorn", "popped", "porch", "pork", "possible", "post", "postage", "postman", "pot", "potato", "potatoes", "pound", "pour", "powder", "power", "powerful", "praise", "pray", "prayer", "prepare", "present", "pretty", "price", "prick", "prince", "princess", "print", "prison", "prize", "promise", "proper", "protect", "proud", "prove", "prune", "public", "puddle", "puff", "pull", "pump", "pumpkin", "punch", "punish", "pup", "pupil", "puppy", "pure", "purple", "purse", "push", "puss", "pussy", "pussycat", "put", "putting", "puzzle", "quack", "quart", "quarter", "queen", "queer", "question", "quick", "quickly", "quiet", "quilt", "quit", "quite", "rabbit", "race", "rack", "radio", "radish", "rag", "rail", "railroad", "railway", "rain", "rainy", "rainbow", "raise", "raisin", "rake", "ram", "ran", "ranch", "rang", "rap", "rapidly", "rat", "rate", "rather", "rattle", "raw", "ray", "reach", "read", "reader", "reading", "ready", "real", "really", "reap", "rear", "reason", "rebuild", "receive", "recess", "record", "red", "redbird", "redbreast", "refuse", "reindeer", "rejoice", "remain", "remember", "remind", "remove", "rent", "repair", "repay", "repeat", "report", "rest", "return", "review", "reward", "rib", "ribbon", "rice", "rich", "rid", "riddle", "ride", "rider", "riding", "right", "rim", "ring", "rip", "ripe", "rise", "rising", "river", "road", "roadside", "roar", "roast", "rob", "robber", "robe", "robin", "rock", "rocky", "rocket", "rode", "roll", "roller", "roof", "room", "rooster", "root", "rope", "rose", "rosebud", "rot", "rotten", "rough", "round", "route", "row", "rowboat", "royal", "rub", "rubbed", "rubber", "rubbish", "rug", "rule", "ruler", "rumble", "run", "rung", "runner", "running", "rush", "rust", "rusty", "rye", "sack", "sad", "saddle", "sadness", "safe", "safety", "said", "sail", "sailboat", "sailor", "saint", "salad", "sale", "salt", "same", "sand", "sandy", "sandwich", "sang", "sank", "sap", "sash", "sat", "satin", "satisfactory", "Saturday", "sausage", "savage", "save", "savings", "saw", "say", "scab", "scales", "scare", "scarf", "school", "schoolboy", "schoolhouse", "schoolmaster", "schoolroom", "scorch", "score", "scrap", "scrape", "scratch", "scream", "screen", "screw", "scrub", "sea", "seal", "seam", "search", "season", "seat", "second", "secret", "see", "seeing", "seed", "seek", "seem", "seen", "seesaw", "select", "self", "selfish", "sell", "send", "sense", "sent", "sentence", "separate", "September", "servant", "serve", "service", "set", "setting", "settle", "settlement", "seven", "seventeen", "seventh", "seventy", "several", "sew", "shade", "shadow", "shady", "shake", "shaker", "shaking", "shall", "shame", "shan\'t", "shape", "share", "sharp", "shave", "she", "she\'d", "she\'ll", "she\'s", "shear", "shears", "shed", "sheep", "sheet", "shelf", "shell", "shepherd", "shine", "shining", "shiny", "ship", "shirt", "shock", "shoe", "shoemaker", "shone", "shook", "shoot", "shop", "shopping", "shore", "short", "shot", "should", "shoulder", "shouldn\'t", "shout", "shovel", "show", "shower", "shut", "shy", "sick", "sickness", "side", "sidewalk", "sideways", "sigh", "sight", "sign", "silence", "silent", "silk", "sill", "silly", "silver", "simple", "sin", "since", "sing", "singer", "single", "sink", "sip", "sir", "sis", "sissy", "sister", "sit", "sitting", "six", "sixteen", "sixth", "sixty", "size", "skate", "skater", "ski", "skin", "skip", "skirt", "sky", "slam", "slap", "slate", "slave", "sled", "sleep", "sleepy", "sleeve", "sleigh", "slept", "slice", "slid", "slide", "sling", "slip", "slipped", "slipper", "slippery", "slit", "slow", "slowly", "sly", "smack", "small", "smart", "smell", "smile", "smoke", "smooth", "snail", "snake", "snap", "snapping", "sneeze", "snow", "snowy", "snowball", "snowflake", "snuff", "snug", "so", "soak", "soap", "sob", "socks", "sod", "soda", "sofa", "soft", "soil", "sold", "soldier", "sole", "some", "somebody", "somehow", "someone", "something", "sometime", "sometimes", "somewhere", "son", "song", "soon", "sore", "sorrow", "sorry", "sort", "soul", "sound", "soup", "sour", "south", "southern", "space", "spade", "spank", "sparrow", "speak", "speaker", "spear", "speech", "speed", "spell", "spelling", "spend", "spent", "spider", "spike", "spill", "spin", "spinach", "spirit", "spit", "splash", "spoil", "spoke", "spook", "spoon", "sport", "spot", "spread", "spring", "springtime", "sprinkle", "square", "squash", "squeak", "squeeze", "squirrel", "stable", "stack", "stage", "stair", "stall", "stamp", "stand", "star", "stare", "start", "starve", "state", "station", "stay", "steak", "steal", "steam", "steamboat", "steamer", "steel", "steep", "steeple", "steer", "stem", "step", "stepping", "stick", "sticky", "stiff", "still", "stillness", "sting", "stir", "stitch", "stock", "stocking", "stole", "stone", "stood", "stool", "stoop", "stop", "stopped", "stopping", "store", "stork", "stories", "storm", "stormy", "story", "stove", "straight", "strange", "stranger", "strap", "straw", "strawberry", "stream", "street", "stretch", "string", "strip", "stripes", "strong", "stuck", "study", "stuff", "stump", "stung", "subject", "such", "suck", "sudden", "suffer", "sugar", "suit", "sum", "summer", "sun", "Sunday", "sunflower", "sung", "sunk", "sunlight", "sunny", "sunrise", "sunset", "sunshine", "supper", "suppose", "sure", "surely", "surface", "surprise", "swallow", "swam", "swamp", "swan", "swat", "swear", "sweat", "sweater", "sweep", "sweet", "sweetness", "sweetheart", "swell", "swept", "swift", "swim", "swimming", "swing", "switch", "sword", "swore", "table", "tablecloth", "tablespoon", "tablet", "tack", "tag", "tail", "tailor", "take", "taken", "taking", "tale", "talk", "talker", "tall", "tame", "tan", "tank", "tap", "tape", "tar", "tardy", "task", "taste", "taught", "tax", "tea", "teach", "teacher", "team", "tear", "tease", "teaspoon", "teeth", "telephone", "tell", "temper", "ten", "tennis", "tent", "term", "terrible", "test", "than", "thank", "thanks", "thankful", "Thanksgiving", "that", "that\'s", "the", "theater", "thee", "their", "them", "then", "there", "these", "they", "they\'d", "they\'ll", "they\'re", "they\'ve", "thick", "thief", "thimble", "thin", "thing", "think", "third", "thirsty", "thirteen", "thirty", "this", "thorn", "those", "though", "thought", "thousand", "thread", "three", "threw", "throat", "throne", "through", "throw", "thrown", "thumb", "thunder", "Thursday", "thy", "tick", "ticket", "tickle", "tie", "tiger", "tight", "till", "time", "tin", "tinkle", "tiny", "tip", "tiptoe", "tire", "tired", "title", "to", "toad", "toadstool", "toast", "tobacco", "today", "toe", "together", "toilet", "told", "tomato", "tomorrow", "ton", "tone", "tongue", "tonight", "too", "took", "tool", "toot", "tooth", "toothbrush", "toothpick", "top", "tore", "torn", "toss", "touch", "tow", "toward", "towards", "towel", "tower", "town", "toy", "trace", "track", "trade", "train", "tramp", "trap", "tray", "treasure", "treat", "tree", "trick", "tricycle", "tried", "trim", "trip", "trolley", "trouble", "truck", "true", "truly", "trunk", "trust", "truth", "try", "tub", "Tuesday", "tug", "tulip", "tumble", "tune", "tunnel", "turkey", "turn", "turtle", "twelve", "twenty", "twice", "twig", "twin", "two", "ugly", "umbrella", "uncle", "under", "understand", "underwear", "undress", "unfair", "unfinished", "unfold", "unfriendly", "unhappy", "unhurt", "uniform", "United", "States", "unkind", "unknown", "unless", "unpleasant", "until", "unwilling", "up", "upon", "upper", "upset", "upside", "upstairs", "uptown", "upward", "us", "use", "used", "useful", "valentine", "valley", "valuable", "value", "vase", "vegetable", "velvet", "very", "vessel", "victory", "view", "village", "vine", "violet", "visit", "visitor", "voice", "vote", "wag", "wagon", "waist", "wait", "wake", "waken", "walk", "wall", "walnut", "want", "war", "warm", "warn", "was", "wash", "washer", "washtub", "wasn\'t", "waste", "watch", "watchman", "water", "watermelon", "waterproof", "wave", "wax", "way", "wayside", "we", "weak", "weakness", "weaken", "wealth", "weapon", "wear", "weary", "weather", "weave", "web", "we\'d", "wedding", "Wednesday", "wee", "weed", "week", "we\'ll", "weep", "weigh", "welcome", "well", "went", "were", "we\'re", "west", "western", "wet", "we\'ve", "whale", "what", "what\'s", "wheat", "wheel", "when", "whenever", "where", "which", "while", "whip", "whipped", "whirl", "whisky", "whiskey", "whisper", "whistle", "white", "who", "who\'d", "whole", "who\'ll", "whom", "who\'s", "whose", "why", "wicked", "wide", "wife", "wiggle", "wild", "wildcat", "will", "willing", "willow", "win", "wind", "windy", "windmill", "window", "wine", "wing", "wink", "winner", "winter", "wipe", "wire", "wise", "wish", "wit", "witch", "with", "without", "woke", "wolf", "woman", "women", "won", "wonder", "wonderful", "won\'t", "wood", "wooden", "woodpecker", "woods", "wool", "woolen", "word", "wore", "work", "worker", "workman", "world", "worm", "worn", "worry", "worse", "worst", "worth", "would", "wouldn\'t", "wound", "wove", "wrap", "wrapped", "wreck", "wren", "wring", "write", "writing", "written", "wrong", "wrote", "wrung", "yard", "yarn", "year", "yell", "yellow", "yes", "yesterday", "yet", "yolk", "yonder", "you", "you\'d", "you\'ll", "young", "youngster", "your", "yours", "you\'re", "yourself", "yourselves"))); private static final Set<String> SPACHE_WORDLIST = Collections.unmodifiableSet(new HashSet<>(Arrays.asList("a", "able", "about", "above", "across", "act", "add", "afraid", "after", "afternoon", "again", "against", "ago", "air", "airplane", "alarm", "all", "almost", "alone", "along", "already", "also", "always", "am", "among", "an", "and", "angry", "animal", "another", "answer", "any", "anyone", "appear", "apple", "are", "arm", "around", "arrow", "as", "ask", "asleep", "at", "ate", "attention", "aunt", "awake", "away", "b", "baby", "back", "bad", "bag", "ball", "balloon", "bang", "bank", "bark", "barn", "basket", "be", "bean", "bear", "beat", "beautiful", "became", "because", "become", "bed", "bee", "been", "before", "began", "begin", "behind", "believe", "bell", "belong", "bend", "bent", "beside", "best", "better", "between", "big", "bird", "birthday", "bit", "bite", "black", "blanket", "blew", "block", "blow", "blue", "board", "boat", "book", "boot", "born", "borrow", "both", "bother", "bottle", "bottom", "bought", "bow", "box", "boy", "branch", "brave", "bread", "break", "breakfast", "breath", "brick", "bridge", "bright", "bring", "broke", "broken", "brother", "brought", "brown", "brush", "build", "bump", "burn", "bus", "busy", "but", "butter", "button", "buy", "by", "c", "cabin", "cage", "cake", "call", "came", "camp", "can", "candle", "candy", "can\'t", "cap", "captain", "car", "card", "care", "careful", "carrot", "carry", "case", "castle", "cat", "catch", "cattle", "caught", "cause", "cent", "certain", "chair", "chance", "change", "chase", "chicken", "chief", "child", "children", "church", "circle", "circus", "city", "clap", "clean", "clever", "cliff", "climb", "clock", "close", "cloth", "clothes", "clown", "coat", "cold", "color", "come", "comfortable", "company", "contest", "continue", "cook", "cool", "corner", "could", "count", "country", "course", "cover", "cow", "crawl", "cream", "cry", "cup", "curtain", "cut", "d", "Dad", "dance", "danger", "dangerous", "dark", "dash", "daughter", "day", "dear", "decide", "deep", "desk", "did", "didn\'t", "die", "different", "dig", "dinner", "direction", "disappear", "disappoint", "discover", "distance", "do", "doctor", "does", "dog", "dollar", "done", "don\'t", "door", "down", "dragon", "dream", "dress", "drink", "drive", "drop", "drove", "dry", "duck", "during", "dust", "e", "each", "eager", "ear", "early", "earn", "earth", "easy", "eat", "edge", "egg", "eight", "eighteen", "either", "elephant", "else", "empty", "end", "enemy", "enough", "enter", "even", "ever", "every", "everything", "exact", "except", "excite", "exclaim", "explain", "eye", "face", "fact", "fair", "fall", "family", "far", "farm", "farmer", "farther", "fast", "fat", "father", "feather", "feed", "feel", "feet", "fell", "fellow", "felt", "fence", "few", "field", "fierce", "fight", "figure", "fill", "final", "find", "fine", "finger", "finish", "fire", "first", "fish", "five", "flag", "flash", "flat", "flew", "floor", "flower", "fly", "follow", "food", "for", "forest", "forget", "forth", "found", "four", "fourth", "fox", "fresh", "friend", "frighten", "frog", "from", "front", "fruit", "full", "fun", "funny", "fur", "g", "game", "garden", "gasp", "gate", "gave", "get", "giant", "gift", "girl", "give", "glad", "glass", "go", "goat", "gone", "good", "got", "grandfather", "grandmother", "grass", "gray", "great", "green", "grew", "grin", "ground", "group", "grow", "growl", "guess", "gun", "h", "had", "hair", "half", "hall", "hand", "handle", "hang", "happen", "happiness", "happy", "hard", "harm", "has", "hat", "hate", "have", "he", "head", "hear", "heard", "heavy", "held", "hello", "help", "hen", "her", "here", "herself", "he\'s", "hid", "hide", "high", "hill", "him", "himself", "his", "hit", "hold", "hole", "holiday", "home", "honey", "hop", "horn", "horse", "hot", "hour", "house", "how", "howl", "hum", "hundred", "hung", "hungry", "hunt", "hurry", "hurt", "husband", "i", "I", "ice", "idea", "if", "I\'ll", "I\'m", "imagine", "important", "in", "inch", "indeed", "inside", "instead", "into", "invite", "is", "it", "it\'s", "its", "j", "jacket", "jar", "jet", "job", "join", "joke", "joy", "jump", "just", "k", "keep", "kept", "key", "kick", "kill", "kind", "king", "kitchen", "kitten", "knee", "knew", "knock", "know", "l", "ladder", "lady", "laid", "lake", "land", "large", "last", "late", "laugh", "lay", "lazy", "lead", "leap", "learn", "least", "leave", "left", "leg", "less", "let", "let\'s", "letter", "lick", "lift", "light", "like", "line", "lion", "list", "listen", "little", "live", "init", "long", "look", "lost", "lot", "loud", "love", "low", "luck", "lump", "lunch", "m", "machine", "made", "magic", "mail", "make", "man", "many", "march", "mark", "market", "master", "matter", "may", "maybe", "me", "mean", "meant", "meat", "meet", "melt", "men", "merry", "met", "middle", "might", "mile", "milk", "milkman", "mind", "mine", "minute", "miss", "mistake", "moment", "money", "monkey", "month", "more", "morning", "most", "mother", "mountain", "mouse", "mouth", "move", "much", "mud", "music", "must", "my", "n", "name", "near", "neck", "need", "needle", "neighbor", "neighborhood", "nest", "never", "new", "next", "nibble", "nice", "night", "nine", "no", "nod", "noise", "none", "north", "nose", "not", "note", "nothing", "notice", "now", "number", "o", "ocean", "of", "off", "offer", "often", "oh", "old", "on", "once", "one", "only", "open", "or", "orange", "order", "other", "our", "out", "outside", "over", "owl", "own", "p", "pack", "paid", "pail", "paint", "pair", "palace", "pan", "paper", "parade", "parent", "park", "part", "party", "pass", "past", "pasture", "path", "paw", "pay", "peanut", "peek", "pen", "penny", "people", "perfect", "perhaps", "person", "pet", "pick", "picnic", "picture", "pie", "piece", "pig", "pile", "pin", "place", "plan", "plant", "play", "pleasant", "please", "plenty", "plow", "picket", "point", "poke", "pole", "policeman", "pond", "poor", "pop", "postman", "pot", "potato", "pound", "pour", "practice", "prepare", "present", "pretend", "pretty", "princess", "prize", "probably", "problem", "promise", "protect", "proud", "puff", "pull", "puppy", "push", "put", "q", "queen", "queer", "quick", "quiet", "quite", "r", "rabbit", "raccoon", "race", "radio", "rag", "rain", "raise", "ran", "ranch", "rang", "reach", "read", "ready", "real", "red", "refuse", "remember", "reply", "rest", "return", "reward", "rich", "ride", "right", "ring", "river", "road", "roar", "rock", "rode", "roll", "roof", "room", "rope", "round", "row", "rub", "rule", "run", "rush", "s", "sad", "safe", "said", "sail", "sale", "salt", "same", "sand", "sang", "sat", "save", "saw", "say", "scare", "school", "scold", "scratch", "scream", "sea", "seat", "second", "secret", "see", "seed", "seem", "seen", "sell", "send", "sent", "seven", "several", "sew", "shadow", "shake", "shall", "shape", "she", "sheep", "shell", "shine", "ship", "shoe", "shone", "shook", "shoot", "shop", "shore", "short", "shot", "should", "show", "sick", "side", "sight", "sign", "signal", "silent", "silly", "silver", "since", "sing", "sister", "sit", "six", "size", "skip", "sky", "sled", "sleep", "slid", "slide", "slow", "small", "smart", "smell", "smile", "smoke", "snap", "sniff", "snow", "so", "soft", "sold", "some", "something", "sometimes", "son", "song", "soon", "sorry", "sound", "speak", "special", "spend", "spill", "splash", "spoke", "spot", "spread", "spring", "squirrel", "stand", "star", "start", "station", "stay", "step", "stick", "still", "stone", "stood", "stop", "store", "story", "straight", "strange", "street", "stretch", "strike", "strong", "such", "sudden", "sugar", "suit", "summer", "sun", "supper", "suppose", "sure", "surprise", "swallow", "sweet", "swim", "swing", "t", "table", "tail", "take", "talk", "tall", "tap", "taste", "teach", "teacher", "team", "tear", "teeth", "telephone", "tell", "ten", "tent", "than", "thank", "that", "that\'s", "the", "their", "them", "then", "there", "these", "they", "thick", "thin", "thing", "think", "third", "this", "those", "though", "thought", "three", "threw", "through", "throw", "tie", "tiger", "tight", "time", "tiny", "tip", "tire", "to", "today", "toe", "together", "told", "tomorrow", "too", "took", "tooth", "top", "touch", "toward", "tower", "town", "toy", "track", "traffic", "train", "trap", "tree", "trick", "trip", "trot", "truck", "true", "trunk", "try", "turkey", "turn", "turtle", "twelve", "twin", "two", "u", "ugly", "uncle", "under", "unhappy", "until", "up", "upon", "upstairs", "us", "use", "usual", "v", "valley", "vegetable", "very", "village", "visit", "voice", "w", "wag", "wagon", "wait", "wake", "walk", "want", "war", "warm", "was", "wash", "waste", "watch", "water", "wave", "way", "we", "wear", "weather", "week", "well", "went", "were", "wet", "what", "wheel", "when", "where", "which", "while", "whisper", "whistle", "white", "who", "whole", "whose", "why", "wide", "wife", "will", "win", "wind", "window", "wing", "wink", "winter", "wire", "wise", "wish", "with", "without", "woke", "wolf", "woman", "women", "wonder", "won\'t", "wood", "word", "wore", "work", "world", "worm", "worry", "worth", "would", "wrong", "x", "y", "yard", "year", "yell", "yellow", "yes", "yet", "you", "young", "your", "z", "zoo")));
10,225
if(maxFeatures!=null && maxFeatures<maxFeatureScores.size()) { AbstractScoreBasedFeatureSelector.selectHighScoreFeatures(maxFeatureScores, maxFeatures); } } @Override <BUG>protected void filterFeatures(Dataframe newData) { </BUG> DatabaseConnector dbc = knowledgeBase.getDbc(); Map<Object, Double> maxTFIDFfeatureScores = knowledgeBase.getModelParameters().getMaxTFIDFfeatureScores(); Map<Object, Boolean> tmp_removedColumns = dbc.getBigMap("tmp_removedColumns", Object.class, Boolean.class, MapType.HASHMAP, StorageHint.IN_MEMORY, false, true);
protected void _transform(Dataframe newData) {
10,226
import com.datumbox.framework.common.concurrency.ConcurrencyConfiguration; import com.datumbox.framework.common.concurrency.ForkJoinStream; import com.datumbox.framework.common.concurrency.StreamMethods; import com.datumbox.framework.common.dataobjects.AssociativeArray; import com.datumbox.framework.common.dataobjects.Dataframe; <BUG>import com.datumbox.framework.common.dataobjects.Record; import java.io.Serializable;</BUG> import java.util.Map; public interface PredictParallelizable extends Parallelizable { public static class Prediction implements Serializable {
import com.datumbox.framework.common.persistentstorage.interfaces.DatabaseConnector; import java.io.Serializable;
10,227
fit(trainingData, trainingParameters); transform(trainingData); } public void transform(Dataframe newData) { logger.info("transform()"); <BUG>knowledgeBase.load(); </BUG> _convert(newData); _normalize(newData); }
knowledgeBase.init();
10,228
_convert(newData); _normalize(newData); } public void denormalize(Dataframe data) { logger.info("denormalize()"); <BUG>knowledgeBase.load(); </BUG> _denormalize(data); } protected abstract void _convert(Dataframe data);
knowledgeBase.init();
10,229
estimateFeatureScores(trainingData.size(), tmp_classCounts, tmp_featureClassCounts, tmp_featureCounts); dbc.dropBigMap("tmp_featureClassCounts", tmp_featureClassCounts); dbc.dropBigMap("tmp_featureCounts", tmp_featureCounts); } @Override <BUG>protected void filterFeatures(Dataframe newdata) { </BUG> filterData(newdata, knowledgeBase.getDbc(), knowledgeBase.getModelParameters().getFeatureScores(), knowledgeBase.getTrainingParameters().isIgnoringNumericalFeatures()); } private static void filterData(Dataframe data, DatabaseConnector dbc, Map<Object, Double> featureScores, boolean ignoringNumericalFeatures) {
protected void _transform(Dataframe newdata) {
10,230
private AtomicReference<GridTimeoutObject> lastTimeoutObj = new AtomicReference<>(); private volatile GridDhtPartitionsExchangeFuture lastExchangeFut; @Deprecated//Backward compatibility. To be removed in future. private final ReadWriteLock demandLock; @Deprecated//Backward compatibility. To be removed in future. <BUG>private final AtomicInteger dmIdx = new AtomicInteger(); private final Map<Integer, Object> rebalanceTopics;</BUG> public GridDhtPartitionDemander(GridCacheContext<?, ?> cctx, ReadWriteLock demandLock) { assert cctx != null; this.cctx = cctx;
private volatile DemandWorker worker; private final Map<Integer, Object> rebalanceTopics;
10,231
try { rebalanceFut.cancel(); } catch (Exception ex) { rebalanceFut.onDone(false); <BUG>} lastExchangeFut = null;</BUG> lastTimeoutObj.set(null); } IgniteInternalFuture<?> syncFuture() {
DemandWorker dw = worker; if (dw != null) dw.cancel(); lastExchangeFut = null;
10,232
U.log(log, "Starting rebalancing (old api) [cache=" + cctx.name() + ", mode=" + cfg.getRebalanceMode() + ", fromNode=" + node.id() + ", partitionsCount=" + parts.size() + ", topology=" + fut.topologyVersion() + ", updateSeq=" + fut.updateSeq + "]"); d.timeout(cctx.config().getRebalanceTimeout()); d.workerId(0);//old api support. <BUG>DemandWorker dw = new DemandWorker(dmIdx.incrementAndGet(), fut); dw.run(node, d); </BUG> }
worker = new DemandWorker(dmIdx.incrementAndGet(), fut); worker.run(node, d);
10,233
@Nullable private <T> T poll(BlockingQueue<T> deque, long time) throws InterruptedException { return deque.poll(time, MILLISECONDS); } public Object topic(long idx) { return TOPIC_CACHE.topic(cctx.namexx(), cctx.nodeId(), id, idx); <BUG>} private void demandFromNode(</BUG> ClusterNode node, final AffinityTopologyVersion topVer, GridDhtPartitionDemandMessage d,
public void cancel() { msgQ.clear(); msgQ.offer(new SupplyMessage(null, null)); private void demandFromNode(
10,234
) throws InterruptedException, IgniteCheckedException { GridDhtPartitionTopology top = cctx.dht().topology(); cntr++; d.topic(topic(cntr)); d.workerId(id); <BUG>if (topologyChanged(fut)) </BUG> return; cctx.io().addOrderedHandler(d.topic(), new CI2<UUID, GridDhtPartitionSupplyMessage>() { @Override public void apply(UUID nodeId, GridDhtPartitionSupplyMessage msg) {
if (fut.isDone() || topologyChanged(fut))
10,235
retry = true; break; // While. } else continue; // While. <BUG>} if (!s.senderId().equals(node.id())) {</BUG> U.warn(log, "Received supply message from unexpected node [expectedId=" + node.id() + ", rcvdId=" + s.senderId() + ", msg=" + s + ']'); continue; // While.
if (s.senderId() == null) return; // Stopping now. if (!s.senderId().equals(node.id())) {
10,236
private AffinityTopologyVersion affinityTopologyVersion(DiscoveryEvent evt) { if (evt.type() == DiscoveryCustomEvent.EVT_DISCOVERY_CUSTOM_EVT) return ((DiscoveryCustomEvent)evt).affinityTopologyVersion(); return new AffinityTopologyVersion(evt.topologyVersion()); } <BUG>public boolean topologyChanged() { return exchWorker.topologyChanged(); }</BUG> public void forceDummyExchange(boolean reassign, GridDhtPartitionsExchangeFuture exchFut) {
[DELETED]
10,237
log.debug("Skip partitions refresh, there are no server nodes [loc=" + cctx.localNodeId() + ']'); return; } if (log.isDebugEnabled()) log.debug("Refreshing partitions [oldest=" + oldest.id() + ", loc=" + cctx.localNodeId() + ']'); <BUG>Collection<ClusterNode> rmts = null; if (oldest.id().equals(cctx.localNodeId())) {</BUG> rmts = CU.remoteNodes(cctx, AffinityTopologyVersion.NONE); if (log.isDebugEnabled()) log.debug("Refreshing partitions from oldest node: " + cctx.localNodeId());
Collection<ClusterNode> rmts; if (oldest.id().equals(cctx.localNodeId())) {
10,238
if (asyncStartFut != null) asyncStartFut.get(); // Wait for thread stop. rebalanceQ.addAll(orderedRs); if (marshR != null || !rebalanceQ.isEmpty()) { if (futQ.isEmpty()) { <BUG>U.log(log, "Starting caches rebalancing [top=" + exchFut.topologyVersion() + "]"); if (marshR != null)</BUG> try { marshR.call(); //Marshaller cache rebalancing launches in sync way. }
U.log(log, "Rebalancing required" + "[top=" + exchFut.topologyVersion() + ", evt=" + exchFut.discoveryEvent().name() + ", node=" + exchFut.discoveryEvent().node().id() + ']'); if (marshR != null)
10,239
catch (IgniteCheckedException e) { U.error(log, "Failed to wait for completion of partition map exchange " + "(preloading will not start): " + exchFut, e); } } <BUG>} boolean topologyChanged() { return !futQ.isEmpty() || busy;</BUG> } }
[DELETED]
10,240
import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; import java.security.DigestOutputStream; import java.security.MessageDigest; <BUG>import java.security.NoSuchAlgorithmException; import java.util.ArrayList; import java.util.Collections; import java.util.List;</BUG> public final class PatchUtils {
import java.text.DateFormat; import java.util.Date; import java.util.List;
10,241
package org.jboss.as.patching.runner; <BUG>import org.jboss.as.boot.DirectoryStructure; import org.jboss.as.patching.LocalPatchInfo;</BUG> import org.jboss.as.patching.PatchInfo; import org.jboss.as.patching.PatchLogger; import org.jboss.as.patching.PatchMessages;
import static org.jboss.as.patching.runner.PatchUtils.generateTimestamp; import org.jboss.as.patching.CommonAttributes; import org.jboss.as.patching.LocalPatchInfo;
10,242
private static final String PATH_DELIMITER = "/"; public static final byte[] NO_CONTENT = PatchingTask.NO_CONTENT; enum Element { ADDED_BUNDLE("added-bundle"), ADDED_MISC_CONTENT("added-misc-content"), <BUG>ADDED_MODULE("added-module"), BUNDLES("bundles"),</BUG> CUMULATIVE("cumulative"), DESCRIPTION("description"), MISC_FILES("misc-files"),
APPLIES_TO_VERSION("applies-to-version"), BUNDLES("bundles"),
10,243
final int count = reader.getAttributeCount(); for (int i = 0; i < count; i++) { final String value = reader.getAttributeValue(i); final Attribute attribute = Attribute.forName(reader.getAttributeLocalName(i)); switch (attribute) { <BUG>case APPLIES_TO_VERSION: builder.addAppliesTo(value); break;</BUG> case RESULTING_VERSION: if(type == Patch.PatchType.CUMULATIVE) {
[DELETED]
10,244
final StringBuilder path = new StringBuilder(); for(final String p : item.getPath()) { path.append(p).append(PATH_DELIMITER); } path.append(item.getName()); <BUG>writer.writeAttribute(Attribute.PATH.name, path.toString()); if(type != ModificationType.REMOVE) {</BUG> writer.writeAttribute(Attribute.HASH.name, bytesToHexString(item.getContentHash())); } if(type != ModificationType.ADD) {
if (item.isDirectory()) { writer.writeAttribute(Attribute.DIRECTORY.name, "true"); if(type != ModificationType.REMOVE) {
10,245
package org.jboss.as.patching; import org.jboss.as.controller.OperationFailedException; import org.jboss.as.patching.runner.PatchingException; import org.jboss.logging.Messages; import org.jboss.logging.annotations.Message; <BUG>import org.jboss.logging.annotations.MessageBundle; import java.io.IOException;</BUG> import java.util.List; @MessageBundle(projectCode = "JBAS") public interface PatchMessages {
import org.jboss.logging.annotations.Cause; import java.io.IOException;
10,246
import util.access.V; import util.access.fieldvalue.FileField; import util.access.fieldvalue.ObjectField; import util.action.Action; import util.animation.Anim; <BUG>import util.animation.interpolator.ElasticInterpolator; import util.async.future.Fut;</BUG> import util.collections.map.ClassListMap; import util.collections.map.ClassMap; import util.conf.Configurable;
import util.async.Async; import util.async.future.Fut;
10,247
import util.collections.map.ClassListMap; import util.collections.map.ClassMap; import util.conf.Configurable; import util.conf.IsConfig; import util.conf.IsConfigurable; <BUG>import util.functional.Functors; import util.functional.Functors.Ƒ1; import util.type.ClassName;</BUG> import util.type.InstanceInfo; import util.type.InstanceName;
import util.functional.Try; import util.type.ClassName;
10,248
if (action.isComplex) { ComplexActionData complexAction = action.complexData; showIcons = false; insteadIcons = (Node) complexAction.gui.get(); show(complexAction.input.apply(action.prepInput(getData()))); <BUG>} else { doneHide(); }</BUG> } private final Label dataInfo = new Label();
if (!action.preventClosing)
10,249
Anim.par(icons, (i,icon) -> new Anim(at -> setScaleXY(icon,at*at)).dur(500).intpl(intpl).delay(350+i*delay)) .play(); } private void runAction(ActionData action, Object data) { if (!action.isLong) { <BUG>action.apply(data); </BUG> doneHide(action); } else { futAfter(fut(data))
action.accept(data);
10,250
public final String description; public final GlyphIcons icon; public final Predicate<? super T> condition; public final GroupApply groupApply; public final boolean isLong; <BUG>private final Ƒ1<T,?> action; private boolean isComplex = false; private ComplexActionData<?,?> complexData = null; private ActionData(String name, String description, GlyphIcons icon, GroupApply group, Predicate<? super T> constriction, boolean isLong, Ƒ1<T,?> action) { </BUG> this.name = name;
private final Consumer<? super T> action; private boolean preventClosing = false; private ActionData(String name, String description, GlyphIcons icon, GroupApply group, Predicate<? super T> constriction, boolean isLong, Consumer<? super T> action) {
10,251
package gui.objects.image; import java.io.File; import java.util.function.Consumer; <BUG>import de.jensd.fx.glyphs.GlyphIcons; import util.file.Environment; import util.async.future.Fut; import util.file.FileType;</BUG> import util.graphics.drag.DragPane;
[DELETED]
10,252
import util.graphics.drag.DragUtil; import static de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIcon.DETAILS; import static javafx.scene.input.DragEvent.DRAG_EXITED; import static javafx.scene.input.DragEvent.DRAG_OVER; import static javafx.scene.input.MouseButton.PRIMARY; <BUG>import static javafx.scene.input.MouseEvent.MOUSE_CLICKED; import static javafx.scene.input.MouseEvent.MOUSE_ENTERED; import static javafx.scene.input.MouseEvent.MOUSE_EXITED; </BUG> import static util.async.future.Fut.fut;
import static javafx.scene.input.MouseEvent.*;
10,253
root.addEventHandler(MOUSE_ENTERED, e -> highlight(true)); root.addEventHandler(DRAG_OVER, e -> { if (DragUtil.hasImage(e)) onHighlight.accept(true); }); root.addEventHandler(DRAG_EXITED, e -> onHighlight.accept(false)); root.addEventHandler(MOUSE_CLICKED, e -> { if (e.getButton()==PRIMARY) { <BUG>File f = Environment.chooseFile("Select image to add to tag", FILE, new File(""), root.getScene().getWindow()); if (f!= null && onFileDropped!=null) onFileDropped.accept(fut(f)); e.consume();</BUG> } });
Environment.chooseFile("Select image to add to tag", FILE, new File(""), root.getScene().getWindow()) .ifOk(file -> { if (onFileDropped!=null) onFileDropped.accept(fut(file)); e.consume();
10,254
public void addUris(Collection<URI> uris) { addUris(uris, size()); } public void addUris(Collection<URI> uris, int at) { int _at = at; <BUG>if (_at < 0) _at = 0; if (_at > size()) _at = size();</BUG> List<PlaylistItem> l = new ArrayList<>(); uris.forEach(uri->l.add(new PlaylistItem(uri))); addPlaylist(l, _at);
if (_at < 0) _at = 0; if (_at > size()) _at = size();
10,255
public void addItems(Collection<? extends Item> items, int at) { addPlaylist(map(items, Item::toPlaylist), at); } public void addPlaylist(Collection<PlaylistItem> ps, int at) { int _at = at; <BUG>if (_at < 0) _at = 0; if (_at > size()) _at = size();</BUG> addAll(_at, ps); updateItems(ps); }
if (_at < 0) _at = 0; if (_at > size()) _at = size();
10,256
setRight(layHorizontally(5, Pos.CENTER_RIGHT, b1,b2)); } } @Override void onDialogAction() { <BUG>File f = Environment.chooseFile(type==DIRECTORY ? "Choose directory" : "Choose file", type, v, getScene().getWindow()); if (f!=null) setValue(f); }</BUG> @Override String itemToString(File item) {
Environment.chooseFile(type==DIRECTORY ? "Choose directory" : "Choose file", type, v, getScene().getWindow()) .ifOk(this::setValue);
10,257
import java.security.SecureRandom; import java.security.cert.X509Certificate; import java.security.spec.ECGenParameterSpec; import junit.framework.TestCase; import org.bouncycastle.asn1.x500.X500Name; <BUG>import org.bouncycastle.cert.X509CertificateHolder; import org.bouncycastle.est.ESTServiceBuilder;</BUG> import org.bouncycastle.est.http.BasicAuth; import org.bouncycastle.esttst.ESTServerUtils; import org.bouncycastle.operator.jcajce.JcaContentSignerBuilder;
import org.bouncycastle.est.ESTService; import org.bouncycastle.est.ESTServiceBuilder;
10,258
X509CertificateHolder[] theirCAs = null; ESTServerUtils.ServerInstance serverInstance = null; try { serverInstance = startDefaultServerWithBasicAuth(); <BUG>ESTServiceBuilder est = new ESTServiceBuilder("https://localhost:8443/.well-known/est/"); est.setTlsTrustAnchors( </BUG> ESTTestUtils.toTrustAnchor( ESTTestUtils.readPemCertificate(
ESTService est = new ESTServiceBuilder("https://localhost:8443/.well-known/est/") .withTlsTrustAnchors(
10,259
import org.bouncycastle.asn1.x500.X500NameBuilder; import org.bouncycastle.asn1.x500.style.BCStyle; import org.bouncycastle.asn1.x509.KeyPurposeId; import org.bouncycastle.asn1.x509.KeyUsage; import org.bouncycastle.asn1.x509.SubjectPublicKeyInfo; <BUG>import org.bouncycastle.cert.X509CertificateHolder; import org.bouncycastle.est.ESTServiceBuilder;</BUG> import org.bouncycastle.est.http.BasicAuth; import org.bouncycastle.est.http.DigestAuth; import org.bouncycastle.esttst.ESTServerUtils;
import org.bouncycastle.est.ESTService; import org.bouncycastle.est.ESTServiceBuilder;
10,260
X509CertificateHolder[] theirCAs = null; ESTServerUtils.ServerInstance serverInstance = null; try { serverInstance = startDefaultServerWithBasicAuth(); <BUG>ESTServiceBuilder est = new ESTServiceBuilder("https://localhost:8443/.well-known/est/"); est.setTlsTrustAnchors( </BUG> ESTTestUtils.toTrustAnchor( ESTTestUtils.readPemCertificate(
ESTService est = new ESTServiceBuilder("https://localhost:8443/.well-known/est/") .withTlsTrustAnchors(
10,261
X509CertificateHolder[] theirCAs = null; ESTServerUtils.ServerInstance serverInstance = null; try { serverInstance = startDefaultServerWithDigestAuth(); <BUG>ESTServiceBuilder est = new ESTServiceBuilder("https://localhost:8443/.well-known/est/"); est.setTlsTrustAnchors( </BUG> ESTTestUtils.toTrustAnchor( ESTTestUtils.readPemCertificate(
ESTService est = new ESTServiceBuilder("https://localhost:8443/.well-known/est/") .withTlsTrustAnchors(
10,262
TrustAnchor ta = new TrustAnchor( ESTTestUtils.toJavaX509Certificate( ESTTestUtils.readPemCertificate( ESTServerUtils.makeRelativeToServerHome("/estCA/cacert.crt") ) <BUG>), null); est.setTlsTrustAnchors(Collections.singleton(ta)); </BUG> PKCS10CertificationRequestBuilder pkcs10Builder = new JcaPKCS10CertificationRequestBuilder(new X500Name("CN=Test"), enrollmentPair.getPublic()); PKCS10CertificationRequest csr = pkcs10Builder.build(
ESTService est = new ESTServiceBuilder("https://localhost:8443/.well-known/est/") .withClientKeystore(clientKeyStore) .withClientKeystorePassword(clientKeyStorePass) .withTlsTrustAnchors(Collections.singleton(ta)).build();
10,263
import java.security.cert.TrustAnchor; import java.util.Collections; import java.util.concurrent.atomic.AtomicBoolean; import javax.net.ssl.SSLSession; import javax.security.cert.X509Certificate; <BUG>import org.bouncycastle.cert.X509CertificateHolder; import org.bouncycastle.est.ESTServiceBuilder;</BUG> import org.bouncycastle.est.RFC7030BootstrapAuthorizer; import org.bouncycastle.esttst.ESTServerUtils; import org.bouncycastle.util.Store;
import org.bouncycastle.est.ESTService; import org.bouncycastle.est.ESTServiceBuilder;
10,264
X509CertificateHolder[] theirCAs = null; ESTServerUtils.ServerInstance serverInstance = null; try { serverInstance = startDefaultServer(); <BUG>ESTServiceBuilder est = new ESTServiceBuilder("https://localhost:8443/.well-known/est/"); X509CertificateHolder[] caCerts = ESTServiceBuilder.storeToArray(est.getCACerts(null, true)); FileReader fr = new FileReader(ESTServerUtils.makeRelativeToServerHome("/estCA/cacert.crt"));</BUG> PemReader reader = new PemReader(fr);
ESTService est = new ESTServiceBuilder("https://localhost:8443/.well-known/est/").build(); X509CertificateHolder[] caCerts = ESTService.storeToArray(est.getCACerts(null, true)); FileReader fr = new FileReader(ESTServerUtils.makeRelativeToServerHome("/estCA/cacert.crt"));
10,265
throws Exception { bootStrapAuthorizerCalled.set(true); } }; <BUG>ESTServiceBuilder est = new ESTServiceBuilder("https://localhost:8443/.well-known/est/"); X509CertificateHolder[] caCerts = ESTServiceBuilder.storeToArray(est.getCACerts(bootstrapAuthorizer, true)); FileReader fr = new FileReader(ESTServerUtils.makeRelativeToServerHome("/estCA/cacert.crt"));</BUG> PemReader reader = new PemReader(fr);
ESTTestUtils.ensureProvider(); X509CertificateHolder[] theirCAs = null; ESTServerUtils.ServerInstance serverInstance = null; try serverInstance = startDefaultServer(); FileReader fr = new FileReader(ESTServerUtils.makeRelativeToServerHome("/estCA/cacert.crt"));
10,266
} else { updateMemo(); callback.updateMemo(); } dismiss(); <BUG>}else{ </BUG> Toast.makeText(getActivity(), getString(R.string.toast_memo_empty), Toast.LENGTH_SHORT).show(); } }
[DELETED]
10,267
} @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_memo); <BUG>ChinaPhoneHelper.setStatusBar(this,true); </BUG> topicId = getIntent().getLongExtra("topicId", -1); if (topicId == -1) { finish();
ChinaPhoneHelper.setStatusBar(this, true);
10,268
MemoEntry.COLUMN_REF_TOPIC__ID + " = ?" , new String[]{String.valueOf(topicId)}); } public Cursor selectMemo(long topicId) { Cursor c = db.query(MemoEntry.TABLE_NAME, null, MemoEntry.COLUMN_REF_TOPIC__ID + " = ?", new String[]{String.valueOf(topicId)}, null, null, <BUG>MemoEntry._ID + " DESC", null); </BUG> if (c != null) { c.moveToFirst(); }
MemoEntry.COLUMN_ORDER + " ASC", null);
10,269
MemoEntry._ID + " = ?", new String[]{String.valueOf(memoId)}); } public long updateMemoContent(long memoId, String memoContent) { ContentValues values = new ContentValues(); <BUG>values.put(MemoEntry.COLUMN_CONTENT, memoContent); return db.update(</BUG> MemoEntry.TABLE_NAME, values, MemoEntry._ID + " = ?",
return db.update(
10,270
import android.widget.RelativeLayout; import android.widget.TextView; import com.kiminonawa.mydiary.R; import com.kiminonawa.mydiary.db.DBManager; import com.kiminonawa.mydiary.shared.EditMode; <BUG>import com.kiminonawa.mydiary.shared.ThemeManager; import java.util.List; public class MemoAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder> implements EditMode { </BUG> private List<MemoEntity> memoList;
import com.marshalchen.ultimaterecyclerview.dragsortadapter.DragSortAdapter; public class MemoAdapter extends DragSortAdapter<DragSortAdapter.ViewHolder> implements EditMode {
10,271
private DBManager dbManager; private boolean isEditMode = false; private EditMemoDialogFragment.MemoCallback callback; private static final int TYPE_HEADER = 0; private static final int TYPE_ITEM = 1; <BUG>public MemoAdapter(FragmentActivity activity, long topicId, List<MemoEntity> memoList, DBManager dbManager, EditMemoDialogFragment.MemoCallback callback) { this.mActivity = activity;</BUG> this.topicId = topicId; this.memoList = memoList;
public MemoAdapter(FragmentActivity activity, long topicId, List<MemoEntity> memoList, DBManager dbManager, EditMemoDialogFragment.MemoCallback callback, RecyclerView recyclerView) { super(recyclerView); this.mActivity = activity;
10,272
this.memoList = memoList; this.dbManager = dbManager; this.callback = callback; } @Override <BUG>public RecyclerView.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) { </BUG> View view; if (isEditMode) { if (viewType == TYPE_HEADER) {
public DragSortAdapter.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
10,273
editMemoDialogFragment.show(mActivity.getSupportFragmentManager(), "editMemoDialogFragment"); } }); } } <BUG>protected class MemoViewHolder extends RecyclerView.ViewHolder implements View.OnClickListener { private View rootView; private TextView TV_memo_item_content;</BUG> private ImageView IV_memo_item_delete;
protected class MemoViewHolder extends DragSortAdapter.ViewHolder implements View.OnClickListener, View.OnLongClickListener { private ImageView IV_memo_item_dot; private TextView TV_memo_item_content;
10,274
DESC { @Override public String toString() { return "desc"; } <BUG>}; private static final SortOrder PROTOTYPE = ASC; </BUG> @Override public SortOrder readFrom(StreamInput in) throws IOException {
public static final SortOrder DEFAULT = DESC; private static final SortOrder PROTOTYPE = DEFAULT;
10,275
GeoDistance geoDistance = GeoDistance.DEFAULT; boolean reverse = false; MultiValueMode sortMode = null; NestedInnerQueryParseSupport nestedHelper = null; final boolean indexCreatedBeforeV2_0 = context.indexShard().getIndexSettings().getIndexVersionCreated().before(Version.V_2_0_0); <BUG>boolean coerce = GeoDistanceSortBuilder.DEFAULT_COERCE; boolean ignoreMalformed = GeoDistanceSortBuilder.DEFAULT_IGNORE_MALFORMED; XContentParser.Token token;</BUG> String currentName = parser.currentName(); while ((token = parser.nextToken()) != XContentParser.Token.END_OBJECT) {
boolean coerce = false; boolean ignoreMalformed = false; XContentParser.Token token;
10,276
String currentName = parser.currentName(); while ((token = parser.nextToken()) != XContentParser.Token.END_OBJECT) { if (token == XContentParser.Token.FIELD_NAME) { currentName = parser.currentName(); } else if (token == XContentParser.Token.START_ARRAY) { <BUG>GeoDistanceSortBuilder.parseGeoPoints(parser, geoPoints); fieldName = currentName;</BUG> } else if (token == XContentParser.Token.START_OBJECT) { if ("nested_filter".equals(currentName) || "nestedFilter".equals(currentName)) { if (nestedHelper == null) {
fieldName = currentName;
10,277
if (temp == MultiValueMode.SUM) { throw new IllegalArgumentException("sort_mode [sum] isn't supported for sorting by geo distance"); }</BUG> this.sortMode = sortMode; return this; <BUG>} public String sortMode() { return this.sortMode;</BUG> } public GeoDistanceSortBuilder setNestedFilter(QueryBuilder nestedFilter) {
@Override public GeoDistanceSortBuilder order(SortOrder order) { this.order = order; @Override public SortBuilder missing(Object missing) { public GeoDistanceSortBuilder sortMode(String sortMode) {
10,278
builder.field("unit", unit); builder.field("distance_type", geoDistance.name().toLowerCase(Locale.ROOT)); if (order == SortOrder.DESC) {</BUG> builder.field("reverse", true); <BUG>} else { builder.field("reverse", false);</BUG> } if (sortMode != null) { builder.field("mode", sortMode); }
if (geoDistance != null) { if (order == SortOrder.DESC) {
10,279
chart.addYAxisLabels(AxisLabelsFactory.newAxisLabels(labels)); chart.addXAxisLabels(AxisLabelsFactory.newNumericRangeAxisLabels(0, max)); chart.setBarWidth(BarChart.AUTO_RESIZE); chart.setSize(600, 500); chart.setHorizontal(true); <BUG>chart.setTitle("Total Evaluations by User"); showChartImg(resp, chart.toURLString()); }</BUG> private List<Entry<String, Integer>> sortEntries(Collection<Entry<String, Integer>> entries) { List<Entry<String, Integer>> result = new ArrayList<Entry<String, Integer>>(entries);
chart.setDataEncoding(DataEncoding.TEXT); return chart; }
10,280
checkEvaluationsEqual(eval4, foundissueProto.getEvaluations(0)); checkEvaluationsEqual(eval5, foundissueProto.getEvaluations(1)); } public void testGetRecentEvaluationsNoneFound() throws Exception { DbIssue issue = createDbIssue("fad", persistenceHelper); <BUG>DbEvaluation eval1 = createEvaluation(issue, "someone", 100); DbEvaluation eval2 = createEvaluation(issue, "someone", 200); DbEvaluation eval3 = createEvaluation(issue, "someone", 300); issue.addEvaluations(eval1, eval2, eval3);</BUG> getPersistenceManager().makePersistent(issue);
[DELETED]
10,281
public int read() throws IOException { return inputStream.read(); } }); } <BUG>} protected DbEvaluation createEvaluation(DbIssue issue, String who, long when) {</BUG> DbUser user; Query query = getPersistenceManager().newQuery("select from " + persistenceHelper.getDbUserClass().getName() + " where openid == :myopenid");
@SuppressWarnings({"unchecked"}) protected DbEvaluation createEvaluation(DbIssue issue, String who, long when) {
10,282
eval.setComment("my comment"); eval.setDesignation("MUST_FIX"); eval.setIssue(issue); eval.setWhen(when); eval.setWho(user.createKeyObject()); <BUG>eval.setEmail(who); return eval;</BUG> } protected PersistenceManager getPersistenceManager() { return testHelper.getPersistenceManager();
issue.addEvaluation(eval); return eval;
10,283
private void _testThemeBuildScripts(Path dirPath) throws IOException { if (!_contains( dirPath.resolve("package.json"), "\"liferay-theme-tasks\":")) { return; } <BUG>Path gulpfileJsPath = dirPath.resolve("gulpfile.js"); if (Files.notExists(gulpfileJsPath)) { Assert.fail("Missing " + gulpfileJsPath); }</BUG> }
Assert.assertTrue( "Missing " + gulpfileJsPath, Files.exists(gulpfileJsPath));
10,284
import org.apache.commons.lang3.math.NumberUtils; import org.json.JSONException; import org.mariotaku.microblog.library.MicroBlog; import org.mariotaku.microblog.library.MicroBlogException; import org.mariotaku.microblog.library.twitter.model.RateLimitStatus; <BUG>import org.mariotaku.microblog.library.twitter.model.Status; import org.mariotaku.sqliteqb.library.AllColumns;</BUG> import org.mariotaku.sqliteqb.library.Columns; import org.mariotaku.sqliteqb.library.Columns.Column; import org.mariotaku.sqliteqb.library.Expression;
import org.mariotaku.pickncrop.library.PNCUtils; import org.mariotaku.sqliteqb.library.AllColumns;
10,285
context.getApplicationContext().sendBroadcast(intent); } } @Nullable public static Location getCachedLocation(Context context) { <BUG>if (BuildConfig.DEBUG) { Log.v(LOGTAG, "Fetching cached location", new Exception()); }</BUG> Location location = null;
DebugLog.v(LOGTAG, "Fetching cached location", new Exception());
10,286
FileBody fileBody = null; try { fileBody = getFileBody(context, imageUri); twitter.updateProfileBannerImage(fileBody); } finally { <BUG>Utils.closeSilently(fileBody); if (deleteImage && "file".equals(imageUri.getScheme())) { final File file = new File(imageUri.getPath()); if (!file.delete()) { Log.w(LOGTAG, String.format("Unable to delete %s", file)); }</BUG> }
if (deleteImage) { Utils.deleteMedia(context, imageUri);
10,287
FileBody fileBody = null; try { fileBody = getFileBody(context, imageUri); twitter.updateProfileBackgroundImage(fileBody, tile); } finally { <BUG>Utils.closeSilently(fileBody); if (deleteImage && "file".equals(imageUri.getScheme())) { final File file = new File(imageUri.getPath()); if (!file.delete()) { Log.w(LOGTAG, String.format("Unable to delete %s", file)); }</BUG> }
twitter.updateProfileBannerImage(fileBody); if (deleteImage) { Utils.deleteMedia(context, imageUri);
10,288
FileBody fileBody = null; try { fileBody = getFileBody(context, imageUri); return twitter.updateProfileImage(fileBody); } finally { <BUG>Utils.closeSilently(fileBody); if (deleteImage && "file".equals(imageUri.getScheme())) { final File file = new File(imageUri.getPath()); if (!file.delete()) { Log.w(LOGTAG, String.format("Unable to delete %s", file)); }</BUG> }
twitter.updateProfileBannerImage(fileBody); if (deleteImage) { Utils.deleteMedia(context, imageUri);
10,289
import org.mariotaku.twidere.receiver.NotificationReceiver; import org.mariotaku.twidere.service.LengthyOperationsService; import org.mariotaku.twidere.util.ActivityTracker; import org.mariotaku.twidere.util.AsyncTwitterWrapper; import org.mariotaku.twidere.util.DataStoreFunctionsKt; <BUG>import org.mariotaku.twidere.util.DataStoreUtils; import org.mariotaku.twidere.util.ImagePreloader;</BUG> import org.mariotaku.twidere.util.InternalTwitterContentUtils; import org.mariotaku.twidere.util.JsonSerializer; import org.mariotaku.twidere.util.NotificationManagerWrapper;
import org.mariotaku.twidere.util.DebugLog; import org.mariotaku.twidere.util.ImagePreloader;
10,290
final List<InetAddress> addresses = mDns.lookup(host); for (InetAddress address : addresses) { c.addRow(new String[]{host, address.getHostAddress()}); } } catch (final IOException ignore) { <BUG>if (BuildConfig.DEBUG) { Log.w(LOGTAG, ignore); }</BUG> }
DebugLog.w(LOGTAG, null, ignore);
10,291
for (Location location : twitter.getAvailableTrends()) { map.put(location); } return map.pack(); } catch (final MicroBlogException e) { <BUG>if (BuildConfig.DEBUG) { Log.w(LOGTAG, e); }</BUG> }
DebugLog.w(LOGTAG, null, e);
10,292
import android.content.Context; import android.content.SharedPreferences; import android.location.Location; import android.os.AsyncTask; import android.support.annotation.NonNull; <BUG>import android.util.Log; import org.mariotaku.twidere.BuildConfig; import org.mariotaku.twidere.Constants; import org.mariotaku.twidere.util.JsonSerializer;</BUG> import org.mariotaku.twidere.util.Utils;
import org.mariotaku.twidere.util.DebugLog; import org.mariotaku.twidere.util.JsonSerializer;
10,293
} public static LatLng getCachedLatLng(@NonNull final Context context) { final Context appContext = context.getApplicationContext(); final SharedPreferences prefs = DependencyHolder.Companion.get(context).getPreferences(); if (!prefs.getBoolean(KEY_USAGE_STATISTICS, false)) return null; <BUG>if (BuildConfig.DEBUG) { Log.d(HotMobiLogger.LOGTAG, "getting cached location"); }</BUG> final Location location = Utils.getCachedLocation(appContext);
DebugLog.d(HotMobiLogger.LOGTAG, "getting cached location", null);
10,294
public int destroySavedSearchAsync(final UserKey accountKey, final long searchId) { final DestroySavedSearchTask task = new DestroySavedSearchTask(accountKey, searchId); return asyncTaskManager.add(task, true); } public int destroyStatusAsync(final UserKey accountKey, final String statusId) { <BUG>final DestroyStatusTask task = new DestroyStatusTask(context,accountKey, statusId); </BUG> return asyncTaskManager.add(task, true); } public int destroyUserListAsync(final UserKey accountKey, final String listId) {
final DestroyStatusTask task = new DestroyStatusTask(context, accountKey, statusId);
10,295
@Override public void afterExecute(Bus handler, SingleResponse<Relationship> result) { if (result.hasData()) { handler.post(new FriendshipUpdatedEvent(accountKey, userKey, result.getData())); } else if (result.hasException()) { <BUG>if (BuildConfig.DEBUG) { Log.w(LOGTAG, "Unable to update friendship", result.getException()); }</BUG> }
public UserKey[] getAccountKeys() { return DataStoreUtils.getActivatedAccountKeys(context);
10,296
MicroBlog microBlog = MicroBlogAPIFactory.getInstance(context, accountId); if (!Utils.isOfficialCredentials(context, accountId)) continue; try { microBlog.setActivitiesAboutMeUnread(cursor); } catch (MicroBlogException e) { <BUG>if (BuildConfig.DEBUG) { Log.w(LOGTAG, e); }</BUG> }
DebugLog.w(LOGTAG, null, e);
10,297
this.popularity = Boolean.valueOf(prop.getProperty("popularity")); this.context = Boolean.valueOf(prop.getProperty("context")); this.acronym = Boolean.valueOf(prop.getProperty("acronym")); this.commonEntities = Boolean.valueOf(prop.getProperty("commonEntities")); } <BUG>public void insertCandidatesIntoText(DirectedSparseGraph<Node, String> graph, Document document, double threshholdTrigram, Boolean heuristicExpansionOn) throws IOException { NamedEntitiesInText namedEntities = document.getNamedEntitiesInText();</BUG> String text = document.DocumentText().getText(); HashMap<String, Node> nodes = new HashMap<String, Node>(); Collections.sort(namedEntities.getNamedEntities(), new NamedEntityLengthComparator());
public void insertCandidatesIntoText(DirectedSparseGraph<Node, String> graph, Document document, NamedEntitiesInText namedEntities = document.getNamedEntitiesInText();
10,298
long start = System.currentTimeMillis(); if (heuristicExpansionOn) { label = heuristicExpansion(heuristicExpansion, label); } checkLabelCandidates(graph, threshholdTrigram, nodes, entity, label, false, entities); <BUG>log.info("\tGraph size: " + graph.getVertexCount() + " took: " + (System.currentTimeMillis() - start) + " ms"); }</BUG> } private String heuristicExpansion(HashSet<String> heuristicExpansion, String label) { String tmp = label;
log.info("\tGraph size: " + graph.getVertexCount() + " took: " + (System.currentTimeMillis() - start)
10,299
if (!expansion) { heuristicExpansion.add(label); } return label; } <BUG>public void addNodeToGraph(DirectedSparseGraph<Node, String> graph, HashMap<String, Node> nodes, NamedEntityInText entity, Triple c, String candidateURL) throws IOException { Node currentNode = new Node(candidateURL, 0, 0);</BUG> log.debug("CandidateURL: " + candidateURL); if (!graph.addVertex(currentNode)) { int st = entity.getStartPos();
public void addNodeToGraph(DirectedSparseGraph<Node, String> graph, HashMap<String, Node> nodes, Node currentNode = new Node(candidateURL, 0, 0);
10,300
public class DomainWhiteLister { private TripleIndex index; HashSet<String> whiteList = new HashSet<String>(); public DomainWhiteLister(TripleIndex index) throws IOException { Properties prop = new Properties(); <BUG>InputStream input =DomainWhiteLister.class.getResourceAsStream("/config/agdistis.properties"); </BUG> prop.load(input); String file = prop.getProperty("whiteList"); loadWhiteDomains(file);
InputStream input = DomainWhiteLister.class.getResourceAsStream("/config/agdistis.properties");