repo_name
stringlengths
7
104
file_path
stringlengths
13
198
context
stringlengths
67
7.15k
import_statement
stringlengths
16
4.43k
code
stringlengths
40
6.98k
prompt
stringlengths
227
8.27k
next_line
stringlengths
8
795
thehiflyer/Fettle
src/main/java/se/fearless/fettle/builder/EntryExitActionBuilder.java
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
import se.fearless.fettle.Action; import se.fearless.fettle.MutableTransitionModel; import se.fearless.fettle.util.GuavaReplacement; import java.util.List;
package se.fearless.fettle.builder; public class EntryExitActionBuilder<S, E, C> implements EntryExit<S, E, C> { private final Mode mode; private final S state; private EntryExitActionBuilder(Mode mode, S state) { this.mode = mode; this.state = state; } private enum Mode { ENTRY, EXIT }
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
private final List<Action<S, E, C>> actions = GuavaReplacement.newArrayList();
thehiflyer/Fettle
src/main/java/se/fearless/fettle/builder/EntryExitActionBuilder.java
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
import se.fearless.fettle.Action; import se.fearless.fettle.MutableTransitionModel; import se.fearless.fettle.util.GuavaReplacement; import java.util.List;
package se.fearless.fettle.builder; public class EntryExitActionBuilder<S, E, C> implements EntryExit<S, E, C> { private final Mode mode; private final S state; private EntryExitActionBuilder(Mode mode, S state) { this.mode = mode; this.state = state; } private enum Mode { ENTRY, EXIT }
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
private final List<Action<S, E, C>> actions = GuavaReplacement.newArrayList();
thehiflyer/Fettle
src/main/java/se/fearless/fettle/builder/EntryExitActionBuilder.java
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
import se.fearless.fettle.Action; import se.fearless.fettle.MutableTransitionModel; import se.fearless.fettle.util.GuavaReplacement; import java.util.List;
package se.fearless.fettle.builder; public class EntryExitActionBuilder<S, E, C> implements EntryExit<S, E, C> { private final Mode mode; private final S state; private EntryExitActionBuilder(Mode mode, S state) { this.mode = mode; this.state = state; } private enum Mode { ENTRY, EXIT } private fin...
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
public void addToMachine(MutableTransitionModel<S, E, C> machineConstructor) {
thehiflyer/Fettle
src/main/java/se/fearless/fettle/builder/TransitionBuilder.java
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
import se.fearless.fettle.Action; import se.fearless.fettle.BasicConditions; import se.fearless.fettle.Condition; import se.fearless.fettle.MutableTransitionModel; import se.fearless.fettle.util.GuavaReplacement; import java.util.List;
package se.fearless.fettle.builder; class TransitionBuilder<S, E, C> implements Transition<S, E, C>, From<S, E, C>, To<S, E, C>, On<S, E, C>, When<S, E, C>, Internal<S, E, C> { private final List<Action<S, E, C>> actions = GuavaReplacement.newArrayList(); private S from; private S to; private E event;
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
private Condition<C> condition = BasicConditions.always();
thehiflyer/Fettle
src/main/java/se/fearless/fettle/builder/TransitionBuilder.java
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
import se.fearless.fettle.Action; import se.fearless.fettle.BasicConditions; import se.fearless.fettle.Condition; import se.fearless.fettle.MutableTransitionModel; import se.fearless.fettle.util.GuavaReplacement; import java.util.List;
package se.fearless.fettle.builder; class TransitionBuilder<S, E, C> implements Transition<S, E, C>, From<S, E, C>, To<S, E, C>, On<S, E, C>, When<S, E, C>, Internal<S, E, C> { private final List<Action<S, E, C>> actions = GuavaReplacement.newArrayList(); private S from; private S to; private E event;
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
private Condition<C> condition = BasicConditions.always();
thehiflyer/Fettle
src/main/java/se/fearless/fettle/builder/TransitionBuilder.java
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
import se.fearless.fettle.Action; import se.fearless.fettle.BasicConditions; import se.fearless.fettle.Condition; import se.fearless.fettle.MutableTransitionModel; import se.fearless.fettle.util.GuavaReplacement; import java.util.List;
public To<S, E, C> to(S toState) { this.to = toState; return this; } @Override public Internal<S, E, C> internal(S state) { this.from = state; this.to = state; runEntryAndExit = false; return this; } @Override public When<S, E, C> when(Condition<C> condition) { this.condition = con...
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
void addToTransitionModel(MutableTransitionModel<S, E, C> transitionModel) {
thehiflyer/Fettle
src/test/java/se/fearless/fettle/PredicateConditionTest.java
// Path: src/main/java/se/fearless/fettle/util/PredicateCondition.java // public class PredicateCondition<C> implements Condition<C> { // // private final Predicate<? super C> predicate; // // public PredicateCondition(Predicate<? super C> predicate) { // this.predicate = predicate; // } // // @Override // pu...
import com.google.common.base.Predicates; import org.junit.Test; import se.fearless.fettle.util.PredicateCondition; import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertTrue;
package se.fearless.fettle; public class PredicateConditionTest { @Test public void predicate() {
// Path: src/main/java/se/fearless/fettle/util/PredicateCondition.java // public class PredicateCondition<C> implements Condition<C> { // // private final Predicate<? super C> predicate; // // public PredicateCondition(Predicate<? super C> predicate) { // this.predicate = predicate; // } // // @Override // pu...
PredicateCondition<String> condition = new PredicateCondition<>(Predicates.containsPattern("foo")::apply);
thehiflyer/Fettle
src/test/java/se/fearless/fettle/TestStatesImmutable.java
// Path: src/main/java/se/fearless/fettle/impl/MutableTransitionModelImpl.java // public class MutableTransitionModelImpl<S, E, C> extends AbstractTransitionModel<S, E, C> implements MutableTransitionModel<S, E, C> { // // private MutableTransitionModelImpl(Class<S> stateClass, Class<E> eventClass, C defaultContext) ...
import com.googlecode.gentyref.TypeToken; import org.junit.Test; import se.fearless.fettle.impl.MutableTransitionModelImpl; import java.util.Collections; import static org.junit.Assert.assertEquals; import static se.mockachino.Mockachino.mock; import static se.mockachino.Mockachino.verifyNever; import static se.mockach...
package se.fearless.fettle; public class TestStatesImmutable { private static final TypeToken<Action<States, String, Void>> ACTION_TYPE_TOKEN = new TypeToken<Action<States, String, Void>>() { }; @Test public void simpleStateTransition() {
// Path: src/main/java/se/fearless/fettle/impl/MutableTransitionModelImpl.java // public class MutableTransitionModelImpl<S, E, C> extends AbstractTransitionModel<S, E, C> implements MutableTransitionModel<S, E, C> { // // private MutableTransitionModelImpl(Class<S> stateClass, Class<E> eventClass, C defaultContext) ...
MutableTransitionModelImpl<States, String, Void> model = MutableTransitionModelImpl.create(States.class, String.class);
thehiflyer/Fettle
src/test/java/se/fearless/fettle/SelfTransitionsTest.java
// Path: src/main/java/se/fearless/fettle/builder/StateMachineBuilder.java // public class StateMachineBuilder<S, E, C> { // private final List<TransitionBuilder<S, E, C>> transitionBuilders = GuavaReplacement.newArrayList(); // private final List<EntryExitActionBuilder<S, E, C>> entryExitActions = GuavaReplacement.n...
import org.junit.Before; import org.junit.Test; import se.fearless.fettle.builder.StateMachineBuilder; import se.mockachino.annotations.Mock; import static se.mockachino.Mockachino.setupMocks; import static se.mockachino.Mockachino.verifyOnce; import static se.mockachino.matchers.Matchers.any;
package se.fearless.fettle; public class SelfTransitionsTest { @Mock private Action<States, String, Void> transitionAction; @Mock private Action<States, String, Void> entryAction; @Mock private Action<States, String, Void> exitAction; private StateMachine<States, String, Void> stateMachine; @Before pub...
// Path: src/main/java/se/fearless/fettle/builder/StateMachineBuilder.java // public class StateMachineBuilder<S, E, C> { // private final List<TransitionBuilder<S, E, C>> transitionBuilders = GuavaReplacement.newArrayList(); // private final List<EntryExitActionBuilder<S, E, C>> entryExitActions = GuavaReplacement.n...
StateMachineBuilder<States, String, Void> builder = Fettle.newBuilder(States.class, String.class);
thehiflyer/Fettle
src/main/java/se/fearless/fettle/impl/ImmutableTransitionModel.java
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
import se.fearless.fettle.Action; import se.fearless.fettle.StateMachine; import se.fearless.fettle.StateMachineTemplate; import se.fearless.fettle.Transition; import se.fearless.fettle.util.GuavaReplacement; import java.util.Collection; import java.util.Map; import java.util.concurrent.locks.Lock; import java.util.con...
package se.fearless.fettle.impl; public class ImmutableTransitionModel<S, E, C> extends AbstractTransitionModel<S, E, C> implements StateMachineTemplate<S, E, C> { public ImmutableTransitionModel(Class<S> stateClass, Class<E> eventClass,
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
Map<S, Map<E, Collection<Transition<S, E, C>>>> transitionMap,
thehiflyer/Fettle
src/main/java/se/fearless/fettle/impl/ImmutableTransitionModel.java
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
import se.fearless.fettle.Action; import se.fearless.fettle.StateMachine; import se.fearless.fettle.StateMachineTemplate; import se.fearless.fettle.Transition; import se.fearless.fettle.util.GuavaReplacement; import java.util.Collection; import java.util.Map; import java.util.concurrent.locks.Lock; import java.util.con...
package se.fearless.fettle.impl; public class ImmutableTransitionModel<S, E, C> extends AbstractTransitionModel<S, E, C> implements StateMachineTemplate<S, E, C> { public ImmutableTransitionModel(Class<S> stateClass, Class<E> eventClass, Map<S, Map<E, Collection<Transition<S, E, C>>>> transitionMap, ...
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
Map<S, Collection<Action<S, E, C>>> exitActions,
thehiflyer/Fettle
src/main/java/se/fearless/fettle/impl/ImmutableTransitionModel.java
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
import se.fearless.fettle.Action; import se.fearless.fettle.StateMachine; import se.fearless.fettle.StateMachineTemplate; import se.fearless.fettle.Transition; import se.fearless.fettle.util.GuavaReplacement; import java.util.Collection; import java.util.Map; import java.util.concurrent.locks.Lock; import java.util.con...
package se.fearless.fettle.impl; public class ImmutableTransitionModel<S, E, C> extends AbstractTransitionModel<S, E, C> implements StateMachineTemplate<S, E, C> { public ImmutableTransitionModel(Class<S> stateClass, Class<E> eventClass, Map<S, Map<E, Collection<Transition<S, E, C>>>> transitionMap, ...
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
Map<E, Collection<Transition<S, E, C>>> res = GuavaReplacement.newHashMap();
thehiflyer/Fettle
src/main/java/se/fearless/fettle/impl/ImmutableTransitionModel.java
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
import se.fearless.fettle.Action; import se.fearless.fettle.StateMachine; import se.fearless.fettle.StateMachineTemplate; import se.fearless.fettle.Transition; import se.fearless.fettle.util.GuavaReplacement; import java.util.Collection; import java.util.Map; import java.util.concurrent.locks.Lock; import java.util.con...
return res; } private Map<E, Collection<Transition<S, E, C>>> copyTransitions2(Map<E, Collection<Transition<S, E, C>>> input) { Map<E, Collection<Transition<S, E, C>>> res = GuavaReplacement.newHashMap(); for (Map.Entry<E, Collection<Transition<S, E, C>>> entry : input.entrySet()) { E key = entry.getKey(); ...
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
public StateMachine<S, E, C> newStateMachine(S init) {
thehiflyer/Fettle
src/main/java/se/fearless/fettle/impl/ImmutableTransitionModel.java
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
import se.fearless.fettle.Action; import se.fearless.fettle.StateMachine; import se.fearless.fettle.StateMachineTemplate; import se.fearless.fettle.Transition; import se.fearless.fettle.util.GuavaReplacement; import java.util.Collection; import java.util.Map; import java.util.concurrent.locks.Lock; import java.util.con...
} private Map<E, Collection<Transition<S, E, C>>> copyTransitions2(Map<E, Collection<Transition<S, E, C>>> input) { Map<E, Collection<Transition<S, E, C>>> res = GuavaReplacement.newHashMap(); for (Map.Entry<E, Collection<Transition<S, E, C>>> entry : input.entrySet()) { E key = entry.getKey(); Collection<...
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
return newStateMachine(init, new ReentrantLock());
thehiflyer/Fettle
src/main/java/se/fearless/fettle/impl/ImmutableTransitionModel.java
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
import se.fearless.fettle.Action; import se.fearless.fettle.StateMachine; import se.fearless.fettle.StateMachineTemplate; import se.fearless.fettle.Transition; import se.fearless.fettle.util.GuavaReplacement; import java.util.Collection; import java.util.Map; import java.util.concurrent.locks.Lock; import java.util.con...
for (Map.Entry<E, Collection<Transition<S, E, C>>> entry : input.entrySet()) { E key = entry.getKey(); Collection<Transition<S, E, C>> value = entry.getValue(); res.put(key, copy(value)); } return res; } private Map<S, Collection<Action<S, E, C>>> copy(Map<S, Collection<Action<S, E, C>>> input) { Ma...
// Path: src/main/java/se/fearless/fettle/Action.java // public interface Action<S, E, C> { // /** // * Called when a transition occurs // * @param from the state the machine was in before the transition // * @param to the state the machine is in after the transition // * @param causedBy the event that trigger...
public StateMachine<S, E, C> newStateMachine(S init, Lock lock) {
thehiflyer/Fettle
src/test/java/se/fearless/fettle/TestFireEvent.java
// Path: src/main/java/se/fearless/fettle/impl/MutableTransitionModelImpl.java // public class MutableTransitionModelImpl<S, E, C> extends AbstractTransitionModel<S, E, C> implements MutableTransitionModel<S, E, C> { // // private MutableTransitionModelImpl(Class<S> stateClass, Class<E> eventClass, C defaultContext) ...
import org.junit.Test; import se.fearless.fettle.impl.MutableTransitionModelImpl; import java.util.Collections; import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertTrue;
package se.fearless.fettle; public class TestFireEvent { enum Triggers { FOO, BAR, BAZ } @Test public void fireEvent() {
// Path: src/main/java/se/fearless/fettle/impl/MutableTransitionModelImpl.java // public class MutableTransitionModelImpl<S, E, C> extends AbstractTransitionModel<S, E, C> implements MutableTransitionModel<S, E, C> { // // private MutableTransitionModelImpl(Class<S> stateClass, Class<E> eventClass, C defaultContext) ...
MutableTransitionModelImpl<States, Triggers, Void> model = MutableTransitionModelImpl.create(States.class, Triggers.class);
nchambers/probschemas
src/main/java/nate/probschemas/EntityFiller.java
// Path: src/main/java/nate/EntityMention.java // public class EntityMention { // int entityID, sentenceID, start, end; // String string = ""; // boolean wordBased = false; // NERSpan.TYPE namedEntity = NERSpan.TYPE.NONE; // // // public EntityMention(int sid, String text, Span span, int eid) { // thi...
import java.util.Set; import nate.EntityMention;
package nate.probschemas; public class EntityFiller { private int _entityID; private String _string; private double _scoredInRole;
// Path: src/main/java/nate/EntityMention.java // public class EntityMention { // int entityID, sentenceID, start, end; // String string = ""; // boolean wordBased = false; // NERSpan.TYPE namedEntity = NERSpan.TYPE.NONE; // // // public EntityMention(int sid, String text, Span span, int eid) { // thi...
public EntityMention _mainMention;
nchambers/probschemas
src/main/java/nate/probschemas/Frame.java
// Path: src/main/java/nate/util/SortableObject.java // public class SortableObject<E> implements Comparable<SortableObject<E>> { // double score = 0.0f; // E key; // // public SortableObject(double s, E k) { // score = s; // key = k; // } // public SortableObject() { } // // public int compareTo(...
import java.util.ArrayList; import java.util.Arrays; import java.util.Collection; import java.util.HashMap; import java.util.HashSet; import java.util.List; import java.util.Map; import java.util.Set; import nate.util.SortableObject; import nate.util.SortableScore;
if( clone.getRoles() != null ) for( FrameRole role : clone.getRoles() ) addRole(role); // _tokens = null; // _arguments = clone.arguments(); } public void clear() { if( _tokenScores != null ) _tokenScores.clear(); // if( _tokens != null ) _tokens.clear(); if( _orderedByScore != null ) ...
// Path: src/main/java/nate/util/SortableObject.java // public class SortableObject<E> implements Comparable<SortableObject<E>> { // double score = 0.0f; // E key; // // public SortableObject(double s, E k) { // score = s; // key = k; // } // public SortableObject() { } // // public int compareTo(...
public void setTokenScores(Collection<SortableObject<String>> scores) {
nchambers/probschemas
src/main/java/nate/probschemas/Frame.java
// Path: src/main/java/nate/util/SortableObject.java // public class SortableObject<E> implements Comparable<SortableObject<E>> { // double score = 0.0f; // E key; // // public SortableObject(double s, E k) { // score = s; // key = k; // } // public SortableObject() { } // // public int compareTo(...
import java.util.ArrayList; import java.util.Arrays; import java.util.Collection; import java.util.HashMap; import java.util.HashSet; import java.util.List; import java.util.Map; import java.util.Set; import nate.util.SortableObject; import nate.util.SortableScore;
public void setTokenScores(Map<String,Double> scores) { if( _tokenScores == null ) _tokenScores = new HashMap<String, Double>(); clear(); for( Map.Entry<String, Double> entry : scores.entrySet() ) { String token = (String)entry.getKey(); double score = entry.getValue(); _tokenScores.put(...
// Path: src/main/java/nate/util/SortableObject.java // public class SortableObject<E> implements Comparable<SortableObject<E>> { // double score = 0.0f; // E key; // // public SortableObject(double s, E k) { // score = s; // key = k; // } // public SortableObject() { } // // public int compareTo(...
SortableScore[] sorted = new SortableScore[_tokenScores.size()];
waldheinz/fat32-lib
src/main/java/de/waldheinz/fs/fat/FsInfoSector.java
// Path: src/main/java/de/waldheinz/fs/BlockDevice.java // public interface BlockDevice { // // /** // * Gets the total length of this device in bytes. // * // * @return the total number of bytes on this device // * @throws IOException on error getting the size of this device // */ // ...
import de.waldheinz.fs.BlockDevice; import java.io.IOException;
/* * Copyright (C) 2009-2013 Matthias Treydte <mt@waldheinz.de> * * This library is free software; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as published * by the Free Software Foundation; either version 2.1 of the License, or * (at your option) any later ...
// Path: src/main/java/de/waldheinz/fs/BlockDevice.java // public interface BlockDevice { // // /** // * Gets the total length of this device in bytes. // * // * @return the total number of bytes on this device // * @throws IOException on error getting the size of this device // */ // ...
private FsInfoSector(BlockDevice device, long offset) {
waldheinz/fat32-lib
src/main/java/de/waldheinz/fs/fat/Fat.java
// Path: src/main/java/de/waldheinz/fs/BlockDevice.java // public interface BlockDevice { // // /** // * Gets the total length of this device in bytes. // * // * @return the total number of bytes on this device // * @throws IOException on error getting the size of this device // */ // ...
import java.util.Arrays; import de.waldheinz.fs.BlockDevice; import java.io.IOException; import java.nio.ByteBuffer;
/* * Copyright (C) 2003-2009 JNode.org * 2009-2013 Matthias Treydte <mt@waldheinz.de> * * This library is free software; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as published * by the Free Software Foundation; either version 2.1 of the Licen...
// Path: src/main/java/de/waldheinz/fs/BlockDevice.java // public interface BlockDevice { // // /** // * Gets the total length of this device in bytes. // * // * @return the total number of bytes on this device // * @throws IOException on error getting the size of this device // */ // ...
private final BlockDevice device;
waldheinz/fat32-lib
src/test/java/de/waldheinz/fs/fat/FileSystemSizeTest.java
// Path: src/main/java/de/waldheinz/fs/util/RamDisk.java // public final class RamDisk implements BlockDevice { // // /** // * The default sector size for {@code RamDisk}s. // */ // public final static int DEFAULT_SECTOR_SIZE = 512; // // private final int sectorSize; // private fina...
import org.junit.Assert; import org.junit.Test; import java.io.InputStream; import de.waldheinz.fs.util.RamDisk;
package de.waldheinz.fs.fat; /** * @author Jan Seeger &lt;jan@alphadev.net&gt; */ public class FileSystemSizeTest { @Test public void testFat32Size() throws Exception { System.out.println("fat32Size"); final InputStream is = getClass().getResourceAsStream( "fat32-test.img....
// Path: src/main/java/de/waldheinz/fs/util/RamDisk.java // public final class RamDisk implements BlockDevice { // // /** // * The default sector size for {@code RamDisk}s. // */ // public final static int DEFAULT_SECTOR_SIZE = 512; // // private final int sectorSize; // private fina...
final RamDisk rd = RamDisk.readGzipped(is);
waldheinz/fat32-lib
src/main/java/de/waldheinz/fs/fat/SuperFloppyFormatter.java
// Path: src/main/java/de/waldheinz/fs/BlockDevice.java // public interface BlockDevice { // // /** // * Gets the total length of this device in bytes. // * // * @return the total number of bytes on this device // * @throws IOException on error getting the size of this device // */ // ...
import de.waldheinz.fs.BlockDevice; import java.io.IOException; import java.util.Random;
/* * Copyright (C) 2009-2013 Matthias Treydte <mt@waldheinz.de> * * This library is free software; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as published * by the Free Software Foundation; either version 2.1 of the License, or * (at your option) any later ...
// Path: src/main/java/de/waldheinz/fs/BlockDevice.java // public interface BlockDevice { // // /** // * Gets the total length of this device in bytes. // * // * @return the total number of bytes on this device // * @throws IOException on error getting the size of this device // */ // ...
private final BlockDevice device;
waldheinz/fat32-lib
src/test/java/de/waldheinz/fs/util/FileDiskTest.java
// Path: src/main/java/de/waldheinz/fs/ReadOnlyException.java // public final class ReadOnlyException extends RuntimeException { // // private final static long serialVersionUID = 1; // // /** // * Creates a new instance of {@code ReadOnlyException}. // * // */ // public ReadOnlyExcepti...
import de.waldheinz.fs.ReadOnlyException; import java.io.File; import java.io.IOException; import java.nio.ByteBuffer; import java.util.Random; import org.junit.After; import org.junit.Before; import org.junit.Test; import static org.junit.Assert.*;
/* * Copyright (C) 2009-2013 Matthias Treydte <mt@waldheinz.de> * * This library is free software; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as published * by the Free Software Foundation; either version 2.1 of the License, or * (at your option) any later ...
// Path: src/main/java/de/waldheinz/fs/ReadOnlyException.java // public final class ReadOnlyException extends RuntimeException { // // private final static long serialVersionUID = 1; // // /** // * Creates a new instance of {@code ReadOnlyException}. // * // */ // public ReadOnlyExcepti...
@Test(expected=ReadOnlyException.class)
waldheinz/fat32-lib
src/main/java/de/waldheinz/fs/fat/FatFileSystem.java
// Path: src/main/java/de/waldheinz/fs/AbstractFileSystem.java // public abstract class AbstractFileSystem implements FileSystem { // private final boolean readOnly; // private boolean closed; // // /** // * Creates a new {@code AbstractFileSystem}. // * // * @param readOnly if the file...
import de.waldheinz.fs.ReadOnlyException; import de.waldheinz.fs.AbstractFileSystem; import de.waldheinz.fs.BlockDevice; import java.io.IOException;
/* * Copyright (C) 2003-2009 JNode.org * 2009-2013 Matthias Treydte <mt@waldheinz.de> * * This library is free software; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as published * by the Free Software Foundation; either version 2.1 of the Licen...
// Path: src/main/java/de/waldheinz/fs/AbstractFileSystem.java // public abstract class AbstractFileSystem implements FileSystem { // private final boolean readOnly; // private boolean closed; // // /** // * Creates a new {@code AbstractFileSystem}. // * // * @param readOnly if the file...
FatFileSystem(BlockDevice api, boolean readOnly) throws IOException {
waldheinz/fat32-lib
src/main/java/de/waldheinz/fs/fat/FatFileSystem.java
// Path: src/main/java/de/waldheinz/fs/AbstractFileSystem.java // public abstract class AbstractFileSystem implements FileSystem { // private final boolean readOnly; // private boolean closed; // // /** // * Creates a new {@code AbstractFileSystem}. // * // * @param readOnly if the file...
import de.waldheinz.fs.ReadOnlyException; import de.waldheinz.fs.AbstractFileSystem; import de.waldheinz.fs.BlockDevice; import java.io.IOException;
checkClosed(); return this.fatType; } /** * Returns the volume label of this file system. * * @return the volume label */ public String getVolumeLabel() { checkClosed(); final String fromDir = rootDirStore.getLabel(); if (fromDi...
// Path: src/main/java/de/waldheinz/fs/AbstractFileSystem.java // public abstract class AbstractFileSystem implements FileSystem { // private final boolean readOnly; // private boolean closed; // // /** // * Creates a new {@code AbstractFileSystem}. // * // * @param readOnly if the file...
throws ReadOnlyException, IOException {
waldheinz/fat32-lib
src/main/java/de/waldheinz/fs/fat/Fat16BootSector.java
// Path: src/main/java/de/waldheinz/fs/BlockDevice.java // public interface BlockDevice { // // /** // * Gets the total length of this device in bytes. // * // * @return the total number of bytes on this device // * @throws IOException on error getting the size of this device // */ // ...
import de.waldheinz.fs.BlockDevice; import java.io.IOException;
/* * Copyright (C) 2009-2013 Matthias Treydte <mt@waldheinz.de> * * This library is free software; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as published * by the Free Software Foundation; either version 2.1 of the License, or * (at your option) any later ...
// Path: src/main/java/de/waldheinz/fs/BlockDevice.java // public interface BlockDevice { // // /** // * Gets the total length of this device in bytes. // * // * @return the total number of bytes on this device // * @throws IOException on error getting the size of this device // */ // ...
public Fat16BootSector(BlockDevice device) {
waldheinz/fat32-lib
src/main/java/de/waldheinz/fs/util/FileDisk.java
// Path: src/main/java/de/waldheinz/fs/BlockDevice.java // public interface BlockDevice { // // /** // * Gets the total length of this device in bytes. // * // * @return the total number of bytes on this device // * @throws IOException on error getting the size of this device // */ // ...
import de.waldheinz.fs.BlockDevice; import de.waldheinz.fs.ReadOnlyException; import java.io.File; import java.io.FileNotFoundException; import java.io.IOException; import java.io.RandomAccessFile; import java.nio.ByteBuffer; import java.nio.channels.FileChannel;
} } @Override public long getSize() throws IOException { checkClosed(); return raf.length(); } @Override public void read(long devOffset, ByteBuffer dest) throws IOException { checkClosed(); int toRead = dest.remaining(); if ((devOf...
// Path: src/main/java/de/waldheinz/fs/BlockDevice.java // public interface BlockDevice { // // /** // * Gets the total length of this device in bytes. // * // * @return the total number of bytes on this device // * @throws IOException on error getting the size of this device // */ // ...
if (this.readOnly) throw new ReadOnlyException();
waldheinz/fat32-lib
src/main/java/de/waldheinz/fs/fat/Fat32BootSector.java
// Path: src/main/java/de/waldheinz/fs/BlockDevice.java // public interface BlockDevice { // // /** // * Gets the total length of this device in bytes. // * // * @return the total number of bytes on this device // * @throws IOException on error getting the size of this device // */ // ...
import de.waldheinz.fs.BlockDevice; import java.io.IOException;
/* * Copyright (C) 2009-2013 Matthias Treydte <mt@waldheinz.de> * * This library is free software; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as published * by the Free Software Foundation; either version 2.1 of the License, or * (at your option) any later ...
// Path: src/main/java/de/waldheinz/fs/BlockDevice.java // public interface BlockDevice { // // /** // * Gets the total length of this device in bytes. // * // * @return the total number of bytes on this device // * @throws IOException on error getting the size of this device // */ // ...
public Fat32BootSector(BlockDevice device) throws IOException {
waldheinz/fat32-lib
src/main/java/de/waldheinz/fs/fat/ClusterChain.java
// Path: src/main/java/de/waldheinz/fs/AbstractFsObject.java // public class AbstractFsObject implements FsObject { // // /** // * Holds the read-only state of this object. // */ // private final boolean readOnly; // // /** // * Remembers if this object still valid. // */ // pr...
import de.waldheinz.fs.AbstractFsObject; import de.waldheinz.fs.BlockDevice; import java.io.EOFException; import java.io.IOException; import java.nio.ByteBuffer;
/* * Copyright (C) 2009-2013 Matthias Treydte <mt@waldheinz.de> * * This library is free software; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as published * by the Free Software Foundation; either version 2.1 of the License, or * (at your option) any later ...
// Path: src/main/java/de/waldheinz/fs/AbstractFsObject.java // public class AbstractFsObject implements FsObject { // // /** // * Holds the read-only state of this object. // */ // private final boolean readOnly; // // /** // * Remembers if this object still valid. // */ // pr...
private final BlockDevice device;
waldheinz/fat32-lib
src/test/java/de/waldheinz/fs/fat/MoveToReplaceTest.java
// Path: src/main/java/de/waldheinz/fs/util/RamDisk.java // public final class RamDisk implements BlockDevice { // // /** // * The default sector size for {@code RamDisk}s. // */ // public final static int DEFAULT_SECTOR_SIZE = 512; // // private final int sectorSize; // private fina...
import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNull; import java.io.IOException; import org.junit.Before; import org.junit.Test; import de.waldheinz.fs.util.RamDisk;
package de.waldheinz.fs.fat; public class MoveToReplaceTest { private static final String FILE_NAME = "file"; private static final String DIRECTORY_NAME = "dir"; private FatLfnDirectoryEntry file; private FatLfnDirectoryEntry dir; private FatLfnDirectory root; private FatFileSystem fs; ...
// Path: src/main/java/de/waldheinz/fs/util/RamDisk.java // public final class RamDisk implements BlockDevice { // // /** // * The default sector size for {@code RamDisk}s. // */ // public final static int DEFAULT_SECTOR_SIZE = 512; // // private final int sectorSize; // private fina...
RamDisk dev = new RamDisk(1024 * 1024);
waldheinz/fat32-lib
src/main/java/de/waldheinz/fs/fat/BootSector.java
// Path: src/main/java/de/waldheinz/fs/BlockDevice.java // public interface BlockDevice { // // /** // * Gets the total length of this device in bytes. // * // * @return the total number of bytes on this device // * @throws IOException on error getting the size of this device // */ // ...
import java.nio.ByteOrder; import de.waldheinz.fs.BlockDevice; import java.io.IOException; import java.nio.ByteBuffer;
/* * Copyright (C) 2003-2009 JNode.org * 2009-2013 Matthias Treydte <mt@waldheinz.de> * * This library is free software; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as published * by the Free Software Foundation; either version 2.1 of the Licen...
// Path: src/main/java/de/waldheinz/fs/BlockDevice.java // public interface BlockDevice { // // /** // * Gets the total length of this device in bytes. // * // * @return the total number of bytes on this device // * @throws IOException on error getting the size of this device // */ // ...
protected BootSector(BlockDevice device) {
foobnix/android-universal-utils
src/com/foobnix/android/utils/broadcast/LocalBroadcastFragment.java
// Path: src/com/foobnix/android/utils/LOG.java // public class LOG { // public static boolean isEnable = true; // public static String TAG = "DEBUG"; // public static String DELIMITER = "|"; // // public static void printlog(String statement) { // if (isEnable) { // Log.d(TAG, stat...
import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; import android.support.v4.app.Fragment; import android.support.v4.content.LocalBroadcastManager; import com.foobnix.android.utils.LOG; import com.foobnix.android.utils.ResultResponse;
package com.foobnix.android.utils.broadcast; public abstract class LocalBroadcastFragment extends Fragment implements ResultResponse<Intent> { BroadcastReceiver broadcastReceiver = new BroadcastReceiver() { @Override public void onReceive(Context context, Intent intent) {
// Path: src/com/foobnix/android/utils/LOG.java // public class LOG { // public static boolean isEnable = true; // public static String TAG = "DEBUG"; // public static String DELIMITER = "|"; // // public static void printlog(String statement) { // if (isEnable) { // Log.d(TAG, stat...
LOG.d("LocalBroadcastFragment", "onReceive", intent);
foobnix/android-universal-utils
src/com/foobnix/android/utils/res/ExtraArgument_1.java
// Path: src/com/foobnix/android/utils/ModelFragment.java // public abstract class ModelFragment<T extends Serializable> extends Fragment { // public static final String EXTRA_FRAGMENT_MODEL = "model"; // // public static final String EXTRA_ARGUMENT_1 = "EXTRA_ARGIMENT_1"; // public static final String EXT...
import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; import com.foobnix.android.utils.ModelFragment;
package com.foobnix.android.utils.res; @Retention(RetentionPolicy.RUNTIME) @Target({ ElementType.FIELD }) public @interface ExtraArgument_1 {
// Path: src/com/foobnix/android/utils/ModelFragment.java // public abstract class ModelFragment<T extends Serializable> extends Fragment { // public static final String EXTRA_FRAGMENT_MODEL = "model"; // // public static final String EXTRA_ARGUMENT_1 = "EXTRA_ARGIMENT_1"; // public static final String EXT...
String value() default ModelFragment.EXTRA_ARGUMENT_1;
foobnix/android-universal-utils
src/com/foobnix/android/utils/broadcast/LocalBroadcast.java
// Path: src/com/foobnix/android/utils/LOG.java // public class LOG { // public static boolean isEnable = true; // public static String TAG = "DEBUG"; // public static String DELIMITER = "|"; // // public static void printlog(String statement) { // if (isEnable) { // Log.d(TAG, stat...
import android.content.Context; import android.content.Intent; import android.content.IntentFilter; import android.support.v4.content.LocalBroadcastManager; import com.foobnix.android.utils.LOG;
package com.foobnix.android.utils.broadcast; public class LocalBroadcast { public static String LOCAL_NOTIFY_ACTION = "LOCAL_NOTIFY_ACTION"; public static IntentFilter INTENT_FILTER = new IntentFilter(LocalBroadcast.LOCAL_NOTIFY_ACTION); public static void send(Context context, Intent intent) {
// Path: src/com/foobnix/android/utils/LOG.java // public class LOG { // public static boolean isEnable = true; // public static String TAG = "DEBUG"; // public static String DELIMITER = "|"; // // public static void printlog(String statement) { // if (isEnable) { // Log.d(TAG, stat...
LOG.d("LocalBroadcast", "send", intent);
foobnix/android-universal-utils
src/com/foobnix/android/utils/broadcast/LocalBroadcastFragmentInvisible.java
// Path: src/com/foobnix/android/utils/LOG.java // public class LOG { // public static boolean isEnable = true; // public static String TAG = "DEBUG"; // public static String DELIMITER = "|"; // // public static void printlog(String statement) { // if (isEnable) { // Log.d(TAG, stat...
import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; import android.os.Bundle; import android.support.v4.app.Fragment; import android.support.v4.content.LocalBroadcastManager; import com.foobnix.android.utils.LOG; import com.foobnix.android.utils.ResultResponse;
package com.foobnix.android.utils.broadcast; public abstract class LocalBroadcastFragmentInvisible extends Fragment implements ResultResponse<Intent> { BroadcastReceiver broadcastReceiver = new BroadcastReceiver() { @Override public void onReceive(Context context, Intent intent) {
// Path: src/com/foobnix/android/utils/LOG.java // public class LOG { // public static boolean isEnable = true; // public static String TAG = "DEBUG"; // public static String DELIMITER = "|"; // // public static void printlog(String statement) { // if (isEnable) { // Log.d(TAG, stat...
LOG.d("LocalBroadcastFragmentInvisible", "onReceive", intent);
foobnix/android-universal-utils
src/com/foobnix/android/utils/res/ExtraArgument_3.java
// Path: src/com/foobnix/android/utils/ModelFragment.java // public abstract class ModelFragment<T extends Serializable> extends Fragment { // public static final String EXTRA_FRAGMENT_MODEL = "model"; // // public static final String EXTRA_ARGUMENT_1 = "EXTRA_ARGIMENT_1"; // public static final String EXT...
import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; import com.foobnix.android.utils.ModelFragment;
package com.foobnix.android.utils.res; @Retention(RetentionPolicy.RUNTIME) @Target({ ElementType.FIELD }) public @interface ExtraArgument_3 {
// Path: src/com/foobnix/android/utils/ModelFragment.java // public abstract class ModelFragment<T extends Serializable> extends Fragment { // public static final String EXTRA_FRAGMENT_MODEL = "model"; // // public static final String EXTRA_ARGUMENT_1 = "EXTRA_ARGIMENT_1"; // public static final String EXT...
String value() default ModelFragment.EXTRA_ARGUMENT_3;
foobnix/android-universal-utils
src/com/foobnix/android/utils/res/ExtraArgument_2.java
// Path: src/com/foobnix/android/utils/ModelFragment.java // public abstract class ModelFragment<T extends Serializable> extends Fragment { // public static final String EXTRA_FRAGMENT_MODEL = "model"; // // public static final String EXTRA_ARGUMENT_1 = "EXTRA_ARGIMENT_1"; // public static final String EXT...
import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; import com.foobnix.android.utils.ModelFragment;
package com.foobnix.android.utils.res; @Retention(RetentionPolicy.RUNTIME) @Target({ ElementType.FIELD }) public @interface ExtraArgument_2 {
// Path: src/com/foobnix/android/utils/ModelFragment.java // public abstract class ModelFragment<T extends Serializable> extends Fragment { // public static final String EXTRA_FRAGMENT_MODEL = "model"; // // public static final String EXTRA_ARGUMENT_1 = "EXTRA_ARGIMENT_1"; // public static final String EXT...
String value() default ModelFragment.EXTRA_ARGUMENT_2;
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/controller/StepController.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/StepModel.java // public interface StepModel { // // }
import org.n52.sos.importer.model.StepModel; import javax.swing.JPanel;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/StepModel.java // public interface StepModel { // // } // Path: wizard/src/main/java/org/n52/sos/importer/controller/StepController.java import org.n52.sos.importer.model.StepModel; import javax.swing.JPanel; /** * Copyright (C) 2011-2015 52°North Initiative...
public abstract StepModel getModel();
52North/sos-importer
wizard/src/test/java/org/n52/sos/importer/model/xml/Step7ModelHandlerTest.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Step7Model.java // public class Step7Model implements StepModel { // // private String sosURL; // // private String version; // // private String binding; // // private File configFile; // // private boolean generateOfferingFromSensorName; // // priva...
import static org.junit.Assert.assertThat; import java.util.NoSuchElementException; import org.junit.Test; import org.n52.sos.importer.Constants.ImportStrategy; import org.n52.sos.importer.model.Step7Model; import org.x52North.sensorweb.sos.importer.x04.KeyDocument.Key; import org.x52North.sensorweb.sos.importer.x04.Ke...
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Step7Model.java // public class Step7Model implements StepModel { // // private String sosURL; // // private String version; // // private String binding; // // private File configFile; // // private boolean generateOfferingFromSensorName; // // priva...
final Step7Model stepModel = new Step7Model(null, null, false, null, null, binding);
52North/sos-importer
feeder/src/main/java/org/n52/sos/importer/feeder/model/requests/RegisterSensor.java
// Path: feeder/src/main/java/org/n52/sos/importer/feeder/model/ObservedProperty.java // public class ObservedProperty extends Resource { // public ObservedProperty(String name, String uri) { // super(name, uri); // } // }
import org.n52.sos.importer.feeder.model.ObservedProperty; import java.util.Collection; import java.util.Map;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: feeder/src/main/java/org/n52/sos/importer/feeder/model/ObservedProperty.java // public class ObservedProperty extends Resource { // public ObservedProperty(String name, String uri) { // super(name, uri); // } // } // Path: feeder/src/main/java/org/n52/sos/importer/feeder/model/requests/RegisterSensor.jav...
private final Map<ObservedProperty, String> measuredValueTypes;
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/Month.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingMonthPanel; import java.util.GregorianCalendar;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/Month.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingMonthPanel; import java.util.GregorianCalendar;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/Month.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingMonthPanel; import java.util.GregorianCalendar;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
return new MissingMonthPanel((DateAndTime)c);
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/Time.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingTimePanel; import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.Component;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/Time.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingTimePanel; import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.Component;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/view/MissingComponentPanel.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Component.java // public abstract class Component { // // /** // * returns a panel to complete the component // * in case it is missing // * @param c // * @return // */ // public abstract MissingComponentPanel getMissingComponentPanel(Combination c);...
import org.n52.sos.importer.model.Component; import javax.swing.JPanel;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Component.java // public abstract class Component { // // /** // * returns a panel to complete the component // * in case it is missing // * @param c // * @return // */ // public abstract MissingComponentPanel getMissingComponentPanel(Combination c);...
public abstract Component getMissingComponent();
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/position/EPSGCode.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.table.Cell; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.position.MissingEPSGCodePanel; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.n52.sos.importer.model.Combinati...
} } /** * colors this particular component */ public void mark() { if (tableElement != null) { tableElement.mark(); } } @Override public String toString() { if (getTableElement() == null) { return "EPSG-Code " + getValue(); } else { return "EPSG-Code " + getTableElement(); } } pu...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(final Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/position/EPSGCode.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.table.Cell; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.position.MissingEPSGCodePanel; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.n52.sos.importer.model.Combinati...
} } /** * colors this particular component */ public void mark() { if (tableElement != null) { tableElement.mark(); } } @Override public String toString() { if (getTableElement() == null) { return "EPSG-Code " + getValue(); } else { return "EPSG-Code " + getTableElement(); } } pu...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(final Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/TimeZone.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingTimeZonePanel; import java.util.GregorianCalendar;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/TimeZone.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingTimeZonePanel; import java.util.GregorianCalendar;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/TimeZone.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingTimeZonePanel; import java.util.GregorianCalendar;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
return new MissingTimeZonePanel((DateAndTime)c);
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/Minute.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingMinutePanel; import java.util.GregorianCalendar;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/Minute.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingMinutePanel; import java.util.GregorianCalendar;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/Minute.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingMinutePanel; import java.util.GregorianCalendar;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
return new MissingMinutePanel((DateAndTime)c);
52North/sos-importer
wizard/src/test/java/org/n52/sos/importer/test/Step3TestPositionInTable.java
// Path: wizard/src/main/java/org/n52/sos/importer/controller/MainController.java // public class MainController { // // private static MainController instance = null; // // private final MainFrame mainFrame = new MainFrame(this); // // private final Model xmlModel; // // private MainController() { // // /...
import org.n52.sos.importer.controller.Step3Controller; import org.n52.sos.importer.controller.TableController; import org.n52.sos.importer.Constants; import org.n52.sos.importer.controller.MainController;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/controller/MainController.java // public class MainController { // // private static MainController instance = null; // // private final MainFrame mainFrame = new MainFrame(this); // // private final Model xmlModel; // // private MainController() { // // /...
final MainController f = MainController.getInstance();
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/Year.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingYearPanel; import java.util.GregorianCalendar;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/Year.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingYearPanel; import java.util.GregorianCalendar;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/Year.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingYearPanel; import java.util.GregorianCalendar;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
return new MissingYearPanel((DateAndTime)c);
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/position/Height.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.table.Cell; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.position.MissingHeightPanel; import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.measuredValue.Numeric...
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/position/Height.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.table.Cell; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.position.MissingHeightPanel; import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.measuredValue.Numeric...
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/Start.java
// Path: wizard/src/main/java/org/n52/sos/importer/controller/MainController.java // public class MainController { // // private static MainController instance = null; // // private final MainFrame mainFrame = new MainFrame(this); // // private final Model xmlModel; // // private MainController() { // // /...
import org.n52.sos.importer.controller.MainController; import org.n52.sos.importer.controller.Step1Controller;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/controller/MainController.java // public class MainController { // // private static MainController instance = null; // // private final MainFrame mainFrame = new MainFrame(this); // // private final Model xmlModel; // // private MainController() { // // /...
MainController.getInstance().setStepController(new Step1Controller());
52North/sos-importer
feeder/src/main/java/org/n52/sos/importer/feeder/Configuration.java
// Path: feeder/src/main/java/org/n52/sos/importer/feeder/csv/WrappedCSVReader.java // public class WrappedCSVReader implements CsvParser { // // private CSVReader csvReader; // // @Override // public String[] readNext() throws IOException { // return csvReader.readNext(); // } // // @Override // public void...
import java.io.File; import java.io.IOException; import java.net.MalformedURLException; import java.net.URL; import java.text.DecimalFormat; import java.text.DecimalFormatSymbols; import java.text.MessageFormat; import java.text.ParseException; import java.util.ArrayList; import java.util.Arrays; import java.util.HashM...
if (regEx != null && !regEx.isEmpty()) { patterns.add(Pattern.compile(regEx)); } } return patterns.toArray(new Pattern[patterns.size()]); } public boolean isInsertSweArrayObservationTimeoutBufferSet() { return importConf.getSosMetadata().isSetInsertSweArrayObservationTimeoutBuffer(); } public int ...
// Path: feeder/src/main/java/org/n52/sos/importer/feeder/csv/WrappedCSVReader.java // public class WrappedCSVReader implements CsvParser { // // private CSVReader csvReader; // // @Override // public String[] readNext() throws IOException { // return csvReader.readNext(); // } // // @Override // public void...
return isCsvParserDefined()?importConf.getCsvMetadata().getCsvParserClass():WrappedCSVReader.class.getName();
52North/sos-importer
wizard/src/test/java/org/n52/sos/importer/test/Step3TestMultipleDateTimeColumns.java
// Path: wizard/src/main/java/org/n52/sos/importer/controller/MainController.java // public class MainController { // // private static MainController instance = null; // // private final MainFrame mainFrame = new MainFrame(this); // // private final Model xmlModel; // // private MainController() { // // /...
import org.n52.sos.importer.controller.Step3Controller; import org.n52.sos.importer.controller.TableController; import org.n52.sos.importer.Constants; import org.n52.sos.importer.controller.MainController;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/controller/MainController.java // public class MainController { // // private static MainController instance = null; // // private final MainFrame mainFrame = new MainFrame(this); // // private final Model xmlModel; // // private MainController() { // // /...
final MainController f = MainController.getInstance();
52North/sos-importer
feeder/src/test/java/org/n52/sos/importer/feeder/model/TimeSeriesRepositoryTest.java
// Path: feeder/src/main/java/org/n52/sos/importer/feeder/model/requests/RegisterSensor.java // public class RegisterSensor { // // private final InsertObservation io; // // private final Map<ObservedProperty, String> measuredValueTypes; // // private final Collection<ObservedProperty> observedProperties; // //...
import static org.junit.Assert.assertThat; import org.hamcrest.Matchers; import org.junit.Test; import org.n52.sos.importer.feeder.model.requests.InsertObservation; import org.n52.sos.importer.feeder.model.requests.RegisterSensor; import static org.hamcrest.CoreMatchers.is; import static org.hamcrest.Matchers.hasSize;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: feeder/src/main/java/org/n52/sos/importer/feeder/model/requests/RegisterSensor.java // public class RegisterSensor { // // private final InsertObservation io; // // private final Map<ObservedProperty, String> measuredValueTypes; // // private final Collection<ObservedProperty> observedProperties; // //...
RegisterSensor registerSensor = tsr.getRegisterSensor(sensorURI);
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/Hour.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingHourPanel; import java.util.GregorianCalendar;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/dateAndTime/Hour.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
import org.n52.sos.importer.model.Combination; import org.n52.sos.importer.model.table.TableElement; import org.n52.sos.importer.view.MissingComponentPanel; import org.n52.sos.importer.view.dateAndTime.MissingHourPanel; import java.util.GregorianCalendar;
/** * Copyright (C) 2011-2015 52°North Initiative for Geospatial Open Source * Software GmbH * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 as published * by the Free Software Foundation. * * If the program is linked with...
// Path: wizard/src/main/java/org/n52/sos/importer/model/Combination.java // public abstract class Combination implements Formatable, Parseable { // // /** for parsing */ // private String pattern; // // /** for merging */ // private String group; // // public void setPattern(String pattern) { // this.patte...
public MissingComponentPanel getMissingComponentPanel(Combination c) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/model/xml/Helper.java
// Path: wizard/src/main/java/org/n52/sos/importer/model/table/Row.java // public class Row extends TableElement { // // private int number = -1; // // public Row(int number) { // this.number = number; // } // // public void setNumber(int number) { // this.number = number; // } // // public int getNumber...
import org.n52.sos.importer.model.table.TableElement; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.x52North.sensorweb.sos.importer.x04.ColumnAssignmentsDocument.ColumnAssignments; import org.x52North.sensorweb.sos.importer.x04.ColumnDocument.Column; import org.x52North.sensorweb.sos.importer.x04....
meta = col.addNewMetadata(); meta.setKey(key); addedOrUpdated = "Added"; } meta.setValue(value); if (logger.isDebugEnabled()) { logger.debug(addedOrUpdated + " column metadata. Key: " + key + "; Value: " + value + " in column " + col.getNumber()); } return (meta.getValue().equalsIgnoreCase(v...
// Path: wizard/src/main/java/org/n52/sos/importer/model/table/Row.java // public class Row extends TableElement { // // private int number = -1; // // public Row(int number) { // this.number = number; // } // // public void setNumber(int number) { // this.number = number; // } // // public int getNumber...
} else if (tabElem instanceof Row) {
52North/sos-importer
wizard/src/main/java/org/n52/sos/importer/view/position/MissingPositionPanel.java
// Path: wizard/src/main/java/org/n52/sos/importer/view/MissingComponentPanel.java // public abstract class MissingComponentPanel extends JPanel { // // private static final long serialVersionUID = 1L; // // /** // * Allocate values of the missing component // */ // public abstract void assignValues(); // //...
import javax.swing.JPanel; import org.n52.sos.importer.Constants; import org.n52.sos.importer.model.Step6cModel; import org.n52.sos.importer.model.position.Position; import org.n52.sos.importer.view.MissingComponentPanel; import java.awt.BorderLayout; import java.awt.GridLayout;
this.s6cM = s6cM; manualInputPanel = initManualInputPanel(s6cM); containerPanel = new JPanel(); containerPanel.setLayout(new BorderLayout(0,0)); containerPanel.add(manualInputPanel,BorderLayout.CENTER); add(containerPanel,BorderLayout.CENTER); if (Constants.GUI_DEBUG) { manualInputPanel....
// Path: wizard/src/main/java/org/n52/sos/importer/view/MissingComponentPanel.java // public abstract class MissingComponentPanel extends JPanel { // // private static final long serialVersionUID = 1L; // // /** // * Allocate values of the missing component // */ // public abstract void assignValues(); // //...
if (component instanceof MissingComponentPanel) {
SW-Team/java-TelegramBot
src/milk/telegram/method/getter/ChatGetter.java
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
import milk.telegram.bot.TelegramBot; import milk.telegram.type.chat.Chat;
package milk.telegram.method.getter; public class ChatGetter extends Getter{ public ChatGetter(TelegramBot bot){ super(bot); } public String getChatId(){ return this.optString("chat_id"); } public ChatGetter setChatId(Object chat_id){ this.put("chat_id", (chat_id instanc...
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
public Chat send(){
SW-Team/java-TelegramBot
src/milk/telegram/type/inline/InlineQuery.java
// Path: src/milk/telegram/type/Identifier.java // public interface Identifier<T>{ // // T getId(); // // } // // Path: src/milk/telegram/type/file/Location.java // public class Location{ // // private final double latitude; // private final double longitude; // // private Location(JSONObject objec...
import milk.telegram.type.Identifier; import milk.telegram.type.file.Location; import milk.telegram.type.user.User; import org.json.JSONObject;
package milk.telegram.type.inline; public class InlineQuery implements Identifier<String>{ private final String id;
// Path: src/milk/telegram/type/Identifier.java // public interface Identifier<T>{ // // T getId(); // // } // // Path: src/milk/telegram/type/file/Location.java // public class Location{ // // private final double latitude; // private final double longitude; // // private Location(JSONObject objec...
private final User from;
SW-Team/java-TelegramBot
src/milk/telegram/type/inline/InlineQuery.java
// Path: src/milk/telegram/type/Identifier.java // public interface Identifier<T>{ // // T getId(); // // } // // Path: src/milk/telegram/type/file/Location.java // public class Location{ // // private final double latitude; // private final double longitude; // // private Location(JSONObject objec...
import milk.telegram.type.Identifier; import milk.telegram.type.file.Location; import milk.telegram.type.user.User; import org.json.JSONObject;
package milk.telegram.type.inline; public class InlineQuery implements Identifier<String>{ private final String id; private final User from;
// Path: src/milk/telegram/type/Identifier.java // public interface Identifier<T>{ // // T getId(); // // } // // Path: src/milk/telegram/type/file/Location.java // public class Location{ // // private final double latitude; // private final double longitude; // // private Location(JSONObject objec...
private final Location location;
SW-Team/java-TelegramBot
src/milk/telegram/type/inline/ChosenInlineResult.java
// Path: src/milk/telegram/type/Identifier.java // public interface Identifier<T>{ // // T getId(); // // } // // Path: src/milk/telegram/type/file/Location.java // public class Location{ // // private final double latitude; // private final double longitude; // // private Location(JSONObject objec...
import milk.telegram.type.Identifier; import milk.telegram.type.file.Location; import milk.telegram.type.user.User; import org.json.JSONObject;
package milk.telegram.type.inline; public class ChosenInlineResult implements Identifier<String>{ private final String id;
// Path: src/milk/telegram/type/Identifier.java // public interface Identifier<T>{ // // T getId(); // // } // // Path: src/milk/telegram/type/file/Location.java // public class Location{ // // private final double latitude; // private final double longitude; // // private Location(JSONObject objec...
private final User from;
SW-Team/java-TelegramBot
src/milk/telegram/type/inline/ChosenInlineResult.java
// Path: src/milk/telegram/type/Identifier.java // public interface Identifier<T>{ // // T getId(); // // } // // Path: src/milk/telegram/type/file/Location.java // public class Location{ // // private final double latitude; // private final double longitude; // // private Location(JSONObject objec...
import milk.telegram.type.Identifier; import milk.telegram.type.file.Location; import milk.telegram.type.user.User; import org.json.JSONObject;
package milk.telegram.type.inline; public class ChosenInlineResult implements Identifier<String>{ private final String id; private final User from;
// Path: src/milk/telegram/type/Identifier.java // public interface Identifier<T>{ // // T getId(); // // } // // Path: src/milk/telegram/type/file/Location.java // public class Location{ // // private final double latitude; // private final double longitude; // // private Location(JSONObject objec...
private final Location location;
SW-Team/java-TelegramBot
src/milk/telegram/method/other/LeaveChat.java
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
import milk.telegram.bot.TelegramBot; import milk.telegram.method.SendInstance; import milk.telegram.type.Identifier; import milk.telegram.type.Usernamed; import milk.telegram.type.chat.Channel; import org.json.JSONObject;
package milk.telegram.method.other; public class LeaveChat extends SendInstance{ public LeaveChat(TelegramBot bot){ super(bot); } public LeaveChat setChatId(Object chat_id){
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
if(chat_id instanceof Identifier){
SW-Team/java-TelegramBot
src/milk/telegram/method/other/LeaveChat.java
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
import milk.telegram.bot.TelegramBot; import milk.telegram.method.SendInstance; import milk.telegram.type.Identifier; import milk.telegram.type.Usernamed; import milk.telegram.type.chat.Channel; import org.json.JSONObject;
package milk.telegram.method.other; public class LeaveChat extends SendInstance{ public LeaveChat(TelegramBot bot){ super(bot); } public LeaveChat setChatId(Object chat_id){ if(chat_id instanceof Identifier){
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
chat_id = chat_id instanceof Channel ? "@" + ((Usernamed) chat_id).getUsername() : ((Identifier) chat_id).getId();
SW-Team/java-TelegramBot
src/milk/telegram/method/other/LeaveChat.java
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
import milk.telegram.bot.TelegramBot; import milk.telegram.method.SendInstance; import milk.telegram.type.Identifier; import milk.telegram.type.Usernamed; import milk.telegram.type.chat.Channel; import org.json.JSONObject;
package milk.telegram.method.other; public class LeaveChat extends SendInstance{ public LeaveChat(TelegramBot bot){ super(bot); } public LeaveChat setChatId(Object chat_id){ if(chat_id instanceof Identifier){
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
chat_id = chat_id instanceof Channel ? "@" + ((Usernamed) chat_id).getUsername() : ((Identifier) chat_id).getId();
SW-Team/java-TelegramBot
src/milk/telegram/type/message/PhotoMessage.java
// Path: src/milk/telegram/type/Textable.java // public interface Textable{ // // String getText(); // } // // Path: src/milk/telegram/type/file/photo/PhotoSize.java // public class PhotoSize implements Identifier<String>{ // // private final String id; // // private final int width; // private fina...
import milk.telegram.type.Textable; import milk.telegram.type.file.photo.PhotoSize; import org.json.JSONObject; import java.util.ArrayList;
package milk.telegram.type.message; public class PhotoMessage extends Message implements Textable{ private final String caption;
// Path: src/milk/telegram/type/Textable.java // public interface Textable{ // // String getText(); // } // // Path: src/milk/telegram/type/file/photo/PhotoSize.java // public class PhotoSize implements Identifier<String>{ // // private final String id; // // private final int width; // private fina...
private final ArrayList<PhotoSize> photo = new ArrayList<>();
SW-Team/java-TelegramBot
src/milk/telegram/type/file/media/Video.java
// Path: src/milk/telegram/type/file/photo/PhotoSize.java // public class PhotoSize implements Identifier<String>{ // // private final String id; // // private final int width; // private final int height; // // private final Integer size; // // private PhotoSize(JSONObject object){ // t...
import milk.telegram.type.file.photo.PhotoSize; import milk.telegram.type.Identifier; import org.json.JSONObject;
package milk.telegram.type.file.media; public class Video implements Identifier<String>{ private final String id; private final String mime_type; private final int width; private final int height; private final int duration;
// Path: src/milk/telegram/type/file/photo/PhotoSize.java // public class PhotoSize implements Identifier<String>{ // // private final String id; // // private final int width; // private final int height; // // private final Integer size; // // private PhotoSize(JSONObject object){ // t...
private final PhotoSize thumb;
SW-Team/java-TelegramBot
src/milk/telegram/method/getter/FileGetter.java
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
import milk.telegram.bot.TelegramBot; import milk.telegram.type.file.File; import org.json.JSONObject;
package milk.telegram.method.getter; public class FileGetter extends Getter{ protected String file_id;
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
public FileGetter(TelegramBot bot){
SW-Team/java-TelegramBot
src/milk/telegram/method/getter/FileGetter.java
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
import milk.telegram.bot.TelegramBot; import milk.telegram.type.file.File; import org.json.JSONObject;
package milk.telegram.method.getter; public class FileGetter extends Getter{ protected String file_id; public FileGetter(TelegramBot bot){ super(bot); } public String getFileId(){ return file_id; } public FileGetter setFileId(String file_id){ this.file_id = file_id;...
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
public File send(){
SW-Team/java-TelegramBot
src/milk/telegram/type/game/GameHighScore.java
// Path: src/milk/telegram/type/user/User.java // public class User implements Identifier<Integer>, Usernamed{ // // private int id; // // private String last; // private String first; // private String username; // // private User(JSONObject object){ // this.id = object.getInt("id"); // ...
import milk.telegram.type.user.User; import org.json.JSONObject;
package milk.telegram.type.game; public class GameHighScore{ private final long score; private final long position;
// Path: src/milk/telegram/type/user/User.java // public class User implements Identifier<Integer>, Usernamed{ // // private int id; // // private String last; // private String first; // private String username; // // private User(JSONObject object){ // this.id = object.getInt("id"); // ...
private final User user;
SW-Team/java-TelegramBot
src/milk/telegram/type/message/Message.java
// Path: src/milk/telegram/type/chat/Chat.java // public abstract class Chat implements Identifier<Long>{ // // private long id; // // private String type; // // protected Chat(JSONObject object){ // this.id = object.getLong("id"); // this.type = object.getString("type"); // } // // ...
import milk.telegram.type.chat.Chat; import milk.telegram.type.Identifier; import milk.telegram.type.user.User; import org.json.JSONObject;
package milk.telegram.type.message; public class Message implements Identifier<Integer>{ private final int date; private final int message_id;
// Path: src/milk/telegram/type/chat/Chat.java // public abstract class Chat implements Identifier<Long>{ // // private long id; // // private String type; // // protected Chat(JSONObject object){ // this.id = object.getLong("id"); // this.type = object.getString("type"); // } // // ...
private final User from;
SW-Team/java-TelegramBot
src/milk/telegram/type/message/Message.java
// Path: src/milk/telegram/type/chat/Chat.java // public abstract class Chat implements Identifier<Long>{ // // private long id; // // private String type; // // protected Chat(JSONObject object){ // this.id = object.getLong("id"); // this.type = object.getString("type"); // } // // ...
import milk.telegram.type.chat.Chat; import milk.telegram.type.Identifier; import milk.telegram.type.user.User; import org.json.JSONObject;
package milk.telegram.type.message; public class Message implements Identifier<Integer>{ private final int date; private final int message_id; private final User from;
// Path: src/milk/telegram/type/chat/Chat.java // public abstract class Chat implements Identifier<Long>{ // // private long id; // // private String type; // // protected Chat(JSONObject object){ // this.id = object.getLong("id"); // this.type = object.getString("type"); // } // // ...
private final Chat chat;
SW-Team/java-TelegramBot
src/milk/telegram/bot/TelegramBot.java
// Path: src/milk/telegram/handler/Handler.java // public interface Handler{ // // void update(List<Update> list); // // } // // Path: src/milk/telegram/update/Update.java // public class Update implements Identifier<Integer>{ // // private final int id; // // private final Message message; // priv...
import milk.telegram.handler.Handler; import milk.telegram.update.Update; import milk.telegram.type.user.User; import org.json.JSONArray; import org.json.JSONObject; import org.json.JSONTokener; import java.io.IOException; import java.io.InputStreamReader; import java.io.OutputStream; import java.net.URL; import java.n...
package milk.telegram.bot; public class TelegramBot extends Thread{ public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; private String token = ""; private int lastId = 0; private int limit = 100; private int timeout = 1500;
// Path: src/milk/telegram/handler/Handler.java // public interface Handler{ // // void update(List<Update> list); // // } // // Path: src/milk/telegram/update/Update.java // public class Update implements Identifier<Integer>{ // // private final int id; // // private final Message message; // priv...
private User me;
SW-Team/java-TelegramBot
src/milk/telegram/bot/TelegramBot.java
// Path: src/milk/telegram/handler/Handler.java // public interface Handler{ // // void update(List<Update> list); // // } // // Path: src/milk/telegram/update/Update.java // public class Update implements Identifier<Integer>{ // // private final int id; // // private final Message message; // priv...
import milk.telegram.handler.Handler; import milk.telegram.update.Update; import milk.telegram.type.user.User; import org.json.JSONArray; import org.json.JSONObject; import org.json.JSONTokener; import java.io.IOException; import java.io.InputStreamReader; import java.io.OutputStream; import java.net.URL; import java.n...
package milk.telegram.bot; public class TelegramBot extends Thread{ public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; private String token = ""; private int lastId = 0; private int limit = 100; private int timeout = 1500; private User me;
// Path: src/milk/telegram/handler/Handler.java // public interface Handler{ // // void update(List<Update> list); // // } // // Path: src/milk/telegram/update/Update.java // public class Update implements Identifier<Integer>{ // // private final int id; // // private final Message message; // priv...
private Handler handler;
SW-Team/java-TelegramBot
src/milk/telegram/bot/TelegramBot.java
// Path: src/milk/telegram/handler/Handler.java // public interface Handler{ // // void update(List<Update> list); // // } // // Path: src/milk/telegram/update/Update.java // public class Update implements Identifier<Integer>{ // // private final int id; // // private final Message message; // priv...
import milk.telegram.handler.Handler; import milk.telegram.update.Update; import milk.telegram.type.user.User; import org.json.JSONArray; import org.json.JSONObject; import org.json.JSONTokener; import java.io.IOException; import java.io.InputStreamReader; import java.io.OutputStream; import java.net.URL; import java.n...
stream.write(object.toString().getBytes(StandardCharsets.UTF_8)); } return new JSONObject(new JSONTokener(new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))); }catch(IOException ex){ }catch(Exception e){ e.printStackTrace(); ...
// Path: src/milk/telegram/handler/Handler.java // public interface Handler{ // // void update(List<Update> list); // // } // // Path: src/milk/telegram/update/Update.java // public class Update implements Identifier<Integer>{ // // private final int id; // // private final Message message; // priv...
List<Update> list = new ArrayList<>();
SW-Team/java-TelegramBot
src/milk/telegram/method/getter/ChatAdministratorsGetter.java
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
import milk.telegram.bot.TelegramBot; import milk.telegram.type.Identifier; import milk.telegram.type.Usernamed; import milk.telegram.type.chat.Channel; import milk.telegram.type.user.ChatMember; import org.json.JSONArray; import org.json.JSONObject; import java.util.ArrayList;
package milk.telegram.method.getter; public class ChatAdministratorsGetter extends Getter{ public ChatAdministratorsGetter(TelegramBot bot){ super(bot); } public String getChatId(){ return this.optString("chat_id"); } public ChatAdministratorsGetter setChatId(Object chat_id){
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
if(chat_id instanceof Identifier){
SW-Team/java-TelegramBot
src/milk/telegram/method/getter/ChatAdministratorsGetter.java
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
import milk.telegram.bot.TelegramBot; import milk.telegram.type.Identifier; import milk.telegram.type.Usernamed; import milk.telegram.type.chat.Channel; import milk.telegram.type.user.ChatMember; import org.json.JSONArray; import org.json.JSONObject; import java.util.ArrayList;
package milk.telegram.method.getter; public class ChatAdministratorsGetter extends Getter{ public ChatAdministratorsGetter(TelegramBot bot){ super(bot); } public String getChatId(){ return this.optString("chat_id"); } public ChatAdministratorsGetter setChatId(Object chat_id){ ...
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
chat_id = chat_id instanceof Channel ? "@" + ((Usernamed) chat_id).getUsername() : ((Identifier) chat_id).getId();
SW-Team/java-TelegramBot
src/milk/telegram/method/getter/ChatAdministratorsGetter.java
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
import milk.telegram.bot.TelegramBot; import milk.telegram.type.Identifier; import milk.telegram.type.Usernamed; import milk.telegram.type.chat.Channel; import milk.telegram.type.user.ChatMember; import org.json.JSONArray; import org.json.JSONObject; import java.util.ArrayList;
package milk.telegram.method.getter; public class ChatAdministratorsGetter extends Getter{ public ChatAdministratorsGetter(TelegramBot bot){ super(bot); } public String getChatId(){ return this.optString("chat_id"); } public ChatAdministratorsGetter setChatId(Object chat_id){ ...
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
chat_id = chat_id instanceof Channel ? "@" + ((Usernamed) chat_id).getUsername() : ((Identifier) chat_id).getId();
SW-Team/java-TelegramBot
src/milk/telegram/method/getter/ChatMembersCountGetter.java
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
import milk.telegram.bot.TelegramBot; import milk.telegram.type.Identifier; import milk.telegram.type.Usernamed; import milk.telegram.type.chat.Channel; import org.json.JSONObject;
package milk.telegram.method.getter; public class ChatMembersCountGetter extends Getter{ protected String chat_id;
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
public ChatMembersCountGetter(TelegramBot bot){
SW-Team/java-TelegramBot
src/milk/telegram/method/getter/ChatMembersCountGetter.java
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
import milk.telegram.bot.TelegramBot; import milk.telegram.type.Identifier; import milk.telegram.type.Usernamed; import milk.telegram.type.chat.Channel; import org.json.JSONObject;
package milk.telegram.method.getter; public class ChatMembersCountGetter extends Getter{ protected String chat_id; public ChatMembersCountGetter(TelegramBot bot){ super(bot); } public String getChatId(){ return chat_id; } public ChatMembersCountGetter setChatId(Object chat_...
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
if(chat_id instanceof Identifier){
SW-Team/java-TelegramBot
src/milk/telegram/method/getter/ChatMembersCountGetter.java
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
import milk.telegram.bot.TelegramBot; import milk.telegram.type.Identifier; import milk.telegram.type.Usernamed; import milk.telegram.type.chat.Channel; import org.json.JSONObject;
package milk.telegram.method.getter; public class ChatMembersCountGetter extends Getter{ protected String chat_id; public ChatMembersCountGetter(TelegramBot bot){ super(bot); } public String getChatId(){ return chat_id; } public ChatMembersCountGetter setChatId(Object chat_...
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
chat_id = chat_id instanceof Channel ? "@" + ((Usernamed) chat_id).getUsername() : ((Identifier) chat_id).getId();
SW-Team/java-TelegramBot
src/milk/telegram/method/getter/ChatMembersCountGetter.java
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
import milk.telegram.bot.TelegramBot; import milk.telegram.type.Identifier; import milk.telegram.type.Usernamed; import milk.telegram.type.chat.Channel; import org.json.JSONObject;
package milk.telegram.method.getter; public class ChatMembersCountGetter extends Getter{ protected String chat_id; public ChatMembersCountGetter(TelegramBot bot){ super(bot); } public String getChatId(){ return chat_id; } public ChatMembersCountGetter setChatId(Object chat_...
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
chat_id = chat_id instanceof Channel ? "@" + ((Usernamed) chat_id).getUsername() : ((Identifier) chat_id).getId();
SW-Team/java-TelegramBot
src/milk/telegram/method/replier/CallbackReplier.java
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
import milk.telegram.bot.TelegramBot; import milk.telegram.type.callback.CallbackQuery; import org.json.JSONObject;
package milk.telegram.method.replier; public class CallbackReplier extends Replier{ public CallbackReplier(TelegramBot bot){ super(bot); } public String getUrl(){ return optString("url"); } public String getText(){ return optString("text"); } public boolean isSh...
// Path: src/milk/telegram/bot/TelegramBot.java // public class TelegramBot extends Thread{ // // public static final String BASE_URL = "https://api.telegram.org/bot%s/%s"; // // private String token = ""; // // private int lastId = 0; // private int limit = 100; // private int timeout = 1500; //...
if(query_id instanceof CallbackQuery){
SW-Team/java-TelegramBot
src/milk/telegram/type/game/Game.java
// Path: src/milk/telegram/type/Titled.java // public interface Titled{ // // String getTitle(); // // } // // Path: src/milk/telegram/type/file/photo/PhotoSize.java // public class PhotoSize implements Identifier<String>{ // // private final String id; // // private final int width; // private fin...
import milk.telegram.type.Titled; import milk.telegram.type.file.photo.PhotoSize; import milk.telegram.type.message.MessageEntity; import milk.telegram.type.Textable; import org.json.JSONArray; import org.json.JSONObject; import java.util.ArrayList;
package milk.telegram.type.game; public class Game implements Titled, Textable{ private String text; private String title; private String description; private Animation animation;
// Path: src/milk/telegram/type/Titled.java // public interface Titled{ // // String getTitle(); // // } // // Path: src/milk/telegram/type/file/photo/PhotoSize.java // public class PhotoSize implements Identifier<String>{ // // private final String id; // // private final int width; // private fin...
private ArrayList<PhotoSize> photo = new ArrayList<>();
SW-Team/java-TelegramBot
src/milk/telegram/type/game/Game.java
// Path: src/milk/telegram/type/Titled.java // public interface Titled{ // // String getTitle(); // // } // // Path: src/milk/telegram/type/file/photo/PhotoSize.java // public class PhotoSize implements Identifier<String>{ // // private final String id; // // private final int width; // private fin...
import milk.telegram.type.Titled; import milk.telegram.type.file.photo.PhotoSize; import milk.telegram.type.message.MessageEntity; import milk.telegram.type.Textable; import org.json.JSONArray; import org.json.JSONObject; import java.util.ArrayList;
package milk.telegram.type.game; public class Game implements Titled, Textable{ private String text; private String title; private String description; private Animation animation; private ArrayList<PhotoSize> photo = new ArrayList<>();
// Path: src/milk/telegram/type/Titled.java // public interface Titled{ // // String getTitle(); // // } // // Path: src/milk/telegram/type/file/photo/PhotoSize.java // public class PhotoSize implements Identifier<String>{ // // private final String id; // // private final int width; // private fin...
private ArrayList<MessageEntity> text_entities = new ArrayList<>();
SW-Team/java-TelegramBot
src/milk/telegram/type/message/DocumentMessage.java
// Path: src/milk/telegram/type/Textable.java // public interface Textable{ // // String getText(); // } // // Path: src/milk/telegram/type/file/Document.java // public class Document implements Identifier<String>{ // // private final String file_id; // private final String file_name; // // private ...
import milk.telegram.type.Textable; import milk.telegram.type.file.Document; import org.json.JSONObject;
package milk.telegram.type.message; public class DocumentMessage extends Message implements Textable{ private String caption;
// Path: src/milk/telegram/type/Textable.java // public interface Textable{ // // String getText(); // } // // Path: src/milk/telegram/type/file/Document.java // public class Document implements Identifier<String>{ // // private final String file_id; // private final String file_name; // // private ...
private Document document;
SW-Team/java-TelegramBot
src/milk/telegram/type/message/MessageEntity.java
// Path: src/milk/telegram/type/user/User.java // public class User implements Identifier<Integer>, Usernamed{ // // private int id; // // private String last; // private String first; // private String username; // // private User(JSONObject object){ // this.id = object.getInt("id"); // ...
import milk.telegram.type.user.User; import org.json.JSONObject;
package milk.telegram.type.message; public class MessageEntity{ private final String type; private final String url; private final int offset; private final int length;
// Path: src/milk/telegram/type/user/User.java // public class User implements Identifier<Integer>, Usernamed{ // // private int id; // // private String last; // private String first; // private String username; // // private User(JSONObject object){ // this.id = object.getInt("id"); // ...
private final User user;
SW-Team/java-TelegramBot
src/milk/telegram/type/callback/CallbackQuery.java
// Path: src/milk/telegram/type/Identifier.java // public interface Identifier<T>{ // // T getId(); // // } // // Path: src/milk/telegram/type/message/Message.java // public class Message implements Identifier<Integer>{ // // private final int date; // private final int message_id; // // private fi...
import milk.telegram.type.Identifier; import milk.telegram.type.message.Message; import milk.telegram.type.user.User; import org.json.JSONObject;
package milk.telegram.type.callback; public class CallbackQuery implements Identifier<String>{ private final String id;
// Path: src/milk/telegram/type/Identifier.java // public interface Identifier<T>{ // // T getId(); // // } // // Path: src/milk/telegram/type/message/Message.java // public class Message implements Identifier<Integer>{ // // private final int date; // private final int message_id; // // private fi...
private final User from;