LPS-44216 Add util methods equivalent to the existing ones for preferences but using PortletSettings instead

Later on we will need to revisit whether we can avoid having this type of methods.
LPS-44216 Sort
LPS-44216 Use consistent var names
LPS-44216 Move to its own method
LPS-44216 Sort
LPS-44216 SF
LPS-44216 Javadocs are most likely correct, but let's give Jim a chance to review, please send those to him. Thx.
LPS-44216 SF
LPS-44052 Do not leave file handles open
LPS-44052 don't use url.openConnection if url is file (helps JBoss WildFly).
LPS-44052 Source formatting
LPS-44175 - actions, paths
LPS-44175 - macros
LPS-44175 - tests
LPS-44175 SF
LPS-44218  Avoid using Pattern.matches() whenever possible
LPS-43428 - Make the screenshots all generic, so it's easier to move them along with "report.html"
LPS-44099 fix tests
LPS-44099 SF
LPS-42569 If there is a virtualHostName we should return it even if canonicalURL is false or if the virtualHostName doesn't match the portalDomain (because the virtual hostname of the site can be different than the portal virtualhostname)