P4C
The P4 Compiler
Loading...
Searching...
No Matches
P4::ControlPlaneAPI::FieldIdAllocator< T > Class Template Reference

Public Member Functions

template<typename It >
 FieldIdAllocator (It begin, It end, typename std::enable_if< std::is_same< typename std::iterator_traits< It >::value_type, T >::value >::type *=0)
 
p4rt_id_t getId (T v)
 

Detailed Description

template<typename T>
class P4::ControlPlaneAPI::FieldIdAllocator< T >

FieldIdAllocator is used to allocate ids for non top-level P4Info objects that need them (match fields, action parameters, packet IO metadata fields). Some of these ids can come from the P4 program (@id annotation), the rest is auto-generated.