#ifndef CHROME_BROWSER_POLICY_PRINTING_RESTRICTIONS_POLICY_HANDLER_H_
#define CHROME_BROWSER_POLICY_PRINTING_RESTRICTIONS_POLICY_HANDLER_H_
#include <memory>
#include "base/containers/flat_map.h"
#include "base/values.h"
#include "build/chromeos_buildflags.h"
#include "components/policy/core/browser/configuration_policy_handler.h"
#include "printing/backend/printing_restrictions.h"
#include "printing/buildflags/buildflags.h"
class PrefValueMap;
namespace policy {
class PolicyMap;
template <class Mode>
class PrintingEnumPolicyHandler : public TypeCheckingPolicyHandler { … };
#if BUILDFLAG(IS_CHROMEOS_ASH)
class PrintingAllowedColorModesPolicyHandler
: public PrintingEnumPolicyHandler<printing::ColorModeRestriction> {
public:
PrintingAllowedColorModesPolicyHandler();
~PrintingAllowedColorModesPolicyHandler() override;
};
class PrintingColorDefaultPolicyHandler
: public PrintingEnumPolicyHandler<printing::ColorModeRestriction> {
public:
PrintingColorDefaultPolicyHandler();
~PrintingColorDefaultPolicyHandler() override;
};
class PrintingAllowedDuplexModesPolicyHandler
: public PrintingEnumPolicyHandler<printing::DuplexModeRestriction> {
public:
PrintingAllowedDuplexModesPolicyHandler();
~PrintingAllowedDuplexModesPolicyHandler() override;
};
class PrintingDuplexDefaultPolicyHandler
: public PrintingEnumPolicyHandler<printing::DuplexModeRestriction> {
public:
PrintingDuplexDefaultPolicyHandler();
~PrintingDuplexDefaultPolicyHandler() override;
};
class PrintingAllowedPinModesPolicyHandler
: public PrintingEnumPolicyHandler<printing::PinModeRestriction> {
public:
PrintingAllowedPinModesPolicyHandler();
~PrintingAllowedPinModesPolicyHandler() override;
};
class PrintingPinDefaultPolicyHandler
: public PrintingEnumPolicyHandler<printing::PinModeRestriction> {
public:
PrintingPinDefaultPolicyHandler();
~PrintingPinDefaultPolicyHandler() override;
};
#endif
#if BUILDFLAG(ENABLE_PRINT_PREVIEW)
class PrintingAllowedBackgroundGraphicsModesPolicyHandler
: public PrintingEnumPolicyHandler<
printing::BackgroundGraphicsModeRestriction> { … };
class PrintingBackgroundGraphicsDefaultPolicyHandler
: public PrintingEnumPolicyHandler<
printing::BackgroundGraphicsModeRestriction> { … };
class PrintingPaperSizeDefaultPolicyHandler : public TypeCheckingPolicyHandler { … };
class PrintPdfAsImageDefaultPolicyHandler : public TypeCheckingPolicyHandler { … };
#endif
}
#endif