View Javadoc
1   /*
2    *    Copyright 2010-2026 the original author or authors.
3    *
4    *    Licensed under the Apache License, Version 2.0 (the "License");
5    *    you may not use this file except in compliance with the License.
6    *    You may obtain a copy of the License at
7    *
8    *       https://www.apache.org/licenses/LICENSE-2.0
9    *
10   *    Unless required by applicable law or agreed to in writing, software
11   *    distributed under the License is distributed on an "AS IS" BASIS,
12   *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   *    See the License for the specific language governing permissions and
14   *    limitations under the License.
15   */
16  package org.mybatis.jpetstore.mapper;
17  
18  import org.mybatis.jpetstore.domain.Account;
19  
20  /**
21   * The Interface AccountMapper.
22   *
23   * @author Eduardo Macarron
24   */
25  public interface AccountMapper {
26  
27    /**
28     * Get account by username.
29     *
30     * @param username
31     *          the username
32     *
33     * @return the account
34     */
35    Account getAccountByUsername(String username);
36  
37    /**
38     * Get account by username and password.
39     *
40     * @param username
41     *          the username
42     * @param password
43     *          the password
44     *
45     * @return the account
46     */
47    Account getAccountByUsernameAndPassword(String username, String password);
48  
49    /**
50     * Insert account.
51     *
52     * @param account
53     *          the account
54     */
55    void insertAccount(Account account);
56  
57    /**
58     * Insert profile.
59     *
60     * @param account
61     *          the account
62     */
63    void insertProfile(Account account);
64  
65    /**
66     * Insert signon.
67     *
68     * @param account
69     *          the account
70     */
71    void insertSignon(Account account);
72  
73    /**
74     * Update account.
75     *
76     * @param account
77     *          the account
78     */
79    void updateAccount(Account account);
80  
81    /**
82     * Update profile.
83     *
84     * @param account
85     *          the account
86     */
87    void updateProfile(Account account);
88  
89    /**
90     * Update signon.
91     *
92     * @param account
93     *          the account
94     */
95    void updateSignon(Account account);
96  
97  }