Tech giant Apple Inc. is planning a major expansion in San Diego and has leased all of a new office building currently under development by BioMed Realty in the bustling University Town Center neighborhood, according to three sources familiar with the deal.