SAN FRANCISCO — Former Sun CEO Jonathan Schwartz took the stand here today as a witness for the defense, and disputed Oracle’s claim that Java APIs were proprietary code from Sun.

Google’s lawyer, Robert van Nest, asked Schwartz whether, during his tenure at Sun, Java APIs were considered proprietary or protected by Sun.

“No,” Schwartz said in explaining the nature of open software. “These are open APIs, and we wanted to bring in more people…we wanted to build the biggest tent and invite as many people as possible.”

Oracle contends that Google’sAndroid platform violated some of its patents and copyrights around Java and its APIs, which it acquired from Sun in a $7.4 billion deal at the beginning of 2010.

Schwartz corroborated testimony by former Google CEO (now executive chairman) Eric Schmidt, who said that during meetings following the launch of Android the Sun CEO didn’t express any concerns or disapproval regarding Android, nor did he state that Google needed a license to use Java APIs in Android.

“My understanding is that what we were doing was permissible because of the sum of my experiences and interactions I had,” Schmidt said in this testimony, adding that he was “very comfortable that what we were doing was both legally correct and consistent” with the policies of Sun and Google at that time.

Schmidt, who spent 14 years at Sun, was Schwartz’s first boss at the company, and the two became close friends.

Regarding a partnership between Google and Android, Schwartz said that Sun wanted Google to pay a big license fee to call its phone a Java phone, and join Nokia, Motorola, Blackberry (RIM) and others in developing apps that run across all the platforms. At this point Nokia was dominant, and Apple’siPhone was not in the market, and Java licensing was a $100 million plus business for Sun, Schwartz said. Sun would profit by enlarging the Java community and creating more of a barrier to competition with the likes of Microsoft at the time.

JAVA is a technology whose value is near infinite to the internet, and a brand that’s inseparably a part of Sun (and our profitability). And so next week, we’re going to embrace that reality by changing our trading symbol, from SUNW to JAVA. This is a big change for us, capitalizing on the extraordinary affinity our teams have invested to build, introducing Sun to new investors, developers and consumers. Most know Java, few know Sun – we can bring the two one step closer.

The partnership with Google did not work out, even though Sun was willing to pay to have Google onboard with its Java platform. “I would venture a guess they felt they could better execute on their own,” Schwartz said, calling Google “opaque,” not sharing all the cards. Basically, Sun did not want to cede control of managing the key components in the Java stack, and Google wanted more control over its destiny.

Schwartz was asked why, given the lack of a partnership with Google, he applauded the announcement of Android in a blog post (which is viewable on Schwartz’s personal site) on Sun’s web site on Nov. 5, 2007, in which he wrote:

I just wanted to add my voice to the chorus of others from Sun in offering my heartfelt congratulations to Google on the announcement of their new Java/Linux platform, Android. Congratulations!

I’d also like Sun to be the first platform software company to commit to a complete developer environment around the platform, as we throw Sun’s NetBeans developer platform for mobile devices behind the effort. We’ve obviously done a ton of work to support developers on all Java-based platforms, and we’re pleased to add Google’s Android to the list.

And needless to say, Google and the Open Handset Alliance just strapped another set of rockets to the community’s momentum — and to the vision defining opportunity across our (and other) planets.

‘We decided to grit our teeth’
Schwartz said his blog post was like a press release, an official Sun statement, but there was a lot left unsaid.

“We didn’t like [what Google was doing with Android], but we weren’t going to stop it by complaining about it,” Schwartz said, explaining that Google could have chosen to work with Microsoft, a major competitor for Sun, or an open-source Java implementation. “At least with Java they could be part of the Java community,” he said. Without the Java community, Google would have to “reinvent a whole community,” Schwartz said.

“We saw a handset bypass our brand and licensing restrictions…we decided to grit our teeth and support it so anyone supporting it would see us as part of the value chain. For example, developers could use Sun’s Java developer tools NetBeans to write applications. Sun developed JavaFX, which could run on top of the Android stack.

In cross-examination, Oracle’s lawyer Michael Jacobs asked Schwartz about a document referencing Sun’s approach for granting intellectual property rights for independent implementations of Java, such as Android and Apache.

Schwartz responded that as long as Google, Apache or others creating independent implementations didn’t call their product Java, Sun had no problem. ”In order to get the brand, you had to get the TCK (Technology Compatibility Kit).”

Jacobs took Schwartz through a series of e-mails to counter the former CEO’s statements about Google getting a free pass with Android.

In e-mails from March 2008, Sun’s executives, including Schwartz, wrote that they were upset that Google took Android “without attribution or contribution,” and worried about Java revenue due to competition with Sun for Java OEMs. One executive talked about using an “IP hammer” on Google.

But Schwartz insisted under questioning by Jacobs that as long as Google or the Apache Foundation didn’t call their products “Java” it was his view they could ship their implementations of Java without any license from Sun.

Jacobs also questioned Schwartz about his resignation from Sun on the day Oracle took control of the company, as if to suggest that the former CEO of Sun had a bone to pick with Oracle.

Happier times: Sun and Google were Java allies in October 2005, when Sun’s then-president Jonathan Schwartz, left, and CEO Scott McNealy, center, joined Google CEO Eric Schmidt to tout a partnership that ultimately fizzled. For the partnership, the Google toolbar became a standard part of the software people get when they download Java from Sun’s Web site. (Credit: Stephen Shankland/CNET)

Schwartz resigned from Sun on January 27, 2010. In a blog post from March 9 of that year titled “Good Artists Copy, Great Artists Steal,” prior to Oracle suing Google on August 12, 2010, he made clear his view on open software, patents and lawsuits:

I understand the value of patents – offensively and, more importantly, for defensive purposes. Sun had a treasure trove of some of the internet’s most valuable patents – ranging from search to microelectronics – so no one in the technology industry could come after us without fearing an expensive counter assault. And there’s no defense like an obvious offense.

But for a technology company, going on offense with software patents seems like an act of desperation, relying on the courts instead of the marketplace. See Nokia’s suit against Apple for a parallel example of frivolous litigation – it hasn’t slowed iPhone momentum (I’d argue it accelerated it). So I wonder who will be first to claim Apple’s iPad is stepping on their IP… perhaps those that own the carcass of thetablet computing pioneer Go Corp.? Except that would be ATT. Hm.

Having watched this movie play out many times, suing a competitor typically makes them more relevant, not less. Developers I know aren’t getting less interested in Google’s Android platform, they’re getting more interested – Apple’s actions are enhancing that interest.