My question involves juvenile law in the State of: Virginia

So me and my friend today bought some marijuana today, and we stopped at 7-11, shortly after. Right after a police car stops behind us, and searches the car. They found 2 grams. My friend is 19, and I'm 17. I'm going to a Juvenile and Domestic Relations Court in a month. So I received a "notice of right to Consideration of Diversion", which I do not understand clearly what it means. Also am I allowed to leave the country in the next few months, since my family has planned a trip which starts 5 days after the court day. In 2 months I'm starting college in a Iowa. Will this be in conflict with anything that may happen?