void defiGroup::print(FILE* f) const { int i; fprintf(f, "Group '%s'\n", name()); if (hasRegionName()) { fprintf(f, " region name '%s'\n", regionName()); } if (hasRegionBox()) { int size = numRects_; int* xl = xl_; int* yl = yl_; int* xh = xh_; int* yh = yh_; for (i = 0; i < size; i++) fprintf(f, " region box %d,%d %d,%d\n", xl[i], yl[i], xh[i], yh[i]); } if (hasMaxX()) { fprintf(f, " max x %d\n", maxX()); } if (hasMaxY()) { fprintf(f, " max y %d\n", maxY()); } if (hasPerim()) { fprintf(f, " perim %d\n", perim()); } }
/*! * Returns \c true is this endpoint is valid; \c false otherwise. * * The endpoint is considered valid if the host specified during construction is * a known AWS host, and thus we know what region and service(s) it supports. * * For example: * \code * AwsEndpoint good(QLatin1String("cloudformation.us-east-1.amazonaws.com")); * AwsEndpoint bad(QLatin1String("example.com")); * Q_ASSERT(good.isValid()); // good is valid. * Q_ASSERT(!bad.isValid()); // bad is not. * \endcode */ bool AwsEndpoint::isValid() const { return ((!hostName().isEmpty()) && (!regionName().isEmpty()) && (!serviceName().isEmpty())); }
/*! * Returns \c true if the given \c transport is supported by this endpoint; \c false otherwise. */ bool AwsEndpoint::isSupported(const Transport transport) const { return isSupported(regionName(), serviceName(), AwsEndpoint::Transports(transport)); }