20 #include <boost/algorithm/string.hpp>
21 #include <boost/regex.hpp>
28 "((?:cs|fg|pq|tq|vq)[0-9]+)?"
30 boost::regex_constants::icase
35 "((?:fg|ft|pq)[0-9]+)?"
37 boost::regex_constants::icase
42 "((?:cp|fg|ft|pq|tq|vq)[0-9]+)?"
44 boost::regex_constants::icase
49 "((?:fg|fgg|ft|tq|tqg)[0-9]+)?"
51 boost::regex_constants::icase
56 "((?:cp|fg|ft|pq|tq|vq)[0-9]+)?"
58 boost::regex_constants::icase
62 "(x?c?6s[l]x[0-9]+t?l?)"
63 "((?:cpg|csg|fgg|ftg|tqg)[0-9]+)?"
65 boost::regex_constants::icase
70 "((?:bg|cs|fg|hq|pq|tq)[0-9]+)?"
72 boost::regex_constants::icase
77 "((?:bg|cs|fg|hq|pq)[0-9]+)?"
79 boost::regex_constants::icase
84 "((?:bf|bg|cs|ff|fg)[0-9]+)?"
86 boost::regex_constants::icase
93 boost::regex_constants::icase
97 "(x?c?4v[fls]x[0-9]+)"
100 boost::regex_constants::icase
104 "(x?c?5v[flst]x[0-9]+t?)"
107 boost::regex_constants::icase
111 "(x?c?6v[chls]x[0-9]+t?l?)"
114 boost::regex_constants::icase
119 "((?:cpg|csg|fbg|ffg|fgg|ftg)[0-9]+)?"
121 boost::regex_constants::icase
126 "((?:fbg|ffg|sbg)[0-9]+)?"
128 boost::regex_constants::icase
132 "(x?c?7v[hx]?[0-9]+tl?)"
133 "((?:ffg|fhg)[0-9]+)?"
135 boost::regex_constants::icase
140 "((?:clg|fbg|ffg)[0-9]+|die)?"
142 boost::regex_constants::icase
169 string designator = inDeviceDesignator;
170 boost::to_lower(designator);
171 if(boost::regex_match(designator, what, inRegEx, boost::match_default)) {
175 if(what[1].matched) {
EFamily mFamily
The family type.
static boost::regex sArtix7RegEx
Regular expression for Artix7 devices.
Encapsulation of a device designator and its constituent elements.
string mDevicePackage
The device package.
static boost::regex sVirtexERegEx
Regular expression for VirtexE devices.
string mDeviceSpeedGrade
The device speed grade.
static boost::regex sVirtex4RegEx
Regular expression for Virtex4 devices.
static boost::regex sSpartan6RegEx
Regular expression for Spartan3E devices.
static boost::regex sKintex7RegEx
Regular expression for Kintex7 devices.
std::ostream & operator<<(std::ostream &os, const DeviceDesignator &rhs)
bool parse(const string &inDeviceDesignator, const boost::regex &inRegEx)
Parses the device name into constituent device, package, and speed components.
string mDeviceDesignator
The full device designator.
Header for the DeviceDesignator class.
static boost::regex sSpartan3RegEx
Regular expression for Spartan3 devices.
static boost::regex sVirtex6RegEx
Regular expression for Virtex6 devices.
static boost::regex sSpartan2RegEx
Regular expression for Spartan2 devices.
const string & getDeviceSpeedGrade(void) const
Returns the device speed grade.
static boost::regex sVirtexRegEx
Regular expression for Virtex devices.
static boost::regex sSpartan3ERegEx
Regular expression for Spartan3E devices.
static boost::regex sSpartan3ARegEx
Regular expression for Spartan3A devices.
static boost::regex sVirtex2PRegEx
Regular expression for Virtex2P devices.
static boost::regex sVirtex7RegEx
Regular expression for Virtex7 devices.
static boost::regex sVirtex5RegEx
Regular expression for Virtex5 devices.
const string & getDevicePackage(void) const
Returns the device package.
const string & getDeviceName(void) const
Returns the device name.
static boost::regex sZynq7000RegEx
Regular expression for Zynq7000 devices.
DeviceDesignator(const string &inDeviceDesignator)
Basic constructor.
static boost::regex sSpartan2ERegEx
Regular expression for Spartan2E devices.
static boost::regex sVirtex2RegEx
Regular expression for Virtex2 devices.
string mDeviceName
The device name.