This repository has been archived by the owner on Mar 27, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 9
Regions (DO NOT MERGE) #542
Open
gerring
wants to merge
43
commits into
master
Choose a base branch
from
regions
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
43 commits
Select commit
Hold shift + click to select a range
18d9667
Put back in regions to the CompoundSpgIterator.
gerring c7d6ef7
Merge branch 'master' of [email protected]:DiamondLightSource/daq-eclips…
gerring e281a4e
Put back in regions to the CompoundSpgIterator.
gerring 4c60fba
Merge branch 'regions' of [email protected]:DiamondLightSource/daq-eclip…
gerring 7039fca
Changed generators to match 'generation_rewrite' branch of spg repo
gerring cbf8177
Merge branch 'master' into regions
gerring d4f5c5f
Added iterator to generator.
gerring df1e2ef
Fixes to run Unit Tests.
gerring c7e311c
Merge branch 'master' into regions
gerring 125dd3e
Put back strange sleep which makes test work on traivs.
gerring ddc61f5
Added an NPE check for travis.
gerring 7f98841
Merge branch 'regions' of [email protected]:DiamondLightSource/daq-eclip…
gerring d577565
Added changes to support numjy in tests.
gerring 3c390aa
Fixed malcolm device now that regions are sent.
gerring 69aa97f
Removed comment
gerring 1468bd7
Used existing generator because more efficient.
gerring 011c71b
Moved method locations to make easier to read.
gerring 91505fd
Commented out line which fails MScanServletTest
gerring 4d00626
Merge branch 'master' into regions
gerring 04c3add
Fix project xml
gerring 111fa64
Merge branch 'regions' of [email protected]:DiamondLightSource/daq-eclip…
gerring 0bfbe33
Put back in Jama
gerring 6005c93
Merge branch 'master' into regions
gerring e5cc2f7
Merge branch 'master' into regions
gerring c6908a4
Merge branch 'master' into regions
gerring 73fa03e
Merge branch 'master' into regions
gerring aa1c186
Merge branch 'master' into regions
gerring 595196a
Merge branch 'master' into regions
gerring b5daafb
Merge branch 'master' into regions
gerring 0dae613
Merge branch 'master' into regions
gerring b01e982
Merge branch 'master' into regions
gerring 0b09a99
Merge branch 'master' into regions
gerring 24277a4
Merge branch 'master' into regions
gerring 82c3b86
Merge branch 'master' into regions
gerring 1addc61
Merge branch 'master' into regions
gerring 672ee6f
Merge branch 'master' into regions
gerring 598beab
Merge branch 'master' into regions
gerring 753e94c
Merge branch 'master' into regions
gerring 683c39a
Merge branch 'master' into regions
gerring b42f954
Merge branch 'master' into regions
gerring b5a3d4f
Merge branch 'master' into regions
gerring ea8bda5
Merge branch 'master' into regions
gerring a9e1853
Merge branch 'master' into regions
gerring File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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 |
---|---|---|
@@ -1,45 +1,51 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<projectDescription> | ||
<name>org.eclipse.scanning.api</name> | ||
<comment></comment> | ||
<projects> | ||
</projects> | ||
<buildSpec> | ||
<buildCommand> | ||
<name>org.eclipse.jdt.core.javabuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.pde.ManifestBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.pde.SchemaBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.pde.ds.core.builder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.zeroturnaround.eclipse.rebelXmlBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.zeroturnaround.eclipse.remoting.remotingBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
</buildSpec> | ||
<natures> | ||
<nature>org.eclipse.pde.PluginNature</nature> | ||
<nature>org.eclipse.jdt.core.javanature</nature> | ||
<nature>org.zeroturnaround.eclipse.jrebelNature</nature> | ||
<nature>org.zeroturnaround.eclipse.remoting.remotingNature</nature> | ||
</natures> | ||
</projectDescription> | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<projectDescription> | ||
<name>org.eclipse.scanning.api</name> | ||
<comment></comment> | ||
<projects> | ||
</projects> | ||
<buildSpec> | ||
<buildCommand> | ||
<name>org.python.pydev.PyDevBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.jdt.core.javabuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.pde.ManifestBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.pde.SchemaBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.pde.ds.core.builder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.zeroturnaround.eclipse.rebelXmlBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.zeroturnaround.eclipse.remoting.remotingBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
</buildSpec> | ||
<natures> | ||
<nature>org.eclipse.pde.PluginNature</nature> | ||
<nature>org.eclipse.jdt.core.javanature</nature> | ||
<nature>org.python.pydev.pythonNature</nature> | ||
<nature>org.zeroturnaround.eclipse.jrebelNature</nature> | ||
<nature>org.zeroturnaround.eclipse.remoting.remotingNature</nature> | ||
</natures> | ||
</projectDescription> |
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,8 @@ | ||
<?xml version="1.0" encoding="UTF-8" standalone="no"?> | ||
<?eclipse-pydev version="1.0"?><pydev_project> | ||
<pydev_property name="org.python.pydev.PYTHON_PROJECT_INTERPRETER">Default</pydev_property> | ||
<pydev_property name="org.python.pydev.PYTHON_PROJECT_VERSION">jython 2.7</pydev_property> | ||
<pydev_pathproperty name="org.python.pydev.PROJECT_SOURCE_PATH"> | ||
<path>/${PROJECT_DIR_NAME}/bin</path> | ||
</pydev_pathproperty> | ||
</pydev_project> |
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 |
---|---|---|
|
@@ -16,6 +16,8 @@ | |
import java.util.LinkedHashMap; | ||
import java.util.List; | ||
import java.util.Map; | ||
import java.util.regex.Matcher; | ||
import java.util.regex.Pattern; | ||
|
||
import org.eclipse.scanning.api.annotation.UiHidden; | ||
|
||
|
@@ -133,4 +135,23 @@ public Map<String, Integer> getIndices() { | |
} | ||
return indices; | ||
} | ||
|
||
private static final String VERTEX = "([a-zA-Z0-9_])+\\((\\d+)\\)=([-+]?[0-9]*\\.?[0-9]+)"; | ||
private static final Pattern POSITION = Pattern.compile(VERTEX+", "+VERTEX); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
/** | ||
* Parse a point from the toString() method into an instance of Point | ||
* | ||
* y(0)=2.397560627408689, x(4)=5.266805527444651 | ||
* @param asString | ||
* @return | ||
*/ | ||
public static Point parse(String asString) { | ||
|
||
Matcher m = POSITION.matcher(asString); | ||
if (m.matches()) { | ||
return new Point(m.group(4), Integer.parseInt(m.group(5)), Double.parseDouble(m.group(6)), | ||
m.group(1), Integer.parseInt(m.group(2)), Double.parseDouble(m.group(3))); | ||
} | ||
throw new RuntimeException("Unparsable string "+asString); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
} | ||
} |
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 |
---|---|---|
@@ -1,5 +1,8 @@ | ||
<?xml version="1.0" encoding="UTF-8" standalone="no"?> | ||
<?eclipse-pydev version="1.0"?><pydev_project> | ||
<pydev_property name="org.python.pydev.PYTHON_PROJECT_INTERPRETER">Default</pydev_property> | ||
<pydev_property name="org.python.pydev.PYTHON_PROJECT_VERSION">python 2.7</pydev_property> | ||
</pydev_project> | ||
<?xml version="1.0" encoding="UTF-8" standalone="no"?> | ||
<?eclipse-pydev version="1.0"?><pydev_project> | ||
<pydev_property name="org.python.pydev.PYTHON_PROJECT_INTERPRETER">Default</pydev_property> | ||
<pydev_property name="org.python.pydev.PYTHON_PROJECT_VERSION">jython 2.7</pydev_property> | ||
<pydev_pathproperty name="org.python.pydev.PROJECT_SOURCE_PATH"> | ||
<path>/${PROJECT_DIR_NAME}/bin</path> | ||
</pydev_pathproperty> | ||
</pydev_project> |
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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Move this variable to comply with Java Code Conventions.