plugins: Remove J1939 condition in CMakeLists file
[apps/agl-service-can-low-level.git] / low-can-binding / utils / socketcan-raw.hpp
index 6167241..02b3884 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2015, 2016 ,2017 "IoT.bzh"
+ * Copyright (C) 2015, 2016 , 2017, 2018, 2019 "IoT\.bzh"
  * Author "Romain Forlot" <romain.forlot@iot.bzh>
  * Author "Loïc Collignon" <loic.collignon@iot.bzh>
  * Licensed under the Apache License, Version 2.0 (the "License");
@@ -17,7 +17,7 @@
 #pragma once
 
 #include "socketcan.hpp"
-#include "../can/can-message.hpp"
+#include "../can/message/can-message.hpp"
 
 namespace utils
 {
@@ -26,10 +26,8 @@ namespace utils
        public:
                using socketcan_t::socketcan_t;
                virtual int open(std::string device_name);
-
-       private:
-               int bind(const struct sockaddr* addr, socklen_t len);
+               virtual std::shared_ptr<message_t> read_message();
+               virtual int write_message(message_t& cm);
        };
 
-       socketcan_raw_t& operator>>(socketcan_raw_t& s, can_message_t& cm);
 }