1 // -*- mode:C++; tab-width:8; c-basic-offset:2; indent-tabs-mode:t -*-
2 // vim: ts=8 sw=2 smarttab
8 namespace rgw::notify
{
11 ObjectCreatedPut
= 0x1,
12 ObjectCreatedPost
= 0x2,
13 ObjectCreatedCopy
= 0x4,
14 ObjectCreatedCompleteMultipartUpload
= 0x8,
16 ObjectRemovedDelete
= 0x10,
17 ObjectRemovedDeleteMarkerCreated
= 0x20,
18 // lifecycle events (RGW extension)
19 ObjectLifecycle
= 0xFF00,
20 ObjectExpiration
= 0xF00,
21 ObjectExpirationCurrent
= 0x100,
22 ObjectExpirationNoncurrent
= 0x200,
23 ObjectExpirationDeleteMarker
= 0x400,
24 ObjectExpirationAbortMPU
= 0x800,
25 ObjectTransition
= 0xF000,
26 ObjectTransitionCurrent
= 0x1000,
27 ObjectTransitionNoncurrent
= 0x2000,
28 UnknownEvent
= 0x10000
31 using EventTypeList
= std::vector
<EventType
>;
33 // two event types are considered equal if their bits intersect
34 bool operator==(EventType lhs
, EventType rhs
);
36 std::string
to_string(EventType t
);
38 std::string
to_ceph_string(EventType t
);
40 std::string
to_event_string(EventType t
);
42 EventType
from_string(const std::string
& s
);
44 // create a vector of event types from comma separated list of event types
45 void from_string_list(const std::string
& string_list
, EventTypeList
& event_list
);