Learning Apex Programming
eBook - ePub

Learning Apex Programming

Matt Kaufman, Michael Wicherski

Share book
  1. 302 pages
  2. English
  3. ePUB (mobile friendly)
  4. Available on iOS & Android
eBook - ePub

Learning Apex Programming

Matt Kaufman, Michael Wicherski

Book details
Book preview
Table of contents
Citations

Frequently asked questions

How do I cancel my subscription?
Simply head over to the account section in settings and click on “Cancel Subscription” - it’s as simple as that. After you cancel, your membership will stay active for the remainder of the time you’ve paid for. Learn more here.
Can/how do I download books?
At the moment all of our mobile-responsive ePub books are available to download via the app. Most of our PDFs are also available to download and we're working on making the final remaining ones downloadable now. Learn more here.
What is the difference between the pricing plans?
Both plans give you full access to the library and all of Perlego’s features. The only differences are the price and subscription period: With the annual plan you’ll save around 30% compared to 12 months on the monthly plan.
What is Perlego?
We are an online textbook subscription service, where you can get access to an entire online library for less than the price of a single book per month. With over 1 million books across 1000+ topics, we’ve got you covered! Learn more here.
Do you support text-to-speech?
Look out for the read-aloud symbol on your next book to see if you can listen to it. The read-aloud tool reads text aloud for you, highlighting the text as it is being read. You can pause it, speed it up and slow it down. Learn more here.
Is Learning Apex Programming an online PDF/ePUB?
Yes, you can access Learning Apex Programming by Matt Kaufman, Michael Wicherski in PDF and/or ePUB format, as well as other popular books in Informatique & Réseaux informatiques. We have over one million books available in our catalogue for you to explore.

Information

Year
2015
ISBN
9781782173977

Learning Apex Programming


Table of Contents

Learning Apex Programming
Credits
Foreword
About the Authors
About the Reviewers
www.PacktPub.com
Support files, eBooks, discount offers, and more
Why subscribe?
Free access for Packt account holders
Instant updates on new Packt books
Preface
What this book covers
What you need for this book
Who this book is for
Conventions
Reader feedback
Customer support
Downloading the example code
Errata
Piracy
Questions
1. Apex Assumptions and Comparisons
Before you start
A gift to our readers
Safety first
The Force.com IDE
Getting comfortable with Eclipse
Linking Eclipse to the Salesforce1 Platform
Under the hood
Data and metadata
Writing code
Summary
2. Apex Limits
Exceptions prove the rule
Embracing an exception
An exception to end all exceptions
Obeying the speed limit
More limits
Edition limits
API limits
E-mail limits
Time and relative limits in space
You want me to process how many records?
How many times and how many things
Techniques to avoid query limits
These aren't the queries you're looking for
Visualforce limits
Summary
3. More and Later
Chain reactions
Where we're going, we don't need roads
I fought the law and won
Please sir, I want some more
Combining forces
Bigger, better, and batchier
Dyna batch
More than meets the eye
Building skynet
More scheduling options
Master control
Summary
4. Triggers and Classes
A brief history of triggers
Trigger happy
Pulling the trigger
Execution time
Inside the mind of a trigger
All for one and one for all
Class is in session
Inner space
Share and share alike
Staying classy
Wrap it up
No libraries, no problem
Rinse, lather, and repeat
Put your hands together
Behind the scenes
The Pablo Picasso of Apex
Summary
5. Visualforce Development with Apex
s-con, what?
Your own personal Force.com
Creating a Visualforce page
Not much to see here
Tag, you're it!
Taking control
Tags that bind us
Paging the doctor variable
Actions speak louder than methods
Ajax your actions
Communication is key
Param face
Put your hands together
Extending control
More internal goodies
Global variables
Functions galore
Static cling
Dynamic pages
Creating a custom label
Creating a custom setting object
Data-driven pages
Visualforce components
Your component library
Controlling components
Summary
6. Exposing Force.com to the World
Three ways to skin a cat
Seeing is believing
What happened?
At your service
Let's REST
Getting SOAP
JavaScript buttons jubilee
For your consideration
Pros and cons
Limits
Pitfalls and gotchas
Profile permissions
Code happens
My turn!
Permissions again…
Let's get loud
Well RESTed
Console my Force.com developer
Squeaky clean
Anonymous Eclipse
Summary
7. Use Case – Integration with Google Calendar
Gimme an O!
Googol
Hello, I'm new
Ooo shiny!
Needle in a haystack
Forget me not
I'm late, very, very late!
O, Auth me mighty Google!
Manual labour
Let me google that for you
Not so fast
My, aren't we busy?
Custom settings
Picking up where we left off
Summary
8. Creating a Property Management Application
Why
What
Who
How
When and Where
A custom model
Account (standard object)
Contact (standard object)
Property (custom object)
Rental Unit
Rental Agreement (custom junction object)
Statement (custom object)
Payment (custom object)
The Authorize.net setting (custom setting)
Paying your dues
Mine, all mine
Black magic
I did it my way!
Ain't no mountain
Upgrade to the app status
Summary
9. Test Coverage
@isTest
Always on my mind
The rundown
At the parallel
Products
Batches and @future
Workflows and validation rules
Get tested
Helping hands
Itchy trigger finger
Mocking you
AI – Sans input
Batch tests
Fruits of our labour
The ultimate goal
Summary
Index

