I google and I find Jeff article of extending person properties. http://ecmarchitect.com/archives/2012/02/27/1555 So, i tried something like this. I extends in share-config-custom.xml and do other. But my problem is its implementation,in which java file do I need to add my custom properties. I trace and also google for the actual implementation file, but I do not found any clue how to extend folder metadata. For eg,in above person case, Jeff has uses SlingshotUserFactory. I am really glad to say Thanks if someone give me just a clue to this.
Extending the folder with custom properties shouldn't be as difficult as extending the person object.
In fact, it really isn't any different than extending cm:content or creating your own custom aspect and adding it to the folder.
Try creating a custom aspect with those two properties and adding it to a folder. Use the share-config-custom.xml to configure the fields that are displayed for cm:folder. If you need help doing that, look at the custom content types tutorial on ecmarchitect.com.
Once you get your custom properties displaying properly you can move on to how those properties are calculated. It looks like you want to count the files in a folder and also keep track of the total size of the files in a folder. There are multiple ways to do that, but one way would be to create a behavior bound to your custom aspect that is triggered when children are added. The behavior can calculate the stats and store them in the custom properties you defined in the previous step. Realize this could get very expensive and time consuming if you do it in enough folders and if the folders grow large.
If you need help writing a behavior, look at the behavior tutorial on ecmarchitect.com.
is there something special that needs to be done to get custom properties to show up in a unqualified search? I have qualified the fields in the search.get file but still I have to fully qualify my custom folder fields to get them to show up.