diff options
Diffstat (limited to 'p2pvr/ice')
-rw-r--r-- | p2pvr/ice/Jamfile.jam | 2 | ||||
-rw-r--r-- | p2pvr/ice/converters.cpp | 33 | ||||
-rw-r--r-- | p2pvr/ice/dvbsi.ice | 2 | ||||
-rw-r--r-- | p2pvr/ice/p2pvr.ice | 8 |
4 files changed, 45 insertions, 0 deletions
diff --git a/p2pvr/ice/Jamfile.jam b/p2pvr/ice/Jamfile.jam index c5031bd..cc97614 100644 --- a/p2pvr/ice/Jamfile.jam +++ b/p2pvr/ice/Jamfile.jam @@ -8,7 +8,9 @@ lib p2pvrice : <library>Ice <library>IceUtil <library>pthread + <library>..//p2common <library>..//p2lib + <library>..//p2ice : : <include>. <library>Ice diff --git a/p2pvr/ice/converters.cpp b/p2pvr/ice/converters.cpp new file mode 100644 index 0000000..94f2353 --- /dev/null +++ b/p2pvr/ice/converters.cpp @@ -0,0 +1,33 @@ +#include <variableType.h> +#include <common.h> +#include <iceConvert.h> +#include "commonHelpers.h" + +template<> +VariableType +IceConvert<Common::DateTime>::ToVariable(const Common::DateTime & dt) +{ + return *dt; +} + +template<> +VariableType +IceConvert<Common::Duration>::ToVariable(const Common::Duration & d) +{ + return *d; +} + +template<> +Common::DateTime +IceConvert<Common::DateTime>::FromVariable(const VariableType & dt) +{ + return *dt.as<boost::posix_time::ptime>(); +} + +template<> +Common::Duration +IceConvert<Common::Duration>::FromVariable(const VariableType & d) +{ + return *d.as<boost::posix_time::time_duration>(); +} + diff --git a/p2pvr/ice/dvbsi.ice b/p2pvr/ice/dvbsi.ice index 8cf6527..7978d3f 100644 --- a/p2pvr/ice/dvbsi.ice +++ b/p2pvr/ice/dvbsi.ice @@ -83,6 +83,7 @@ module DVBSI { BouquetTransportStreamList Streams; }; + ["project2:type"] class Service { int ServiceId; int TransportStreamId; @@ -121,6 +122,7 @@ module DVBSI { int OriginalNetworkId; }; + ["project2:type"] class Event { int ServiceId; int EventId; diff --git a/p2pvr/ice/p2pvr.ice b/p2pvr/ice/p2pvr.ice index 75bfbf8..61c0e32 100644 --- a/p2pvr/ice/p2pvr.ice +++ b/p2pvr/ice/p2pvr.ice @@ -65,16 +65,19 @@ module P2PVR { interface Recordings { idempotent int NewRecording(Recording rec); + ["project2:task"] idempotent void DeleteRecording(int recordingId); idempotent RecordingList GetRecordings(); }; interface Schedules { + ["project2:task"] idempotent void DeleteSchedule(int scheduleId); idempotent Schedule GetSchedule(int scheduleId); idempotent ScheduleList GetSchedules(); idempotent ScheduledToRecordList GetScheduledToRecord(); idempotent int UpdateSchedule(Schedule newSchedule); + ["project2:task"] idempotent void DoReschedule(); }; @@ -86,11 +89,16 @@ module P2PVR { idempotent DVBSI::Delivery GetDeliveryForTransport(int id); idempotent DVBSI::Delivery GetDeliveryForSi(); // Get services + ["project2:rows"] idempotent DVBSI::ServiceList GetServices(); + ["project2:rows"] idempotent DVBSI::Service GetService(int id); // Get events + ["project2:rows"] idempotent DVBSI::Event GetEvent(int serviceId, int eventId); + ["project2:rows"] idempotent DVBSI::Events EventsOnNow(); + ["project2:rows"] idempotent DVBSI::Events EventsInRange(Common::DateTime from, Common::DateTime to); }; |