Hi @GokulakannanV,
I think what would you like to achieve would be very difficult, or will break some fundamental rules in AEM. Let me explain the complexity below.
- Unlike Asset search or Lanches etc filters set for Collection view is not included in Search Forms, which would allow you to extend/modify filter set in very easy way.
- In theory you could try to modify Collection search filters programmatically, but this takes us into another limitation. Configuration for Collection view can be found under /libs/settings/dam/search/collections/jcr:content/items, the problem is that this section is marked as granite:InternalArea, which means you should not overlay this area. Or you are doing it on your own risk.
- Last but not least, even if you will decide to overlay above section and extend OOTB set of filters, this could be also a challenging exercise. It's because private and public collections are not distinguish by property but by path, so build a proper query that will limit the results will be difficult.
Having above knowledge, and keeping in mind what is available OOTB, I would suggest below approach:
- Create two tags, one for public collection, and the other for private
- Use above tags to mark specific collection as public or private
- Use OOTB Tag filtering on search level.
Of course the solution is not ideal, and would requires some maintenance, but technically it is 100% OOTB solution. Which also have some additional benefits, like the fact you do not have to check this solution after AEM or SP upgrade.