XRF stands for
X-Ray Fluorescence, which is a method used in
Spectroscopy.
Basically what you have is a machine that records the amount of secondary emmissions, or "bounce off," of X-Rays from a substance that is bombarded with gamma radiation (which are also x-rays).
The amount of x-rays that the dectector records can tell the observer about the element content of the material. This is where the intensity of the x-ray gun comes into play. With different wavelengths, you can detect the amount of different elements by the amount of flourescence, or the concentration of x-rays bouncing back.
It is a form of Spectroscopy, because the detector reads into a computer that displays the data in a spectrographic fashion - because the intensity of the flourescence will be spread out along a range of various wavelengths, usually with big spikes that tell you about the elemental and chemical content of your sample.
In Industry, this technique is very useful in determining the purity of a substance that is being sold or used to make products, like a chemical or an alloy.
In the sciences, it has a wide variety of uses. Geologists can determine mineral content of samples, Bioarchaeologists have used the method to determine the dietary habits of previous cultures via XRF analysis of bones.
Anyway, the basic principle is fairly easy to understand, but how it is actually applied can get fairly complicated depending on what you are trying to do. Your XRF set-up might include monochromators and crystals. These sorts of things are done to make sure the geometry of the x-ray streams are right and your detector is picking up only flourescence, and to help get the maximum efficiency out of your set up.