Don Newton | 379ae25 | 2019-04-01 12:17:06 -0400 | [diff] [blame^] | 1 | // Copyright (C) MongoDB, Inc. 2017-present. |
| 2 | // |
| 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may |
| 4 | // not use this file except in compliance with the License. You may obtain |
| 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 |
| 6 | |
| 7 | package wiremessage |
| 8 | |
| 9 | import "github.com/mongodb/mongo-go-driver/bson" |
| 10 | |
| 11 | // Command represents the OP_COMMAND message of the MongoDB wire protocol. |
| 12 | type Command struct { |
| 13 | MsgHeader Header |
| 14 | Database string |
| 15 | CommandName string |
| 16 | Metadata string |
| 17 | CommandArgs string |
| 18 | InputDocs []bson.Raw |
| 19 | } |
| 20 | |
| 21 | // MarshalWireMessage implements the Marshaler and WireMessage interfaces. |
| 22 | func (c Command) MarshalWireMessage() ([]byte, error) { |
| 23 | panic("not implemented") |
| 24 | } |
| 25 | |
| 26 | // ValidateWireMessage implements the Validator and WireMessage interfaces. |
| 27 | func (c Command) ValidateWireMessage() error { |
| 28 | panic("not implemented") |
| 29 | } |
| 30 | |
| 31 | // AppendWireMessage implements the Appender and WireMessage interfaces. |
| 32 | func (c Command) AppendWireMessage([]byte) ([]byte, error) { |
| 33 | panic("not implemented") |
| 34 | } |
| 35 | |
| 36 | // String implements the fmt.Stringer interface. |
| 37 | func (c Command) String() string { |
| 38 | panic("not implemented") |
| 39 | } |
| 40 | |
| 41 | // Len implements the WireMessage interface. |
| 42 | func (c Command) Len() int { |
| 43 | panic("not implemented") |
| 44 | } |
| 45 | |
| 46 | // UnmarshalWireMessage implements the Unmarshaler interface. |
| 47 | func (c *Command) UnmarshalWireMessage([]byte) error { |
| 48 | panic("not implemented") |
| 49 | } |