Yes, using the locations features in the admin manually of course [0]
or using the workflow event system to automate this process (their are several which offer similar functionality). [1-4]
By what criteria would you like to determine weather assignment should be added?
By default to all objects of a specific content class or some other criteria?
I think I would recommend copying most recent related extension as the basis for your solution. [3]