Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New BetweenInclusive class in Types #32

Closed
wants to merge 1 commit into from
Closed

Conversation

EgoLaparra
Copy link
Contributor

No description provided.

@@ -136,7 +136,10 @@ class AnaforaReader(val DCT: Interval)(implicit data: Data) {
case ("Two-Digit-Year", Some(value), N, N, N, None) => value.partition(_ != '?') match {
case (year, questionMarks) => YearSuffix(interval(properties), year.toInt, questionMarks.length)
}
case ("Between", None, N, N, N, None) => Between(interval(properties, "Start-"), interval(properties, "End-"))
case ("Between", None, N, N, N, None) => interval(properties, "Start-").end == interval(properties, "End-").start match {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You need to instead be checking the "Start-Included" and "End-Included" properties.

* @param startInterval first interval
* @param endInterval second interval
*/
case class BetweenInclusive(startInterval: Interval, endInterval: Interval) extends Interval {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we may need to add extra parameters to Between rather than adding a new class. See the comment above: the start and end can independently be set as inclusive or not.

@EgoLaparra EgoLaparra closed this Oct 17, 2017
@EgoLaparra EgoLaparra deleted the between-inclusive branch October 17, 2017 01:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants