-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #22 from usdAG/develop
Merge develop into master
- Loading branch information
Showing
30 changed files
with
1,020 additions
and
206 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
version: 2 | ||
updates: | ||
- package-ecosystem: "java:maven" | ||
directory: "/" | ||
target_branch: "develop" | ||
schedule: | ||
interval: "daily" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
name: develop maven CI | ||
|
||
on: | ||
push: | ||
branches: | ||
- develop | ||
pull_request: | ||
branches: | ||
- develop | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Set up JDK 1.8 | ||
uses: actions/setup-java@v1 | ||
with: | ||
java-version: 1.8 | ||
- name: Cache local Maven repository | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.m2/repository | ||
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }} | ||
restore-keys: | | ||
${{ runner.os }}-maven- | ||
- name: Build with Maven | ||
run: mvn -B package --file pom.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
name: master maven CI | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
branches: | ||
- master | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Set up JDK 1.8 | ||
uses: actions/setup-java@v1 | ||
with: | ||
java-version: 1.8 | ||
- name: Cache local Maven repository | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.m2/repository | ||
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }} | ||
restore-keys: | | ||
${{ runner.os }}-maven- | ||
- name: Build with Maven | ||
run: mvn -B package --file pom.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
52 changes: 52 additions & 0 deletions
52
src/de/usd/cstchef/operations/conditional/ConditionalOperation.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
package de.usd.cstchef.operations.conditional; | ||
|
||
import javax.swing.JTextField; | ||
|
||
import de.usd.cstchef.operations.Operation; | ||
import de.usd.cstchef.view.ui.VariableTextField; | ||
|
||
public abstract class ConditionalOperation extends Operation { | ||
|
||
protected VariableTextField expr; | ||
private JTextField operationSkipField; | ||
private JTextField laneSkipField; | ||
|
||
public void setOperationSkip() { | ||
|
||
try { | ||
int operationSkip = Integer.valueOf(operationSkipField.getText()); | ||
this.setOperationSkip(operationSkip); | ||
} catch( Exception e ) { | ||
throw new IllegalArgumentException("Input is not a number."); | ||
} | ||
} | ||
|
||
public void setLaneSkip() { | ||
|
||
try { | ||
int laneSkip = Integer.valueOf(laneSkipField.getText()); | ||
this.setLaneSkip(laneSkip); | ||
} catch( Exception e ) { | ||
throw new IllegalArgumentException("Input is not a number."); | ||
} | ||
} | ||
|
||
public void resetSkips() { | ||
this.setOperationSkip(0); | ||
this.setLaneSkip(0); | ||
} | ||
|
||
@Override | ||
public void createUI() { | ||
this.expr = new VariableTextField(); | ||
this.addUIElement("Expr", this.expr); | ||
|
||
this.operationSkipField = new JTextField("0"); | ||
this.addUIElement("Skip Operations", this.operationSkipField); | ||
|
||
this.laneSkipField = new JTextField("0"); | ||
this.addUIElement("Skip Lanes", this.laneSkipField); | ||
|
||
} | ||
|
||
} |
Oops, something went wrong.