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

Support Conversion of Product classes to/from DefaultLeapFrame #111

Closed
hollinwilkins opened this issue Jan 25, 2017 · 1 comment
Closed
Milestone

Comments

@hollinwilkins
Copy link
Member

Spark has a nice feature that let's you build a Dataset from a case class. We should support this as well.

MleapReflection provides many tools that will be needed for this task.
I am thinking we should support the following conversions:

  1. (case class) -> DefaultLeapFrame w/ 1 row
  2. Seq(case class) -> DefaultLeapFrame w/ n rows
  3. DefaultLeapFrame -> (case class), extracts first row (throw error if more than one?)
  4. DefaultLeapFrame -> Seq(case class), extracts all rows into a Seq of a case class

These conversions should be implicit and included in the MleapSupport trait for easy usage.

@hollinwilkins hollinwilkins added this to the 0.6.0 milestone Jan 25, 2017
@hollinwilkins hollinwilkins modified the milestones: 0.7.0, 0.6.0 Feb 15, 2017
hollinwilkins pushed a commit that referenced this issue Mar 28, 2017
* support conversion of Product classes to DefaultLeapFrame

* support conversion of Product classes to DefaultLeapFrame

* fix misspelling in LeapFrameConverterSpec test class

* add ability to create newInstance of case class from seq of arguments passed in

* add ability to create newInstance of case class from seq of arguments passed in

* add support to convert from defaultleapframe to a sequence of case classes

* better method name for converting from leapframe to seq of case classes
@ancasarb
Copy link
Member

@hollinwilkins I believe this issue can be closed now?

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

No branches or pull requests

2 participants