blob: d7ca758d1ecfad60216cfbff8c3421c22c58080e [file] [log] [blame]
Brian Silvermanf7f267a2017-02-04 16:16:08 -08001/*----------------------------------------------------------------------------*/
2/* Copyright (c) FIRST 2011-2017. All Rights Reserved. */
3/* Open Source Software - may be modified and shared by FRC teams. The code */
4/* must be accompanied by the FIRST BSD license file in the root directory of */
5/* the project. */
6/*----------------------------------------------------------------------------*/
7
8#pragma once
9
10#include <memory>
11#include <string>
12
13#include "tables/ITable.h"
14
15namespace frc {
16
17class Sendable {
18 public:
19 /**
20 * Initializes a table for this sendable object.
21 * @param subtable The table to put the values in.
22 */
23 virtual void InitTable(std::shared_ptr<ITable> subtable) = 0;
24
25 /**
26 * @return the table that is currently associated with the sendable
27 */
28 virtual std::shared_ptr<ITable> GetTable() const = 0;
29
30 /**
31 * @return the string representation of the named data type that will be used
32 * by the smart dashboard for this sendable
33 */
34 virtual std::string GetSmartDashboardType() const = 0;
35};
36
37} // namespace frc