java java中的客户端代码是什么

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/13912438/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-10-31 14:25:16  来源:igfitidea点击:

What is client code in java

javaandroidclient

提问by rootpanthera

I have simple question. Of course before i asked here , i asked Google, but unfortunately i didn't get the answer i want.

我有一个简单的问题。当然,在我在这里问之前,我问过谷歌,但不幸的是我没有得到我想要的答案。

I just want to know simple question. What is client code in java (android)?When i asked google, it gave me results about client/network server. I think in this case a client is a program running on my/your computer, and network is a server communicating with client?

我只想知道简单的问题。java (android) 中的客户端代码是什么?当我问谷歌时,它给了我关于客户端/网络服务器的结果。我认为在这种情况下,客户端是在我/您的计算机上运行的程序,而网络是与客户端通信的服务器?

I want to know what is a client code in Java? Like in this context: ( Copied from android developers site )

我想知道 Java 中的客户端代码是什么?就像在这种情况下一样:(从 android 开发者网站复制)

There are two reasons that a service can be run by the system. If someone calls Context.startService() then the system will retrieve the service (creating it and calling its onCreate() method if needed) and then call its onStartCommand(Intent, int, int) method with the arguments supplied by the client.

系统可以运行服务有两个原因。如果有人调用 Context.startService() ,则系统将检索服务(创建它并在需要时调用其 onCreate() 方法),然后使用客户端提供的参数调用其 onStartCommand(Intent, int, int) 方法

Is in this case client code like Activity code ..or?

在这种情况下,客户端代码是否类似于活动代码 .. 或?

回答by Natix

In this context, clientmeans client of the API, which is simply the caller of the given methods or user of the given classes.

在这种情况下,客户端意味着API 的客户,它只是给定方法的调用者或给定类的用户。

回答by NickL

If activity A call's onStartCommand(Intent, int, int)of activity B, then activity A is the client. In this context, it simply means the caller of a method and/or service.

如果活动 A 调用onStartCommand(Intent, int, int)活动 B,则活动 A 是客户端。在这种情况下,它仅表示方法和/或服务的调用者。

When looking at webservices, the 'server' retrieving the requests is called the server. The 'client' calling the webservice, is the client. When the 'server' calls another server, this server calling the other server can also be seen as a client.

在查看 Web 服务时,检索请求的“服务器”称为服务器。调用 Web 服务的“客户端”是客户端。当“服务器”调用另一台服务器时,该服务器调用另一台服务器也可以看作是一个客户端。

A client can also be seen as a customer. Wiki.

客户也可以被视为客户。维基

回答by Murali

Client code ?

客户代码 ?

What kind of client code you want?

你想要什么样的客户端代码?

A web based client code?

基于 Web 的客户端代码?

An application client code?

应用程序客户端代码?

or Simply a client code?

或者只是一个客户端代码?

Client - A thing which requests for something for something.

客户 - 为某事请求某事的事物。

Something( any service, any information, any content or any answers or for answers)

东西(任何服务,任何信息,任何内容或任何答案或答案)