Learning Apex Programming

Copyright © 2015 Packt Publishing
All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.
Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the authors, nor Packt Publishing, and its dealers and distributors will be held liable for any damages caused or alleged to be caused directly or indirectly by this book.
Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.
First published: January 2015
Production reference: 1270115
Published by Packt Publishing Ltd.
Livery Place
35 Livery Street
Birmingham B3 2PB, UK.
ISBN 978-1-78217-397-7
www.packtpub.com

Credits

Authors
Matt Kaufman
Michael Wicherski
Reviewers
Marco Boerlage
John M. Daniel
Anup Jadhav
Pat Patterson
Commissioning Editor
Edward Gordan
Acquisition Editor
Sonali Vernekar
Content Development Editor
Govindan K.
Technical Editors
Narsimha Pai
Shweta Pant
Copy Editors
Shivangi Chaturvedi
Deepa Nambiar
Neha Vyas
Project Coordinator
Shipra Chauhan
Proofreaders
Simran Bhogal
Maria Gould
Ameesha Green
Paul Hindle
Joanna McMahon
Indexer
Priya Subramani
Production Coordinator
Nilesh R. Mohite
Cover Work
Nilesh R. Mohite

Foreword

Apps, and especially mobile apps, have become the primary path to innovation for most of the companies in the world. Businesses need apps for their employees that solve real problems, and they need apps to help them better connect to their customers and partners. These new apps are being created and are evolving at an amazing pace, and cloud platforms such as Force.com are making this possible.
However, when a modern-day developer sets out to build an app, they have a mind-boggling set of languages and services to choose from. So, it's important for them to understand when and how to use Force.com. We designed Force.com with the guiding principle that there is simply no faster way to build an enterprise application, and once you've built an app on Force.com, it is instantly ready for hundreds of thousands, even millions, of users. It will always be available, mobile, and secure. However, the critical thing to understand is that when we release new features three times a year, your app automatically gets them. It's like having 500 extra developers supporting you, who are working relentlessly to make your apps better, release after release and year after year.
If there's one piece of advice I would offer before you embark on your journey through this book, it's to be sure that you understand this foundational philosophy and why it makes Force.com special. It's a unique platform that can radically change how you think about application development.
Mike Rosenbaum
Executive Vice President,
Salesforce Platform

About the Authors

Matt Kaufman is no stranger to the Salesforce1 Platform, as he is one of the early employees at salesforce.com. Since 2002, Matt Kaufman has worked with hundreds of businesses to improve their efficiency through Salesforce. He is a certified Salesforce Advanced Administrator, Sales Cloud Consultant, Service Cloud Consultant, Advanced Developer, and Advanced Developer Instructor. His extensive experience and knowledge of salesforce.com technologies cause him to regularly be referred to as Mr. Salesforce, Salesforce wizard, Salesforce genie, and other magically endowed names.
Matt is currently the chief technology officer of MK Partners, Inc. (www.mkpartners.com), the leading salesforce.com implementation partner in southern California. He regularly provides training and talks on cloud technologies and development. He has also written other pu...

Table of contents