rb.templates.persistence_interface.erb Maven / Gradle / Ivy
<%#
# Copyright 2011 Rapleaf
#
# 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.
%>
<%= autogenerated %>
package <%= root_package %>.iface;
import <%= root_package %>.models.<%= model_defn.model_name %>;
import <%= root_package %>.query.<%= model_defn.query_builder_name %>;
import <%= root_package %>.query.<%= model_defn.delete_builder_name %>;
import java.io.IOException;
import java.util.Map;
import java.util.List;
import <%= JACK_NAMESPACE %>.IModelPersistence;
public interface <%= model_defn.iface_name %> extends IModelPersistence<<%= model_defn.model_name %>> {
<%= model_defn.model_name %> create(<%= create_signature_full %>) throws IOException;
<% unless create_signature_small.nil? %>
<%= model_defn.model_name %> create(<%= create_signature_small %>) throws IOException;
<% end %>
<%= model_defn.model_name %> createDefaultInstance() throws IOException;
<% model_defn.fields.each do |field_defn| %>
List<<%= model_defn.model_name %>> findBy<%= field_defn.name.camelcase %>(<%= field_defn.java_type %> value) throws IOException;
<% end %>
<%= model_defn.query_builder_name %> query();
<%= model_defn.delete_builder_name %> delete();
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy