Could you give me an example of how this could be achieved?
What you want to do is create a class implementing IRecipe. Fill in the methods appropriately. Check all conditions under the matches() method and return false if any of your conditions are false. Return the crafting result under getRecipeResult(). See net.minecraft.item.crafting for more details.
EDIT: Forgot the most important part: register your recipe using GameRegistry.addRecipe(new YourIRecipe());
To add onto Mitchellbrine's comment, add
dependencies = "after:*"
replacing * with the mod ID you want the item from, to your @Mod declaration in the main mod class.
Go here for more information.
http://www.minecraftforum.net/forums/mapping-and-modding/minecraft-mods/2342595-craft-v2-2-2-a-simple-vanilla-enhancing-mod