Uploaded image for project: 'OFBiz'
  1. OFBiz
  2. OFBIZ-7272 Enforce noninstantiability to all Utility classes
  3. OFBIZ-7459

Enforce noninstantiability to ApacheFopWorker Class

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • 16.11.01
    • framework
    • None
    • Community Day 2 - 2016, OFBiz Community Day (May 2020)

    Description

      • Make class as final.
      • Add a private constructor.
      • Make the following protected variable as private
            protected static FopFactory fopFactory = null;
        
      • Make the following public variable as private
            public static final String tempFilePrefix = "org.ofbiz.webapp.view.ApacheFopWorker-";
        
            public static final int encryptionLengthBitsDefault = 128;
            
            public static final String encryptionLengthDefault = UtilProperties.getPropertyValue("fop", "fop.encryption-length.default", String.valueOf(encryptionLengthBitsDefault));
        
            public static final String userPasswordDefault = UtilProperties.getPropertyValue("fop", "fop.userPassword.default");
        
            public static final String ownerPasswordDefault = UtilProperties.getPropertyValue("fop", "fop.ownerPassword.default");
        
            public static final String allowPrintDefault = UtilProperties.getPropertyValue("fop", "fop.allowPrint.default", "true");
        
            public static final String allowCopyContentDefault = UtilProperties.getPropertyValue("fop", "fop.allowCopyContent.default", "true");
        
            public static final String allowEditContentDefault = UtilProperties.getPropertyValue("fop", "fop.allowEditContent.default", "true");
        
            public static final String allowEditAnnotationsDefault = UtilProperties.getPropertyValue("fop", "fop.allowEditAnnotations.default", "true");
        
            public static final String allowFillInFormsDefault = UtilProperties.getPropertyValue("fop", "fop.allowFillInForms.default", "true");
        
            public static final String allowAccessContentDefault = UtilProperties.getPropertyValue("fop", "fop.allowAccessContent.default", "true");
        
            public static final String allowAssembleDocumentDefault = UtilProperties.getPropertyValue("fop", "fop.allowAssembleDocument.default", "true");
        
            public static final String allowPrintHqDefault = UtilProperties.getPropertyValue("fop", "fop.allowPrintHq.default", "true");
        
            public static final String encryptMetadataDefault = UtilProperties.getPropertyValue("fop", "fop.encrypt-metadata.default", "true");
            
            public static final String fopPath = UtilProperties.getPropertyValue("fop", "fop.path", "/framework/webapp/config");
            
            public static final String fopFontBaseProperty = UtilProperties.getPropertyValue("fop", "fop.font.base.url", "/framework/webapp/config/");
        
        
      • Make getter methods for all above converted private variables.

      Attachments

        1. OFBIZ-7459.patch
          12 kB
          Rohit Koushal

        Activity

          People

            arunpati Arun Patidar
            arunpati Arun Patidar
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: