Is it possible to create a nickname for a package name, that I can refer in xml file?
I don’t want to write the whole package name e.g. com.example.go.deck.today instead can I create an alias and refer that alias?
I’d like to refer an alias or nick instead of the package name in an android/layout XML file.
Android by itself does not provide such facility. However you can use the ant to do it for you. You could write a custom build.xml, customizing the target
<target name="-code-gen">to do token replacement before theRclass is generated. You could add the rule :this would replace every occurrence of
@PACKAGE_ALIAS@bycom.example.go.deck.todayin thetargetFile.I am not an
antspecialist but based on past experience I would say that it would not be hard to write a rule that could scan all file in theresdir.