什么是司机类? (JAVA) [英] What is a driver class? (Java)

查看:228
本文介绍了什么是司机类? (JAVA)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在阅读一本Java教科书,它提到了一个叫做驱动程序类的东西。它是什么,它与普通类有什么不同?

解决方案

驱动程序类通常只是一个类包含一个主要的。在一个真实的项目中,你可能经常有许多驱动程序类用于测试和诸如此类,或者你可以在你的任何对象中构建一个main,并通过IDE选择runnable类,或者只是指定java classname。。 p>

I was reading through a Java textbook, and it mentions something called a "driver class". What is it, and how is it different from a normal class?

解决方案

A "Driver class" is often just the class that contains a main. In a real project, you may often have numerous "Driver classes" for testing and whatnot, or you can build a main into any of your objects and select the runnable class through your IDE, or by simply specifying "java classname."

这篇关于什么是司机类? (JAVA)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