SAN JOSE — In a hotly contested Central Coast Section Open Division championship game Saturday night in which two Los Gatos coaches and a St. Francis player were ejected on close plays at the plate in the fifth inning, Andrew Martinez settled the issue with one swing.

The St. Francis junior ripped a two-run triple just past diving left fielder Doug Neubauer to break a tie in the sixth and send St. Francis to a 5-2 victory at Municipal Stadium.

“That was probably the most intense game I have ever been a part of, with the way their crowd was reacting, their players were reacting, our players were reacting,” St. Francis coach Mike Oakland said. “My heart was racing all game.”

The section championship was St. Francis’ second in three years — the Lancers won Division I in 2013 — and capped a 29-5 season in which the team won the prestigious Boras Classic, West Catholic Athletic League regular-season and postseason tournament titles and now the CCS’s premier division.

For Los Gatos (30-6), the loss was a bitter end to a special season. A revved-up crowd that filled the seats on the Los Gatos side, including a vocal group of students, was hoping to see the team that began the season with 20 wins in its first 21 games end the season with a celebration.

Instead, Los Gatos coach Nate Anderson and one of his assistants were not around for the finish after they were ejected for arguing a play at the plate that put St. Francis ahead 2-0.

Lancers catcher Johnny Mendoza singled to right, and the throw home arrived at the same time as Martinez, running from second.

The umpire signaled safe. Anderson erupted and was thrown out of the game. Then one of his assistants erupted and was ejected, too.

Down 2-0, Los Gatos rallied in the bottom of the fifth, tying the score when Matt Wilcox’s slide at home jarred the ball loose from Mendoza.

“I tried to go for the tag, and he came in hard,” Mendoza said.

Oakland protested the call, and during the heated moment a St. Francis player was tossed.

The score stayed 2-2 until Martinez’s second big hit of the game. His double in the fifth gave St. Francis a 1-0 lead. In the sixth, his two-out triple propelled St. Francis to a title.

“There was a lot going through my head,” Martinez said. “But I was just trying to see fastball and adjust curve ball up. For the triple, I saw fastball early and jumped on it.”

The ball sailed to deep left-center, and Neubauer nearly chased it down. But he could not make the circus catch, and two runs scored. A passed ball brought Martinez in for the final run.

Pitcher Andrew Carter finished strong, throwing a complete game.

“A.C. pitched his butt off,” Mendoza said. “He threw 100 pitches. Coach was like, ‘Do you want to go out there for the seventh?’ He said, ‘Yeah.’ He wanted to finish it off.”

When Hunter Bigge grounded out to first to end the game, St. Francis players charged the mound, a season filled with celebrations ending with one more.

“We’re best team in the section,” Mendoza said about Saturday’s win. “That’s what we wanted. We got the 2 seed, and we wanted to prove we should have got the 1 seed — and we did.”

Division I

The Piedmont Hills team went to Denny’s for breakfast Saturday, with the players ordering — what else? — the grand slam.

The 16th-seeded Pirates then went out and hit like the Bambino himself.

Five of the first six batters crushed the ball for hits, and the one who did not sacrificed a runner to second. The onslaught led to four first-inning runs that sent Piedmont Hills on its way to a 10-0, five-inning victory over seventh-seeded Pioneer (18-12) in the CCS Division I championship game.

Piedmont Hills (21-7) had never won a CCS playoff baseball game before this season. It took a four-game run to bring the school the championship it celebrated at Municipal Stadium.

Cameron Castaneda was the star of stars for Piedmont Hills. He went 4 for 4 with two doubles, three RBIs and scored two runs. The junior also pitched a complete game, allowing just four hits and finishing the title game with a strikeout.

“Unbelievable,” coach Bill Kennedy said of Castaneda. “He stepped up big like we needed him to. We saved him for tonight’s game. We didn’t use him in the other game, the 10-inning game. He was the only fresh arm we had.”

The pitcher had plenty of support.

Jordan Leffler led off the game with a sharp single to left and moved to second on Jacob Pangelina’s sacrifice. Castaneda followed with a double to left to make it 1-0.

Evan Williams knocked in Castaneda with a single and moved to third on Dominik Pedraza’s double. John Kelly then hit a two-run single to make it 4-0.

Castaneda’s double to left in the second drove in another run to extend the lead to 5-0.

The Pirates added three in the fourth and two in the fifth to position themselves for the 10-run rule triumph.

Division II

Five outs from defeat Saturday, Sacred Heart Prep instead added to its trophy case, completing a magical school year with a CCS Division II baseball championship.

The fourth-seeded Gators (21-12) scored three runs in the bottom of the sixth inning to erase a one-run deficit, then watched closer John Bird retire Carmel (23-8) in order in the seventh to clinch a 4-2 victory at Municipal Stadium.

The three players who drove in runs for SHP in the sixth — Andrew Daschbach, John Van Sweden and Andrew Robinson — all played on the school’s football team that went undefeated and won the CCS Open Division title in the fall.

Throw in SHP’s boys basketball team qualifying for the section’s Open Division playoffs and, yes, it’s been quite a year for the small coed private school in Atherton.

“Oh my gosh, it’s been a dream come true,” said Daschbach, whose double down the left-field line tied the score 2-2. “When I came over to Sacred Heart, that was my goal, to win a championship. It’s been a blessing to be able to win a couple.

“The football team’s success kind of set the tone. That carried over to basketball, and we were able to carry it over to baseball as well. A lot of credit goes to our coaches and athletes who work hard day in and day out.”

Freshman pitcher Angelo Tonas overcame a rough second inning to give his team the chance to rally.