You can build your .jar files with whatever contents you want. Swapping classes between .jars is not typically best practice as you can eventually loose track of what components are where and it makes for a nightmare when you want to apply an update/change, but it can be done in hard-cases. If your dealing with thirdparty .jar files you also have to pay attention to the copyright and legal issue. Some agreements inforce a policy thats restricts the use of components to use from within the 'whole', i.e. you are no authorized to split a thirdparty .jar file into its subcomponents, you are only entitled to use the component (.class) if it is embedded within the supplied .jar. So check the contracts or contact the vendor.