Skip to content
Snippets Groups Projects
Commit 073bc19c authored by Sebastian Ebert's avatar Sebastian Ebert
Browse files

removed bazel build, fixed dependencies, removed non-core-packages

parent 111c1d10
No related branches found
No related tags found
No related merge requests found
/*
* Copyright (C) 2011 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
package org.ros.rosjava_tutorial_services;
import org.ros.namespace.GraphName;
import org.ros.node.AbstractNodeMain;
import org.ros.node.ConnectedNode;
import org.ros.node.NodeMain;
import org.ros.node.service.ServiceResponseBuilder;
import org.ros.node.service.ServiceServer;
/**
* This is a simple {@link ServiceServer} {@link NodeMain}.
*
* @author damonkohler@google.com (Damon Kohler)
*/
public class Server extends AbstractNodeMain {
@Override
public GraphName getDefaultNodeName() {
return GraphName.of("rosjava_tutorial_services/server");
}
@Override
public void onStart(ConnectedNode connectedNode) {
connectedNode.newServiceServer("add_two_ints", rosjava_test_msgs.AddTwoInts._TYPE,
new ServiceResponseBuilder<rosjava_test_msgs.AddTwoIntsRequest, rosjava_test_msgs.AddTwoIntsResponse>() {
@Override
public void
build(rosjava_test_msgs.AddTwoIntsRequest request, rosjava_test_msgs.AddTwoIntsResponse response) {
response.setSum(request.getA() + request.getB());
}
});
}
}
......@@ -19,13 +19,7 @@ include(
'apache_xmlrpc_common',
'apache_xmlrpc_server',
'rosjava',
'rosjava_geometry',
'rosjava_benchmarks',
'rosjava_test',
'rosjava_helpers',
'rosjava_tutorial_pubsub',
'rosjava_tutorial_right_hand_rule',
'rosjava_tutorial_services',
'docs',
)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment