Java file visibility constraints

I and my friend are connected through Socket Programming and he can see list of Files in specified location of my system and can even download them.

But i don’t want to show all the files in that location. i.e., i want visibility constraints. can anyone help this in java?