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

Implement session nanos #104

Merged
merged 1 commit into from
Oct 25, 2021
Merged

Implement session nanos #104

merged 1 commit into from
Oct 25, 2021

Conversation

maread99
Copy link
Collaborator

@maread99 maread99 commented Oct 25, 2021

Side effect of implementation is to allow a considerable number of parsing calls to be handled by common _get_*_idx methods.

Also, restricts date input to is_session and date_to_session to dates within calendar range. This removes the current ambiguity of whether False is saying the date is 'not a session' or 'is out of calendar range, but it might be a session'.

Added following properties and methods:

  • all_sessions_nanos
  • _get_session_idx
  • _get_date_idx
  • _get_minute_idx
  • _get_sessions_slice
  • _get_minutes_slice
  • _date_oob
  • _minute_oob

- Implements quick session index lookups via session nanos.
- Amends quick minute index lookup to a similar common implementation.

Adds following properties and methods:
- `all_sessions_nanos`
- `_get_session_idx`
- `_get_date_idx`
- `_get_minute_idx`
- `_get_sessions_slice`
- `_get_minutes_slice`
- `_date_oob`
- `_minute_oob`

Also:
- restricts date input to `is_session` and `date_to_session` to dates
within calendar range.
- changes default `raise_oob` option of parsing methods from False to
True.
@maread99 maread99 marked this pull request as ready for review October 25, 2021 08:21
@maread99 maread99 merged commit 05ab948 into master Oct 25, 2021
@maread99 maread99 deleted the session-nanos-0 branch October 25, 2021 08:39
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.

1 participant