Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
2XB3FinalProject
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Analyze
Contributor analytics
Repository analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Christopher Schankula
2XB3FinalProject
Commits
726c57de
Commit
726c57de
authored
6 years ago
by
Christopher Schankula
Browse files
Options
Downloads
Patches
Plain Diff
rename some variables in BasicSearch
parent
12ac6314
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/search/BasicSearch.java
+9
-9
9 additions, 9 deletions
src/search/BasicSearch.java
with
9 additions
and
9 deletions
src/search/BasicSearch.java
+
9
−
9
View file @
726c57de
...
...
@@ -30,36 +30,36 @@ public class BasicSearch {
* @return
*/
public
static
BasicSearchResult
range
(
Integer
taxonId
,
Integer
yearLo
,
Integer
yearHi
,
Double
latLo
,
Double
latHi
,
Double
longLo
,
Double
longHi
){
GeneralRange
<
Record
>
a0
=
RangeHelper
.
date
(
Bound
.
ANY
);
GeneralRange
<
Record
>
dateRange
=
RangeHelper
.
date
(
Bound
.
ANY
);
if
((
yearLo
!=
null
)
&&
(
yearHi
!=
null
))
{
Date
lower
=
new
Date
(
yearLo
,
01
,
01
);
Date
upper
=
new
Date
(
yearHi
+
1
,
01
,
01
);
a0
=
RangeHelper
.
date
(
Bound
.
LOWHIGH
,
lower
,
upper
);
dateRange
=
RangeHelper
.
date
(
Bound
.
LOWHIGH
,
lower
,
upper
);
}
GeneralRange
<
Record
>
a2
=
RangeHelper
.
latitude
(
Bound
.
ANY
);
GeneralRange
<
Record
>
a3
=
RangeHelper
.
longitude
(
Bound
.
ANY
);
GeneralRange
<
Record
>
latRange
=
RangeHelper
.
latitude
(
Bound
.
ANY
);
GeneralRange
<
Record
>
longRange
=
RangeHelper
.
longitude
(
Bound
.
ANY
);
if
((
latLo
!=
null
)
&&
(
latHi
!=
null
))
{
a2
=
RangeHelper
.
latitude
(
Bound
.
LOWHIGH
,
latLo
,
latHi
);
latRange
=
RangeHelper
.
latitude
(
Bound
.
LOWHIGH
,
latLo
,
latHi
);
}
if
((
longLo
!=
null
)
&&
(
longHi
!=
null
))
{
a3
=
RangeHelper
.
longitude
(
Bound
.
LOWHIGH
,
longLo
,
longHi
);
longRange
=
RangeHelper
.
longitude
(
Bound
.
LOWHIGH
,
longLo
,
longHi
);
}
GeneralRange
<
Record
>
a1
;
GeneralRange
<
Record
>
taxonRange
;
Iterable
<
Integer
>
searches
=
BioTree
.
getNonEmptyChildren
(
taxonId
);
Stopwatch
sw
=
new
Stopwatch
();
ArrayList
<
Record
>
results
=
new
ArrayList
<
Record
>();
for
(
Integer
txId:
searches
)
{
a1
=
RangeHelper
.
taxonID
(
Bound
.
EQUALS
,
txId
);
taxonRange
=
RangeHelper
.
taxonID
(
Bound
.
EQUALS
,
txId
);
ArrayList
<
GeneralRange
<
Record
>>
axes
=
new
ArrayList
<
GeneralRange
<
Record
>>();
axes
.
add
(
a0
);
axes
.
add
(
a1
);
axes
.
add
(
a2
);
axes
.
add
(
a3
);
axes
.
add
(
dateRange
);
axes
.
add
(
taxonRange
);
axes
.
add
(
latRange
);
axes
.
add
(
longRange
);
results
.
addAll
((
Collection
<?
extends
Record
>)
DataStore
.
records
.
rangeSearch
(
axes
));
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment