[JAVA-1313] CommandOperation commands should be generic Created: 17/Jul/14 Updated: 18/Jul/14 Resolved: 18/Jul/14 |
|
| Status: | Closed |
| Project: | Java Driver |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 3.0.0 |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Ross Lawley | Assignee: | Ross Lawley |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Description |
|
Currently, the CommandRead and CommandWrite operations require the commands to be BsonDocuments. This adds complexity for Driver authors who may be using their own custom type and already have encoder / decoders for them. |
| Comments |
| Comment by Ross Lawley [ 18/Jul/14 ] |
|
As using operations directly is specialised (eg for driver authors) and as there already is a simple way to wrap documents of type T - BsonDocumentWrapper<T>(T, Encoder<T>) it's not worth the complication, potential for bugs and increased complexity of opening up all the operations to take an Encoder<T>. Won't Fix. |