blob_id
stringlengths
40
40
directory_id
stringlengths
40
40
path
stringlengths
7
410
content_id
stringlengths
40
40
detected_licenses
listlengths
0
51
license_type
stringclasses
2 values
repo_name
stringlengths
5
132
snapshot_id
stringlengths
40
40
revision_id
stringlengths
40
40
branch_name
stringlengths
4
80
visit_date
timestamp[us]
revision_date
timestamp[us]
committer_date
timestamp[us]
github_id
int64
5.85k
684M
star_events_count
int64
0
209k
fork_events_count
int64
0
110k
gha_license_id
stringclasses
22 values
gha_event_created_at
timestamp[us]
gha_created_at
timestamp[us]
gha_language
stringclasses
132 values
src_encoding
stringclasses
34 values
language
stringclasses
1 value
is_vendor
bool
1 class
is_generated
bool
2 classes
length_bytes
int64
3
9.45M
extension
stringclasses
28 values
content
stringlengths
3
9.45M
authors
listlengths
1
1
author_id
stringlengths
0
352
d6885be8766e9bb674d5ea1fe2f9bcf31a6b6f18
d51db8ba03d1438fbfa80879186f2ea998ed3dcb
/forum/src/main/java/com/example/demo/service/imp/UserServiceImp.java
d51ea2dde8b3d6cdb1a1bded01cd27e3903e7826
[]
no_license
yangdongchao/springboot
f9bdc780a71deb460f49e451cb6363535a086c8d
164b97e045e59089c8d83bc14f5dc436b6b24802
refs/heads/master
2021-11-26T22:23:53.849169
2021-11-21T15:11:07
2021-11-21T15:11:07
172,504,864
10
5
null
2020-04-19T10:26:09
2019-02-25T12:48:53
JavaScript
UTF-8
Java
false
false
5,293
java
package com.example.demo.service.imp; import com.example.demo.dao.LoginLogDao; import com.example.demo.dao.UserDao; import com.example.demo.domain.LoginLog; import com.example.demo.domain.User; import com.example.demo.service.UserService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.data.domain.Page; import org.springframework.data.domain.PageRequest; import org.springframework.data.domain.Sort; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; import java.util.Date; import java.util.List; /** * @ClassName UserService * @Description TODO * @Auther ydc * @Date 2019/1/7 20:27 * @Version 1.0 **/ @Transactional @Service public class UserServiceImp implements UserService { private UserDao userDao; private LoginLogDao loginLogDao; /** * 重置密码 * @param id * @param newPassword */ @Override public void resetPassword(String newPassword,int id) { userDao.updatePasswordById(newPassword,id); } @Override public User getUserById(int id) { return userDao.findByUserId(id); } @Override public User getUserByName(String name) { return userDao.findByUserName(name); } @Override public List<User> getUsersByName(String name) { name = "%"+name+"%"; //通过设置占位符实现模糊查询 return userDao.findByUserNameLike(name); } /** * 根据用户id从小到大进行分页 * @param pageNum * @param pageSize * @return */ @Override public Page<User> getUserPage(int pageNum, int pageSize) { PageRequest pageable = new PageRequest(pageNum-1,pageSize,Sort.Direction.ASC,"userId"); return userDao.findAll(pageable); } /** * 按名字进行模糊查询,并分页 * @param name * @param pageNum * @param pageSize * @return */ @Override public Page<User> getUserPageByName(String name, int pageNum, int pageSize) { name = "%"+name+"%"; PageRequest pageable = PageRequest.of(pageNum,pageSize,Sort.by(Sort.Direction.DESC,"userId")); return userDao.findByUserNameLike(name,pageable); } /** * 重置用户年级,学院等 * @param academy * @param id */ @Override public void resetUserAcademy(String academy, int id) { userDao.updateUserGradeById(academy,id); userDao.flush(); } @Override public void resetUserGrade(String grade, int id) { userDao.updateUserGradeById(grade,id); userDao.flush(); } @Override public User getUserByEmail(String email) { return userDao.findByEmail(email); } /** * 修改用户类型 * @param type * @param id */ @Override public void resetUserType(int type, int id) { userDao.updateUserTypeById(type,id); userDao.flush(); } /** * 更新头像地址 * @param photo * @param id */ @Override public void updateUserPhoto(String photo, int id) { userDao.updateUserPhoto(photo,id); } /** * 重置用户锁定状态 * @param sta * @param id */ @Override public void restUserLock(int sta, int id) { userDao.updateUserLockedById(sta,id); userDao.flush(); } @Override public void updateCredits(int credit, int id) { userDao.updateUserCreditById(credit,id); userDao.flush(); } @Override public void updateUserSignature(String signature, int id) { userDao.updateUserSignature(signature,id); userDao.flush(); } /** * 更新用户名 * @param name * @param id */ @Override public void updateUserName(String name, int id) { userDao.updateUserName(name,id); userDao.flush(); } @Override public void loginSuccess(User user) { LoginLog loginLog = new LoginLog(user.getUserId(),user.getLastIp(),new Date()); System.out.println(loginLog); loginLogDao.save(loginLog);//先保存登录日志 updateCredits(user.getCredits()+5,user.getUserId()); } @Override public void updateUserValidCode(String validCode, int userId) { userDao.updateUserValidCode(validCode,userId); } /** * 更新用户背景图像地址 * @param bg * @param userId */ @Override public void updateUserBg(String bg, int userId) { userDao.updateUserBg(bg,userId); } /** * 存储user * @param user */ @Override public void saveUser(User user) { userDao.save(user); } @Override public List<User> getUsersByUserName(String name) { name="%"+name+"%"; return userDao.findByUserNameLike(name); } @Autowired public void setUserDao(UserDao userDao) { this.userDao = userDao; } @Autowired public void setLoginLogDao(LoginLogDao loginLogDao) { this.loginLogDao = loginLogDao; } }
[ "15087581161@163.com" ]
15087581161@163.com
9fec2ca9b33992a527d7df9db938538b589ae23d
4d023ba7ed5445b0994b5ca37ef0096ab9a715a8
/src/main/java/au/usyd/elec5619/service/Organization_edit.java
651bab3afcabd0c644e868f76d489128de1ebf49
[]
no_license
CrystalGuo0312/volunteer_time
15223f36cdcc4e2b843db79d8d1a2b389eba1206
7b4592373b0db11fcc315fac8533a0a6aa7a8a40
refs/heads/master
2020-04-12T07:47:02.957868
2018-12-19T12:15:33
2018-12-19T12:15:33
162,370,383
0
0
null
null
null
null
UTF-8
Java
false
false
804
java
package au.usyd.elec5619.service; import java.io.Serializable; import java.util.List; import au.usyd.elec5619.domain.Event; import au.usyd.elec5619.domain.Organization; import au.usyd.elec5619.domain.Volunteer; import au.usyd.elec5619.domain.Volunteer_einfo; import au.usyd.elec5619.domain.Volunteer_event; public interface Organization_edit extends Serializable{ public Event findById_event(String id); public Organization findById_organization(String id); public Volunteer findById_v(String id); public Volunteer_event findbyVeid(String id); public String updateEvent(Event event); public String updateve(Volunteer_event ve); public List<Event> search_event(String cevent,String id) throws Exception; public List<Volunteer_einfo> search_v(String cevent) throws Exception; }
[ "xguo0887@uni.sydney.edu.au" ]
xguo0887@uni.sydney.edu.au
567acd624b7500b30d7a84bcadf2b38cca9eaea8
f929b1799ae325c4c6d4f41f84e5180f771899e2
/his-system/src/main/java/com/sdzy/his/system/util/RedisUtil.java
ff2895c409b46353ca2ff5f9829b25bd166735b9
[]
no_license
mamaoqing/his
1952b2faf7325c2f8474bc5c3400c57009684820
345dd5ff682eb67b08d619c48390412c820bcb74
refs/heads/master
2023-01-22T18:37:55.723077
2020-12-08T09:36:41
2020-12-08T09:36:41
319,255,174
0
0
null
null
null
null
UTF-8
Java
false
false
1,374
java
package com.sdzy.his.system.util; import com.alibaba.fastjson.JSON; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.data.redis.core.RedisTemplate; import org.springframework.stereotype.Component; import java.util.concurrent.TimeUnit; /** * @program: wygl * @description: redis工具类 * @author: cfy * @create: 2020-07-28 11:18 **/ @Component public class RedisUtil { @Autowired private RedisTemplate<String,Object> redisTemplate; //设置key-value public void set(String key,Object value){ String valueString = JSON.toJSONString(value); redisTemplate.opsForValue().set(key,valueString); } //设置key-value 加时长 public void set(String key,Object value,int seconds){ redisTemplate.opsForValue().set(key,value,seconds, TimeUnit.SECONDS); } //设置key-value 加时长 public void set(String key,Object value,int seconds,TimeUnit tm){ redisTemplate.opsForValue().set(key,value,seconds, tm); } //获取value public Object get(String key){ return redisTemplate.opsForValue().get(key); } //获取value转对象 public Boolean delete(String key){ return redisTemplate.delete(key); } public void expire(String key,int seconds) { redisTemplate.expire(key,seconds,TimeUnit.SECONDS); } }
[ "luyuna1121@163.com" ]
luyuna1121@163.com
8011595f8e8f81b031633f01bc8a32f4d651f3b2
751974f467edd15a620637fe50a3bc83b94d5559
/Ristorante - Server/src/BarServer.java
11b760c882a92d8eab2f977d8640f9ad2b4b8e55
[]
no_license
M0nk3yH4cks/Java
4f1e0cc9be48ee14738eb154c922ee2478530420
1366b478242d5d89564bd918ac21cd171e576503
refs/heads/master
2021-05-12T10:47:44.193332
2018-02-07T11:00:07
2018-02-07T11:00:07
117,361,018
0
0
null
null
null
null
UTF-8
Java
false
false
2,419
java
import java.io.*; import java.net.Socket; import java.util.ArrayList; import java.util.Collections; import java.util.List; public class BarServer implements Runnable{ InputStream is = null; OutputStream os = null; InputStreamReader isr = null; BufferedReader br = null; PrintWriter pw = null; boolean isDone = false; Socket sInThread = null; private final Bar bar; public BarServer(Socket sxxx, Bar bar) { this.sInThread = sxxx; this.bar = bar; } @Override public void run() { if (sInThread.isConnected()) { System.out.println("Nuovo Client Connesso"); } System.out.println("Entered"); try { is = sInThread.getInputStream(); DataOutputStream outToClient = new DataOutputStream(sInThread.getOutputStream()); BufferedReader inFromClient = new BufferedReader(new InputStreamReader(sInThread.getInputStream())); String input = String.valueOf(inFromClient.readLine()).trim(); if(input.equals("req")){ System.out.println("Client Bar Connesso...<<<"); if(bar.get_order() != -1) { System.out.println("Fornendo Dati:\nOrdine : " + bar.get_order() + "\nLista: " + bar.getProdottiDisponibili()); outToClient.writeBytes(bar.get_order() + "," + bar.getProdottiDisponibili() + "\n"); System.out.println(">>>Soddifatta Richieseta Client Bar..."); bar.set_order(-1); } }else { System.out.println("Client Tablet Connesso <<<"); String[] splittedInput = input.split(","); System.err.println(input); int _order = Integer.valueOf(splittedInput[0]); bar.set_order(_order); bar.setProdottiDisponibili(splittedInput[1]); System.out.println("Operazioni Completate\nFile Inviati : " + _order + " || " + splittedInput[1]); outToClient.writeBytes("Operation Completed" + "\n"); } outToClient.flush(); } catch (IOException e) { e.printStackTrace(); } } }
[ "una-ciola@hotmail.it" ]
una-ciola@hotmail.it
8a90859483ddc26680511f78f076a2999fd879e8
35029f02d7573415d6fc558cfeeb19c7bfa1e3cc
/gs-accessing-data-jpa-complete/src/main/java/hello/service/CustomerService1446.java
33f7755f708b30c28bc3c3b4e748475a12cf0d55
[]
no_license
MirekSz/spring-boot-slow-startup
e06fe9d4f3831ee1e79cf3735f6ceb8c50340cbe
3b1e9e4ebd4a95218b142b7eb397d0eaa309e771
refs/heads/master
2021-06-25T22:50:21.329236
2017-02-19T19:08:24
2017-02-19T19:08:24
59,591,530
0
2
null
null
null
null
UTF-8
Java
false
false
119
java
package hello.service; import org.springframework.stereotype.Service; @Service public class CustomerService1446 { }
[ "miro1994" ]
miro1994
6be50e63ca63887402faaf95f9fe45c5a80c4e2f
ac176de6994c6c379d26982ba687885ade92adca
/app/build/generated/not_namespaced_r_class_sources/debug/processDebugResources/r/com/github/rtoshiro/mflibrary/R.java
679b60a393087561ef48d196788577269e83898d
[]
no_license
LucasRangelSSouza/AreaAzul
d4dacb82b4eeeb870dacdff2d4b3a3d216d255b4
7cf054283e82f48cd7a3a938f99858f7516c3f98
refs/heads/main
2023-01-02T16:59:47.669135
2020-10-17T17:06:08
2020-10-17T17:06:08
304,910,450
0
0
null
null
null
null
UTF-8
Java
false
false
83,896
java
/* AUTO-GENERATED FILE. DO NOT MODIFY. * * This class was automatically generated by the * gradle plugin from the resource data it found. It * should not be modified by hand. */ package com.github.rtoshiro.mflibrary; public final class R { private R() {} public static final class anim { private anim() {} public static final int abc_fade_in = 0x7f010000; public static final int abc_fade_out = 0x7f010001; public static final int abc_grow_fade_in_from_bottom = 0x7f010002; public static final int abc_popup_enter = 0x7f010003; public static final int abc_popup_exit = 0x7f010004; public static final int abc_shrink_fade_out_from_bottom = 0x7f010005; public static final int abc_slide_in_bottom = 0x7f010006; public static final int abc_slide_in_top = 0x7f010007; public static final int abc_slide_out_bottom = 0x7f010008; public static final int abc_slide_out_top = 0x7f010009; } public static final class attr { private attr() {} public static final int actionBarDivider = 0x7f040000; public static final int actionBarItemBackground = 0x7f040001; public static final int actionBarPopupTheme = 0x7f040002; public static final int actionBarSize = 0x7f040003; public static final int actionBarSplitStyle = 0x7f040004; public static final int actionBarStyle = 0x7f040005; public static final int actionBarTabBarStyle = 0x7f040006; public static final int actionBarTabStyle = 0x7f040007; public static final int actionBarTabTextStyle = 0x7f040008; public static final int actionBarTheme = 0x7f040009; public static final int actionBarWidgetTheme = 0x7f04000a; public static final int actionButtonStyle = 0x7f04000b; public static final int actionDropDownStyle = 0x7f04000c; public static final int actionLayout = 0x7f04000d; public static final int actionMenuTextAppearance = 0x7f04000e; public static final int actionMenuTextColor = 0x7f04000f; public static final int actionModeBackground = 0x7f040010; public static final int actionModeCloseButtonStyle = 0x7f040011; public static final int actionModeCloseDrawable = 0x7f040012; public static final int actionModeCopyDrawable = 0x7f040013; public static final int actionModeCutDrawable = 0x7f040014; public static final int actionModeFindDrawable = 0x7f040015; public static final int actionModePasteDrawable = 0x7f040016; public static final int actionModePopupWindowStyle = 0x7f040017; public static final int actionModeSelectAllDrawable = 0x7f040018; public static final int actionModeShareDrawable = 0x7f040019; public static final int actionModeSplitBackground = 0x7f04001a; public static final int actionModeStyle = 0x7f04001b; public static final int actionModeWebSearchDrawable = 0x7f04001c; public static final int actionOverflowButtonStyle = 0x7f04001d; public static final int actionOverflowMenuStyle = 0x7f04001e; public static final int actionProviderClass = 0x7f04001f; public static final int actionViewClass = 0x7f040020; public static final int activityChooserViewStyle = 0x7f040021; public static final int alertDialogButtonGroupStyle = 0x7f040022; public static final int alertDialogCenterButtons = 0x7f040023; public static final int alertDialogStyle = 0x7f040024; public static final int alertDialogTheme = 0x7f040025; public static final int allowStacking = 0x7f040026; public static final int arrowHeadLength = 0x7f04002a; public static final int arrowShaftLength = 0x7f04002b; public static final int autoCompleteTextViewStyle = 0x7f04002c; public static final int background = 0x7f040032; public static final int backgroundSplit = 0x7f040033; public static final int backgroundStacked = 0x7f040034; public static final int backgroundTint = 0x7f040035; public static final int backgroundTintMode = 0x7f040036; public static final int barLength = 0x7f040037; public static final int borderlessButtonStyle = 0x7f040041; public static final int buttonBarButtonStyle = 0x7f04004f; public static final int buttonBarNegativeButtonStyle = 0x7f040050; public static final int buttonBarNeutralButtonStyle = 0x7f040051; public static final int buttonBarPositiveButtonStyle = 0x7f040052; public static final int buttonBarStyle = 0x7f040053; public static final int buttonPanelSideLayout = 0x7f040056; public static final int buttonStyle = 0x7f040058; public static final int buttonStyleSmall = 0x7f040059; public static final int buttonTint = 0x7f04005a; public static final int buttonTintMode = 0x7f04005b; public static final int checkboxStyle = 0x7f04006b; public static final int checkedTextViewStyle = 0x7f040070; public static final int closeIcon = 0x7f040084; public static final int closeItemLayout = 0x7f04008b; public static final int collapseContentDescription = 0x7f04008c; public static final int collapseIcon = 0x7f04008d; public static final int color = 0x7f040090; public static final int colorAccent = 0x7f040091; public static final int colorButtonNormal = 0x7f040093; public static final int colorControlActivated = 0x7f040094; public static final int colorControlHighlight = 0x7f040095; public static final int colorControlNormal = 0x7f040096; public static final int colorPrimary = 0x7f040098; public static final int colorPrimaryDark = 0x7f040099; public static final int colorSwitchThumbNormal = 0x7f04009c; public static final int commitIcon = 0x7f04009d; public static final int contentInsetEnd = 0x7f0400a2; public static final int contentInsetLeft = 0x7f0400a4; public static final int contentInsetRight = 0x7f0400a5; public static final int contentInsetStart = 0x7f0400a6; public static final int controlBackground = 0x7f0400ae; public static final int customNavigationLayout = 0x7f0400b5; public static final int defaultQueryHint = 0x7f0400b6; public static final int dialogPreferredPadding = 0x7f0400b8; public static final int dialogTheme = 0x7f0400b9; public static final int displayOptions = 0x7f0400ba; public static final int divider = 0x7f0400bb; public static final int dividerHorizontal = 0x7f0400bc; public static final int dividerPadding = 0x7f0400bd; public static final int dividerVertical = 0x7f0400be; public static final int drawableSize = 0x7f0400bf; public static final int drawerArrowStyle = 0x7f0400c0; public static final int dropDownListViewStyle = 0x7f0400c1; public static final int dropdownListPreferredItemHeight = 0x7f0400c2; public static final int editTextBackground = 0x7f0400c3; public static final int editTextColor = 0x7f0400c4; public static final int editTextStyle = 0x7f0400c5; public static final int elevation = 0x7f0400c6; public static final int expandActivityOverflowButtonDrawable = 0x7f0400cc; public static final int gapBetweenBars = 0x7f0400ee; public static final int goIcon = 0x7f0400ef; public static final int height = 0x7f0400f1; public static final int hideOnContentScroll = 0x7f0400f6; public static final int homeAsUpIndicator = 0x7f0400fb; public static final int homeLayout = 0x7f0400fc; public static final int icon = 0x7f0400fe; public static final int iconifiedByDefault = 0x7f040106; public static final int imageButtonStyle = 0x7f040109; public static final int indeterminateProgressStyle = 0x7f04010a; public static final int initialActivityCount = 0x7f04010b; public static final int isLightTheme = 0x7f04010d; public static final int itemPadding = 0x7f040114; public static final int layout = 0x7f040121; public static final int listChoiceBackgroundIndicator = 0x7f040162; public static final int listDividerAlertDialog = 0x7f040163; public static final int listItemLayout = 0x7f040164; public static final int listLayout = 0x7f040165; public static final int listPopupWindowStyle = 0x7f040167; public static final int listPreferredItemHeight = 0x7f040168; public static final int listPreferredItemHeightLarge = 0x7f040169; public static final int listPreferredItemHeightSmall = 0x7f04016a; public static final int listPreferredItemPaddingLeft = 0x7f04016b; public static final int listPreferredItemPaddingRight = 0x7f04016c; public static final int logo = 0x7f04016e; public static final int logoDescription = 0x7f04016f; public static final int maxButtonHeight = 0x7f040174; public static final int measureWithLargestChild = 0x7f040176; public static final int multiChoiceItemLayout = 0x7f040178; public static final int navigationContentDescription = 0x7f040179; public static final int navigationIcon = 0x7f04017a; public static final int navigationMode = 0x7f04017b; public static final int overlapAnchor = 0x7f04017e; public static final int paddingEnd = 0x7f040180; public static final int paddingStart = 0x7f040181; public static final int panelBackground = 0x7f040183; public static final int panelMenuListTheme = 0x7f040184; public static final int panelMenuListWidth = 0x7f040185; public static final int popupMenuStyle = 0x7f04018b; public static final int popupTheme = 0x7f04018c; public static final int popupWindowStyle = 0x7f04018d; public static final int preserveIconSpacing = 0x7f04018e; public static final int progressBarPadding = 0x7f040190; public static final int progressBarStyle = 0x7f040191; public static final int queryBackground = 0x7f040192; public static final int queryHint = 0x7f040193; public static final int radioButtonStyle = 0x7f040194; public static final int ratingBarStyle = 0x7f040195; public static final int searchHintIcon = 0x7f04019e; public static final int searchIcon = 0x7f04019f; public static final int searchViewStyle = 0x7f0401a0; public static final int seekBarStyle = 0x7f0401a1; public static final int selectableItemBackground = 0x7f0401a2; public static final int selectableItemBackgroundBorderless = 0x7f0401a3; public static final int showAsAction = 0x7f0401a4; public static final int showDividers = 0x7f0401a5; public static final int showText = 0x7f0401a7; public static final int singleChoiceItemLayout = 0x7f0401a9; public static final int spinBars = 0x7f0401af; public static final int spinnerDropDownItemStyle = 0x7f0401b0; public static final int spinnerStyle = 0x7f0401b1; public static final int splitTrack = 0x7f0401b2; public static final int state_above_anchor = 0x7f0401b5; public static final int submitBackground = 0x7f0401bf; public static final int subtitle = 0x7f0401c0; public static final int subtitleTextAppearance = 0x7f0401c1; public static final int subtitleTextColor = 0x7f0401c2; public static final int subtitleTextStyle = 0x7f0401c3; public static final int suggestionRowLayout = 0x7f0401c4; public static final int switchMinWidth = 0x7f0401c5; public static final int switchPadding = 0x7f0401c6; public static final int switchStyle = 0x7f0401c7; public static final int switchTextAppearance = 0x7f0401c8; public static final int textAllCaps = 0x7f0401e3; public static final int textAppearanceLargePopupMenu = 0x7f0401ee; public static final int textAppearanceListItem = 0x7f0401ef; public static final int textAppearanceListItemSmall = 0x7f0401f1; public static final int textAppearanceSearchResultSubtitle = 0x7f0401f4; public static final int textAppearanceSearchResultTitle = 0x7f0401f5; public static final int textAppearanceSmallPopupMenu = 0x7f0401f6; public static final int textColorAlertDialogListItem = 0x7f0401f9; public static final int textColorSearchUrl = 0x7f0401fa; public static final int theme = 0x7f0401fe; public static final int thickness = 0x7f0401ff; public static final int thumbTextPadding = 0x7f040200; public static final int title = 0x7f040208; public static final int titleMarginBottom = 0x7f04020b; public static final int titleMarginEnd = 0x7f04020c; public static final int titleMarginStart = 0x7f04020d; public static final int titleMarginTop = 0x7f04020e; public static final int titleMargins = 0x7f04020f; public static final int titleTextAppearance = 0x7f040210; public static final int titleTextColor = 0x7f040211; public static final int titleTextStyle = 0x7f040212; public static final int toolbarNavigationButtonStyle = 0x7f040214; public static final int toolbarStyle = 0x7f040215; public static final int track = 0x7f040219; public static final int voiceIcon = 0x7f040228; public static final int windowActionBar = 0x7f040229; public static final int windowActionBarOverlay = 0x7f04022a; public static final int windowActionModeOverlay = 0x7f04022b; public static final int windowFixedHeightMajor = 0x7f04022c; public static final int windowFixedHeightMinor = 0x7f04022d; public static final int windowFixedWidthMajor = 0x7f04022e; public static final int windowFixedWidthMinor = 0x7f04022f; public static final int windowMinWidthMajor = 0x7f040230; public static final int windowMinWidthMinor = 0x7f040231; public static final int windowNoTitle = 0x7f040232; } public static final class bool { private bool() {} public static final int abc_action_bar_embed_tabs = 0x7f050000; public static final int abc_allow_stacked_button_bar = 0x7f050001; public static final int abc_config_actionMenuItemAllCaps = 0x7f050002; } public static final class color { private color() {} public static final int abc_background_cache_hint_selector_material_dark = 0x7f060000; public static final int abc_background_cache_hint_selector_material_light = 0x7f060001; public static final int abc_color_highlight_material = 0x7f060004; public static final int abc_input_method_navigation_guard = 0x7f060007; public static final int abc_primary_text_disable_only_material_dark = 0x7f060008; public static final int abc_primary_text_disable_only_material_light = 0x7f060009; public static final int abc_primary_text_material_dark = 0x7f06000a; public static final int abc_primary_text_material_light = 0x7f06000b; public static final int abc_search_url_text = 0x7f06000c; public static final int abc_search_url_text_normal = 0x7f06000d; public static final int abc_search_url_text_pressed = 0x7f06000e; public static final int abc_search_url_text_selected = 0x7f06000f; public static final int abc_secondary_text_material_dark = 0x7f060010; public static final int abc_secondary_text_material_light = 0x7f060011; public static final int accent_material_dark = 0x7f060018; public static final int accent_material_light = 0x7f060019; public static final int background_floating_material_dark = 0x7f06001a; public static final int background_floating_material_light = 0x7f06001b; public static final int background_material_dark = 0x7f06001c; public static final int background_material_light = 0x7f06001d; public static final int bright_foreground_disabled_material_dark = 0x7f06001e; public static final int bright_foreground_disabled_material_light = 0x7f06001f; public static final int bright_foreground_inverse_material_dark = 0x7f060020; public static final int bright_foreground_inverse_material_light = 0x7f060021; public static final int bright_foreground_material_dark = 0x7f060022; public static final int bright_foreground_material_light = 0x7f060023; public static final int button_material_dark = 0x7f060024; public static final int button_material_light = 0x7f060025; public static final int dim_foreground_disabled_material_dark = 0x7f060045; public static final int dim_foreground_disabled_material_light = 0x7f060046; public static final int dim_foreground_material_dark = 0x7f060047; public static final int dim_foreground_material_light = 0x7f060048; public static final int foreground_material_dark = 0x7f06004b; public static final int foreground_material_light = 0x7f06004c; public static final int highlighted_text_material_dark = 0x7f06004d; public static final int highlighted_text_material_light = 0x7f06004e; public static final int material_blue_grey_800 = 0x7f060050; public static final int material_blue_grey_900 = 0x7f060051; public static final int material_blue_grey_950 = 0x7f060052; public static final int material_deep_teal_200 = 0x7f060053; public static final int material_deep_teal_500 = 0x7f060054; public static final int material_grey_100 = 0x7f060055; public static final int material_grey_300 = 0x7f060056; public static final int material_grey_50 = 0x7f060057; public static final int material_grey_600 = 0x7f060058; public static final int material_grey_800 = 0x7f060059; public static final int material_grey_850 = 0x7f06005a; public static final int material_grey_900 = 0x7f06005b; public static final int primary_dark_material_dark = 0x7f060079; public static final int primary_dark_material_light = 0x7f06007a; public static final int primary_material_dark = 0x7f06007b; public static final int primary_material_light = 0x7f06007c; public static final int primary_text_default_material_dark = 0x7f06007d; public static final int primary_text_default_material_light = 0x7f06007e; public static final int primary_text_disabled_material_dark = 0x7f06007f; public static final int primary_text_disabled_material_light = 0x7f060080; public static final int ripple_material_dark = 0x7f060081; public static final int ripple_material_light = 0x7f060082; public static final int secondary_text_default_material_dark = 0x7f060083; public static final int secondary_text_default_material_light = 0x7f060084; public static final int secondary_text_disabled_material_dark = 0x7f060085; public static final int secondary_text_disabled_material_light = 0x7f060086; public static final int switch_thumb_disabled_material_dark = 0x7f060087; public static final int switch_thumb_disabled_material_light = 0x7f060088; public static final int switch_thumb_material_dark = 0x7f060089; public static final int switch_thumb_material_light = 0x7f06008a; public static final int switch_thumb_normal_material_dark = 0x7f06008b; public static final int switch_thumb_normal_material_light = 0x7f06008c; } public static final class dimen { private dimen() {} public static final int abc_action_bar_content_inset_material = 0x7f070000; public static final int abc_action_bar_default_height_material = 0x7f070002; public static final int abc_action_bar_default_padding_end_material = 0x7f070003; public static final int abc_action_bar_default_padding_start_material = 0x7f070004; public static final int abc_action_bar_icon_vertical_padding_material = 0x7f070006; public static final int abc_action_bar_overflow_padding_end_material = 0x7f070007; public static final int abc_action_bar_overflow_padding_start_material = 0x7f070008; public static final int abc_action_bar_stacked_max_height = 0x7f070009; public static final int abc_action_bar_stacked_tab_max_width = 0x7f07000a; public static final int abc_action_bar_subtitle_bottom_margin_material = 0x7f07000b; public static final int abc_action_bar_subtitle_top_margin_material = 0x7f07000c; public static final int abc_action_button_min_height_material = 0x7f07000d; public static final int abc_action_button_min_width_material = 0x7f07000e; public static final int abc_action_button_min_width_overflow_material = 0x7f07000f; public static final int abc_alert_dialog_button_bar_height = 0x7f070010; public static final int abc_button_inset_horizontal_material = 0x7f070012; public static final int abc_button_inset_vertical_material = 0x7f070013; public static final int abc_button_padding_horizontal_material = 0x7f070014; public static final int abc_button_padding_vertical_material = 0x7f070015; public static final int abc_config_prefDialogWidth = 0x7f070017; public static final int abc_control_corner_material = 0x7f070018; public static final int abc_control_inset_material = 0x7f070019; public static final int abc_control_padding_material = 0x7f07001a; public static final int abc_dialog_fixed_height_major = 0x7f07001c; public static final int abc_dialog_fixed_height_minor = 0x7f07001d; public static final int abc_dialog_fixed_width_major = 0x7f07001e; public static final int abc_dialog_fixed_width_minor = 0x7f07001f; public static final int abc_dialog_min_width_major = 0x7f070022; public static final int abc_dialog_min_width_minor = 0x7f070023; public static final int abc_dialog_padding_material = 0x7f070024; public static final int abc_dialog_padding_top_material = 0x7f070025; public static final int abc_disabled_alpha_material_dark = 0x7f070027; public static final int abc_disabled_alpha_material_light = 0x7f070028; public static final int abc_dropdownitem_icon_width = 0x7f070029; public static final int abc_dropdownitem_text_padding_left = 0x7f07002a; public static final int abc_dropdownitem_text_padding_right = 0x7f07002b; public static final int abc_edit_text_inset_bottom_material = 0x7f07002c; public static final int abc_edit_text_inset_horizontal_material = 0x7f07002d; public static final int abc_edit_text_inset_top_material = 0x7f07002e; public static final int abc_floating_window_z = 0x7f07002f; public static final int abc_list_item_padding_horizontal_material = 0x7f070030; public static final int abc_panel_menu_list_width = 0x7f070031; public static final int abc_search_view_preferred_width = 0x7f070034; public static final int abc_seekbar_track_background_height_material = 0x7f070035; public static final int abc_seekbar_track_progress_height_material = 0x7f070036; public static final int abc_select_dialog_padding_start_material = 0x7f070037; public static final int abc_switch_padding = 0x7f070038; public static final int abc_text_size_body_1_material = 0x7f070039; public static final int abc_text_size_body_2_material = 0x7f07003a; public static final int abc_text_size_button_material = 0x7f07003b; public static final int abc_text_size_caption_material = 0x7f07003c; public static final int abc_text_size_display_1_material = 0x7f07003d; public static final int abc_text_size_display_2_material = 0x7f07003e; public static final int abc_text_size_display_3_material = 0x7f07003f; public static final int abc_text_size_display_4_material = 0x7f070040; public static final int abc_text_size_headline_material = 0x7f070041; public static final int abc_text_size_large_material = 0x7f070042; public static final int abc_text_size_medium_material = 0x7f070043; public static final int abc_text_size_menu_material = 0x7f070045; public static final int abc_text_size_small_material = 0x7f070046; public static final int abc_text_size_subhead_material = 0x7f070047; public static final int abc_text_size_subtitle_material_toolbar = 0x7f070048; public static final int abc_text_size_title_material = 0x7f070049; public static final int abc_text_size_title_material_toolbar = 0x7f07004a; public static final int disabled_alpha_material_dark = 0x7f070083; public static final int disabled_alpha_material_light = 0x7f070084; public static final int highlight_alpha_material_colored = 0x7f070089; public static final int highlight_alpha_material_dark = 0x7f07008a; public static final int highlight_alpha_material_light = 0x7f07008b; public static final int notification_large_icon_height = 0x7f0700c9; public static final int notification_large_icon_width = 0x7f0700ca; public static final int notification_subtext_size = 0x7f0700d1; } public static final class drawable { private drawable() {} public static final int abc_ab_share_pack_mtrl_alpha = 0x7f080007; public static final int abc_action_bar_item_background_material = 0x7f080008; public static final int abc_btn_borderless_material = 0x7f080009; public static final int abc_btn_check_material = 0x7f08000a; public static final int abc_btn_check_to_on_mtrl_000 = 0x7f08000b; public static final int abc_btn_check_to_on_mtrl_015 = 0x7f08000c; public static final int abc_btn_colored_material = 0x7f08000d; public static final int abc_btn_default_mtrl_shape = 0x7f08000e; public static final int abc_btn_radio_material = 0x7f08000f; public static final int abc_btn_radio_to_on_mtrl_000 = 0x7f080010; public static final int abc_btn_radio_to_on_mtrl_015 = 0x7f080011; public static final int abc_btn_switch_to_on_mtrl_00001 = 0x7f080012; public static final int abc_btn_switch_to_on_mtrl_00012 = 0x7f080013; public static final int abc_cab_background_internal_bg = 0x7f080014; public static final int abc_cab_background_top_material = 0x7f080015; public static final int abc_cab_background_top_mtrl_alpha = 0x7f080016; public static final int abc_control_background_material = 0x7f080017; public static final int abc_edit_text_material = 0x7f080019; public static final int abc_ic_commit_search_api_mtrl_alpha = 0x7f08001d; public static final int abc_ic_menu_copy_mtrl_am_alpha = 0x7f08001f; public static final int abc_ic_menu_cut_mtrl_alpha = 0x7f080020; public static final int abc_ic_menu_paste_mtrl_am_alpha = 0x7f080022; public static final int abc_ic_menu_selectall_mtrl_alpha = 0x7f080023; public static final int abc_ic_menu_share_mtrl_alpha = 0x7f080024; public static final int abc_item_background_holo_dark = 0x7f08002d; public static final int abc_item_background_holo_light = 0x7f08002e; public static final int abc_list_divider_mtrl_alpha = 0x7f080030; public static final int abc_list_focused_holo = 0x7f080031; public static final int abc_list_longpressed_holo = 0x7f080032; public static final int abc_list_pressed_holo_dark = 0x7f080033; public static final int abc_list_pressed_holo_light = 0x7f080034; public static final int abc_list_selector_background_transition_holo_dark = 0x7f080035; public static final int abc_list_selector_background_transition_holo_light = 0x7f080036; public static final int abc_list_selector_disabled_holo_dark = 0x7f080037; public static final int abc_list_selector_disabled_holo_light = 0x7f080038; public static final int abc_list_selector_holo_dark = 0x7f080039; public static final int abc_list_selector_holo_light = 0x7f08003a; public static final int abc_menu_hardkey_panel_mtrl_mult = 0x7f08003b; public static final int abc_popup_background_mtrl_mult = 0x7f08003c; public static final int abc_scrubber_control_off_mtrl_alpha = 0x7f080040; public static final int abc_scrubber_control_to_pressed_mtrl_000 = 0x7f080041; public static final int abc_scrubber_control_to_pressed_mtrl_005 = 0x7f080042; public static final int abc_scrubber_primary_mtrl_alpha = 0x7f080043; public static final int abc_scrubber_track_mtrl_alpha = 0x7f080044; public static final int abc_seekbar_thumb_material = 0x7f080045; public static final int abc_seekbar_track_material = 0x7f080047; public static final int abc_spinner_mtrl_am_alpha = 0x7f080048; public static final int abc_spinner_textfield_background_material = 0x7f080049; public static final int abc_switch_thumb_material = 0x7f08004a; public static final int abc_switch_track_mtrl_alpha = 0x7f08004b; public static final int abc_tab_indicator_material = 0x7f08004c; public static final int abc_tab_indicator_mtrl_alpha = 0x7f08004d; public static final int abc_text_cursor_material = 0x7f08004e; public static final int abc_textfield_activated_mtrl_alpha = 0x7f080055; public static final int abc_textfield_default_mtrl_alpha = 0x7f080056; public static final int abc_textfield_search_activated_mtrl_alpha = 0x7f080057; public static final int abc_textfield_search_default_mtrl_alpha = 0x7f080058; public static final int abc_textfield_search_material = 0x7f080059; public static final int notification_template_icon_bg = 0x7f080099; } public static final class id { private id() {} public static final int action0 = 0x7f0a0006; public static final int action_bar = 0x7f0a0007; public static final int action_bar_activity_content = 0x7f0a0008; public static final int action_bar_container = 0x7f0a0009; public static final int action_bar_root = 0x7f0a000a; public static final int action_bar_spinner = 0x7f0a000b; public static final int action_bar_subtitle = 0x7f0a000c; public static final int action_bar_title = 0x7f0a000d; public static final int action_context_bar = 0x7f0a000f; public static final int action_divider = 0x7f0a0010; public static final int action_menu_divider = 0x7f0a0012; public static final int action_menu_presenter = 0x7f0a0013; public static final int action_mode_bar = 0x7f0a0014; public static final int action_mode_bar_stub = 0x7f0a0015; public static final int action_mode_close_button = 0x7f0a0016; public static final int activity_chooser_view_content = 0x7f0a0019; public static final int alertTitle = 0x7f0a001d; public static final int always = 0x7f0a001f; public static final int beginning = 0x7f0a0023; public static final int buttonPanel = 0x7f0a002a; public static final int cancel_action = 0x7f0a002b; public static final int checkbox = 0x7f0a0031; public static final int chronometer = 0x7f0a0032; public static final int collapseActionView = 0x7f0a0035; public static final int contentPanel = 0x7f0a003a; public static final int custom = 0x7f0a003c; public static final int customPanel = 0x7f0a003d; public static final int decor_content_parent = 0x7f0a003f; public static final int default_activity_button = 0x7f0a0040; public static final int disableHome = 0x7f0a0048; public static final int edit_query = 0x7f0a004a; public static final int end = 0x7f0a0050; public static final int end_padder = 0x7f0a0051; public static final int expand_activities_button = 0x7f0a0055; public static final int expanded_menu = 0x7f0a0056; public static final int home = 0x7f0a0066; public static final int homeAsUp = 0x7f0a0067; public static final int icon = 0x7f0a0069; public static final int ifRoom = 0x7f0a006c; public static final int image = 0x7f0a006d; public static final int info = 0x7f0a007a; public static final int line1 = 0x7f0a0084; public static final int line3 = 0x7f0a0085; public static final int listMode = 0x7f0a0086; public static final int list_item = 0x7f0a0087; public static final int media_actions = 0x7f0a0089; public static final int middle = 0x7f0a008b; public static final int multiply = 0x7f0a008f; public static final int never = 0x7f0a0095; public static final int none = 0x7f0a0096; public static final int normal = 0x7f0a0097; public static final int parentPanel = 0x7f0a009f; public static final int progress_circular = 0x7f0a00a3; public static final int progress_horizontal = 0x7f0a00a4; public static final int radio = 0x7f0a00a5; public static final int screen = 0x7f0a00ae; public static final int scrollIndicatorDown = 0x7f0a00b0; public static final int scrollIndicatorUp = 0x7f0a00b1; public static final int scrollView = 0x7f0a00b2; public static final int search_badge = 0x7f0a00b5; public static final int search_bar = 0x7f0a00b6; public static final int search_button = 0x7f0a00b7; public static final int search_close_btn = 0x7f0a00b8; public static final int search_edit_frame = 0x7f0a00b9; public static final int search_go_btn = 0x7f0a00ba; public static final int search_mag_icon = 0x7f0a00bb; public static final int search_plate = 0x7f0a00bc; public static final int search_src_text = 0x7f0a00bd; public static final int search_voice_btn = 0x7f0a00be; public static final int select_dialog_listview = 0x7f0a00bf; public static final int shortcut = 0x7f0a00c2; public static final int showCustom = 0x7f0a00c3; public static final int showHome = 0x7f0a00c4; public static final int showTitle = 0x7f0a00c5; public static final int spacer = 0x7f0a00cb; public static final int split_action_bar = 0x7f0a00cd; public static final int src_atop = 0x7f0a00d0; public static final int src_in = 0x7f0a00d1; public static final int src_over = 0x7f0a00d2; public static final int status_bar_latest_event_content = 0x7f0a00d5; public static final int submit_area = 0x7f0a00d8; public static final int tabMode = 0x7f0a00d9; public static final int text = 0x7f0a00de; public static final int text2 = 0x7f0a00df; public static final int textSpacerNoButtons = 0x7f0a00e4; public static final int time = 0x7f0a00f2; public static final int title = 0x7f0a00f4; public static final int title_template = 0x7f0a00f6; public static final int topPanel = 0x7f0a00f9; public static final int up = 0x7f0a0106; public static final int useLogo = 0x7f0a0107; public static final int withText = 0x7f0a010b; public static final int wrap_content = 0x7f0a010d; } public static final class integer { private integer() {} public static final int abc_config_activityDefaultDur = 0x7f0b0000; public static final int abc_config_activityShortDur = 0x7f0b0001; public static final int cancel_button_image_alpha = 0x7f0b0004; public static final int status_bar_notification_info_maxnum = 0x7f0b000f; } public static final class layout { private layout() {} public static final int abc_action_bar_title_item = 0x7f0d0000; public static final int abc_action_bar_up_container = 0x7f0d0001; public static final int abc_action_menu_item_layout = 0x7f0d0002; public static final int abc_action_menu_layout = 0x7f0d0003; public static final int abc_action_mode_bar = 0x7f0d0004; public static final int abc_action_mode_close_item_material = 0x7f0d0005; public static final int abc_activity_chooser_view = 0x7f0d0006; public static final int abc_activity_chooser_view_list_item = 0x7f0d0007; public static final int abc_alert_dialog_button_bar_material = 0x7f0d0008; public static final int abc_alert_dialog_material = 0x7f0d0009; public static final int abc_dialog_title_material = 0x7f0d000c; public static final int abc_expanded_menu_layout = 0x7f0d000d; public static final int abc_list_menu_item_checkbox = 0x7f0d000e; public static final int abc_list_menu_item_icon = 0x7f0d000f; public static final int abc_list_menu_item_layout = 0x7f0d0010; public static final int abc_list_menu_item_radio = 0x7f0d0011; public static final int abc_popup_menu_item_layout = 0x7f0d0013; public static final int abc_screen_content_include = 0x7f0d0014; public static final int abc_screen_simple = 0x7f0d0015; public static final int abc_screen_simple_overlay_action_mode = 0x7f0d0016; public static final int abc_screen_toolbar = 0x7f0d0017; public static final int abc_search_dropdown_item_icons_2line = 0x7f0d0018; public static final int abc_search_view = 0x7f0d0019; public static final int abc_select_dialog_material = 0x7f0d001a; public static final int notification_media_action = 0x7f0d003a; public static final int notification_media_cancel_action = 0x7f0d003b; public static final int notification_template_big_media = 0x7f0d003c; public static final int notification_template_big_media_narrow = 0x7f0d003e; public static final int notification_template_media = 0x7f0d0043; public static final int notification_template_part_chronometer = 0x7f0d0045; public static final int notification_template_part_time = 0x7f0d0046; public static final int select_dialog_item_material = 0x7f0d0047; public static final int select_dialog_multichoice_material = 0x7f0d0048; public static final int select_dialog_singlechoice_material = 0x7f0d0049; public static final int support_simple_spinner_dropdown_item = 0x7f0d004a; } public static final class string { private string() {} public static final int abc_action_bar_home_description = 0x7f110000; public static final int abc_action_bar_up_description = 0x7f110001; public static final int abc_action_menu_overflow_description = 0x7f110002; public static final int abc_action_mode_done = 0x7f110003; public static final int abc_activity_chooser_view_see_all = 0x7f110004; public static final int abc_activitychooserview_choose_application = 0x7f110005; public static final int abc_capital_off = 0x7f110006; public static final int abc_capital_on = 0x7f110007; public static final int abc_search_hint = 0x7f11001e; public static final int abc_searchview_description_clear = 0x7f11001f; public static final int abc_searchview_description_query = 0x7f110020; public static final int abc_searchview_description_search = 0x7f110021; public static final int abc_searchview_description_submit = 0x7f110022; public static final int abc_searchview_description_voice = 0x7f110023; public static final int abc_shareactionprovider_share_with = 0x7f110024; public static final int abc_shareactionprovider_share_with_application = 0x7f110025; public static final int abc_toolbar_collapse_description = 0x7f110026; public static final int app_name = 0x7f110028; public static final int status_bar_notification_info_overflow = 0x7f110059; } public static final class style { private style() {} public static final int AlertDialog_AppCompat = 0x7f120000; public static final int AlertDialog_AppCompat_Light = 0x7f120001; public static final int Animation_AppCompat_Dialog = 0x7f120002; public static final int Animation_AppCompat_DropDownUp = 0x7f120003; public static final int Base_AlertDialog_AppCompat = 0x7f12000a; public static final int Base_AlertDialog_AppCompat_Light = 0x7f12000b; public static final int Base_Animation_AppCompat_Dialog = 0x7f12000c; public static final int Base_Animation_AppCompat_DropDownUp = 0x7f12000d; public static final int Base_DialogWindowTitleBackground_AppCompat = 0x7f120011; public static final int Base_DialogWindowTitle_AppCompat = 0x7f120010; public static final int Base_TextAppearance_AppCompat = 0x7f120012; public static final int Base_TextAppearance_AppCompat_Body1 = 0x7f120013; public static final int Base_TextAppearance_AppCompat_Body2 = 0x7f120014; public static final int Base_TextAppearance_AppCompat_Button = 0x7f120015; public static final int Base_TextAppearance_AppCompat_Caption = 0x7f120016; public static final int Base_TextAppearance_AppCompat_Display1 = 0x7f120017; public static final int Base_TextAppearance_AppCompat_Display2 = 0x7f120018; public static final int Base_TextAppearance_AppCompat_Display3 = 0x7f120019; public static final int Base_TextAppearance_AppCompat_Display4 = 0x7f12001a; public static final int Base_TextAppearance_AppCompat_Headline = 0x7f12001b; public static final int Base_TextAppearance_AppCompat_Inverse = 0x7f12001c; public static final int Base_TextAppearance_AppCompat_Large = 0x7f12001d; public static final int Base_TextAppearance_AppCompat_Large_Inverse = 0x7f12001e; public static final int Base_TextAppearance_AppCompat_Light_Widget_PopupMenu_Large = 0x7f12001f; public static final int Base_TextAppearance_AppCompat_Light_Widget_PopupMenu_Small = 0x7f120020; public static final int Base_TextAppearance_AppCompat_Medium = 0x7f120021; public static final int Base_TextAppearance_AppCompat_Medium_Inverse = 0x7f120022; public static final int Base_TextAppearance_AppCompat_Menu = 0x7f120023; public static final int Base_TextAppearance_AppCompat_SearchResult = 0x7f120024; public static final int Base_TextAppearance_AppCompat_SearchResult_Subtitle = 0x7f120025; public static final int Base_TextAppearance_AppCompat_SearchResult_Title = 0x7f120026; public static final int Base_TextAppearance_AppCompat_Small = 0x7f120027; public static final int Base_TextAppearance_AppCompat_Small_Inverse = 0x7f120028; public static final int Base_TextAppearance_AppCompat_Subhead = 0x7f120029; public static final int Base_TextAppearance_AppCompat_Subhead_Inverse = 0x7f12002a; public static final int Base_TextAppearance_AppCompat_Title = 0x7f12002b; public static final int Base_TextAppearance_AppCompat_Title_Inverse = 0x7f12002c; public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Menu = 0x7f12002e; public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Subtitle = 0x7f12002f; public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Subtitle_Inverse = 0x7f120030; public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Title = 0x7f120031; public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Title_Inverse = 0x7f120032; public static final int Base_TextAppearance_AppCompat_Widget_ActionMode_Subtitle = 0x7f120033; public static final int Base_TextAppearance_AppCompat_Widget_ActionMode_Title = 0x7f120034; public static final int Base_TextAppearance_AppCompat_Widget_Button = 0x7f120035; public static final int Base_TextAppearance_AppCompat_Widget_Button_Inverse = 0x7f120038; public static final int Base_TextAppearance_AppCompat_Widget_DropDownItem = 0x7f120039; public static final int Base_TextAppearance_AppCompat_Widget_PopupMenu_Large = 0x7f12003b; public static final int Base_TextAppearance_AppCompat_Widget_PopupMenu_Small = 0x7f12003c; public static final int Base_TextAppearance_AppCompat_Widget_Switch = 0x7f12003d; public static final int Base_TextAppearance_AppCompat_Widget_TextView_SpinnerItem = 0x7f12003e; public static final int Base_TextAppearance_Widget_AppCompat_ExpandedMenu_Item = 0x7f12003f; public static final int Base_TextAppearance_Widget_AppCompat_Toolbar_Subtitle = 0x7f120040; public static final int Base_TextAppearance_Widget_AppCompat_Toolbar_Title = 0x7f120041; public static final int Base_ThemeOverlay_AppCompat = 0x7f120061; public static final int Base_ThemeOverlay_AppCompat_ActionBar = 0x7f120062; public static final int Base_ThemeOverlay_AppCompat_Dark = 0x7f120063; public static final int Base_ThemeOverlay_AppCompat_Dark_ActionBar = 0x7f120064; public static final int Base_ThemeOverlay_AppCompat_Light = 0x7f120067; public static final int Base_Theme_AppCompat = 0x7f120042; public static final int Base_Theme_AppCompat_CompactMenu = 0x7f120043; public static final int Base_Theme_AppCompat_Dialog = 0x7f120044; public static final int Base_Theme_AppCompat_DialogWhenLarge = 0x7f120048; public static final int Base_Theme_AppCompat_Dialog_Alert = 0x7f120045; public static final int Base_Theme_AppCompat_Dialog_FixedSize = 0x7f120046; public static final int Base_Theme_AppCompat_Dialog_MinWidth = 0x7f120047; public static final int Base_Theme_AppCompat_Light = 0x7f120049; public static final int Base_Theme_AppCompat_Light_DarkActionBar = 0x7f12004a; public static final int Base_Theme_AppCompat_Light_Dialog = 0x7f12004b; public static final int Base_Theme_AppCompat_Light_DialogWhenLarge = 0x7f12004f; public static final int Base_Theme_AppCompat_Light_Dialog_Alert = 0x7f12004c; public static final int Base_Theme_AppCompat_Light_Dialog_FixedSize = 0x7f12004d; public static final int Base_Theme_AppCompat_Light_Dialog_MinWidth = 0x7f12004e; public static final int Base_V21_Theme_AppCompat = 0x7f120073; public static final int Base_V21_Theme_AppCompat_Dialog = 0x7f120074; public static final int Base_V21_Theme_AppCompat_Light = 0x7f120075; public static final int Base_V21_Theme_AppCompat_Light_Dialog = 0x7f120076; public static final int Base_V22_Theme_AppCompat = 0x7f120078; public static final int Base_V22_Theme_AppCompat_Light = 0x7f120079; public static final int Base_V23_Theme_AppCompat = 0x7f12007a; public static final int Base_V23_Theme_AppCompat_Light = 0x7f12007b; public static final int Base_V7_Theme_AppCompat = 0x7f120081; public static final int Base_V7_Theme_AppCompat_Dialog = 0x7f120082; public static final int Base_V7_Theme_AppCompat_Light = 0x7f120083; public static final int Base_V7_Theme_AppCompat_Light_Dialog = 0x7f120084; public static final int Base_V7_Widget_AppCompat_AutoCompleteTextView = 0x7f120086; public static final int Base_V7_Widget_AppCompat_EditText = 0x7f120087; public static final int Base_Widget_AppCompat_ActionBar = 0x7f120089; public static final int Base_Widget_AppCompat_ActionBar_Solid = 0x7f12008a; public static final int Base_Widget_AppCompat_ActionBar_TabBar = 0x7f12008b; public static final int Base_Widget_AppCompat_ActionBar_TabText = 0x7f12008c; public static final int Base_Widget_AppCompat_ActionBar_TabView = 0x7f12008d; public static final int Base_Widget_AppCompat_ActionButton = 0x7f12008e; public static final int Base_Widget_AppCompat_ActionButton_CloseMode = 0x7f12008f; public static final int Base_Widget_AppCompat_ActionButton_Overflow = 0x7f120090; public static final int Base_Widget_AppCompat_ActionMode = 0x7f120091; public static final int Base_Widget_AppCompat_ActivityChooserView = 0x7f120092; public static final int Base_Widget_AppCompat_AutoCompleteTextView = 0x7f120093; public static final int Base_Widget_AppCompat_Button = 0x7f120094; public static final int Base_Widget_AppCompat_ButtonBar = 0x7f12009a; public static final int Base_Widget_AppCompat_ButtonBar_AlertDialog = 0x7f12009b; public static final int Base_Widget_AppCompat_Button_Borderless = 0x7f120095; public static final int Base_Widget_AppCompat_Button_Borderless_Colored = 0x7f120096; public static final int Base_Widget_AppCompat_Button_ButtonBar_AlertDialog = 0x7f120097; public static final int Base_Widget_AppCompat_Button_Colored = 0x7f120098; public static final int Base_Widget_AppCompat_Button_Small = 0x7f120099; public static final int Base_Widget_AppCompat_CompoundButton_CheckBox = 0x7f12009c; public static final int Base_Widget_AppCompat_CompoundButton_RadioButton = 0x7f12009d; public static final int Base_Widget_AppCompat_CompoundButton_Switch = 0x7f12009e; public static final int Base_Widget_AppCompat_DrawerArrowToggle = 0x7f12009f; public static final int Base_Widget_AppCompat_DrawerArrowToggle_Common = 0x7f1200a0; public static final int Base_Widget_AppCompat_DropDownItem_Spinner = 0x7f1200a1; public static final int Base_Widget_AppCompat_EditText = 0x7f1200a2; public static final int Base_Widget_AppCompat_ImageButton = 0x7f1200a3; public static final int Base_Widget_AppCompat_Light_ActionBar = 0x7f1200a4; public static final int Base_Widget_AppCompat_Light_ActionBar_Solid = 0x7f1200a5; public static final int Base_Widget_AppCompat_Light_ActionBar_TabBar = 0x7f1200a6; public static final int Base_Widget_AppCompat_Light_ActionBar_TabText = 0x7f1200a7; public static final int Base_Widget_AppCompat_Light_ActionBar_TabText_Inverse = 0x7f1200a8; public static final int Base_Widget_AppCompat_Light_ActionBar_TabView = 0x7f1200a9; public static final int Base_Widget_AppCompat_Light_PopupMenu = 0x7f1200aa; public static final int Base_Widget_AppCompat_Light_PopupMenu_Overflow = 0x7f1200ab; public static final int Base_Widget_AppCompat_ListPopupWindow = 0x7f1200ad; public static final int Base_Widget_AppCompat_ListView = 0x7f1200ae; public static final int Base_Widget_AppCompat_ListView_DropDown = 0x7f1200af; public static final int Base_Widget_AppCompat_ListView_Menu = 0x7f1200b0; public static final int Base_Widget_AppCompat_PopupMenu = 0x7f1200b1; public static final int Base_Widget_AppCompat_PopupMenu_Overflow = 0x7f1200b2; public static final int Base_Widget_AppCompat_PopupWindow = 0x7f1200b3; public static final int Base_Widget_AppCompat_ProgressBar = 0x7f1200b4; public static final int Base_Widget_AppCompat_ProgressBar_Horizontal = 0x7f1200b5; public static final int Base_Widget_AppCompat_RatingBar = 0x7f1200b6; public static final int Base_Widget_AppCompat_SearchView = 0x7f1200b9; public static final int Base_Widget_AppCompat_SearchView_ActionBar = 0x7f1200ba; public static final int Base_Widget_AppCompat_SeekBar = 0x7f1200bb; public static final int Base_Widget_AppCompat_Spinner = 0x7f1200bd; public static final int Base_Widget_AppCompat_Spinner_Underlined = 0x7f1200be; public static final int Base_Widget_AppCompat_TextView_SpinnerItem = 0x7f1200bf; public static final int Base_Widget_AppCompat_Toolbar = 0x7f1200c0; public static final int Base_Widget_AppCompat_Toolbar_Button_Navigation = 0x7f1200c1; public static final int Platform_AppCompat = 0x7f1200c9; public static final int Platform_AppCompat_Light = 0x7f1200ca; public static final int Platform_ThemeOverlay_AppCompat = 0x7f1200cf; public static final int Platform_ThemeOverlay_AppCompat_Dark = 0x7f1200d0; public static final int Platform_ThemeOverlay_AppCompat_Light = 0x7f1200d1; public static final int Platform_Widget_AppCompat_Spinner = 0x7f1200d6; public static final int RtlOverlay_DialogWindowTitle_AppCompat = 0x7f1200d7; public static final int RtlOverlay_Widget_AppCompat_ActionBar_TitleItem = 0x7f1200d8; public static final int RtlOverlay_Widget_AppCompat_DialogTitle_Icon = 0x7f1200d9; public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem = 0x7f1200da; public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_InternalGroup = 0x7f1200db; public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_Text = 0x7f1200de; public static final int RtlOverlay_Widget_AppCompat_SearchView_MagIcon = 0x7f1200e5; public static final int RtlOverlay_Widget_AppCompat_Search_DropDown = 0x7f1200e0; public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Icon1 = 0x7f1200e1; public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Icon2 = 0x7f1200e2; public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Query = 0x7f1200e3; public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Text = 0x7f1200e4; public static final int RtlUnderlay_Widget_AppCompat_ActionButton = 0x7f1200e6; public static final int RtlUnderlay_Widget_AppCompat_ActionButton_Overflow = 0x7f1200e7; public static final int TextAppearance_AppCompat = 0x7f1200e8; public static final int TextAppearance_AppCompat_Body1 = 0x7f1200e9; public static final int TextAppearance_AppCompat_Body2 = 0x7f1200ea; public static final int TextAppearance_AppCompat_Button = 0x7f1200eb; public static final int TextAppearance_AppCompat_Caption = 0x7f1200ec; public static final int TextAppearance_AppCompat_Display1 = 0x7f1200ed; public static final int TextAppearance_AppCompat_Display2 = 0x7f1200ee; public static final int TextAppearance_AppCompat_Display3 = 0x7f1200ef; public static final int TextAppearance_AppCompat_Display4 = 0x7f1200f0; public static final int TextAppearance_AppCompat_Headline = 0x7f1200f1; public static final int TextAppearance_AppCompat_Inverse = 0x7f1200f2; public static final int TextAppearance_AppCompat_Large = 0x7f1200f3; public static final int TextAppearance_AppCompat_Large_Inverse = 0x7f1200f4; public static final int TextAppearance_AppCompat_Light_SearchResult_Subtitle = 0x7f1200f5; public static final int TextAppearance_AppCompat_Light_SearchResult_Title = 0x7f1200f6; public static final int TextAppearance_AppCompat_Light_Widget_PopupMenu_Large = 0x7f1200f7; public static final int TextAppearance_AppCompat_Light_Widget_PopupMenu_Small = 0x7f1200f8; public static final int TextAppearance_AppCompat_Medium = 0x7f1200f9; public static final int TextAppearance_AppCompat_Medium_Inverse = 0x7f1200fa; public static final int TextAppearance_AppCompat_Menu = 0x7f1200fb; public static final int TextAppearance_AppCompat_SearchResult_Subtitle = 0x7f1200fc; public static final int TextAppearance_AppCompat_SearchResult_Title = 0x7f1200fd; public static final int TextAppearance_AppCompat_Small = 0x7f1200fe; public static final int TextAppearance_AppCompat_Small_Inverse = 0x7f1200ff; public static final int TextAppearance_AppCompat_Subhead = 0x7f120100; public static final int TextAppearance_AppCompat_Subhead_Inverse = 0x7f120101; public static final int TextAppearance_AppCompat_Title = 0x7f120102; public static final int TextAppearance_AppCompat_Title_Inverse = 0x7f120103; public static final int TextAppearance_AppCompat_Widget_ActionBar_Menu = 0x7f120105; public static final int TextAppearance_AppCompat_Widget_ActionBar_Subtitle = 0x7f120106; public static final int TextAppearance_AppCompat_Widget_ActionBar_Subtitle_Inverse = 0x7f120107; public static final int TextAppearance_AppCompat_Widget_ActionBar_Title = 0x7f120108; public static final int TextAppearance_AppCompat_Widget_ActionBar_Title_Inverse = 0x7f120109; public static final int TextAppearance_AppCompat_Widget_ActionMode_Subtitle = 0x7f12010a; public static final int TextAppearance_AppCompat_Widget_ActionMode_Subtitle_Inverse = 0x7f12010b; public static final int TextAppearance_AppCompat_Widget_ActionMode_Title = 0x7f12010c; public static final int TextAppearance_AppCompat_Widget_ActionMode_Title_Inverse = 0x7f12010d; public static final int TextAppearance_AppCompat_Widget_Button = 0x7f12010e; public static final int TextAppearance_AppCompat_Widget_Button_Inverse = 0x7f120111; public static final int TextAppearance_AppCompat_Widget_DropDownItem = 0x7f120112; public static final int TextAppearance_AppCompat_Widget_PopupMenu_Large = 0x7f120114; public static final int TextAppearance_AppCompat_Widget_PopupMenu_Small = 0x7f120115; public static final int TextAppearance_AppCompat_Widget_Switch = 0x7f120116; public static final int TextAppearance_AppCompat_Widget_TextView_SpinnerItem = 0x7f120117; public static final int TextAppearance_Widget_AppCompat_ExpandedMenu_Item = 0x7f120139; public static final int TextAppearance_Widget_AppCompat_Toolbar_Subtitle = 0x7f12013a; public static final int TextAppearance_Widget_AppCompat_Toolbar_Title = 0x7f12013b; public static final int ThemeOverlay_AppCompat = 0x7f12016c; public static final int ThemeOverlay_AppCompat_ActionBar = 0x7f12016d; public static final int ThemeOverlay_AppCompat_Dark = 0x7f12016e; public static final int ThemeOverlay_AppCompat_Dark_ActionBar = 0x7f12016f; public static final int ThemeOverlay_AppCompat_Light = 0x7f120172; public static final int Theme_AppCompat = 0x7f12013c; public static final int Theme_AppCompat_CompactMenu = 0x7f12013d; public static final int Theme_AppCompat_Dialog = 0x7f120145; public static final int Theme_AppCompat_DialogWhenLarge = 0x7f120148; public static final int Theme_AppCompat_Dialog_Alert = 0x7f120146; public static final int Theme_AppCompat_Dialog_MinWidth = 0x7f120147; public static final int Theme_AppCompat_Light = 0x7f120149; public static final int Theme_AppCompat_Light_DarkActionBar = 0x7f12014a; public static final int Theme_AppCompat_Light_Dialog = 0x7f12014b; public static final int Theme_AppCompat_Light_DialogWhenLarge = 0x7f12014e; public static final int Theme_AppCompat_Light_Dialog_Alert = 0x7f12014c; public static final int Theme_AppCompat_Light_Dialog_MinWidth = 0x7f12014d; public static final int Theme_AppCompat_Light_NoActionBar = 0x7f12014f; public static final int Theme_AppCompat_NoActionBar = 0x7f120150; public static final int Widget_AppCompat_ActionBar = 0x7f12017f; public static final int Widget_AppCompat_ActionBar_Solid = 0x7f120180; public static final int Widget_AppCompat_ActionBar_TabBar = 0x7f120181; public static final int Widget_AppCompat_ActionBar_TabText = 0x7f120182; public static final int Widget_AppCompat_ActionBar_TabView = 0x7f120183; public static final int Widget_AppCompat_ActionButton = 0x7f120184; public static final int Widget_AppCompat_ActionButton_CloseMode = 0x7f120185; public static final int Widget_AppCompat_ActionButton_Overflow = 0x7f120186; public static final int Widget_AppCompat_ActionMode = 0x7f120187; public static final int Widget_AppCompat_ActivityChooserView = 0x7f120188; public static final int Widget_AppCompat_AutoCompleteTextView = 0x7f120189; public static final int Widget_AppCompat_Button = 0x7f12018a; public static final int Widget_AppCompat_ButtonBar = 0x7f120190; public static final int Widget_AppCompat_ButtonBar_AlertDialog = 0x7f120191; public static final int Widget_AppCompat_Button_Borderless = 0x7f12018b; public static final int Widget_AppCompat_Button_Borderless_Colored = 0x7f12018c; public static final int Widget_AppCompat_Button_ButtonBar_AlertDialog = 0x7f12018d; public static final int Widget_AppCompat_Button_Colored = 0x7f12018e; public static final int Widget_AppCompat_Button_Small = 0x7f12018f; public static final int Widget_AppCompat_CompoundButton_CheckBox = 0x7f120192; public static final int Widget_AppCompat_CompoundButton_RadioButton = 0x7f120193; public static final int Widget_AppCompat_CompoundButton_Switch = 0x7f120194; public static final int Widget_AppCompat_DrawerArrowToggle = 0x7f120195; public static final int Widget_AppCompat_DropDownItem_Spinner = 0x7f120196; public static final int Widget_AppCompat_EditText = 0x7f120197; public static final int Widget_AppCompat_ImageButton = 0x7f120198; public static final int Widget_AppCompat_Light_ActionBar = 0x7f120199; public static final int Widget_AppCompat_Light_ActionBar_Solid = 0x7f12019a; public static final int Widget_AppCompat_Light_ActionBar_Solid_Inverse = 0x7f12019b; public static final int Widget_AppCompat_Light_ActionBar_TabBar = 0x7f12019c; public static final int Widget_AppCompat_Light_ActionBar_TabBar_Inverse = 0x7f12019d; public static final int Widget_AppCompat_Light_ActionBar_TabText = 0x7f12019e; public static final int Widget_AppCompat_Light_ActionBar_TabText_Inverse = 0x7f12019f; public static final int Widget_AppCompat_Light_ActionBar_TabView = 0x7f1201a0; public static final int Widget_AppCompat_Light_ActionBar_TabView_Inverse = 0x7f1201a1; public static final int Widget_AppCompat_Light_ActionButton = 0x7f1201a2; public static final int Widget_AppCompat_Light_ActionButton_CloseMode = 0x7f1201a3; public static final int Widget_AppCompat_Light_ActionButton_Overflow = 0x7f1201a4; public static final int Widget_AppCompat_Light_ActionMode_Inverse = 0x7f1201a5; public static final int Widget_AppCompat_Light_ActivityChooserView = 0x7f1201a6; public static final int Widget_AppCompat_Light_AutoCompleteTextView = 0x7f1201a7; public static final int Widget_AppCompat_Light_DropDownItem_Spinner = 0x7f1201a8; public static final int Widget_AppCompat_Light_ListPopupWindow = 0x7f1201a9; public static final int Widget_AppCompat_Light_ListView_DropDown = 0x7f1201aa; public static final int Widget_AppCompat_Light_PopupMenu = 0x7f1201ab; public static final int Widget_AppCompat_Light_PopupMenu_Overflow = 0x7f1201ac; public static final int Widget_AppCompat_Light_SearchView = 0x7f1201ad; public static final int Widget_AppCompat_Light_Spinner_DropDown_ActionBar = 0x7f1201ae; public static final int Widget_AppCompat_ListPopupWindow = 0x7f1201b0; public static final int Widget_AppCompat_ListView = 0x7f1201b1; public static final int Widget_AppCompat_ListView_DropDown = 0x7f1201b2; public static final int Widget_AppCompat_ListView_Menu = 0x7f1201b3; public static final int Widget_AppCompat_PopupMenu = 0x7f1201b4; public static final int Widget_AppCompat_PopupMenu_Overflow = 0x7f1201b5; public static final int Widget_AppCompat_PopupWindow = 0x7f1201b6; public static final int Widget_AppCompat_ProgressBar = 0x7f1201b7; public static final int Widget_AppCompat_ProgressBar_Horizontal = 0x7f1201b8; public static final int Widget_AppCompat_RatingBar = 0x7f1201b9; public static final int Widget_AppCompat_SearchView = 0x7f1201bc; public static final int Widget_AppCompat_SearchView_ActionBar = 0x7f1201bd; public static final int Widget_AppCompat_SeekBar = 0x7f1201be; public static final int Widget_AppCompat_Spinner = 0x7f1201c0; public static final int Widget_AppCompat_Spinner_DropDown = 0x7f1201c1; public static final int Widget_AppCompat_Spinner_DropDown_ActionBar = 0x7f1201c2; public static final int Widget_AppCompat_Spinner_Underlined = 0x7f1201c3; public static final int Widget_AppCompat_TextView_SpinnerItem = 0x7f1201c4; public static final int Widget_AppCompat_Toolbar = 0x7f1201c5; public static final int Widget_AppCompat_Toolbar_Button_Navigation = 0x7f1201c6; } public static final class styleable { private styleable() {} public static final int[] ActionBar = { 0x7f040032, 0x7f040033, 0x7f040034, 0x7f0400a2, 0x7f0400a3, 0x7f0400a4, 0x7f0400a5, 0x7f0400a6, 0x7f0400a7, 0x7f0400b5, 0x7f0400ba, 0x7f0400bb, 0x7f0400c6, 0x7f0400f1, 0x7f0400f6, 0x7f0400fb, 0x7f0400fc, 0x7f0400fe, 0x7f04010a, 0x7f040114, 0x7f04016e, 0x7f04017b, 0x7f04018c, 0x7f040190, 0x7f040191, 0x7f0401c0, 0x7f0401c3, 0x7f040208, 0x7f040212 }; public static final int ActionBar_background = 0; public static final int ActionBar_backgroundSplit = 1; public static final int ActionBar_backgroundStacked = 2; public static final int ActionBar_contentInsetEnd = 3; public static final int ActionBar_contentInsetEndWithActions = 4; public static final int ActionBar_contentInsetLeft = 5; public static final int ActionBar_contentInsetRight = 6; public static final int ActionBar_contentInsetStart = 7; public static final int ActionBar_contentInsetStartWithNavigation = 8; public static final int ActionBar_customNavigationLayout = 9; public static final int ActionBar_displayOptions = 10; public static final int ActionBar_divider = 11; public static final int ActionBar_elevation = 12; public static final int ActionBar_height = 13; public static final int ActionBar_hideOnContentScroll = 14; public static final int ActionBar_homeAsUpIndicator = 15; public static final int ActionBar_homeLayout = 16; public static final int ActionBar_icon = 17; public static final int ActionBar_indeterminateProgressStyle = 18; public static final int ActionBar_itemPadding = 19; public static final int ActionBar_logo = 20; public static final int ActionBar_navigationMode = 21; public static final int ActionBar_popupTheme = 22; public static final int ActionBar_progressBarPadding = 23; public static final int ActionBar_progressBarStyle = 24; public static final int ActionBar_subtitle = 25; public static final int ActionBar_subtitleTextStyle = 26; public static final int ActionBar_title = 27; public static final int ActionBar_titleTextStyle = 28; public static final int[] ActionBarLayout = { 0x10100b3 }; public static final int ActionBarLayout_android_layout_gravity = 0; public static final int[] ActionMenuItemView = { 0x101013f }; public static final int ActionMenuItemView_android_minWidth = 0; public static final int[] ActionMenuView = { }; public static final int[] ActionMode = { 0x7f040032, 0x7f040033, 0x7f04008b, 0x7f0400f1, 0x7f0401c3, 0x7f040212 }; public static final int ActionMode_background = 0; public static final int ActionMode_backgroundSplit = 1; public static final int ActionMode_closeItemLayout = 2; public static final int ActionMode_height = 3; public static final int ActionMode_subtitleTextStyle = 4; public static final int ActionMode_titleTextStyle = 5; public static final int[] ActivityChooserView = { 0x7f0400cc, 0x7f04010b }; public static final int ActivityChooserView_expandActivityOverflowButtonDrawable = 0; public static final int ActivityChooserView_initialActivityCount = 1; public static final int[] AlertDialog = { 0x10100f2, 0x7f040055, 0x7f040056, 0x7f040164, 0x7f040165, 0x7f040178, 0x7f0401a8, 0x7f0401a9 }; public static final int AlertDialog_android_layout = 0; public static final int AlertDialog_buttonIconDimen = 1; public static final int AlertDialog_buttonPanelSideLayout = 2; public static final int AlertDialog_listItemLayout = 3; public static final int AlertDialog_listLayout = 4; public static final int AlertDialog_multiChoiceItemLayout = 5; public static final int AlertDialog_showTitle = 6; public static final int AlertDialog_singleChoiceItemLayout = 7; public static final int[] AppCompatTextView = { 0x1010034, 0x7f04002d, 0x7f04002e, 0x7f04002f, 0x7f040030, 0x7f040031, 0x7f0400e0, 0x7f0400e3, 0x7f04011c, 0x7f040160, 0x7f0401e3 }; public static final int AppCompatTextView_android_textAppearance = 0; public static final int AppCompatTextView_autoSizeMaxTextSize = 1; public static final int AppCompatTextView_autoSizeMinTextSize = 2; public static final int AppCompatTextView_autoSizePresetSizes = 3; public static final int AppCompatTextView_autoSizeStepGranularity = 4; public static final int AppCompatTextView_autoSizeTextType = 5; public static final int AppCompatTextView_firstBaselineToTopHeight = 6; public static final int AppCompatTextView_fontFamily = 7; public static final int AppCompatTextView_lastBaselineToBottomHeight = 8; public static final int AppCompatTextView_lineHeight = 9; public static final int AppCompatTextView_textAllCaps = 10; public static final int[] ButtonBarLayout = { 0x7f040026 }; public static final int ButtonBarLayout_allowStacking = 0; public static final int[] CompoundButton = { 0x1010107, 0x7f04005a, 0x7f04005b }; public static final int CompoundButton_android_button = 0; public static final int CompoundButton_buttonTint = 1; public static final int CompoundButton_buttonTintMode = 2; public static final int[] DrawerArrowToggle = { 0x7f04002a, 0x7f04002b, 0x7f040037, 0x7f040090, 0x7f0400bf, 0x7f0400ee, 0x7f0401af, 0x7f0401ff }; public static final int DrawerArrowToggle_arrowHeadLength = 0; public static final int DrawerArrowToggle_arrowShaftLength = 1; public static final int DrawerArrowToggle_barLength = 2; public static final int DrawerArrowToggle_color = 3; public static final int DrawerArrowToggle_drawableSize = 4; public static final int DrawerArrowToggle_gapBetweenBars = 5; public static final int DrawerArrowToggle_spinBars = 6; public static final int DrawerArrowToggle_thickness = 7; public static final int[] LinearLayoutCompat = { 0x10100af, 0x10100c4, 0x1010126, 0x1010127, 0x1010128, 0x7f0400bb, 0x7f0400bd, 0x7f040176, 0x7f0401a5 }; public static final int LinearLayoutCompat_android_gravity = 0; public static final int LinearLayoutCompat_android_orientation = 1; public static final int LinearLayoutCompat_android_baselineAligned = 2; public static final int LinearLayoutCompat_android_baselineAlignedChildIndex = 3; public static final int LinearLayoutCompat_android_weightSum = 4; public static final int LinearLayoutCompat_divider = 5; public static final int LinearLayoutCompat_dividerPadding = 6; public static final int LinearLayoutCompat_measureWithLargestChild = 7; public static final int LinearLayoutCompat_showDividers = 8; public static final int[] LinearLayoutCompat_Layout = { 0x10100b3, 0x10100f4, 0x10100f5, 0x1010181 }; public static final int LinearLayoutCompat_Layout_android_layout_gravity = 0; public static final int LinearLayoutCompat_Layout_android_layout_width = 1; public static final int LinearLayoutCompat_Layout_android_layout_height = 2; public static final int LinearLayoutCompat_Layout_android_layout_weight = 3; public static final int[] ListPopupWindow = { 0x10102ac, 0x10102ad }; public static final int ListPopupWindow_android_dropDownHorizontalOffset = 0; public static final int ListPopupWindow_android_dropDownVerticalOffset = 1; public static final int[] MenuGroup = { 0x101000e, 0x10100d0, 0x1010194, 0x10101de, 0x10101df, 0x10101e0 }; public static final int MenuGroup_android_enabled = 0; public static final int MenuGroup_android_id = 1; public static final int MenuGroup_android_visible = 2; public static final int MenuGroup_android_menuCategory = 3; public static final int MenuGroup_android_orderInCategory = 4; public static final int MenuGroup_android_checkableBehavior = 5; public static final int[] MenuItem = { 0x1010002, 0x101000e, 0x10100d0, 0x1010106, 0x1010194, 0x10101de, 0x10101df, 0x10101e1, 0x10101e2, 0x10101e3, 0x10101e4, 0x10101e5, 0x101026f, 0x7f04000d, 0x7f04001f, 0x7f040020, 0x7f040028, 0x7f0400a1, 0x7f040104, 0x7f040105, 0x7f04017d, 0x7f0401a4, 0x7f040218 }; public static final int MenuItem_android_icon = 0; public static final int MenuItem_android_enabled = 1; public static final int MenuItem_android_id = 2; public static final int MenuItem_android_checked = 3; public static final int MenuItem_android_visible = 4; public static final int MenuItem_android_menuCategory = 5; public static final int MenuItem_android_orderInCategory = 6; public static final int MenuItem_android_title = 7; public static final int MenuItem_android_titleCondensed = 8; public static final int MenuItem_android_alphabeticShortcut = 9; public static final int MenuItem_android_numericShortcut = 10; public static final int MenuItem_android_checkable = 11; public static final int MenuItem_android_onClick = 12; public static final int MenuItem_actionLayout = 13; public static final int MenuItem_actionProviderClass = 14; public static final int MenuItem_actionViewClass = 15; public static final int MenuItem_alphabeticModifiers = 16; public static final int MenuItem_contentDescription = 17; public static final int MenuItem_iconTint = 18; public static final int MenuItem_iconTintMode = 19; public static final int MenuItem_numericModifiers = 20; public static final int MenuItem_showAsAction = 21; public static final int MenuItem_tooltipText = 22; public static final int[] MenuView = { 0x10100ae, 0x101012c, 0x101012d, 0x101012e, 0x101012f, 0x1010130, 0x1010131, 0x7f04018e, 0x7f0401be }; public static final int MenuView_android_windowAnimationStyle = 0; public static final int MenuView_android_itemTextAppearance = 1; public static final int MenuView_android_horizontalDivider = 2; public static final int MenuView_android_verticalDivider = 3; public static final int MenuView_android_headerBackground = 4; public static final int MenuView_android_itemBackground = 5; public static final int MenuView_android_itemIconDisabledAlpha = 6; public static final int MenuView_preserveIconSpacing = 7; public static final int MenuView_subMenuArrow = 8; public static final int[] PopupWindow = { 0x1010176, 0x10102c9, 0x7f04017e }; public static final int PopupWindow_android_popupBackground = 0; public static final int PopupWindow_android_popupAnimationStyle = 1; public static final int PopupWindow_overlapAnchor = 2; public static final int[] PopupWindowBackgroundState = { 0x7f0401b5 }; public static final int PopupWindowBackgroundState_state_above_anchor = 0; public static final int[] SearchView = { 0x10100da, 0x101011f, 0x1010220, 0x1010264, 0x7f040084, 0x7f04009d, 0x7f0400b6, 0x7f0400ef, 0x7f040106, 0x7f040121, 0x7f040192, 0x7f040193, 0x7f04019e, 0x7f04019f, 0x7f0401bf, 0x7f0401c4, 0x7f040228 }; public static final int SearchView_android_focusable = 0; public static final int SearchView_android_maxWidth = 1; public static final int SearchView_android_inputType = 2; public static final int SearchView_android_imeOptions = 3; public static final int SearchView_closeIcon = 4; public static final int SearchView_commitIcon = 5; public static final int SearchView_defaultQueryHint = 6; public static final int SearchView_goIcon = 7; public static final int SearchView_iconifiedByDefault = 8; public static final int SearchView_layout = 9; public static final int SearchView_queryBackground = 10; public static final int SearchView_queryHint = 11; public static final int SearchView_searchHintIcon = 12; public static final int SearchView_searchIcon = 13; public static final int SearchView_submitBackground = 14; public static final int SearchView_suggestionRowLayout = 15; public static final int SearchView_voiceIcon = 16; public static final int[] Spinner = { 0x10100b2, 0x1010176, 0x101017b, 0x1010262, 0x7f04018c }; public static final int Spinner_android_entries = 0; public static final int Spinner_android_popupBackground = 1; public static final int Spinner_android_prompt = 2; public static final int Spinner_android_dropDownWidth = 3; public static final int Spinner_popupTheme = 4; public static final int[] SwitchCompat = { 0x1010124, 0x1010125, 0x1010142, 0x7f0401a7, 0x7f0401b2, 0x7f0401c5, 0x7f0401c6, 0x7f0401c8, 0x7f040200, 0x7f040201, 0x7f040202, 0x7f040219, 0x7f04021a, 0x7f04021b }; public static final int SwitchCompat_android_textOn = 0; public static final int SwitchCompat_android_textOff = 1; public static final int SwitchCompat_android_thumb = 2; public static final int SwitchCompat_showText = 3; public static final int SwitchCompat_splitTrack = 4; public static final int SwitchCompat_switchMinWidth = 5; public static final int SwitchCompat_switchPadding = 6; public static final int SwitchCompat_switchTextAppearance = 7; public static final int SwitchCompat_thumbTextPadding = 8; public static final int SwitchCompat_thumbTint = 9; public static final int SwitchCompat_thumbTintMode = 10; public static final int SwitchCompat_track = 11; public static final int SwitchCompat_trackTint = 12; public static final int SwitchCompat_trackTintMode = 13; public static final int[] TextAppearance = { 0x1010095, 0x1010096, 0x1010097, 0x1010098, 0x101009a, 0x101009b, 0x1010161, 0x1010162, 0x1010163, 0x1010164, 0x10103ac, 0x7f0400e3, 0x7f0401e3 }; public static final int TextAppearance_android_textSize = 0; public static final int TextAppearance_android_typeface = 1; public static final int TextAppearance_android_textStyle = 2; public static final int TextAppearance_android_textColor = 3; public static final int TextAppearance_android_textColorHint = 4; public static final int TextAppearance_android_textColorLink = 5; public static final int TextAppearance_android_shadowColor = 6; public static final int TextAppearance_android_shadowDx = 7; public static final int TextAppearance_android_shadowDy = 8; public static final int TextAppearance_android_shadowRadius = 9; public static final int TextAppearance_android_fontFamily = 10; public static final int TextAppearance_fontFamily = 11; public static final int TextAppearance_textAllCaps = 12; public static final int[] Toolbar = { 0x10100af, 0x1010140, 0x7f040054, 0x7f04008c, 0x7f04008d, 0x7f0400a2, 0x7f0400a3, 0x7f0400a4, 0x7f0400a5, 0x7f0400a6, 0x7f0400a7, 0x7f04016e, 0x7f04016f, 0x7f040174, 0x7f040179, 0x7f04017a, 0x7f04018c, 0x7f0401c0, 0x7f0401c1, 0x7f0401c2, 0x7f040208, 0x7f04020a, 0x7f04020b, 0x7f04020c, 0x7f04020d, 0x7f04020e, 0x7f04020f, 0x7f040210, 0x7f040211 }; public static final int Toolbar_android_gravity = 0; public static final int Toolbar_android_minHeight = 1; public static final int Toolbar_buttonGravity = 2; public static final int Toolbar_collapseContentDescription = 3; public static final int Toolbar_collapseIcon = 4; public static final int Toolbar_contentInsetEnd = 5; public static final int Toolbar_contentInsetEndWithActions = 6; public static final int Toolbar_contentInsetLeft = 7; public static final int Toolbar_contentInsetRight = 8; public static final int Toolbar_contentInsetStart = 9; public static final int Toolbar_contentInsetStartWithNavigation = 10; public static final int Toolbar_logo = 11; public static final int Toolbar_logoDescription = 12; public static final int Toolbar_maxButtonHeight = 13; public static final int Toolbar_navigationContentDescription = 14; public static final int Toolbar_navigationIcon = 15; public static final int Toolbar_popupTheme = 16; public static final int Toolbar_subtitle = 17; public static final int Toolbar_subtitleTextAppearance = 18; public static final int Toolbar_subtitleTextColor = 19; public static final int Toolbar_title = 20; public static final int Toolbar_titleMargin = 21; public static final int Toolbar_titleMarginBottom = 22; public static final int Toolbar_titleMarginEnd = 23; public static final int Toolbar_titleMarginStart = 24; public static final int Toolbar_titleMarginTop = 25; public static final int Toolbar_titleMargins = 26; public static final int Toolbar_titleTextAppearance = 27; public static final int Toolbar_titleTextColor = 28; public static final int[] View = { 0x1010000, 0x10100da, 0x7f040180, 0x7f040181, 0x7f0401fe }; public static final int View_android_theme = 0; public static final int View_android_focusable = 1; public static final int View_paddingEnd = 2; public static final int View_paddingStart = 3; public static final int View_theme = 4; public static final int[] ViewBackgroundHelper = { 0x10100d4, 0x7f040035, 0x7f040036 }; public static final int ViewBackgroundHelper_android_background = 0; public static final int ViewBackgroundHelper_backgroundTint = 1; public static final int ViewBackgroundHelper_backgroundTintMode = 2; public static final int[] ViewStubCompat = { 0x10100d0, 0x10100f2, 0x10100f3 }; public static final int ViewStubCompat_android_id = 0; public static final int ViewStubCompat_android_layout = 1; public static final int ViewStubCompat_android_inflatedId = 2; } }
[ "lucas.rangel@outlook.com" ]
lucas.rangel@outlook.com
1696d66806562ef16e40ac6ed13380d1d98ed710
d4f50156e73fd9801316577ed9fac226a231cbce
/src/com/ztspeech/simutalk2/net/VoiceDataCache.java
bbf099fb3fb9ad725b350d447ea62d21c32f7b63
[]
no_license
JayceHuang/Simutalk2
308d8dc71a4a7750cb089490f7035954eb0afe4a
ede66a5c36c9d26ebc5493583042f064b096b52e
refs/heads/master
2021-05-30T11:31:21.557702
2013-09-17T01:54:52
2013-09-17T01:54:52
12,861,166
1
0
null
null
null
null
GB18030
Java
false
false
4,640
java
package com.ztspeech.simutalk2.net; import java.io.ByteArrayOutputStream; import java.io.File; import java.io.FileInputStream; import java.io.FileOutputStream; import java.io.InputStream; import java.util.ArrayList; import cn.ac.ia.files.RequestParam; import com.ztspeech.simutalk2.dictionary.util.LogInfo; import com.ztspeech.simutalk2.dictionary.util.Util; public class VoiceDataCache { private static String cachePath = Util.VOICE_CACHE_PATH; class VoiceData { public byte[] data; public String id = ""; public byte[] getVoice(String id) { if (id == null) { return null; } if (id.equals(this.id)) { return data; } return null; } public void setData(String id, byte[] s) { this.id = id; data = s; } } @SuppressWarnings("unused") private ArrayList<VoiceData> mList = new ArrayList<VoiceData>(); private static VoiceDataCache mInstance = null; public static VoiceDataCache getInstance() { if (mInstance == null) { mInstance = new VoiceDataCache(); } return mInstance; } public void add(String id, byte[] voice, String type) { synchronized (this) { // int nSize = mList.size(); // VoiceData data = null; // if(nSize > 100) { // data = mList.remove(0); // } // else { // data = new VoiceData(); // } // data.setData(id, voice); // mList.add(data); saveVoiceData(id, voice, type); } } /** * 将语音流数据存入本地文件 * * @param id * @param voice * @return */ private boolean saveVoiceData(String id, byte[] voice, String type) { LogInfo.LogOut("haitian", "saveVoiceData>>>>>>>>>>>>>> id = " + id); if (id == null || "".equals(id.trim()) || voice.length <= 0) { return false; } FileOutputStream fileOutputStream = null; try { File dir = null; File temp = null; String fileExt = ".dat"; if (RequestParam.FILE_TYPE_VOICE.equals(type)) { cachePath = Util.VOICE_CACHE_PATH; fileExt = ".dat"; } else if (RequestParam.FILE_TYPE_PHOTO.equals(type)) { cachePath = Util.IMG_CACHE_PATH; fileExt = ".png"; } dir = new File(cachePath); if (!dir.exists()) { dir.mkdirs(); } temp = new File(cachePath + id + fileExt); if (temp.exists()) { return true; } else { temp.createNewFile(); } fileOutputStream = new FileOutputStream(temp); fileOutputStream.write(voice); fileOutputStream.flush(); return true; } catch (Exception e) { e.printStackTrace(); return false; } finally { try { if (fileOutputStream != null) { fileOutputStream.close(); fileOutputStream = null; } } catch (Exception e2) { e2.printStackTrace(); } } } private byte[] getVoiceData(String id, String type) { LogInfo.LogOut("haitian", "getVoiceData>>>>>>>>>>>>>>>>>>>>----id =" + id); if (id == null || "".equals(id.trim())) { return null; } FileInputStream fileInputStream = null; try { File dir = null; File temp = null; String fileExt = ".dat"; if (RequestParam.FILE_TYPE_VOICE.equals(type)) { cachePath = Util.VOICE_CACHE_PATH; fileExt = ".dat"; } else if (RequestParam.FILE_TYPE_PHOTO.equals(type)) { cachePath = Util.IMG_CACHE_PATH; fileExt = ".png"; } dir = new File(cachePath); if (!dir.exists()) { dir.mkdirs(); return null; } temp = new File(cachePath + id + fileExt); if (!temp.exists()) { return null; } fileInputStream = new FileInputStream(temp); return getData(fileInputStream); } catch (Exception e) { e.printStackTrace(); return null; } finally { try { if (fileInputStream != null) { fileInputStream.close(); fileInputStream = null; } } catch (Exception e2) { e2.printStackTrace(); } } } /** * 将InputStream转化为byte[] * * @param in * 输入流 * @return 数组 */ public static byte[] getData(InputStream in) { if (in == null) { return null; } ByteArrayOutputStream bs = new ByteArrayOutputStream(); byte[] b = new byte[1024]; int len = 0; try { while ((len = in.read(b, 0, b.length)) != -1) { bs.write(b, 0, len); } return bs.toByteArray(); } catch (Exception e) { e.printStackTrace(); } return null; } public byte[] findVoice(String id, String type) { byte[] data = null; synchronized (this) { // int nSize = mList.size(); // for (int i = 0; i < nSize; i++) { // VoiceData tts = mList.get(i); // data = tts.getVoice(id); // if (data != null) { // mList.remove(i); // mList.add(tts); // break; // } // } data = getVoiceData(id, type); } return data; } }
[ "3318984@qq.com" ]
3318984@qq.com
93ab12f75494b2c52202910c6c202285a2e70e45
62dd744b057eb7f34964d60dfb63e3c2145c96aa
/acmicpc/ES01966_queuePrinter.java
aae2fbce4133fb75166172860b1688f89170adba
[]
no_license
sssunny21/algorithm
892d8c1feb1d496a008c6f086d626e7389b6fa3e
8bf0ee1c14231fff35768d6395c5d51449e62d0a
refs/heads/master
2020-06-11T09:06:04.047020
2016-12-20T05:48:23
2016-12-20T05:48:23
75,703,369
2
0
null
null
null
null
UHC
Java
false
false
2,170
java
package acmicpc; import java.util.Arrays; import java.util.LinkedList; import java.util.Scanner; public class ES01966_queuePrinter { /** 같은 중요도를 가졌을 때 어떻게 하는 지 **/ /** private final static Scanner sc = new Scanner(System.in); private void solve(){ int testCase = sc.nextInt(); for (int i = 0; i < testCase; i++) { int n = sc.nextInt(); int m = sc.nextInt(); int max = -1; int search = 0; LinkedList<Integer> queue = new LinkedList<>(); for (int j = 0; j < n; j++) { queue.add(sc.nextInt()); if(max < queue.getLast()) max = queue.getLast(); } search = queue.get(m); do{ for (int j = 0; j < n; j++){ if(queue.getFirst() < queue.get(j)){ queue.add(queue.getFirst()); queue.removeFirst(); } if(queue.getFirst() == max) { searchPrint(queue,search); break; } } }while(queue.getFirst() != max); } } private void searchPrint(LinkedList<Integer> queue, int search){ for (int j = 0; j < queue.size(); j++) { if(queue.get(j) == search) System.out.println(j+1); } } **/ private final static Scanner sc = new Scanner(System.in); private void solve(){ int testcase = sc.nextInt(); for (int i = 0; i < testcase; i++) { int n = sc.nextInt(); int m = sc.nextInt(); LinkedList<Integer> queue = new LinkedList<>(); for (int j = 0; j < n; j++) { queue.add(sc.nextInt()); } Integer[] order = queue.toArray(new Integer[n]); //toArray()의 리턴타입을 Integer로 정의하기 위해 쓰는것. Arrays.sort(order); int printed = 0; while(m >= 0) { int tmp = queue.pop(); System.out.println("tmp"+tmp); if(isImportant(tmp, order, n, printed)){ printed++; }else{ queue.add(tmp); if(m == 0){ m = n - printed; } } m--; } System.out.println(printed); } } private boolean isImportant(int tmp, Integer[] order, int n, int printed) { if(tmp == order[n - printed - 1]) return true; return false; } public static void main(String[] args) { // TODO Auto-generated method stub new ES01966_queuePrinter().solve(); } }
[ "esun19@gmail.com" ]
esun19@gmail.com
9cdffc233ada2abb652f3871a522a819f0811b8c
ed5d6a81e4ef9f0efbc9e47c0fc2a33481dba1d2
/app/src/main/java/com/example/hp/assign3/RecyclerViewAdapter.java
51886692b3a934ae4cc842ab1327d45713bfb361
[]
no_license
MaryamRana789/assign3
bdfa558596ec834494bd71c0f4d09d3d93ef9664
a48bf1ef4bb0291d07fde552353dba77911dcb44
refs/heads/master
2022-11-14T06:22:46.238974
2020-06-28T19:40:34
2020-06-28T19:40:34
275,656,214
0
0
null
null
null
null
UTF-8
Java
false
false
2,463
java
package com.example.hp.assign3; import android.content.Context; import android.content.Intent; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.RelativeLayout; import android.widget.TextView; import androidx.annotation.NonNull; import androidx.recyclerview.widget.RecyclerView; import com.bumptech.glide.Glide; import java.util.ArrayList; import de.hdodenhof.circleimageview.CircleImageView; public class RecyclerViewAdapter extends RecyclerView.Adapter<RecyclerViewAdapter.MyViewHolder> { public static final String TAG ="RecyclerViewAdapter"; private ArrayList <String> mImageNames = new ArrayList<>(); private ArrayList <String> mImages = new ArrayList<>(); private Context mContext; public RecyclerViewAdapter(Contacts context, ArrayList<String> imageNames , ArrayList<String> images) { mImageNames= imageNames; mImages=images; mContext=context; } @NonNull @Override public MyViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) { View view = LayoutInflater.from(parent.getContext()).inflate(R.layout.layout_listitem,parent,false); MyViewHolder holder=new MyViewHolder(view); return holder; } @Override public void onBindViewHolder(@NonNull MyViewHolder holder,final int position) { Glide.with(mContext) .asBitmap() .load(mImages.get(position)) .into(holder.image); holder.imageName.setText(mImageNames.get(position)); holder.imageName.setText(mImageNames.get(position)); holder.parentLayout.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { Intent intent = new Intent(mContext, screen4.class); mContext.startActivity(intent); } }); } @Override public int getItemCount() { return mImageNames.size(); } public class MyViewHolder extends RecyclerView.ViewHolder{ CircleImageView image; TextView imageName; RelativeLayout parentLayout; public MyViewHolder(@NonNull View itemView) { super(itemView); image=itemView.findViewById(R.id.image); imageName=itemView.findViewById(R.id.image_name); parentLayout=itemView.findViewById(R.id.parent); } } }
[ "75mayram@gmail.com" ]
75mayram@gmail.com
8d6776e8a8eadcad2a870e5289acfaf6120d6685
01d70e14c3aee61f77a1fd1e0c86aa7b03a9bd64
/DailyAsginmentsDay4/src/Staff.java
b7a02b0015654ee8137136327f368054adcdb1d6
[]
no_license
Kaushiki99/DailyAssignmentsCapg
9fbedd07399687b03046d3c20cd68630cf0766e9
7e809b9eed55081cdfba47941ace9c1b2f7dbabe
refs/heads/main
2023-05-21T19:25:20.504427
2021-06-14T15:31:58
2021-06-14T15:31:58
368,528,482
0
0
null
null
null
null
UTF-8
Java
false
false
594
java
public class Staff extends Person{ private String school; private double pay; // Getters public String getSchool() { return school; } public double getPay() { return pay; } // Setters public void setSchool(String school) { this.school = school; } public void setPay(double pay) { this.pay = pay; } // toString public String toString() { Person p = new Person(); p.setName(this.name); p.setAddress(this.address); return "Staff," + p.toString() + " school= " + getSchool() + ", pay= " + getPay(); } }
[ "trivedi.kaushiki@gmail.com" ]
trivedi.kaushiki@gmail.com
41b8fb2fe22adb75be0d710d08abab9e34c44479
f6a89b04d81c7867ff977e332f711f75970b4689
/src/main/java/dmpApp/appBasicInfo/AppInfoHttpClient.java
4a5ab013e0d73b0e043fd527c7f4aa00768c53b2
[]
no_license
yuan-jk/spider
0da732c724114c590209442b2fc82033088c8f1c
fddf760a0420fd15eab4acfe51f0ec3b56a5713a
refs/heads/master
2022-09-08T01:34:00.924269
2017-04-10T03:33:52
2017-04-10T03:33:52
null
0
0
null
null
null
null
UTF-8
Java
false
false
12,574
java
package dmpApp.appBasicInfo; import java.io.IOException; import java.io.InterruptedIOException; import java.io.UnsupportedEncodingException; import java.net.UnknownHostException; import java.util.ArrayList; import java.util.List; import java.util.Map; import java.util.Set; import java.util.concurrent.CountDownLatch; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import javax.net.ssl.SSLException; import javax.net.ssl.SSLHandshakeException; import org.apache.http.HttpEntity; import org.apache.http.HttpEntityEnclosingRequest; import org.apache.http.HttpHost; import org.apache.http.HttpRequest; import org.apache.http.HttpResponse; import org.apache.http.NameValuePair; import org.apache.http.NoHttpResponseException; import org.apache.http.ProtocolException; import org.apache.http.client.HttpRequestRetryHandler; import org.apache.http.client.RedirectStrategy; import org.apache.http.client.config.RequestConfig; import org.apache.http.client.entity.UrlEncodedFormEntity; import org.apache.http.client.methods.CloseableHttpResponse; import org.apache.http.client.methods.HttpGet; import org.apache.http.client.methods.HttpPost; import org.apache.http.client.methods.HttpRequestBase; import org.apache.http.client.methods.HttpUriRequest; import org.apache.http.client.protocol.HttpClientContext; import org.apache.http.config.Registry; import org.apache.http.config.RegistryBuilder; import org.apache.http.conn.ConnectTimeoutException; import org.apache.http.conn.socket.ConnectionSocketFactory; import org.apache.http.conn.socket.LayeredConnectionSocketFactory; import org.apache.http.conn.socket.PlainConnectionSocketFactory; import org.apache.http.conn.ssl.SSLConnectionSocketFactory; import org.apache.http.impl.client.CloseableHttpClient; import org.apache.http.impl.client.HttpClients; import org.apache.http.impl.conn.PoolingHttpClientConnectionManager; import org.apache.http.message.BasicNameValuePair; import org.apache.http.protocol.HttpContext; import org.apache.http.util.EntityUtils; import org.apache.log4j.Logger; /** * HttpClient工具类 * * @return */ public class AppInfoHttpClient { static final int timeOut = 2 * 15 * 1000; private static String ip = ""; private static int port = 0; private static CloseableHttpClient httpClient = null; private final static Object syncLock = new Object(); public static Logger logger = Logger.getLogger(AppInfoHttpClient.class); private static void config(HttpRequestBase httpRequestBase) { // 设置Header等 httpRequestBase.setHeader("User-Agent", "Mozilla/5.0"); // httpRequestBase.setHeader("Accept", "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"); // httpRequestBase.setHeader("Accept-Language", "zh-CN,zh;q=0.8,en-US;q=0.5,en;q=0.3");// "en-US,en;q=0.5"); // httpRequestBase.setHeader("Accept-Charset", "ISO-8859-1,utf-8,gbk,gb2312;q=0.7,*;q=0.7"); if(!ip.equals("") && port!=0){ // HttpHost proxy = new HttpHost("10.1.2.2", 21); // HttpHost proxy = new HttpHost("10.1.3.110", 21); // HttpHost proxy = new HttpHost("0.0.0.0", 21); HttpHost proxy = new HttpHost(ip, port); // 配置请求的超时设置 RequestConfig requestConfig = RequestConfig.custom() .setConnectionRequestTimeout(timeOut) .setConnectTimeout(timeOut) .setSocketTimeout(timeOut) .setProxy(proxy) .build(); httpRequestBase.setConfig(requestConfig); logger.info("爬虫代理已设置为 "+ip+":"+port); }else{ RequestConfig requestConfig = RequestConfig.custom() .setConnectionRequestTimeout(timeOut) .setConnectTimeout(timeOut).setSocketTimeout(timeOut).build(); httpRequestBase.setConfig(requestConfig); logger.info("爬虫代理未设置 "); } } /** * 获取HttpClient对象 * * @return * @create 2015年12月18日 */ public static CloseableHttpClient getHttpClient(String url) { String hostname = url.split("/")[2]; int port = 80; if (hostname.contains(":")) { String[] arr = hostname.split(":"); hostname = arr[0]; port = Integer.parseInt(arr[1]); } if (httpClient == null) { synchronized (syncLock) { if (httpClient == null) { httpClient = createHttpClient(200, 40, 100, hostname, port); } } } return httpClient; } /** * 创建HttpClient对象 * * @return * @create 2015年12月18日 */ public static CloseableHttpClient createHttpClient(int maxTotal, int maxPerRoute, int maxRoute, String hostname, int port) { //连接池设置 ConnectionSocketFactory plainsf = PlainConnectionSocketFactory.getSocketFactory(); LayeredConnectionSocketFactory sslsf = SSLConnectionSocketFactory.getSocketFactory(); Registry<ConnectionSocketFactory> registry = RegistryBuilder .<ConnectionSocketFactory> create() .register("http", plainsf) .register("https", sslsf) .build(); PoolingHttpClientConnectionManager cm = new PoolingHttpClientConnectionManager(registry); // 将最大连接数增加 cm.setMaxTotal(maxTotal); // 将每个路由基础的连接增加 cm.setDefaultMaxPerRoute(maxPerRoute); // HttpHost httpHost = new HttpHost(hostname, port); // 将目标主机的最大连接数增加 // cm.setMaxPerRoute(new HttpRoute(httpHost), maxRoute); // 请求重试处理 HttpRequestRetryHandler httpRequestRetryHandler = new HttpRequestRetryHandler() { @Override public boolean retryRequest(IOException exception, int executionCount, HttpContext context) { if (executionCount >= 5) {// 如果已经重试了5次,就放弃 return false; } if (exception instanceof NoHttpResponseException) {// 如果服务器丢掉了连接,那么就重试 return true; } if (exception instanceof SSLHandshakeException) {// 不要重试SSL握手异常 return false; } if (exception instanceof InterruptedIOException) {// 超时 return false; } if (exception instanceof UnknownHostException) {// 目标服务器不可达 return false; } if (exception instanceof ConnectTimeoutException) {// 连接被拒绝 return false; } if (exception instanceof SSLException) {// SSL握手异常 return false; } HttpClientContext clientContext = HttpClientContext .adapt(context); HttpRequest request = clientContext.getRequest(); // 如果请求是幂等的,就再次尝试 // treat those request methods defined as idempotent by RFC-2616 as safe to retry automatically: //GET, HEAD, PUT, DELETE, OPTIONS, and TRACE if (!(request instanceof HttpEntityEnclosingRequest)) { return true; } return false; } }; //设置重定向处理方式,限制重定向 RedirectStrategy redirectStrategy = new RedirectStrategy() { @Override public boolean isRedirected(HttpRequest arg0, HttpResponse arg1, HttpContext arg2) throws ProtocolException { return false; } @Override public HttpUriRequest getRedirect(HttpRequest arg0, HttpResponse arg1, HttpContext arg2) throws ProtocolException { return null; } }; CloseableHttpClient httpClient = HttpClients.custom() .setConnectionManager(cm) .setRetryHandler(httpRequestRetryHandler) .setRedirectStrategy(redirectStrategy) .build(); return httpClient; } private static void setPostParams(HttpPost httpost, Map<String, Object> params) { List<NameValuePair> nvps = new ArrayList<NameValuePair>(); Set<String> keySet = params.keySet(); for (String key : keySet) { nvps.add(new BasicNameValuePair(key, params.get(key).toString())); } try { httpost.setEntity(new UrlEncodedFormEntity(nvps, "UTF-8")); } catch (UnsupportedEncodingException e) { e.printStackTrace(); } } /** * POST请求URL获取内容 * * @param url * @return * @throws Exception */ public static String post(String url, Map<String, Object> params) throws Exception { HttpPost httppost = new HttpPost(url); config(httppost); setPostParams(httppost, params); CloseableHttpResponse response = null; try { response = getHttpClient(url).execute(httppost, HttpClientContext.create()); HttpEntity entity = response.getEntity(); String result = EntityUtils.toString(entity, "utf-8"); EntityUtils.consume(entity); return result; } catch (Exception e) { throw e; } finally { try { if (response != null) response.close(); } catch (IOException e) { e.printStackTrace(); } } } /** * GET请求URL获取内容 * * @param url * @return */ public static String[] get(String url) { String[] rs = new String[2]; HttpGet httpget = new HttpGet(url); config(httpget); CloseableHttpResponse response = null; try { response = getHttpClient(url).execute(httpget, HttpClientContext.create()); String status = ""+response.getStatusLine().getStatusCode(); rs[0] = status; HttpEntity entity = response.getEntity(); // String result = EntityUtils.toString(entity, "gb2312"); String result = EntityUtils.toString(entity, "utf-8"); rs[1] = result; EntityUtils.consume(entity); return rs; } catch (IOException e) { logger.error("Connection error: "+url); logger.error(e); } finally { try { if (response != null) response.close(); } catch (IOException e) { logger.error(e); } } return null; } public static void main(String[] args) { // URL列表数组 String[] urisToGet = { "http://mp.weixin.qq.com/s?__biz=MzI2NzMxOTY4NA==&mid=2247484446&idx=1&sn=8d3c4865fdac5c9487092c45c94648b0&chksm=ea81e4f5ddf66de3a90e08d0d2864cc0125478f49835307e8893b827b9044a840cc8696af7a6&mpshare=1&scene=1&srcid$", "http://mp.weixin.qq.com/s?__biz=MjM5Njc3NDQ0Mg==&mid=2667120999&idx=1&sn=437783a5ba0df5a01af3fa21ae0f6495&chksm=bde9be228a9e373417cee08ef3c326da94239f030e54ffa5d23259468761a187218e7e3618a4&mpshare=1&scene=2&srcid=1113GHaI6kK39slJwAmpbYLZ&from=timeline&isappinstalled=0&key=cde9f53f8128acbd67acdd59e62a2cf07610cab760a2508b2ee8e86d4e377502aaee30cd014f1372818d0db90eceece9&ascene=2&uin=MTcxNzQ5MzUwMg%3D%3D&devicetype=android-22&version=2603163b&nettype=cmnet&pass_ticket=EJ5V9DwW2jmPpf14tUG6NDxN$a", "http://mp.weixin.qq.com/s?__biz=MzA3Njg2ODcxNw==&mid=2671748390&idx=3&sn=a91b7f0b1f05773e50fae80277db2c2d&chksm=8591b824b2e631322361a7b5e56f7307df572bf36071c1452b933f382f52208eecffc77b050e&mpshare=1&scene=2&srcid=1024W5sG55YEURTGDX9fLmuQ&from=timeline&isappinstalled=0&key=c3acc508db720376b569ae8eef0acac045bfa0176823ca92962a14082207ac8024287f0b43e2335c2332cd781dd5358f&ascene=2&uin=MjU4MjY0MzExMA%3D%3D&devicetype=android-19&version=26031933&nettype=cmnet&pass_ticket=jET0vPkpG79xPO6CRylxn%2Fg%ac", "http://mp.weixin.qq.com/s?__biz=MzI4NDE3Nzc2OA==&mid=2650114934&idx=1&sn=d4f1788633caf17dcfd2102d2c61b478&chksm=f3fe4f71c489c6672369ae70b03ea3310df6cae2f0c76308cd3f7dff9b1297ab440c83610232&mpshare=1&scene=1&srcid=10291zHaTjkTyLQkyhqj7Mwu&from=groupmessage&isappinstalled=0&key=cde9f53f8128acbde0df0076da5ccbba394081838ceaee964530be2e994afcc063ab76e37621521f164f0989ff31312b&ascene=1&uin=MjIxMTcxMTMyMQ%3D%3D&devicetype=android-23&version=26031b31&nettype=3gnet&pass_ticket=IisGERHk%2BkG21%2Fci%abc" }; long start = System.currentTimeMillis(); try { int pagecount = urisToGet.length; ExecutorService executors = Executors.newFixedThreadPool(pagecount); CountDownLatch countDownLatch = new CountDownLatch(pagecount); for (int i = 0; i < pagecount; i++) { // String ul = URLEncoder.encode(urisToGet[i]); HttpGet httpget = new HttpGet(urisToGet[i].replaceAll("%.?$", "")); // HttpGet httpget = new HttpGet(ul); config(httpget); // 启动线程抓取 executors.execute(new GetRunnable(urisToGet[i], countDownLatch)); } countDownLatch.await(); executors.shutdown(); } catch (InterruptedException e) { e.printStackTrace(); } finally { System.out.println("线程" + Thread.currentThread().getName() + "," + System.currentTimeMillis() + ", 所有线程已完成,开始进入下一步!"); } long end = System.currentTimeMillis(); System.out.println("consume -> " + (end - start)); } static class GetRunnable implements Runnable { private CountDownLatch countDownLatch; private String url; public GetRunnable(String url, CountDownLatch countDownLatch) { this.url = url; this.countDownLatch = countDownLatch; } @Override public void run() { try { System.out.println(AppInfoHttpClient.get(url)); } finally { countDownLatch.countDown(); } } } }
[ "yuanjk@asiainfo-mixdata.com" ]
yuanjk@asiainfo-mixdata.com
46b2ef499d46ddb6a20acf5c12923e35f5838a22
19b51efa87a70bf67d1a18870f6162e776387609
/MapaJuego-CODESOLIDS/src/MapaJuego/Codesolids/Chat.java
36c14c4a448a742f7ad7cee9f6da3af81ebe893d
[]
no_license
kenshin23/codesolids-project
f4addcc59e93144f3e3d35f3e68d9e8e2aa57131
b917dc7e15e19c6296108be85053c85af897b77e
refs/heads/master
2016-08-05T01:52:19.986883
2011-09-23T16:41:29
2011-09-23T16:41:29
32,225,049
0
0
null
null
null
null
UTF-8
Java
false
false
5,114
java
package MapaJuego.Codesolids; import nextapp.echo.app.ImageReference; import nextapp.echo.app.Panel; import nextapp.echo.app.Extent; import nextapp.echo.app.ContentPane; import nextapp.echo.app.Column; import nextapp.echo.app.Color; import nextapp.echo.app.Border; import nextapp.echo.app.Label; import nextapp.echo.app.Font; import nextapp.echo.app.event.ActionEvent; import nextapp.echo.app.event.ActionListener; import nextapp.echo.app.layout.ColumnLayoutData; import nextapp.echo.app.Alignment; import nextapp.echo.app.FillImage; import nextapp.echo.app.ResourceImageReference; import nextapp.echo.app.Insets; import nextapp.echo.app.Button; public class Chat extends Panel { protected Chat() { super(); // SIN ESTE SUPER FUE UN DOLOR PARA QUE FUNCIONARA, este salva vidas constructorComp(); } private void constructorComp() { //al panel inicial le coloco las medidas exactas a usar this.setHeight(new Extent(983, Extent.PX)); this.setWidth(new Extent(1280, Extent.PX)); ContentPane cpExterno = new ContentPane(); cpExterno.setEnabled(true); add(cpExterno); //agrego la columna que contiene los paneles y sus caracteristicas Column columnaExterna = new Column(); columnaExterna.setBorder(new Border(new Extent(5, Extent.PX), new Color(0xd4630c), Border.STYLE_DOUBLE)); columnaExterna.setEnabled(true); columnaExterna.setBackground(Color.BLACK); cpExterno.add(columnaExterna); //agrego titulo superior y caracteristicas Label tituloSuperior = new Label(); tituloSuperior.setFont(new Font(new Font.Typeface("ARIAL"), Font.BOLD | Font.ITALIC, new Extent(16, Extent.PT))); tituloSuperior.setForeground(new Color(0xd4630c)); tituloSuperior.setText("CHAT"); //creo el columnLayoutdata para centrar el titulo superior en la columna ColumnLayoutData tituloSuperiorLD = new ColumnLayoutData(); tituloSuperiorLD.setAlignment(new Alignment(Alignment.CENTER, Alignment.DEFAULT)); tituloSuperior.setLayoutData(tituloSuperiorLD); columnaExterna.add(tituloSuperior); //se podia usar un splitpane como el ejemplo de de Echo3Tutorial/panelchange, usando el separador estatico //creo mas sencillo usar el panel de altura 1pixel y agregarle color Panel lineaSeparadora = new Panel(); lineaSeparadora.setEnabled(true); ColumnLayoutData lineaSeparadoraLD = new ColumnLayoutData(); lineaSeparadoraLD.setBackground(new Color(0xd4630c)); lineaSeparadoraLD.setHeight(new Extent(1, Extent.PX)); lineaSeparadora.setLayoutData(lineaSeparadoraLD); columnaExterna.add(lineaSeparadora); //este panel es el que efectivamente muestra el background que se ve en cada pantalla, le modifico el HEIGHT para 947, si no se lo //agregaba no me muestra la imagen completa, me costo que me funcionara la funcion de Fillimage usando el No_Repeat, ya que la estaba usando //en minusculas Panel panelBackground = new Panel(); panelBackground.setEnabled(true); ColumnLayoutData panelBakcgroundLD = new ColumnLayoutData(); panelBakcgroundLD.setHeight(new Extent(947, Extent.PX)); ResourceImageReference ir = new ResourceImageReference("/MapaJuego/Codesolids/mago_fuego3.jpg"); panelBakcgroundLD.setBackgroundImage(new FillImage(ir,new Extent(50, Extent.PERCENT), new Extent(50, Extent.PERCENT),FillImage.NO_REPEAT)); panelBackground.setLayoutData(panelBakcgroundLD); columnaExterna.add(panelBackground); //este panel contiene la columna que finalmente contiene el boton de regresar a la pantalla inicial //en realidad es overkill usar el panel para una columna con un solo boton, ya que se puede agregar el boton dentro de la columna y se le acomodan //los insets adecuadamente, pero lo dejo asi por si acaso le agregamos mas botones a cada pantalla, es bastante util Panel panelContenedorCol = new Panel(); panelContenedorCol.setInsets(new Insets(new Extent(580, Extent.PX), new Extent(700,Extent.PX), new Extent(0, Extent.PX), new Extent(0, Extent.PX))); panelBackground.add(panelContenedorCol); Column columnaBoton = new Column(); columnaBoton.setEnabled(true); columnaBoton.setCellSpacing(new Extent(10, Extent.PX)); panelContenedorCol.add(columnaBoton); //el boton de regresar es creado con propiedades rollover y foreground, para el futuro deseo agregarle mas caracteristicas, si es posible Button returnButton = new Button(); returnButton.setText("REGRESAR"); returnButton.setStyle(ButtonStyle.BOTON_REGRESAR); returnButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { button1Clicked(e); } }); columnaBoton.add(returnButton); } private void button1Clicked(ActionEvent e) { removeAll(); add(new MapaJuego());//muchahos esta parte fue un dolor de cabeza, despues de muchos intentos porfin pude utilizar el actionevent para crear un nuevo panel } } //NOTA: VERAN QUE A CADA ELEMENTO TUVE QUE AGREGARLE LA PROPIEDAD SETENABLED(TRUE), YA QUE PARA USAR LA PROPIEDAD ROLLOVER DEL BOTON NO ME QUERIA //HACER EL EFECTO SIN ESE SETENABLED(TRUE). A SER SINCERO NO ESTOY SEGURO POR QUE ES ASI, PÈRO FUNCIONA :)
[ "hectorprada73@gmail.com@ea32cc08-60d7-ed69-808b-ffe600edc202" ]
hectorprada73@gmail.com@ea32cc08-60d7-ed69-808b-ffe600edc202
9370d533bd8d42327ec8c4b63e1eb769c7013686
07194d0e8bee8dd791c0eb740211957762ebae5b
/NEURAL_NET/src/main/java/org/xSakix/nn/NetConfig.java
a7b1187b5d6db3761bac21d4befa7cfe1f0b9f72
[ "Apache-2.0" ]
permissive
xSakix/etf_expert
14779efcc6643e32cf8a36e88d6e2050f44c218d
3d811a9a505a43a608106ede228aae05e71cc532
refs/heads/master
2021-10-19T12:20:21.099899
2019-02-20T20:10:29
2019-02-20T20:10:29
103,178,801
2
1
null
null
null
null
UTF-8
Java
false
false
258
java
package org.xSakix.nn; public class NetConfig { public double alpha; public double momentum; public int n_inputs; public int n_outputs; public int[] hidenLayers; public WhichFunctionEnum func; public boolean reinforced=false; }
[ "seckarovci@gmail.com" ]
seckarovci@gmail.com
8aa360f55389ca29cebd77ee9b67ab934b2613fb
79c2990680a56a311963e266b334ef9453a1ff6e
/TestApp1/app/src/main/java/com/example/rishabh/testapp1/TasksDB.java
76e8b7f709961acc5f0aa1449e81ba848c640c12
[]
no_license
git-rishabh/MC_Assignment4
ac8804f1639b7150681cbd376479ab993df89745
04847ef2b39b940bfd89765431da9152d34a111b
refs/heads/master
2021-05-01T18:41:19.105495
2016-11-09T17:06:58
2016-11-09T17:06:58
72,435,471
0
0
null
null
null
null
UTF-8
Java
false
false
3,868
java
package com.example.rishabh.testapp1; import android.content.ContentValues; import android.content.Context; import android.database.Cursor; import android.database.DatabaseUtils; import android.database.sqlite.SQLiteDatabase; import android.database.sqlite.SQLiteOpenHelper; import java.util.ArrayList; import java.util.HashMap; /** * Created by Rishabh on 9/30/2016. */ public class TasksDB extends SQLiteOpenHelper { public static final String DATABASE_NAME = "task.db"; public static final String USERS_TABLE_NAME = "tasks"; public static final String USERS_COLUMN_ID = "id"; public static final String USERS_COLUMN_TITLE = "title"; public static final String USERS_COLUMN_DESCRIPTION = "description"; private HashMap hp; public TasksDB(Context context) { super(context, DATABASE_NAME , null, 1); } @Override public void onCreate(SQLiteDatabase db) { // TODO Auto-generated method stub db.execSQL( "create table tasks " + "(id integer primary key, title text, description text)" ); } @Override public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) { // TODO Auto-generated method stub db.execSQL("DROP TABLE IF EXISTS tasks"); onCreate(db); } public boolean inserttask (Task task) { SQLiteDatabase db = this.getWritableDatabase(); ContentValues contentValues = new ContentValues(); contentValues.put("title", task.getTitle()); contentValues.put("description", task.getDescription()); db.insert("tasks", null, contentValues); return true; } public Task getTask(int id){ SQLiteDatabase db = this.getReadableDatabase(); // Cursor res = db.rawQuery( "select * from tasks where id="+"'"+id+"'"+"", null ); Cursor res = db.rawQuery( "select * from tasks where id="+id, null ); int id1=res.getInt(res.getColumnIndex(USERS_COLUMN_ID)); String title=res.getString(res.getColumnIndex(USERS_COLUMN_TITLE)); String description=res.getString(res.getColumnIndex(USERS_COLUMN_DESCRIPTION)); Task newtask=new Task(id1,title,description); return newtask; } public int numberOfRows(){ SQLiteDatabase db = this.getReadableDatabase(); int numRows = (int) DatabaseUtils.queryNumEntries(db, USERS_TABLE_NAME); return numRows; } /* public boolean updateUser (String name, String username, String qualification) { SQLiteDatabase db = this.getWritableDatabase(); ContentValues contentValues = new ContentValues(); contentValues.put("name", name); contentValues.put("username", username); contentValues.put("qualification", qualification); db.update("users", contentValues, "username = ? ", new String[] {username } ); return true; }*/ /* public Integer deleteUser(int id) { SQLiteDatabase db = this.getWritableDatabase(); return db.delete("tasks", "id = ? ", new String[] { username }); }*/ public ArrayList<Task> getAllTasks() { ArrayList<Task> array_list = new ArrayList<Task>(); SQLiteDatabase db = this.getReadableDatabase(); Cursor res = db.rawQuery( "select * from tasks", null ); res.moveToFirst(); while(res.isAfterLast() == false){ int id1=res.getInt(res.getColumnIndex(USERS_COLUMN_ID)); String title=res.getString(res.getColumnIndex(USERS_COLUMN_TITLE)); String description=res.getString(res.getColumnIndex(USERS_COLUMN_DESCRIPTION)); Task newuser=new Task(id1,title,description); array_list.add(newuser); res.moveToNext(); } return array_list; } }
[ "rishabh999gupta@gmail.com" ]
rishabh999gupta@gmail.com
594c46c22b50f5611660dff2d2fffdd4d5db7e4e
607386530d05a3176b442aa51e313f30ff08e9de
/seamcat/presentation/components/StairDistributionTableModelAdapter.java
4c154f44b70da103069259b5d1678cff5c253f73
[]
no_license
rayvo/seamcat
6b532137b2a6d9149f8a5102a48327188dcbec3c
4f9cfbab3532bb94cb35911d535af2099d779a04
refs/heads/master
2021-01-10T21:33:57.171281
2009-03-27T12:35:45
2009-03-27T12:35:45
33,710,648
0
0
null
null
null
null
UTF-8
Java
false
false
10,044
java
// Decompiled by Jad v1.5.8g. Copyright 2001 Pavel Kouznetsov. // Jad home page: http://www.kpdus.com/jad.html // Decompiler options: packimports(3) // Source File Name: StairDistributionTableModelAdapter.java package org.seamcat.presentation.components; import java.util.*; import javax.swing.event.TableModelEvent; import javax.swing.event.TableModelListener; import javax.swing.table.TableModel; import org.apache.log4j.Logger; import org.jfree.data.category.CategoryDataset; import org.jfree.data.general.*; import org.seamcat.distribution.StairDistribution; import org.seamcat.function.Point2D; public class StairDistributionTableModelAdapter implements TableModel { private class CategoryDatasetImpl implements CategoryDataset { public void addChangeListener(DatasetChangeListener datasetChangeListener) { if(!datasetChangeListeners.contains(datasetChangeListener)) datasetChangeListeners.add(datasetChangeListener); } public void removeChangeListener(DatasetChangeListener datasetChangeListener) { datasetChangeListeners.remove(datasetChangeListener); } public void fireChangeListeners() { updateColumnKeys(); for(Iterator i = datasetChangeListeners.iterator(); i.hasNext(); ((DatasetChangeListener)i.next()).datasetChanged(stdDatasetChangeEvent)); } private void updateColumnKeys() { columnKeys.clear(); int x = 0; for(int size = points.size(); x < size; x++) columnKeys.add(getColumnKey(x)); } public DatasetGroup getGroup() { return datasetGroup; } public void setGroup(DatasetGroup datasetGroup) { this.datasetGroup = datasetGroup; } public Number getValue(int row, int column) { return new Double(((Point2D)points.get(column)).getY()); } public Comparable getRowKey(int row) { return (Comparable)rowKeys.get(row); } public int getRowIndex(Comparable key) { return rowKeys.indexOf(key); } public List getRowKeys() { return rowKeys; } public Comparable getColumnKey(int column) { return new Double(((Point2D)points.get(column)).getX()); } public int getColumnIndex(Comparable key) { return columnKeys.indexOf(key); } public List getColumnKeys() { return columnKeys; } public Number getValue(Comparable rowKey, Comparable colKey) { return getValue(getRowIndex(rowKey), getColumnIndex(colKey)); } public int getRowCount() { return 1; } public int getColumnCount() { return points.size(); } private List datasetChangeListeners; private DatasetChangeEvent stdDatasetChangeEvent; private DatasetGroup datasetGroup; private List rowKeys; private List columnKeys; final StairDistributionTableModelAdapter this$0; public CategoryDatasetImpl() { this$0 = StairDistributionTableModelAdapter.this; super(); datasetChangeListeners = new ArrayList(); stdDatasetChangeEvent = new DatasetChangeEvent(this, this); datasetGroup = new DatasetGroup(); rowKeys = new ArrayList(1); columnKeys = new ArrayList(); rowKeys.add(new Integer(0)); updateColumnKeys(); } } public CategoryDataset getCategoryDS() { return categoryDS; } public StairDistributionTableModelAdapter() { this(new Point2D[0]); } public StairDistributionTableModelAdapter(Point2D _points[]) { tableModelListeners = new ArrayList(); stdTableModelEvent = new TableModelEvent(this); points = new ArrayList(); categoryDS = new CategoryDatasetImpl(); for(int x = 0; x < _points.length; x++) points.add(_points[x]); ensureMinimumRows(); col1Name = "Value"; col2Name = "Cum. Prop."; } public int getColumnCount() { return 2; } public int getRowCount() { return points.size(); } public boolean isCellEditable(int rowIndex, int columnIndex) { return true; } public Class getColumnClass(int columnIndex) { return java/lang/Double; } public Object getValueAt(int rowIndex, int columnIndex) { switch(columnIndex) { case 0: // '\0' return new Double(((Point2D)points.get(rowIndex)).getX()); case 1: // '\001' return new Double(((Point2D)points.get(rowIndex)).getY()); } throw new IllegalArgumentException("Point2D only has two columns"); } public int getIndex(Double key) { int index = -1; int x = 0; int size = points.size(); do { if(x >= size) break; if((new Double(((Point2D)points.get(x)).getX())).compareTo(key) == 0) { index = x; break; } x++; } while(true); return index; } public Comparable getKey(int index) { return new Double(((Point2D)points.get(index)).getX()); } public List getKeys() { List l = new ArrayList(); for(Iterator i = points.iterator(); i.hasNext(); l.add(new Double(((Point2D)i.next()).getX()))); return l; } public void setValueAt(Object aValue, int rowIndex, int columnIndex) { if(aValue instanceof Number) { Number number = (Number)aValue; switch(columnIndex) { case 0: // '\0' ((Point2D)points.get(rowIndex)).setX(number.doubleValue()); break; case 1: // '\001' ((Point2D)points.get(rowIndex)).setY(number.doubleValue()); sortPoints(); break; default: throw new IllegalArgumentException("Point2D only has two columns"); } fireChangeListeners(); } else { throw new IllegalArgumentException("TableModel only accepts instances of class Number"); } } public String getColumnName(int columnIndex) { switch(columnIndex) { case 0: // '\0' return col1Name; case 1: // '\001' return col2Name; } throw new IllegalArgumentException((new StringBuilder()).append("Point2D only has two columns <").append(columnIndex).append(">").toString()); } public void addTableModelListener(TableModelListener l) { if(!tableModelListeners.contains(l)) tableModelListeners.add(l); } public void removeTableModelListener(TableModelListener l) { tableModelListeners.remove(l); } public int getItemCount(int series) { return points.size(); } public int getItemCount() { return points.size(); } public Number getValue(int index) { return new Double(((Point2D)points.get(index)).getY()); } public void fireChangeListeners() { for(Iterator i = tableModelListeners.iterator(); i.hasNext(); ((TableModelListener)i.next()).tableChanged(stdTableModelEvent)); categoryDS.fireChangeListeners(); } public void setPoints(StairDistribution stairDist) { points.clear(); Point2D _points[] = stairDist.getPoints(); for(int x = 0; x < _points.length; x++) points.add(_points[x]); ensureMinimumRows(); sortPoints(); fireChangeListeners(); } public void setPoints(List _points) { points = _points; ensureMinimumRows(); sortPoints(); fireChangeListeners(); } public Point2D[] getPoints() { return (Point2D[])(Point2D[])points.toArray(new Point2D[points.size()]); } public List getPointsList() { return points; } public void clear() { LOG.debug("Clearing model"); int rowCount = getRowCount(); points.clear(); fireChangeListeners(); } public void addRow() { addRow(true); } private void addRow(boolean fireChangeListeners) { points.add(new Point2D(0.0D, 0.0D)); if(fireChangeListeners) fireChangeListeners(); } public void deleteRow(int row) { if(row >= 0 && row < getRowCount()) { LOG.debug((new StringBuilder()).append("Deleting row no. ").append(row).toString()); points.remove(row); ensureMinimumRows(); fireChangeListeners(); } } private void ensureMinimumRows() { if(getRowCount() == 0) addRow(false); } public void sortPoints() { Collections.sort(points, Point2D.POINTX_COMPARATOR); } private static final Logger LOG = Logger.getLogger(org/seamcat/presentation/components/StairDistributionTableModelAdapter); private List tableModelListeners; private TableModelEvent stdTableModelEvent; private List points; private CategoryDatasetImpl categoryDS; private String col1Name; private String col2Name; }
[ "voquocduy1983@0fa86794-1aca-11de-9c9a-2d325a3e6494" ]
voquocduy1983@0fa86794-1aca-11de-9c9a-2d325a3e6494
e4de786061144b55eb6a9270985257ea2fd2c4e1
0c85c1a4eda5574232fee4fe64026bbfba9f77df
/src/org/kaipan/www/socket/test/SslSocketClient.java
578f4d85f938666323b9cdade58af0b12ba5b849
[]
no_license
xuegao2015/Java-Nio-Services
dbc0b930c2f8796130b401cc627a26df9b7affc5
78e139a6c476bcecafc07fd13a75308aa934ddef
refs/heads/master
2021-01-22T23:44:28.590984
2017-08-17T11:22:43
2017-08-17T11:22:43
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,708
java
package org.kaipan.www.socket.test; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; import java.io.OutputStream; import java.io.PrintWriter; import java.net.Socket; import java.net.UnknownHostException; import javax.net.SocketFactory; import javax.net.ssl.SSLSocketFactory; public class SslSocketClient { private Socket socket; public static final int HTTPS_PORT = 443; public SslSocketClient(String hostname) { SocketFactory factory = SSLSocketFactory.getDefault(); try { socket = factory.createSocket(hostname, HTTPS_PORT); } catch (UnknownHostException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } } public void request() { try { OutputStream os = socket.getOutputStream(); PrintWriter pw = new PrintWriter(os); String command = "GET / HTTP/1.1\r\n\r\n"; pw.print(command); pw.flush(); InputStream is = socket.getInputStream(); InputStreamReader isr = new InputStreamReader(is); BufferedReader br = new BufferedReader(isr); String line; while ( (line = br.readLine()) != null ) { System.out.println(line); } pw.close(); br.close(); socket.close(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } } public static void main(String[] args) { String hostname; if ( args.length == 0 ) { hostname = "www.baidu.com"; } else { hostname = args[0]; } SslSocketClient client = new SslSocketClient(hostname); client.request(); } }
[ "530911044@qq.com" ]
530911044@qq.com
741a0d339b767e40147e013270394d1ac45e81d0
42bb692d9140736c468e7ae328564c12b830b4be
/bitcamp-javabasic/src/step17/ex2/Exam03.java
fa1254e83e54af89662e0dfa614f097fa87a92cc
[]
no_license
kimkwanhee/bitcamp
b047f4cc391d2c43bad858f2ffb4f3a6a3779aa2
0245693f83b06d773365b9b5b6b3d4747877d070
refs/heads/master
2021-01-24T10:28:06.247239
2018-08-20T03:13:18
2018-08-20T03:13:18
123,054,178
0
0
null
null
null
null
UTF-8
Java
false
false
324
java
//상수 코드를 스태틱 중첩 클래스로 다루기 package step17.ex2; public class Exam03 { public static void main(String[] args) { Product2 p = new Product2(); p.category = Category2.appliance.TV; p.name = "울트라 비젼 뷰"; p.price = 2000000; } }
[ "rhdwn1955@naver.com" ]
rhdwn1955@naver.com
def38ebf401d48df4b42c1357086c8d683bd3c05
48e835e6f176a8ac9ae3ca718e8922891f1e5a18
/benchmark/training/org/pentaho/di/core/row/RowTest.java
a916a61e76d34f732300d0f8b2c8d73ee23adce8
[]
no_license
STAMP-project/dspot-experiments
f2c7a639d6616ae0adfc491b4cb4eefcb83d04e5
121487e65cdce6988081b67f21bbc6731354a47f
refs/heads/master
2023-02-07T14:40:12.919811
2019-11-06T07:17:09
2019-11-06T07:17:09
75,710,758
14
19
null
2023-01-26T23:57:41
2016-12-06T08:27:42
null
UTF-8
Java
false
false
5,442
java
/** * ! ****************************************************************************** * * Pentaho Data Integration * * Copyright (C) 2002-2018 by Hitachi Vantara : http://www.pentaho.com * * ****************************************************************************** * * 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.pentaho.di.core.row; import java.math.BigDecimal; import java.sql.Timestamp; import java.text.SimpleDateFormat; import java.util.Date; import org.junit.Assert; import org.junit.ClassRule; import org.junit.Test; import org.pentaho.di.junit.rules.RestorePDIEnvironment; public class RowTest { @ClassRule public static RestorePDIEnvironment env = new RestorePDIEnvironment(); @Test public void testNormalStringConversion() throws Exception { SimpleDateFormat fmt = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss.SSS"); Object[] rowData1 = new Object[]{ "sampleString", fmt.parse("2007/05/07 13:04:13.203"), new Double(9123.0), new Long(12345), new BigDecimal("123456789012345678.9349"), Boolean.TRUE }; RowMetaInterface rowMeta1 = createTestRowMetaNormalStringConversion1(); Assert.assertEquals("sampleString", rowMeta1.getString(rowData1, 0)); Assert.assertEquals("2007/05/07 13:04:13.203", rowMeta1.getString(rowData1, 1)); Assert.assertEquals("9,123.00", rowMeta1.getString(rowData1, 2)); Assert.assertEquals("0012345", rowMeta1.getString(rowData1, 3)); Assert.assertEquals("123456789012345678.9349", rowMeta1.getString(rowData1, 4)); Assert.assertEquals("Y", rowMeta1.getString(rowData1, 5)); fmt = new SimpleDateFormat("yyyyMMddHHmmss"); Object[] rowData2 = new Object[]{ null, fmt.parse("20070507130413"), new Double(9123.9), new Long(12345), new BigDecimal("123456789012345678.9349"), Boolean.FALSE }; RowMetaInterface rowMeta2 = createTestRowMetaNormalStringConversion2(); Assert.assertTrue(((rowMeta2.getString(rowData2, 0)) == null)); Assert.assertEquals("20070507130413", rowMeta2.getString(rowData2, 1)); Assert.assertEquals("9.123,9", rowMeta2.getString(rowData2, 2)); Assert.assertEquals("0012345", rowMeta2.getString(rowData2, 3)); Assert.assertEquals("123456789012345678.9349", rowMeta2.getString(rowData2, 4)); Assert.assertEquals("false", rowMeta2.getString(rowData2, 5)); } @Test public void testIndexedStringConversion() throws Exception { String[] colors = new String[]{ "Green", "Red", "Blue", "Yellow", null }; // create some timezone friendly dates SimpleDateFormat fmt = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss.SSS"); Date[] dates = new Date[]{ fmt.parse("2007/05/07 13:04:13.203"), null, fmt.parse("2007/05/05 05:15:49.349"), fmt.parse("2007/05/05 19:08:44.736") }; RowMetaInterface rowMeta = createTestRowMetaIndexedStringConversion1(colors, dates); Object[] rowData1 = new Object[]{ Integer.valueOf(0), Integer.valueOf(0) }; Object[] rowData2 = new Object[]{ Integer.valueOf(1), Integer.valueOf(1) }; Object[] rowData3 = new Object[]{ Integer.valueOf(2), Integer.valueOf(2) }; Object[] rowData4 = new Object[]{ Integer.valueOf(3), Integer.valueOf(3) }; Object[] rowData5 = new Object[]{ Integer.valueOf(4), Integer.valueOf(0) }; Assert.assertEquals("Green", rowMeta.getString(rowData1, 0)); Assert.assertEquals("2007/05/07 13:04:13.203", rowMeta.getString(rowData1, 1)); Assert.assertEquals("Red", rowMeta.getString(rowData2, 0)); Assert.assertTrue((null == (rowMeta.getString(rowData2, 1)))); Assert.assertEquals("Blue", rowMeta.getString(rowData3, 0)); Assert.assertEquals("2007/05/05 05:15:49.349", rowMeta.getString(rowData3, 1)); Assert.assertEquals("Yellow", rowMeta.getString(rowData4, 0)); Assert.assertEquals("2007/05/05 19:08:44.736", rowMeta.getString(rowData4, 1)); Assert.assertTrue((null == (rowMeta.getString(rowData5, 0)))); Assert.assertEquals("2007/05/07 13:04:13.203", rowMeta.getString(rowData5, 1)); } @Test public void testExtractDataWithTimestampConversion() throws Exception { RowMetaInterface rowMeta = createTestRowMetaNormalTimestampConversion(); Timestamp constTimestamp = Timestamp.valueOf("2012-04-05 04:03:02.123456"); Timestamp constTimestampForDate = Timestamp.valueOf("2012-04-05 04:03:02.123"); makeTestExtractDataWithTimestampConversion(rowMeta, " Test1", constTimestamp, constTimestamp); makeTestExtractDataWithTimestampConversion(rowMeta, " Test2", new Date(constTimestamp.getTime()), constTimestampForDate); makeTestExtractDataWithTimestampConversion(rowMeta, " Test3", new java.sql.Date(constTimestamp.getTime()), constTimestampForDate); } }
[ "benjamin.danglot@inria.fr" ]
benjamin.danglot@inria.fr
0cce43b597fd4e0c16edc3c560f4b04a0adb97e1
a0098e9d639e543208bf9e8fa1db072b2dc36a42
/src/main/java/es/once/Pizza/model/Comentario.java
fc9244e5c51d29299234d3707280abd3e2581710
[]
no_license
pacomonle/pizzaworld2
ef52bbb2cb2cfdd5b5f1321d2493a97de7d3593d
6a8cf946f156204d0b62b28d822547708ef8ca54
refs/heads/master
2021-02-10T09:59:32.685726
2020-03-02T13:01:04
2020-03-02T13:01:04
244,372,061
0
0
null
null
null
null
UTF-8
Java
false
false
1,774
java
package es.once.Pizza.model; import java.util.Calendar; import javax.persistence.Entity; import javax.persistence.FetchType; import javax.persistence.GeneratedValue; import javax.persistence.GenerationType; import javax.persistence.Id; import javax.persistence.JoinColumn; import javax.persistence.ManyToOne; @Entity public class Comentario { @Id @GeneratedValue(strategy = GenerationType.AUTO) private Long id; // clave principal de la tabla (autonumérico Long) private String texto; // texto del comentario private String user; // usuario private int puntuacion; // puntuación que se otorga a la pizza private Calendar fecha; // relación de la tabla comentarios con la table Pizza por medio de // @JoinColumn. Se creará una columna FK llamada idPizza en comentarios // que corresponde a la PK de la tabla Pizza // también activamos el modo Lazy @ManyToOne //@JoinColumn(name = "id_pizza") private Pizza pizza; public String getTexto() { return texto; } public void setTexto(String texto) { this.texto = texto; } public String getUser() { return user; } public void setUser(String user) { this.user = user; } public int getPuntuacion() { return puntuacion; } public void setPuntuacion(int puntuacion) { this.puntuacion = puntuacion; } public Calendar getFecha() { return fecha; } public void setFecha(Calendar fecha) { this.fecha = fecha; } public Comentario(String texto, String user, long idPizza, int puntuacion, Calendar fecha) { this.texto = texto; this.user = user; this.puntuacion = puntuacion; this.fecha = fecha; } }
[ "you@example.com" ]
you@example.com
bb38fa6c674aa8d3a8dfb7ef61735ea5b4cfe586
5cca4516ea49cc44aaf3a798835171c6dfb01bfa
/mantis-tests/src/test/java/ru/stqa/pft/mantis/appmanager/HelperBase.java
d1ce9810cf45a1f52c399bf4b7dbeb9f4482ac25
[ "Apache-2.0" ]
permissive
Plizzz/java_for_testers
d0167d09b0255c53e8387ad8991b767b414c7c56
3b5ae2582430c2c76b3615dc505925d953ef506d
refs/heads/master
2020-05-04T12:02:12.646540
2019-06-11T12:03:53
2019-06-11T12:03:53
179,120,292
0
1
null
null
null
null
UTF-8
Java
false
false
1,704
java
package ru.stqa.pft.mantis.appmanager; import org.openqa.selenium.By; import org.openqa.selenium.NoAlertPresentException; import org.openqa.selenium.NoSuchElementException; import org.openqa.selenium.WebDriver; import java.io.File; public class HelperBase { ApplicationManager app; WebDriver wd; HelperBase(ApplicationManager app) { this.app = app; this.wd = app.getDriver(); } void click(By locator) { wd.findElement(locator).click(); } void type(By locator, String text) { if (text != null) { String existingText = wd.findElement(locator).getAttribute("value"); if (!text.equals(existingText)) { wd.findElement(locator).clear(); wd.findElement(locator).sendKeys(text); } } } void attach(By locator, File file) { if (file != null) { wd.findElement(locator).sendKeys(file.getAbsolutePath()); } } public boolean isAlertPresent() { try { wd.switchTo().alert(); return true; } catch (NoAlertPresentException e) { return false; } } boolean isElementPresent(By locator) { try { wd.findElement(locator); return true; } catch (NoSuchElementException ex) { return false; } } public void login(String username, String password) { wd.get(app.getProperty("web.baseUrl") + "/login.php"); type(By.id("username"), username); click(By.cssSelector("[value='Login']")); type(By.id("password"), password); click(By.cssSelector("[value='Login']")); } }
[ "revtov_as@tendertech.ru" ]
revtov_as@tendertech.ru
9457ee18992f63f46583df5421d417bc8ceadd09
083d1781eab539d58b774d572d9ad458c5b38d5d
/cuckoo_video_line/cuckoo_video_line_android_2_5/bogo/src/main/java/com/eliaovideo/videoline/event/CuckooCashEvent.java
d3353e200ace2b1eb942de6262d9f9a6123d9019
[]
no_license
zhubinsheng/cuckoo_video_line
90c5f4dbaa466e181814d771f4193055c8e78cc6
7eb0470adb63d846b276df11352b2d57a1dfef77
refs/heads/master
2022-02-16T22:13:06.514406
2019-08-03T01:47:26
2019-08-03T01:47:26
null
0
0
null
null
null
null
UTF-8
Java
false
false
91
java
package com.eliaovideo.videoline.event; public class CuckooCashEvent extends BaseEvent{ }
[ "807124011@qq.com" ]
807124011@qq.com
377797cc0bf796be5ff79f56017dee325413113f
ef18f37a4e56425f9673776b36cfa1a4548bc91a
/src/nasm/NasmAnd.java
c4c32e30c104c706c7509f928ad6a9a24f586ad1
[]
no_license
sidathgueye/compilationl3-public
8e9ea312cd44b06a2efcb9a86eaa98c3c9268b4c
e4dbf452ef329fc108a9c835813a3a8137aaef77
refs/heads/master
2020-12-20T09:37:38.789768
2020-04-09T20:54:34
2020-04-09T20:54:34
236,031,163
2
0
null
2020-01-24T15:46:03
2020-01-24T15:46:02
null
UTF-8
Java
false
false
547
java
package nasm; public class NasmAnd extends NasmInst { public NasmAnd(NasmOperand label, NasmOperand destination, NasmOperand source, String comment){ destUse = true; destDef = true; srcUse = true; this.label = label; this.destination = destination; this.source = source; this.comment = comment; } public <T> T accept(NasmVisitor <T> visitor) { return visitor.visit(this); } public String toString(){ return super.formatInst(this.label, "and", this.destination, this.source, this.comment); } }
[ "franck.dary@lis-lab.fr" ]
franck.dary@lis-lab.fr
1f5a2fe6cb372c5820e8bbb55f3735a70990cbe8
b9c35a6897b61979b76888f05a463b508314779e
/src/main/java/storage/Storage.java
167bd727aea5271e228827e73d35ea18e2622b33
[]
no_license
alvintan01/ip
851124637dd9a878fb4f7ad128b71519ff35fa92
a61700293a10005cff84d8f8d30f668a6ce112b4
refs/heads/master
2023-08-16T09:02:33.256218
2021-09-29T13:30:55
2021-09-29T13:30:55
395,638,062
0
0
null
2021-09-18T11:03:01
2021-08-13T12:00:19
Java
UTF-8
Java
false
false
2,840
java
package storage; import parser.Parser; import tasks.Task; import ui.Ui; import errors.InvalidFile; import java.io.File; import java.io.FileNotFoundException; import java.io.FileWriter; import java.io.IOException; import java.util.ArrayList; import java.util.Scanner; /** * The Storage class helps to do all the saving and loading of data to the tasks Arraylist. */ public class Storage { File filePath; public Storage(String filePath) { this.filePath = new File(filePath); } /** * Converts all tasks to a string to be written to the file Duke.txt. * * @param ui Reference to the UI object passed by Main to print messages. * @param tasks Reference to the ArrayList of Tasks passed by Main. */ public void saveData(Ui ui, ArrayList<Task> tasks) { if (!filePath.exists()) { createDirectory(); } StringBuilder output = new StringBuilder(); for (Task task : tasks) { output.append(task.toFile()).append("\n"); } try { FileWriter myFile = new FileWriter(filePath); myFile.write(output.toString()); myFile.close(); } catch (IOException e) { ui.customPrint("Could not write to file!"); } } /** * Loads the data to task ArrayList if Duke.txt exists. * * @param ui Reference to the UI object passed by Main to print messages. * @return ArrayList of Tasks. */ public ArrayList<Task> loadData(Ui ui) { ArrayList<Task> tasks = new ArrayList<>(); try { Scanner myReader = new Scanner(filePath); while (myReader.hasNextLine()) { String line = myReader.nextLine(); Task newTask = Parser.fileParser(line); tasks.add(newTask); } myReader.close(); } catch (FileNotFoundException e) { ui.customPrint("Data file does not exist! I will create new one."); if (!filePath.exists()) { createDirectory(); } createFile(ui); } catch (InvalidFile invalidFile) { ui.customPrint("File contains invalid data! Please fix it before running Duke again."); System.exit(0); } return tasks; } /** * Creates the data folder if it doesn't exist. */ public void createDirectory() { File dataDirectory = new File(filePath.getParent()); dataDirectory.mkdirs(); } /** * Creates the file if it doesn't exist. */ public void createFile(Ui ui) { try { FileWriter myFile = new FileWriter(filePath); myFile.close(); } catch (IOException ex) { ui.customPrint("Could not create file!"); } } }
[ "35805635+alvintan01@users.noreply.github.com" ]
35805635+alvintan01@users.noreply.github.com
863cfb0d84c6e7bfc70a074be694d638e82cc4da
551097f2552e0a6a91da77531e85abf89a76f063
/src/main/java/com/github/yuebo/dyna/DbConstant.java
514da746c159799b3b75929b82f760e1d8ea6dea
[ "Apache-2.0" ]
permissive
yuebo/dyna-starter
f9389d562d24c65e8213300c4d3387bb049ef5cc
af78e5145b9041791e2559fd7c92730ce0d80f72
refs/heads/master
2023-06-12T01:28:25.999840
2023-06-06T00:59:10
2023-06-06T00:59:10
131,604,934
4
2
Apache-2.0
2023-02-22T06:53:10
2018-04-30T14:20:41
JavaScript
UTF-8
Java
false
false
1,457
java
/* * * * Copyright 2002-2017 the original author or authors. * * * * 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 com.github.yuebo.dyna; /** * Created by yuebo on 30/11/2017. */ public interface DbConstant { String $in = "$in"; String $gte = "$gte"; String $lte = "$lte"; String $gt = "$gt"; String $lt = "$lt"; String $eq = "$eq"; String $like = "$like"; String $ne = "$ne"; String $null = "$null"; String TBL_USER="tbl_user"; String TBL_ROLE="tbl_role"; String TBL_USER_ROLE="tbl_user_role"; String TBL_JOB="tbl_job"; String TBL_JOB_ERROR="tbl_job_error"; String TBL_MESSAGE="tbl_message"; String TBL_PERMISSION="tbl_permission"; String TBL_USER_PERMISSION="tbl_user_permission"; String TBL_ROLE_PERMISSION="tbl_role_permission"; String TBL_TASK_LOG="tbl_task_log"; String TBL_INTERFACE_PREFIX="tbl_int_"; }
[ "317728991@qq.com" ]
317728991@qq.com
cca451a1df52c49a9d1c93e6b1532ba495c9de99
1aef03ad49af04cd37885efd18cd38110cf4426f
/src/main/java/eLearning/sf/repository/UserJpaRepo.java
109c64dedbb72c27c14be2bb4e711abc61ed4e76
[]
no_license
reloadbrain/eLearning
129f697774319dc0a1071967f7dee8f119f78906
76358929fccac61909c567e8dc370501e95b27c9
refs/heads/master
2020-06-13T21:52:23.589375
2018-07-12T06:09:26
2018-07-12T06:09:26
194,799,570
0
0
null
2019-07-02T06:19:24
2019-07-02T06:13:19
JavaScript
UTF-8
Java
false
false
2,274
java
package eLearning.sf.repository; import java.util.Optional; import org.springframework.data.domain.Page; import org.springframework.data.domain.Pageable; import org.springframework.data.jpa.repository.JpaRepository; import org.springframework.data.jpa.repository.Query; import org.springframework.data.repository.query.Param; import eLearning.sf.model.User; public interface UserJpaRepo extends JpaRepository<User, Long> { Optional<User> findByUsername(String username); Optional<User> findByUsernameAndActiveTrue(String username); @Query("select u from User u where u.active = true and " + "(u.firstName like (CONCAT( '%', LOWER(:searchTerm), '%')) or" + " u.lastName like (CONCAT( '%', LOWER(:searchTerm), '%')) or" + " u.username like (CONCAT( '%', LOWER(:searchTerm), '%')) or" + " u.phoneNumber like (CONCAT( '%', LOWER(:searchTerm), '%')) or" + " u.address like (CONCAT( '%', LOWER(:searchTerm), '%')) or" + " u.dateOfBirth like (CONCAT( '%', LOWER(:searchTerm), '%')))") Page<User> findAllActiveByPageAndSearch(@Param("searchTerm") String searchTerm, Pageable pageable); @Query("select u from User u where u.active = false and " + "(u.firstName like (CONCAT( '%', LOWER(:searchTerm), '%')) or" + " u.lastName like (CONCAT( '%', LOWER(:searchTerm), '%')) or" + " u.username like (CONCAT( '%', LOWER(:searchTerm), '%')) or" + " u.phoneNumber like (CONCAT( '%', LOWER(:searchTerm), '%')) or" + " u.address like (CONCAT( '%', LOWER(:searchTerm), '%')) or" + " u.dateOfBirth like (CONCAT( '%', LOWER(:searchTerm), '%')))") Page<User> findAllNonActiveByPageAndSearch(@Param("searchTerm") String searchTerm, Pageable pageable); @Query("select u from User u where " + "u.firstName like (CONCAT( '%', LOWER(:searchTerm), '%')) or" + " u.lastName like (CONCAT( '%', LOWER(:searchTerm), '%')) or" + " u.username like (CONCAT( '%', LOWER(:searchTerm), '%')) or" + " u.phoneNumber like (CONCAT( '%', LOWER(:searchTerm), '%')) or" + " u.address like (CONCAT( '%', LOWER(:searchTerm), '%')) or" + " u.dateOfBirth like (CONCAT( '%', LOWER(:searchTerm), '%'))") Page<User> findAllPageAndSearch(@Param("searchTerm") String searchTerm, Pageable pageable); }
[ "vladimirilic96@hotmail.com" ]
vladimirilic96@hotmail.com
533599e51dcd7b8f2e8d73bf59a1b8f36ed5d781
e3bbfc931a7e115eb71e7f815cb2c89d20da68b8
/openflowplugin/src/main/java/org/opendaylight/openflowplugin/openflow/md/core/sal/convertor/action/cases/OfToSalDecNwTtlCase.java
7a74be06022bdac66eea46bc544d897add89f90c
[]
no_license
hashsdn/hashsdn-openflowplugin
25f62577f0ee401a8083d8c0b6df9a6ce378fdb8
af3dd0d3e6d3eef07ab4a9399406c7708a55fe49
refs/heads/master
2021-07-20T16:42:43.964956
2017-10-30T06:21:37
2017-10-30T06:21:37
108,927,014
1
0
null
null
null
null
UTF-8
Java
false
false
1,833
java
/* * Copyright (c) 2016 Cisco Systems, Inc. and others. All rights reserved. * * This program and the accompanying materials are made available under the * terms of the Eclipse Public License v1.0 which accompanies this distribution, * and is available at http://www.eclipse.org/legal/epl-v10.html */ package org.opendaylight.openflowplugin.openflow.md.core.sal.convertor.action.cases; import java.util.Optional; import javax.annotation.Nonnull; import org.opendaylight.openflowplugin.api.OFConstants; import org.opendaylight.openflowplugin.openflow.md.core.sal.convertor.ConvertorExecutor; import org.opendaylight.openflowplugin.openflow.md.core.sal.convertor.action.data.ActionResponseConvertorData; import org.opendaylight.openflowplugin.openflow.md.core.sal.convertor.common.ConvertorCase; import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action; import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.DecNwTtlCaseBuilder; import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.dec.nw.ttl._case.DecNwTtlBuilder; import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.common.action.rev150203.action.grouping.action.choice.DecNwTtlCase; public class OfToSalDecNwTtlCase extends ConvertorCase<DecNwTtlCase, Action, ActionResponseConvertorData> { public OfToSalDecNwTtlCase() { super(DecNwTtlCase.class, true, OFConstants.OFP_VERSION_1_0, OFConstants.OFP_VERSION_1_3); } @Override public Optional<Action> process(@Nonnull final DecNwTtlCase source, final ActionResponseConvertorData data, ConvertorExecutor convertorExecutor) { DecNwTtlBuilder decNwTtl = new DecNwTtlBuilder(); return Optional.of(new DecNwTtlCaseBuilder().setDecNwTtl(decNwTtl.build()).build()); } }
[ "tomas.slusny@pantheon.sk" ]
tomas.slusny@pantheon.sk
d8ecfc554563d7eacadcc5c482361b42183d698a
43658461c278bb2f907a0dde991159578245e5ea
/web/src/main/java/com/owen/web/UserController.java
bf35da65953326f778d4333faa0ffd64d830c0ff
[]
no_license
SmallRONArtest/parent
22f33ab437b00dda3e0a5c67d8770dafc8081dce
2b111e7b765126a08997fc300bc11519e4537b0a
refs/heads/master
2020-09-26T16:21:32.476980
2019-12-06T10:41:05
2019-12-06T10:41:05
226,290,232
0
0
null
2019-12-06T09:16:41
2019-12-06T09:16:40
null
UTF-8
Java
false
false
1,143
java
package com.owen.web; import com.owen.User; import com.owen.service.UserService; import org.springframework.ui.ModelMap; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMethod; import org.springframework.web.bind.annotation.RestController; import javax.annotation.Resource; @RestController public class UserController { @Resource(name = "userServiceImpl") private UserService userService; @RequestMapping(value = "/user/{name}",method = RequestMethod.GET) public String getUserInfo(@PathVariable(name = "name")String name, ModelMap modelMap){ User user= userService.getUser(name); return user.toString(); } @RequestMapping(value = "/save/{name}/{age}/{address}",method = RequestMethod.GET) public String saveUserInfo(@PathVariable(name = "name")String name,@PathVariable(name = "age")Integer age,@PathVariable(name = "address")String address,ModelMap modelMap){ User user= userService.saveUser(name,age,address); return user.toString(); } }
[ "mazhqc@yonyou.com" ]
mazhqc@yonyou.com
0dbc363de85b4394ccf875f57659ccb8b5d7a42d
a16e601c65920b444dc0d0ffd56811f5bb9f03a6
/client-api/src/main/java/com/client/model/Telephone.java
eea720b33fd0075076aea7de494b96793e245a83
[]
no_license
leonardothieme/client-api
f0f4b4ffc66ad05caba7b6726fde6bdd3a3318fa
2c361afd74d064618778f23d44576eac6c986bd8
refs/heads/master
2023-02-19T23:22:12.671702
2021-01-25T21:19:37
2021-01-25T21:19:37
332,885,903
0
0
null
null
null
null
UTF-8
Java
false
false
55
java
package com.client.model; public class Telephone { }
[ "leonardo.thieme@fcamara.com.br" ]
leonardo.thieme@fcamara.com.br
157cf2694df864f4e89dbb981a205d999bb1071e
bcb7fa156542b4242b5bf22c2b0d0054a7125c9e
/src/main/java/com/digitalweb/web/rest/errors/package-info.java
cfa3b740ac94b99314cd5a854592f0f96e89c78a
[]
no_license
lehung2907/DigitalWeb
8b3f369518fab8d2d00a3e04a99cc144f588fbee
efbf11d0eeffa1ff6654118dacd8b89334b51eb5
refs/heads/master
2023-05-13T22:53:42.952502
2020-03-19T04:56:55
2020-03-19T04:56:55
248,412,916
0
0
null
null
null
null
UTF-8
Java
false
false
189
java
/** * Specific errors used with Zalando's "problem-spring-web" library. * * More information on https://github.com/zalando/problem-spring-web */ package com.digitalweb.web.rest.errors;
[ "hunglv@teca.vn" ]
hunglv@teca.vn
5f24fd431ac5587c578fd6bae0fe6380ca914cf0
86f6fa9d73d40220f8c3f113ad45803a2b176273
/app/src/main/java/com/example/a28778/coolweather/gson/Now.java
d1e631c0fd63d9dccae5e986178616e482246c9a
[ "Apache-2.0" ]
permissive
jiangjunhua/coolweather
e31c5030d73c871195c7f5eb2fca10b185d4271d
df1bb9467f6218c24510771822217099183fe2f5
refs/heads/master
2020-04-17T20:39:03.227763
2019-01-23T06:51:22
2019-01-23T06:51:22
166,914,996
0
0
null
null
null
null
UTF-8
Java
false
false
318
java
package com.example.a28778.coolweather.gson; import com.google.gson.annotations.SerializedName; public class Now { @SerializedName("tmp") public String temperature; @SerializedName("cond") public More more; public class More { @SerializedName("txt") public String info; } }
[ "287787472@qq.com" ]
287787472@qq.com
6ad7b393c38eedc217d1f399cf488da05026953c
ae9ca1b290bbbc8c21fe354bc612b55e0058e2a1
/src/main/java/com/uca/cesar/config/JPAConfiguration.java
4b2f2138a6be11392a7ca2bd199aa4b417975e2f
[]
no_license
CesarRosales16/PNC-Parcial2-00060917
298f5b577344ceca7e0f2a1a441128fd21ff3e50
252d7717f387b3513f51a569b0cee0477241362f
refs/heads/master
2022-08-23T11:55:41.209531
2020-05-26T03:47:42
2020-05-26T03:47:42
266,908,919
0
0
null
null
null
null
UTF-8
Java
false
false
2,218
java
package com.uca.cesar.config; import java.util.Properties; import javax.persistence.EntityManagerFactory; import javax.sql.DataSource; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import org.springframework.jdbc.datasource.DriverManagerDataSource; import org.springframework.orm.jpa.JpaTransactionManager; import org.springframework.orm.jpa.JpaVendorAdapter; import org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean; import org.springframework.orm.jpa.vendor.HibernateJpaVendorAdapter; import org.springframework.transaction.annotation.EnableTransactionManagement; @Configuration @EnableTransactionManagement public class JPAConfiguration { @Bean public LocalContainerEntityManagerFactoryBean entityManagerFactory() { LocalContainerEntityManagerFactoryBean em = new LocalContainerEntityManagerFactoryBean(); em.setDataSource(dataSource()); em.setPersistenceUnitName("parcial-persistence"); em.setPackagesToScan("com.uca.cesar.domain"); JpaVendorAdapter vendorAdapter = new HibernateJpaVendorAdapter(); em.setJpaVendorAdapter(vendorAdapter); em.setJpaProperties(hibernateProperties()); return em; } @Bean JpaTransactionManager transactionManager(EntityManagerFactory entityManagerFactory) { JpaTransactionManager transactionManager = new JpaTransactionManager(); transactionManager.setEntityManagerFactory(entityManagerFactory); return transactionManager; } @Bean public DataSource dataSource() { DriverManagerDataSource dataSource = new DriverManagerDataSource(); dataSource.setDriverClassName("org.postgresql.Driver"); // dataSource.setUrl(“jdbc:postgresql://<Dirección ip>:<puerto>/<nombre_base”) dataSource.setUrl("jdbc:postgresql://localhost:5432/examen"); dataSource.setUsername("postgres"); dataSource.setPassword("root"); return dataSource; } Properties hibernateProperties() { Properties properties = new Properties(); properties.setProperty("hibernate.show_sql", "true"); properties.setProperty("hibernate.dialect", "org.hibernate.dialect.PostgreSQLDialect"); properties.setProperty("hibernate.enable_lazy_load_no_trans", "true"); return properties; } }
[ "00060917@uca.edu.sv" ]
00060917@uca.edu.sv
84aa48cb34c7016b8ccb540ae19cd13921183043
fbdef7055d401b7dbedf4308783081d2f8df5472
/app/src/test/java/com/sheroy/android/calculator/ExampleUnitTest.java
926dd8b5b0aac9a991bdb8c4e9cf51f278220fbf
[]
no_license
Sheroyi/Calculator
a4d7db38231fcd6a194874cb368b7296269f0f0b
1143bd258eaa6bc199f5e1508bcc99d5e36c2a03
refs/heads/master
2020-04-06T23:54:05.688304
2018-11-16T10:59:25
2018-11-16T10:59:25
157,855,077
0
0
null
null
null
null
UTF-8
Java
false
false
390
java
package com.sheroy.android.calculator; import org.junit.Test; import static org.junit.Assert.*; /** * Example local unit test, which will execute on the development machine (host). * * @see <a href="http://d.android.com/tools/testing">Testing documentation</a> */ public class ExampleUnitTest { @Test public void addition_isCorrect() { assertEquals(4, 2 + 2); } }
[ "tjh951031@gmail.com" ]
tjh951031@gmail.com
98196a19584546f5fb590c4e135941ad5311b23c
2b79120d4da4a8c3b18669241306cb85a77d6c8d
/03 Arrays/src/com/brillio/training/programs/Program04.java
ea7d78bec5de41379ece8e1f2aba62975e8e731a
[]
no_license
MadhumathiBalachandar/brillio
dc7a5e9a5fe70c9759b434552c0ca0d6fbcfa90e
8b929259667a43fce4c5d45b41d889d4d7d17d5f
refs/heads/master
2021-01-10T17:00:38.615916
2015-10-05T11:20:13
2015-10-05T11:20:13
43,680,644
0
0
null
null
null
null
UTF-8
Java
false
false
379
java
package com.brillio.training.programs; public class Program04 { public static void main(String[] args) { //array of 4 strings String[] names={"Scott", "Miller", "Alien", "Jones"}; //enhanced for loop(for-each loop) // introduced in java 1.5 for(String name: names) { System.out.println(name); } System.out.println("Name at index 1 is"+ names[1]); } }
[ "madhumathi.mit@gmail.com" ]
madhumathi.mit@gmail.com
83057cab28d18cf10e2a2c09eff275446afc9c76
1290616ba76700ae8b8ddfb760305428f0c01445
/spring-demo-annotations/src/com/luv2code/springdemo/SportConfig.java
1bf5961e0d44ee879e58822029484c9d04d708ab
[]
no_license
MiskaRantala/Java-Spring-Annotations-Demo
a4cab4a9b314dee8847422c9e821d0d6a52e634f
5b959cb384908883400b41ff708c87affab67c90
refs/heads/master
2020-05-18T00:22:29.352895
2019-04-29T19:19:10
2019-04-29T19:19:10
184,060,473
1
0
null
null
null
null
UTF-8
Java
false
false
719
java
package com.luv2code.springdemo; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.Configuration; import org.springframework.context.annotation.PropertySource; @Configuration // @ComponentScan("com.luv2code.springdemo") @PropertySource("classpath:sport.properties") public class SportConfig { // define bean for our sad fortune service @Bean public FortuneService sadFortuneService() { return new SadFortuneService(); } // define bean for our swim coach AND inject dependency @Bean public Coach swimCoach() { return new SwimCoach(sadFortuneService()); } }
[ "31501140+MiskaRantala@users.noreply.github.com" ]
31501140+MiskaRantala@users.noreply.github.com
83a5084510f925fe09303071d3707fa7144282ab
5dd3b90ff82c6eaef389ff731d45f6578d8bc5f5
/src/main/java/com/xxh/fang/Dao/CommentDao.java
ba5ab91e65218491f5a78f78b4ccf154afc0cd5b
[]
no_license
tang2988/house-trade-provider
0fc54e19e0f9fe22d9604ffa5f43e19de5e05d80
f0c09f208b5a2e57ab00a8faf19b14b9002e9d24
refs/heads/master
2020-03-18T23:11:28.343532
2018-06-11T07:46:14
2018-06-11T07:46:14
135,387,760
0
0
null
null
null
null
UTF-8
Java
false
false
647
java
package com.xxh.fang.Dao; import java.util.List; import java.util.Map; import org.springframework.stereotype.Repository; import com.xxh.fang.entity.CommentAndCustomerVo; import com.xxh.fang.entity.CommentPo; import com.xxh.fang.entity.CommentVo; @Repository public interface CommentDao { public List<CommentAndCustomerVo> sentimentHigh(); public List<CommentAndCustomerVo> newest(); public List<CommentAndCustomerVo> earliest(); public int updatePointOfpraise(CommentVo commentVo); public CommentPo findBycommentOnID(Long commentOnID); public Map<String, Object> FocusOn(Long customerId); public int addComment(CommentPo po); }
[ "tang2988@qq.com" ]
tang2988@qq.com
c2695c5b3f41c28e2b4727cc6c8c58f18fe59399
0290d445346c77aa933d3be7741bfe51cd85cdfa
/app/src/main/java/com/duoyi/drawguess/model/Room.java
7afe725c683157d6d8ee0ddcdc0072bb9fc2fe8f
[]
no_license
YMlion/DG
0dfdbf09664630b9a189de740f7d859abfe5c4df
a33fce31ab163ae3e05076d0e5e38ce16525acd8
refs/heads/master
2021-05-14T04:48:11.000929
2018-02-06T03:31:42
2018-02-06T03:31:42
116,652,814
0
0
null
null
null
null
UTF-8
Java
false
false
173
java
package com.duoyi.drawguess.model; /** * Created by YMlion on 2018/1/02. */ public class Room { public int id; public String game; public boolean started; }
[ "lm_yao@163.com" ]
lm_yao@163.com
117ed9b7f3c8dfb2c2224c9ee2d920e800d27a74
605287716755db64a8f7646fe989cf3a417cd492
/FiveChess/src/comm/ChessPlayer.java
bc122f6237ff3de9600f8bbfc73dde02ff90e5d1
[]
no_license
Kurozaki/FiveChess
c6fce4c420ce2a8bd850f9dc22c418d7c36fb20e
9e88d60f4800507543b40bee8abca33389f8c72e
refs/heads/master
2021-09-08T13:47:01.080426
2018-03-10T01:23:57
2018-03-10T01:23:57
124,610,763
0
0
null
null
null
null
UTF-8
Java
false
false
1,355
java
package comm; import java.awt.*; import java.net.InetAddress; /** * Created by YotWei on 2017/12/4. * chess player */ public class ChessPlayer { private InetAddress mAddress; private int mPort; private String nickname; public ChessPlayer(InetAddress mAddress, int mPort, String nickname) { this.mAddress = mAddress; this.mPort = mPort; this.nickname = nickname; this.mStatus = Status.ONLINE; } public InetAddress getAddress() { return mAddress; } public int getPort() { return mPort; } public String getNickname() { return nickname; } private Status mStatus = Status.OFFLINE; private Color mColor = Color.BLACK; public void setColor(Color color) { this.mColor = color; } public void offLine() { this.mStatus = Status.OFFLINE; } public void setStatus(Status mStatus) { this.mStatus = mStatus; } public Status getStatus() { return mStatus; } @Override public String toString() { return "ChessPlayer{" + "mAddress=" + mAddress.getHostAddress() + ", mPort=" + mPort + ", nickname='" + nickname + '\'' + '}'; } public enum Status { OFFLINE, ONLINE, PREPARE, IN_GAME, } }
[ "1169559037@qq.com" ]
1169559037@qq.com
0c04bddf8daede678894f065bf99fbe34d35f527
f1fb35c4e150bd700475a1e096f8a7856614479e
/AuthorRetriever/src/main/java/com/neu/msd/AuthorRetriever/dao/SearchPaperDao.java
cbf7bf2e76bea9d6ae1676cc7667d916d9d4bc25
[]
no_license
rgaswin/DBLP-Parser-and-Committee-finder-
1ffcc9d039468d785f2022090e3da6b88d2c4a29
3f22ddb6948aaa50af4f7933791553a8a3a6dde2
refs/heads/master
2021-07-05T04:28:23.380358
2017-09-30T02:45:15
2017-09-30T02:45:15
105,335,394
0
0
null
null
null
null
UTF-8
Java
false
false
549
java
package com.neu.msd.AuthorRetriever.dao; import java.sql.SQLException; import java.util.List; import com.neu.msd.AuthorRetriever.model.AuthorPaper; import com.neu.msd.AuthorRetriever.model.Paper; /** * @param A query String to retrieve a list of AuthorPaper from database * @return A list of AuthorPaper Mapping * Retrieve a list of Author Paper mappings from database.This is a abstract implementation of the methods */ public interface SearchPaperDao { public List<AuthorPaper> retrievePapers(String queryString) throws SQLException; }
[ "rgaswin@ccs.neu.edu" ]
rgaswin@ccs.neu.edu
492472e36ae8b1b9ba05348f987a35536d033337
dc1493639473c80619cf8de44fe012e36ed7c6f1
/src/main/java/State.java
3a3d5fc955bb194574dc895fb64f40ed2f7e5608
[]
no_license
ANewHope/TicTacToe
01a75379257480a56a16b6b34fd0a9616ad220e2
4c0dbe0469d5b7d82047df31f32593d41cb17c20
refs/heads/master
2020-06-03T18:05:50.811387
2014-11-04T13:53:07
2014-11-04T13:53:07
null
0
0
null
null
null
null
UTF-8
Java
false
false
37
java
public enum State { ON, TIE, WIN }
[ "asfalt@i-c39488ed.greenqloud.internal" ]
asfalt@i-c39488ed.greenqloud.internal
88a70e22a75a41130afdb999f99465ce6389a72b
d0287bdd0b421971f6c8ce41d9c0a194c7bdf17e
/src/main/java/com/framework/automation/cucumber/env/EnvironmentPreparer.java
f1a39bdc9a64077ac6d82eb4405828a954570e92
[]
no_license
godisloveforme/echotest
fefd4f8d4142a3a773c154cc156588c41fa62763
c742dcc4ba421da8b77621fc122e46818fb6aca3
refs/heads/master
2021-08-08T10:48:51.534499
2017-11-10T06:42:09
2017-11-10T06:42:09
110,087,212
0
0
null
null
null
null
UTF-8
Java
false
false
1,921
java
package com.framework.automation.cucumber.env; import java.io.IOException; import java.io.InputStream; import java.text.DateFormat; import java.text.SimpleDateFormat; import java.util.Date; import java.util.Properties; import org.apache.log4j.LogManager; import org.apache.log4j.Logger; import org.springframework.core.io.ClassPathResource; import org.springframework.core.io.Resource; public class EnvironmentPreparer { private boolean isReady; private Properties envInfo; private static EnvironmentPreparer instance; private final static Logger log = LogManager.getLogger(EnvironmentPreparer.class); private EnvironmentPreparer(){ } public static EnvironmentPreparer getInstance(){ if(EnvironmentPreparer.instance==null) { EnvironmentPreparer.instance = new EnvironmentPreparer(); } return EnvironmentPreparer.instance; } public boolean isReady() { return this.isReady; } private void setReady(final boolean isReady) { this.isReady = isReady; } public void prepare(final String envId) { String fileURL = "env/properties/"+envId+".properties"; Resource resource = new ClassPathResource(fileURL); this.envInfo = new Properties(); try { InputStream is = resource.getInputStream(); this.envInfo.load(is); this.envInfo.put(EnvConstant.TEST_SESSION_NAME, this.constructSessionName(envId)); setReady(true); EnvironmentPreparer.log.info("Complete preparation for test environment: " + envId); } catch (IOException e) { setReady(false); EnvironmentPreparer.log.info("Incomplete preparation for test environment: " + envId); } } public String getEnvInfo(final String key) { return this.envInfo.getProperty(key,""); } private String constructSessionName (final String envId) { DateFormat dateFormat = new SimpleDateFormat("MM-dd-yyyy_hh.mm.ss"); Date date = new Date(); return envId + "_" + dateFormat.format(date); } }
[ "wason21cn@hotmail.com" ]
wason21cn@hotmail.com
6a63b9eda28af94e3ef5434d95a8875b4be567c0
3ee6d6a1ca3f19b56eab7936a1e2839fc4b29e78
/study/src/com/test0328/Test1.java
91111f92a1a64e1f4a0b0f01de4341f5e5d4c924
[]
no_license
daegi/study-dg
2764592b0f0914ec64b0a418a0417a1d6091651f
ad9862ecb60aca7265481daf7735d9dfd826e5f6
refs/heads/master
2021-01-19T13:52:59.044839
2014-07-25T03:27:26
2014-07-25T03:27:26
32,976,520
0
0
null
null
null
null
WINDOWS-1252
Java
false
false
986
java
package com.test0328; public class Test1 { public static void main(String[] args) { /* * int s; * * for(int a=2; a<=9;a++){ System.out.println(a+"´Ü..."); * * for(int b=1; b<=9; b++){ s=a*b; System.out.println(a+"*"+b+"="+s); } * System.out.println("-------------------"); } */ /* * for(int a=1; a<=5; a++){ for(int b=1; b<5-a; b++){ * System.out.println(" "); } * * for(int b=1; b<=a; b++){ System.out.print("*"); } * * } System.out.println(); */ /* for (int a = 1; a <= 5; a++) { for (int b = 1; b < 5 - a; b++) { System.out.print(" "); } for (int b = 1; b <= a*3; b++) { System.out.print("*"); } System.out.println(); }*/ for (int a = 5; a >= 1; a--) { for (int b = 1; b <= 5 - a; b++) { System.out.print(" "); } for (int b = 1; b <= a*2-1; b++) { System.out.print("*"); } System.out.println(); } } }
[ "choyc82@cf0b24a7-709c-1eb7-a6c0-50069b54bc80" ]
choyc82@cf0b24a7-709c-1eb7-a6c0-50069b54bc80
c88ac9a73521290fabcbaf6240d070ab606df1b1
0b26aac6cb5103a25ee1cf73663a3e0adff780b4
/kubernetes/src/test/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassListTest.java
6871b8299d0ec27d74eb6cfc443f834b8848c073
[ "Apache-2.0" ]
permissive
wings-software/java
b7b551989aaf6a943b0f9bf26c4e030ddc6a99f6
ec60b5246a444631fb1a2c72bda6bfb901679bef
refs/heads/master
2020-09-20T14:28:47.084448
2019-12-18T20:41:46
2019-12-18T20:41:46
224,510,803
1
0
Apache-2.0
2019-12-18T20:41:47
2019-11-27T20:21:05
null
UTF-8
Java
false
false
1,848
java
/* * Kubernetes * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: v1.15.6 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ package io.kubernetes.client.openapi.models; import com.google.gson.TypeAdapter; import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; import com.google.gson.stream.JsonReader; import com.google.gson.stream.JsonWriter; import io.kubernetes.client.openapi.models.V1ListMeta; import io.kubernetes.client.openapi.models.V1beta1RuntimeClass; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; import java.util.ArrayList; import java.util.List; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; /** * Model tests for V1beta1RuntimeClassList */ public class V1beta1RuntimeClassListTest { private final V1beta1RuntimeClassList model = new V1beta1RuntimeClassList(); /** * Model tests for V1beta1RuntimeClassList */ @Test public void testV1beta1RuntimeClassList() { // TODO: test V1beta1RuntimeClassList } /** * Test the property 'apiVersion' */ @Test public void apiVersionTest() { // TODO: test apiVersion } /** * Test the property 'items' */ @Test public void itemsTest() { // TODO: test items } /** * Test the property 'kind' */ @Test public void kindTest() { // TODO: test kind } /** * Test the property 'metadata' */ @Test public void metadataTest() { // TODO: test metadata } }
[ "291271447@qq.com" ]
291271447@qq.com
00632d560aa0405e74cb5b910f0e6b340d1b1c07
25d4017096efd48c70d0c2e1cb49cf06bf1401dc
/wordsweeper-core/src/main/test/com/wordsweeper/core/xml/JoinGameResponseTest.java
055eb27634c66ab0cb168145b80633601672e837
[]
no_license
frankgh/CS509
48cdfaf0aef252e0858cea7284802d1e9e79c12f
0b45addc31f38d96a7b9c84d83a3bb4b009663ce
refs/heads/master
2020-04-11T01:32:14.102358
2016-12-14T13:54:57
2016-12-14T13:54:57
68,151,139
1
0
null
2016-12-14T13:39:53
2016-09-13T22:04:09
Java
UTF-8
Java
false
false
349
java
package com.wordsweeper.core.xml; import org.junit.Test; import static org.junit.Assert.assertEquals; public class JoinGameResponseTest { @Test public void constructor() throws Exception { JoinGameResponse res = new JoinGameResponse(); res.setGameId("testID"); assertEquals(res.getGameId(), "testID"); } }
[ "frank.guerrero@gmail.com" ]
frank.guerrero@gmail.com
d1f140c2fa02f345d2f2473521934d3a237d1260
007503b401aa9e4eaab84821ff241280888e1ff4
/pro-service/src/main/java/com/dbin/dao/ScoreDao.java
579d1fd2fae02ff347a9bcd2321de94683f443da
[]
no_license
dbin1573/dbin-project-be-demo-v2
c6e5c08220184b432ec7503fb2ccc6a24a8143cd
3f1c249461b7a290f9579ef4fda3945cf3358e5e
refs/heads/master
2022-04-26T02:55:01.296094
2020-04-25T12:44:45
2020-04-25T12:44:45
258,691,629
0
0
null
null
null
null
UTF-8
Java
false
false
553
java
package com.dbin.dao; import com.dbin.entity.Score; import org.springframework.data.jpa.repository.JpaRepository; import org.springframework.data.repository.Repository; import org.springframework.stereotype.Component; //@Repository @Component public interface ScoreDao extends JpaRepository<Long, Score> { // int insertScore(Score score); // // int deleteScore(Score score); // // int updateScore(Score score); // List<Score> searchFromScore(String s); // Score selectScoreById(Score score); // List<Score> selectAllScores(); }
[ "tenggeli999@163.com" ]
tenggeli999@163.com
80359e6b4ca0da64702e7c6e2f9afc991a701ad0
5598faaaaa6b3d1d8502cbdaca903f9037d99600
/code_changes/Apache_projects/HDFS-162/c14bb61a82f58b8b3ae37c6a6cc4fabe9f65dbec/~ClientNamenodeProtocolTranslatorR23.java
08830285c6ca0155ed557c6251fd8fb7f2465fb6
[]
no_license
SPEAR-SE/LogInBugReportsEmpirical_Data
94d1178346b4624ebe90cf515702fac86f8e2672
ab9603c66899b48b0b86bdf63ae7f7a604212b29
refs/heads/master
2022-12-18T02:07:18.084659
2020-09-09T16:49:34
2020-09-09T16:49:34
286,338,252
0
2
null
null
null
null
UTF-8
Java
false
false
18,023
java
/** * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you 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.apache.hadoop.hdfs.protocolR23Compatible; import java.io.Closeable; import java.io.FileNotFoundException; import java.io.IOException; import java.net.InetSocketAddress; import java.util.HashMap; import java.util.Map; import java.util.concurrent.TimeUnit; import org.apache.hadoop.classification.InterfaceAudience; import org.apache.hadoop.classification.InterfaceStability; import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.fs.ContentSummary; import org.apache.hadoop.fs.CreateFlag; import org.apache.hadoop.fs.FileAlreadyExistsException; import org.apache.hadoop.fs.FsServerDefaults; import org.apache.hadoop.fs.ParentNotDirectoryException; import org.apache.hadoop.fs.UnresolvedLinkException; import org.apache.hadoop.fs.Options.Rename; import org.apache.hadoop.fs.permission.FsPermission; import org.apache.hadoop.hdfs.protocol.AlreadyBeingCreatedException; import org.apache.hadoop.hdfs.protocol.ClientProtocol; import org.apache.hadoop.hdfs.protocol.LocatedBlock; import org.apache.hadoop.hdfs.protocol.LocatedBlocks; import org.apache.hadoop.hdfs.protocol.CorruptFileBlocks; import org.apache.hadoop.hdfs.protocol.DSQuotaExceededException; import org.apache.hadoop.hdfs.protocol.DatanodeID; import org.apache.hadoop.hdfs.protocol.DatanodeInfo; import org.apache.hadoop.hdfs.protocol.DirectoryListing; import org.apache.hadoop.hdfs.protocol.ExtendedBlock; import org.apache.hadoop.hdfs.protocol.HdfsFileStatus; import org.apache.hadoop.hdfs.protocol.NSQuotaExceededException; import org.apache.hadoop.hdfs.protocol.HdfsConstants.DatanodeReportType; import org.apache.hadoop.hdfs.protocol.HdfsConstants.SafeModeAction; import org.apache.hadoop.hdfs.protocol.HdfsConstants.UpgradeAction; import org.apache.hadoop.hdfs.security.token.delegation.DelegationTokenIdentifier; import org.apache.hadoop.hdfs.server.common.UpgradeStatusReport; import org.apache.hadoop.hdfs.server.namenode.NameNode; import org.apache.hadoop.hdfs.server.namenode.NotReplicatedYetException; import org.apache.hadoop.hdfs.server.namenode.SafeModeException; import org.apache.hadoop.io.EnumSetWritable; import org.apache.hadoop.io.Text; import org.apache.hadoop.io.retry.RetryPolicies; import org.apache.hadoop.io.retry.RetryPolicy; import org.apache.hadoop.io.retry.RetryProxy; import org.apache.hadoop.ipc.ProtocolSignature; import org.apache.hadoop.ipc.RPC; import org.apache.hadoop.ipc.RemoteException; import org.apache.hadoop.net.NetUtils; import org.apache.hadoop.security.AccessControlException; import org.apache.hadoop.security.UserGroupInformation; import org.apache.hadoop.security.token.Token; import org.apache.hadoop.hdfs.protocol.HdfsConstants; /** * This class forwards NN's ClientProtocol calls as RPC calls to the NN server * while translating from the parameter types used in ClientProtocol to those * used in protocolR23Compatile.*. */ @InterfaceAudience.Private @InterfaceStability.Stable public class ClientNamenodeProtocolTranslatorR23 implements ClientProtocol, Closeable { final private ClientNamenodeWireProtocol rpcProxy; private static ClientNamenodeWireProtocol createNamenode( InetSocketAddress nameNodeAddr, Configuration conf, UserGroupInformation ugi) throws IOException { return RPC.getProxy(ClientNamenodeWireProtocol.class, ClientNamenodeWireProtocol.versionID, nameNodeAddr, ugi, conf, NetUtils.getSocketFactory(conf, ClientNamenodeWireProtocol.class)); } /** Create a {@link NameNode} proxy */ static ClientNamenodeWireProtocol createNamenodeWithRetry( ClientNamenodeWireProtocol rpcNamenode) { RetryPolicy createPolicy = RetryPolicies .retryUpToMaximumCountWithFixedSleep(5, HdfsConstants.LEASE_SOFTLIMIT_PERIOD, TimeUnit.MILLISECONDS); Map<Class<? extends Exception>, RetryPolicy> remoteExceptionToPolicyMap = new HashMap<Class<? extends Exception>, RetryPolicy>(); remoteExceptionToPolicyMap.put(AlreadyBeingCreatedException.class, createPolicy); Map<Class<? extends Exception>, RetryPolicy> exceptionToPolicyMap = new HashMap<Class<? extends Exception>, RetryPolicy>(); exceptionToPolicyMap.put(RemoteException.class, RetryPolicies .retryByRemoteException(RetryPolicies.TRY_ONCE_THEN_FAIL, remoteExceptionToPolicyMap)); RetryPolicy methodPolicy = RetryPolicies.retryByException( RetryPolicies.TRY_ONCE_THEN_FAIL, exceptionToPolicyMap); Map<String, RetryPolicy> methodNameToPolicyMap = new HashMap<String, RetryPolicy>(); methodNameToPolicyMap.put("create", methodPolicy); return (ClientNamenodeWireProtocol) RetryProxy.create( ClientNamenodeWireProtocol.class, rpcNamenode, methodNameToPolicyMap); } public ClientNamenodeProtocolTranslatorR23(InetSocketAddress nameNodeAddr, Configuration conf, UserGroupInformation ugi) throws IOException { rpcProxy = createNamenodeWithRetry(createNamenode(nameNodeAddr, conf, ugi)); } public void close() { RPC.stopProxy(rpcProxy); } @Override public ProtocolSignature getProtocolSignature(String protocolName, long clientVersion, int clientMethodHash) throws IOException { return ProtocolSignatureWritable.convert(rpcProxy.getProtocolSignature2( protocolName, clientVersion, clientMethodHash)); } @Override public long getProtocolVersion(String protocolName, long clientVersion) throws IOException { return rpcProxy.getProtocolVersion(protocolName, clientVersion); } @Override public LocatedBlocks getBlockLocations(String src, long offset, long length) throws AccessControlException, FileNotFoundException, UnresolvedLinkException, IOException { return LocatedBlocksWritable .convertLocatedBlocks(rpcProxy.getBlockLocations(src, offset, length)); } @Override public FsServerDefaults getServerDefaults() throws IOException { return FsServerDefaultsWritable .convert(rpcProxy.getServerDefaults()); } @Override public void create(String src, FsPermission masked, String clientName, EnumSetWritable<CreateFlag> flag, boolean createParent, short replication, long blockSize) throws AccessControlException, AlreadyBeingCreatedException, DSQuotaExceededException, FileAlreadyExistsException, FileNotFoundException, NSQuotaExceededException, ParentNotDirectoryException, SafeModeException, UnresolvedLinkException, IOException { rpcProxy.create(src, FsPermissionWritable.convertPermission(masked), clientName, flag, createParent, replication, blockSize); } @Override public LocatedBlock append(String src, String clientName) throws AccessControlException, DSQuotaExceededException, FileNotFoundException, SafeModeException, UnresolvedLinkException, IOException { return LocatedBlockWritable .convertLocatedBlock(rpcProxy.append(src, clientName)); } @Override public boolean setReplication(String src, short replication) throws AccessControlException, DSQuotaExceededException, FileNotFoundException, SafeModeException, UnresolvedLinkException, IOException { return rpcProxy.setReplication(src, replication); } @Override public void setPermission(String src, FsPermission permission) throws AccessControlException, FileNotFoundException, SafeModeException, UnresolvedLinkException, IOException { rpcProxy.setPermission(src, FsPermissionWritable.convertPermission(permission)); } @Override public void setOwner(String src, String username, String groupname) throws AccessControlException, FileNotFoundException, SafeModeException, UnresolvedLinkException, IOException { rpcProxy.setOwner(src, username, groupname); } @Override public void abandonBlock(ExtendedBlock b, String src, String holder) throws AccessControlException, FileNotFoundException, UnresolvedLinkException, IOException { rpcProxy.abandonBlock( ExtendedBlockWritable.convertExtendedBlock(b), src, holder); } @Override public LocatedBlock addBlock(String src, String clientName, ExtendedBlock previous, DatanodeInfo[] excludeNodes) throws AccessControlException, FileNotFoundException, NotReplicatedYetException, SafeModeException, UnresolvedLinkException, IOException { return LocatedBlockWritable .convertLocatedBlock(rpcProxy.addBlock(src, clientName, ExtendedBlockWritable.convertExtendedBlock(previous), DatanodeInfoWritable.convertDatanodeInfo(excludeNodes))); } @Override public LocatedBlock getAdditionalDatanode(String src, ExtendedBlock blk, DatanodeInfo[] existings, DatanodeInfo[] excludes, int numAdditionalNodes, String clientName) throws AccessControlException, FileNotFoundException, SafeModeException, UnresolvedLinkException, IOException { return LocatedBlockWritable .convertLocatedBlock(rpcProxy.getAdditionalDatanode(src, ExtendedBlockWritable.convertExtendedBlock(blk), DatanodeInfoWritable.convertDatanodeInfo(existings), DatanodeInfoWritable.convertDatanodeInfo(excludes), numAdditionalNodes, clientName)); } @Override public boolean complete(String src, String clientName, ExtendedBlock last) throws AccessControlException, FileNotFoundException, SafeModeException, UnresolvedLinkException, IOException { return rpcProxy.complete(src, clientName, ExtendedBlockWritable.convertExtendedBlock(last)); } @Override public void reportBadBlocks(LocatedBlock[] blocks) throws IOException { rpcProxy.reportBadBlocks(LocatedBlockWritable.convertLocatedBlock(blocks)); } @Override public boolean rename(String src, String dst) throws UnresolvedLinkException, IOException { return rpcProxy.rename(src, dst); } @Override public void concat(String trg, String[] srcs) throws IOException, UnresolvedLinkException { rpcProxy.concat(trg, srcs); } @Override public void rename2(String src, String dst, Rename... options) throws AccessControlException, DSQuotaExceededException, FileAlreadyExistsException, FileNotFoundException, NSQuotaExceededException, ParentNotDirectoryException, SafeModeException, UnresolvedLinkException, IOException { rpcProxy.rename2(src, dst, options); } @Override public boolean delete(String src, boolean recursive) throws AccessControlException, FileNotFoundException, SafeModeException, UnresolvedLinkException, IOException { return rpcProxy.delete(src, recursive); } @Override public boolean mkdirs(String src, FsPermission masked, boolean createParent) throws AccessControlException, FileAlreadyExistsException, FileNotFoundException, NSQuotaExceededException, ParentNotDirectoryException, SafeModeException, UnresolvedLinkException, IOException { return rpcProxy.mkdirs(src, FsPermissionWritable.convertPermission(masked), createParent); } @Override public DirectoryListing getListing(String src, byte[] startAfter, boolean needLocation) throws AccessControlException, FileNotFoundException, UnresolvedLinkException, IOException { return DirectoryListingWritable.convertDirectoryListing( rpcProxy.getListing(src, startAfter, needLocation)); } @Override public void renewLease(String clientName) throws AccessControlException, IOException { rpcProxy.renewLease(clientName); } @Override public boolean recoverLease(String src, String clientName) throws IOException { return rpcProxy.recoverLease(src, clientName); } @Override public long[] getStats() throws IOException { return rpcProxy.getStats(); } @Override public DatanodeInfo[] getDatanodeReport(DatanodeReportType type) throws IOException { return DatanodeInfoWritable.convertDatanodeInfo( rpcProxy.getDatanodeReport(type)); } @Override public long getPreferredBlockSize(String filename) throws IOException, UnresolvedLinkException { return rpcProxy.getPreferredBlockSize(filename); } @Override public boolean setSafeMode(SafeModeAction action) throws IOException { return rpcProxy.setSafeMode(action); } @Override public void saveNamespace() throws AccessControlException, IOException { rpcProxy.saveNamespace(); } @Override public boolean restoreFailedStorage(String arg) throws AccessControlException, IOException{ return rpcProxy.restoreFailedStorage(arg); } @Override public void refreshNodes() throws IOException { rpcProxy.refreshNodes(); } @Override public void finalizeUpgrade() throws IOException { rpcProxy.finalizeUpgrade(); } @Override public UpgradeStatusReport distributedUpgradeProgress(UpgradeAction action) throws IOException { return UpgradeStatusReportWritable.convert( rpcProxy.distributedUpgradeProgress(action)); } @Override public CorruptFileBlocks listCorruptFileBlocks(String path, String cookie) throws IOException { return CorruptFileBlocksWritable.convertCorruptFileBlocks( rpcProxy.listCorruptFileBlocks(path, cookie)); } @Override public void metaSave(String filename) throws IOException { rpcProxy.metaSave(filename); } @Override public HdfsFileStatus getFileInfo(String src) throws AccessControlException, FileNotFoundException, UnresolvedLinkException, IOException { return HdfsFileStatusWritable.convertHdfsFileStatus( rpcProxy.getFileInfo(src)); } @Override public HdfsFileStatus getFileLinkInfo(String src) throws AccessControlException, UnresolvedLinkException, IOException { return HdfsFileStatusWritable .convertHdfsFileStatus(rpcProxy.getFileLinkInfo(src)); } @Override public ContentSummary getContentSummary(String path) throws AccessControlException, FileNotFoundException, UnresolvedLinkException, IOException { return ContentSummaryWritable .convert(rpcProxy.getContentSummary(path)); } @Override public void setQuota(String path, long namespaceQuota, long diskspaceQuota) throws AccessControlException, FileNotFoundException, UnresolvedLinkException, IOException { rpcProxy.setQuota(path, namespaceQuota, diskspaceQuota); } @Override public void fsync(String src, String client) throws AccessControlException, FileNotFoundException, UnresolvedLinkException, IOException { rpcProxy.fsync(src, client); } @Override public void setTimes(String src, long mtime, long atime) throws AccessControlException, FileNotFoundException, UnresolvedLinkException, IOException { rpcProxy.setTimes(src, mtime, atime); } @Override public void createSymlink(String target, String link, FsPermission dirPerm, boolean createParent) throws AccessControlException, FileAlreadyExistsException, FileNotFoundException, ParentNotDirectoryException, SafeModeException, UnresolvedLinkException, IOException { rpcProxy.createSymlink(target, link, FsPermissionWritable.convertPermission(dirPerm), createParent); } @Override public String getLinkTarget(String path) throws AccessControlException, FileNotFoundException, IOException { return rpcProxy.getLinkTarget(path); } @Override public LocatedBlock updateBlockForPipeline(ExtendedBlock block, String clientName) throws IOException { return LocatedBlockWritable.convertLocatedBlock( rpcProxy.updateBlockForPipeline( ExtendedBlockWritable.convertExtendedBlock(block), clientName)); } @Override public void updatePipeline(String clientName, ExtendedBlock oldBlock, ExtendedBlock newBlock, DatanodeID[] newNodes) throws IOException { rpcProxy.updatePipeline(clientName, ExtendedBlockWritable.convertExtendedBlock(oldBlock), ExtendedBlockWritable.convertExtendedBlock(newBlock), DatanodeIDWritable.convertDatanodeID(newNodes)); } @Override public Token<DelegationTokenIdentifier> getDelegationToken(Text renewer) throws IOException { return rpcProxy.getDelegationToken(renewer); } @Override public long renewDelegationToken(Token<DelegationTokenIdentifier> token) throws IOException { return rpcProxy.renewDelegationToken(token); } @Override public void cancelDelegationToken(Token<DelegationTokenIdentifier> token) throws IOException { rpcProxy.cancelDelegationToken(token); } @Override public void setBalancerBandwidth(long bandwidth) throws IOException { rpcProxy.setBalancerBandwidth(bandwidth); } }
[ "archen94@gmail.com" ]
archen94@gmail.com
f0870fe5f749499e77e3619e5031bc51141de598
898a3d368135f4c1e2f6bf4f6cc0566512cf68ee
/ExaggeratingList.java
1917de30245f6634472661a8af1c760f1e429f76
[]
no_license
BBK-PiJ-2015-01/PiJ-Day-15-Exercises
36e2b86a4b84af1c5c959b64fbfdafaa96105c2b
3a08b0aa85a754cda6e9c4c09cd191158725e006
refs/heads/master
2016-09-01T08:41:56.817371
2015-11-16T17:00:47
2015-11-16T17:00:47
46,276,409
0
0
null
null
null
null
UTF-8
Java
false
false
2,847
java
import java.util.*; import java.util.function.*; import java.util.stream.*; public class ExaggeratingList<T> implements List<T>{ private ArrayList<T> underlying = new ArrayList<>(); private final int SMALL_VALUE_SIZE; public static final int DEFAULT_SMALL_VALUE_SIZE = 5; public ExaggeratingList() { this(DEFAULT_SMALL_VALUE_SIZE); } public ExaggeratingList(Integer smallValueSize) { SMALL_VALUE_SIZE = smallValueSize; } public boolean add(T o) { return underlying.add(o); } public void add(int i, T o) { underlying.add(i, o); } public boolean addAll(Collection<? extends T> c) { return underlying.addAll(c); } public boolean addAll(int i, Collection<? extends T> c) { return underlying.addAll(i, c); } public void clear() { underlying.clear(); } public boolean contains(Object o) { return underlying.contains(o); } public boolean containsAll(Collection<?> o) { return underlying.contains(o); } public void forEach(Consumer<? super T> c) { underlying.forEach(c); } public T get(int i) { return underlying.get(i); } public int indexOf(Object o){ return underlying.indexOf(o); } public boolean isEmpty() { return underlying.isEmpty(); } public Iterator<T> iterator() { return underlying.iterator(); } public int lastIndexOf(Object o) { return underlying.lastIndexOf(o); } public ListIterator<T> listIterator() { return underlying.listIterator(); } public ListIterator<T> listIterator(int i) { return underlying.listIterator(i); } public Stream<T> parallelStream() { return underlying.parallelStream(); } public boolean remove(Object o) { return underlying.remove(o); } public T remove(int i) { return underlying.remove(i); } public boolean removeAll(Collection<?> c) { return underlying.removeAll(c); } public boolean removeIf(Predicate<? super T> p) { return underlying.removeIf(p); } public void replaceAll(UnaryOperator<T> u) { underlying.replaceAll(u); } public boolean retainAll(Collection<?> c) { return underlying.retainAll(c); } public T set(int i, T o) { return underlying.set(i, o); } public int size() { return 2 * underlying.size(); } public void sort(Comparator<? super T> c) { underlying.sort(c); } public Spliterator<T> spliterator() { return underlying.spliterator(); } public Stream<T> stream() { return underlying.stream(); } public List<T> subList(int i, int j) { return underlying.subList(i, j); } @SuppressWarnings("unchecked") public Object[] toArray() { return underlying.toArray(); } @SuppressWarnings("unchecked") public <T> T[] toArray(T[] array) { return underlying.toArray(array); } }
[ "sbaird02@CSPC129.dcs.bbk.ac.uk" ]
sbaird02@CSPC129.dcs.bbk.ac.uk
96201934c8ca27301c4206ce2269bd3ffe3d4cfb
b6b2d056fbcfa544a6ae07e91ed9cedad9a19726
/app/src/test/java/com/facol/giovani/bebumsenso/ExampleUnitTest.java
e156d3dc97a25fb53d04653a5ea0729ce160a112
[]
no_license
GamerSenior/BebumSenso
2a5d58351b2187e040fec88f1607bb7f999e28a8
eec7aedb323938e2ee92d31a1b6aff5e7e9fd8be
refs/heads/master
2021-04-12T08:18:34.177520
2018-03-21T00:55:47
2018-03-21T00:55:47
126,102,020
0
0
null
null
null
null
UTF-8
Java
false
false
406
java
package com.facol.giovani.bebumsenso; import org.junit.Test; import static org.junit.Assert.*; /** * Example local unit test, which will execute on the development machine (host). * * @see <a href="http://d.android.com/tools/testing">Testing documentation</a> */ public class ExampleUnitTest { @Test public void addition_isCorrect() throws Exception { assertEquals(4, 2 + 2); } }
[ "abelgiovani@gmail.com" ]
abelgiovani@gmail.com
42ec189ff0b848109391141a98b09a372099b46d
0641855b8dbe8a7f0303c4b632d3b641b1f16b1e
/SaleManager/SaleManager/SaleManager/SaleManager-ejb/src/main/java/model/Purchaseorder.java
f5b791efa53e8599f934d59001c3897b9c9049c9
[]
no_license
ProjectEJB/Project
138220f0f34573fa99a4ece1df2248d1c4551091
11de9d331fe5b236dd1f3f9ad92a70d1bbbfe97f
refs/heads/master
2021-01-12T08:35:02.931559
2016-12-30T08:32:08
2016-12-30T08:32:08
76,619,352
0
0
null
null
null
null
UTF-8
Java
false
false
5,217
java
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package model; import java.io.Serializable; import java.math.BigInteger; import java.util.Date; import javax.persistence.Basic; import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.Id; import javax.persistence.NamedQueries; import javax.persistence.NamedQuery; import javax.persistence.Table; import javax.persistence.Temporal; import javax.persistence.TemporalType; import javax.validation.constraints.NotNull; import javax.validation.constraints.Size; import javax.xml.bind.annotation.XmlRootElement; /** * * @author ANHVT */ @Entity @Table(name = "purchaseorder") @NamedQueries({ @NamedQuery(name = "Purchaseorder.findAll", query = "SELECT p FROM Purchaseorder p"), @NamedQuery(name = "Purchaseorder.findByOrderNo", query = "SELECT p FROM Purchaseorder p WHERE p.orderNo = :orderNo"), @NamedQuery(name = "Purchaseorder.findByAmount", query = "SELECT p FROM Purchaseorder p WHERE p.amount = :amount"), @NamedQuery(name = "Purchaseorder.findByComAmt", query = "SELECT p FROM Purchaseorder p WHERE p.comAmt = :comAmt"), @NamedQuery(name = "Purchaseorder.findByDiscAmt", query = "SELECT p FROM Purchaseorder p WHERE p.discAmt = :discAmt"), @NamedQuery(name = "Purchaseorder.findByOrderDate", query = "SELECT p FROM Purchaseorder p WHERE p.orderDate = :orderDate"), @NamedQuery(name = "Purchaseorder.findByOrderType", query = "SELECT p FROM Purchaseorder p WHERE p.orderType = :orderType"), @NamedQuery(name = "Purchaseorder.findByOverdueDate", query = "SELECT p FROM Purchaseorder p WHERE p.overdueDate = :overdueDate"), @NamedQuery(name = "Purchaseorder.findByPromAmt", query = "SELECT p FROM Purchaseorder p WHERE p.promAmt = :promAmt"), @NamedQuery(name = "Purchaseorder.findByTaxAmt", query = "SELECT p FROM Purchaseorder p WHERE p.taxAmt = :taxAmt"), @NamedQuery(name = "Purchaseorder.deleteByOrtderNo", query = "DELETE FROM Purchaseorder p WHERE p.orderNo = :orderNo")}) public class Purchaseorder implements Serializable { private static final long serialVersionUID = 1L; @Id @Basic(optional = false) @NotNull @Column(name = "OrderNo") private Integer orderNo; @Column(name = "Amount") private BigInteger amount; @Column(name = "ComAmt") private BigInteger comAmt; @Column(name = "DiscAmt") private BigInteger discAmt; @Column(name = "OrderDate") @Temporal(TemporalType.DATE) private Date orderDate; @Size(max = 255) @Column(name = "OrderType") private String orderType; @Column(name = "OverdueDate") @Temporal(TemporalType.DATE) private Date overdueDate; @Column(name = "PromAmt") private BigInteger promAmt; @Column(name = "TaxAmt") private BigInteger taxAmt; public Purchaseorder() { } public Purchaseorder(Integer orderNo) { this.orderNo = orderNo; } public Integer getOrderNo() { return orderNo; } public void setOrderNo(Integer orderNo) { this.orderNo = orderNo; } public BigInteger getAmount() { return amount; } public void setAmount(BigInteger amount) { this.amount = amount; } public BigInteger getComAmt() { return comAmt; } public void setComAmt(BigInteger comAmt) { this.comAmt = comAmt; } public BigInteger getDiscAmt() { return discAmt; } public void setDiscAmt(BigInteger discAmt) { this.discAmt = discAmt; } public Date getOrderDate() { return orderDate; } public void setOrderDate(Date orderDate) { this.orderDate = orderDate; } public String getOrderType() { return orderType; } public void setOrderType(String orderType) { this.orderType = orderType; } public Date getOverdueDate() { return overdueDate; } public void setOverdueDate(Date overdueDate) { this.overdueDate = overdueDate; } public BigInteger getPromAmt() { return promAmt; } public void setPromAmt(BigInteger promAmt) { this.promAmt = promAmt; } public BigInteger getTaxAmt() { return taxAmt; } public void setTaxAmt(BigInteger taxAmt) { this.taxAmt = taxAmt; } @Override public int hashCode() { int hash = 0; hash += (orderNo != null ? orderNo.hashCode() : 0); return hash; } @Override public boolean equals(Object object) { // TODO: Warning - this method won't work in the case the id fields are not set if (!(object instanceof Purchaseorder)) { return false; } Purchaseorder other = (Purchaseorder) object; if ((this.orderNo == null && other.orderNo != null) || (this.orderNo != null && !this.orderNo.equals(other.orderNo))) { return false; } return true; } @Override public String toString() { return "entities.Purchaseorder[ orderNo=" + orderNo + " ]"; } }
[ "vuthesang6@gmail.com" ]
vuthesang6@gmail.com
fd0e3877b71cf778187075ed40d1d9127f888edb
1ebe6507ad3ff393fa918501a5a784aa37783bd3
/src/main/java/com/bharath/springadvanced/injecting/interfaces/annotations/OrderBo.java
69c5bed6db66d655e87f8c1cbd0381fb6b2fb153
[]
no_license
edwinkimathi/spring-tutorial
fe14fc335579593ab14b0448076fff96b9bf80cb
00315dac1a6fdbeccb21ca007373f547286f25d9
refs/heads/master
2021-10-20T16:15:23.071849
2019-02-28T20:48:09
2019-02-28T20:48:09
null
0
0
null
null
null
null
UTF-8
Java
false
false
122
java
package com.bharath.springadvanced.injecting.interfaces.annotations; public interface OrderBo { void placeOrder(); }
[ "pieprzyk.jakub@gmail.com" ]
pieprzyk.jakub@gmail.com
c8fdb09ccf87a4c101dd97c68bd3388651f94c91
bca2fcb00b78dbd000a97e141ddb6313deef7833
/b4alibs/myLight/Objects/gen/com/mylight/R.java
ef9dcd4addece5f28ec4307eee5d7fdb19ed1f65
[ "MIT" ]
permissive
icefairy/b4xlibs_tk
7fe5341a8db54ed88a02b42e1e2d801feb8722cd
726f8f103ba7cec80ec7122dbdf811300f4d7298
refs/heads/master
2022-05-13T13:27:52.033222
2022-05-03T13:30:28
2022-05-03T13:30:28
79,696,042
6
4
MIT
2022-05-03T13:30:29
2017-01-22T05:31:00
JavaScript
UTF-8
Java
false
false
384
java
/* AUTO-GENERATED FILE. DO NOT MODIFY. * * This class was automatically generated by the * aapt tool from the resource data it found. It * should not be modified by hand. */ package com.mylight; public final class R { public static final class attr { } public static final class drawable { public static final int icon=0x7f020000; } }
[ "860668820@qq.com" ]
860668820@qq.com
5a2f7711362fe5dbd812078df175ccb8e9c93243
50bf8e03937433a47951ec541e3ab06be3aa690e
/gulimall-product/src/main/java/com/atguigu/gulimall/product/entity/AttrAttrgroupRelationEntity.java
0fe9e342b347555db9be4ce3c3ee33693d125897
[]
no_license
daniubi/gulimall
98e06c2b958985e70f2859e5de5c293fb03c341a
9f923a0e078bc892a4a5d39a0f3df45152277392
refs/heads/master
2023-03-13T15:37:04.298128
2021-02-25T08:28:00
2021-02-25T08:28:00
339,659,246
0
0
null
null
null
null
UTF-8
Java
false
false
721
java
package com.atguigu.gulimall.product.entity; import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableName; import java.io.Serializable; import java.util.Date; import lombok.Data; /** * 属性&属性分组关联 * * @author aikaige * @email sunlightcs@gmail.com * @date 2021-02-18 10:56:50 */ @Data @TableName("pms_attr_attrgroup_relation") public class AttrAttrgroupRelationEntity implements Serializable { private static final long serialVersionUID = 1L; /** * id */ @TableId private Long id; /** * 属性id */ private Long attrId; /** * 属性分组id */ private Long attrGroupId; /** * 属性组内排序 */ private Integer attrSort; }
[ "804703017@qq.com" ]
804703017@qq.com
d98eecb202ded750cfef28eda9ce643599aabeab
9da7ff2e58ac4ae6ca918f44ff234b3a79f7ff85
/roje-web-server/src/main/java/com/roje/web/server/configuration/security/DefaultExpiredSessionStrategy.java
0b041abf891acdd9e1b5b2953fe5bc6b7693a955
[]
no_license
RoJeJJ/manager
9590cbe61203247f4bb3f6932284389f34ff9dee
2a8cac6a8f1de37ea05cbb895248c4918126c5c5
refs/heads/master
2022-01-23T02:08:11.578930
2020-03-30T15:48:57
2020-03-30T15:48:57
251,352,353
0
0
null
2022-01-15T06:12:47
2020-03-30T15:46:27
CSS
UTF-8
Java
false
false
1,009
java
package com.roje.web.server.configuration.security; import com.roje.web.server.common.ResultCode; import com.roje.web.server.utils.HttpUtils; import org.springframework.security.web.session.SessionInformationExpiredEvent; import org.springframework.security.web.session.SessionInformationExpiredStrategy; import org.springframework.util.Assert; import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import java.io.IOException; /** * @author Ro */ public class DefaultExpiredSessionStrategy implements SessionInformationExpiredStrategy { public DefaultExpiredSessionStrategy() { } @Override public void onExpiredSessionDetected(SessionInformationExpiredEvent event) throws IOException, ServletException { HttpServletResponse response = event.getResponse(); Assert.notNull(response, "HttpServletResponse required"); HttpUtils.sendJsonData(ResultCode.SESSION_EXPIRED, response); } }
[ "526048513@qq.com" ]
526048513@qq.com
d23fcb3c0bb9f6ee1152a4f03d63dbe62f9c46bc
6e0fe0c6b38e4647172259d6c65c2e2c829cdbc5
/modules/base/test/src/main/java/consulo/test/annotation/Test.java
fae89c8a2ab20c1c916383335058e0b5c8b6dacf
[ "Apache-2.0", "LicenseRef-scancode-jgraph" ]
permissive
TCROC/consulo
3f9a6df84e0fbf2b6211457b8a5f5857303b3fa6
cda24a03912102f916dc06ffce052892a83dd5a7
refs/heads/master
2023-01-30T13:19:04.216407
2020-12-06T16:57:00
2020-12-06T16:57:00
null
0
0
null
null
null
null
UTF-8
Java
false
false
929
java
/* * Copyright 2013-2017 consulo.io * * 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 consulo.test.annotation; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; /** * @author VISTALL * @since 05-Dec-17 */ @Retention(RetentionPolicy.RUNTIME) @Target(ElementType.METHOD) public @interface Test { }
[ "vistall.valeriy@gmail.com" ]
vistall.valeriy@gmail.com
aaa7bec1f1ed4d62f296bc5267b89b478d710d7c
08506438512693067b840247fa2c9a501765f39d
/Product/Production/Services/AdminDistributionCore/src/test/java/gov/hhs/fha/nhinc/admindistribution/AdminDistributionUtilsTest.java
21f814ee0e539c639be9bf7b02bcfe970a39c5b2
[]
no_license
AurionProject/Aurion
2f577514de39e91e1453c64caa3184471de891fa
b99e87e6394ecdde8a4197b755774062bf9ef890
refs/heads/master
2020-12-24T07:42:11.956869
2017-09-27T22:08:31
2017-09-27T22:08:31
49,459,710
1
0
null
2017-03-07T23:24:56
2016-01-11T22:55:12
Java
UTF-8
Java
false
false
5,445
java
/* * Copyright (c) 2012, United States Government, as represented by the Secretary of Health and Human Services. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * Redistributions of source code must retain the above * copyright notice, this list of conditions and the following disclaimer. * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the documentation * and/or other materials provided with the distribution. * * Neither the name of the United States Government nor the * names of its contributors may be used to endorse or promote products * derived from this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE * DISCLAIMED. IN NO EVENT SHALL THE UNITED STATES GOVERNMENT BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ package gov.hhs.fha.nhinc.admindistribution; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNotNull; import gov.hhs.fha.nhinc.largefile.LargeFileUtils; import java.io.File; import java.io.IOException; import java.net.URI; import javax.activation.DataHandler; import oasis.names.tc.emergency.edxl.de._1.ContentObjectType; import oasis.names.tc.emergency.edxl.de._1.EDXLDistribution; import oasis.names.tc.emergency.edxl.de._1.NonXMLContentType; import org.apache.cxf.attachment.ByteDataSource; import org.jmock.Expectations; import org.jmock.Mockery; import org.jmock.integration.junit4.JUnit4Mockery; import org.jmock.lib.legacy.ClassImposteriser; import org.junit.Test; /** * @author akong * */ public class AdminDistributionUtilsTest { final String URI_STRING = "file:///nhin/temp"; final String URI_SAVED_FILE_STRING = "file:///nhin/temp/saved"; protected Mockery context = new JUnit4Mockery() { { setImposteriser(ClassImposteriser.INSTANCE); } }; final LargeFileUtils mockFileUtils = context.mock(LargeFileUtils.class); @Test public void testConvertFileLocationToDataIfEnabled() throws Exception { AdminDistributionUtils adminUtils = createAdminDistributionUtils(); context.checking(new Expectations() { { oneOf(mockFileUtils).isParsePayloadAsFileLocationEnabled(); will(returnValue(true)); oneOf(mockFileUtils).parseBase64DataAsUri( with(any(DataHandler.class))); will(returnValue(new URI(URI_SAVED_FILE_STRING))); oneOf(mockFileUtils) .convertToDataHandler(with(any(File.class))); will(returnValue(createDataHandler())); } }); EDXLDistribution request = createEDXLDistribution(); adminUtils.convertFileLocationToDataIfEnabled(request); DataHandler dh = request.getContentObject().get(0).getNonXMLContent() .getContentData(); assertNotNull(dh); } @Test public void testConvertDataToFileLocationIfEnabled() throws Exception { AdminDistributionUtils adminUtils = createAdminDistributionUtils(); context.checking(new Expectations() { { oneOf(mockFileUtils).isSavePayloadToFileEnabled(); will(returnValue(true)); oneOf(mockFileUtils).generateAttachmentFile(); will(returnValue(new File(new URI(URI_SAVED_FILE_STRING)))); oneOf(mockFileUtils).saveDataToFile( with(any(DataHandler.class)), with(any(File.class))); oneOf(mockFileUtils).convertToDataHandler( with(any(String.class))); will(returnValue(LargeFileUtils.getInstance() .convertToDataHandler(URI_SAVED_FILE_STRING))); } }); EDXLDistribution request = createEDXLDistribution(); adminUtils.convertDataToFileLocationIfEnabled(request); URI contentUri = LargeFileUtils.getInstance().parseBase64DataAsUri( request.getContentObject().get(0).getNonXMLContent() .getContentData()); assertEquals(URI_SAVED_FILE_STRING, contentUri.toString()); } private EDXLDistribution createEDXLDistribution() throws IOException { LargeFileUtils fileUtils = LargeFileUtils.getInstance(); EDXLDistribution request = new EDXLDistribution(); ContentObjectType co = new ContentObjectType(); NonXMLContentType nonXmlContentType = new NonXMLContentType(); DataHandler dh = fileUtils.convertToDataHandler(URI_STRING); nonXmlContentType.setContentData(dh); co.setNonXMLContent(nonXmlContentType); request.getContentObject().add(co); return request; } private DataHandler createDataHandler() { ByteDataSource bds = new ByteDataSource(new byte[0]); return new DataHandler(bds); } private AdminDistributionUtils createAdminDistributionUtils() { return new AdminDistributionUtils() { protected LargeFileUtils getLargeFileUtils() { return mockFileUtils; } }; } }
[ "neilkwebb@hotmail.com" ]
neilkwebb@hotmail.com
87b43b6219875c21dfe245095d669f67e492fdce
0f2206c3dbd333891dc3204002e83951b6957180
/src/Hoorcollege/Gui/FormEvent.java
0392bc5475d11dcabca4a46ca9b3f3e269df5de2
[]
no_license
NielsVitse/Demo
2362e2bb58cd2187aa04525fcbf16f37bfd94b53
d708fba2d5610cdc1f123e18218c565985ef7288
refs/heads/master
2023-04-26T21:33:14.095648
2021-05-23T19:48:43
2021-05-23T19:48:43
370,143,994
0
0
null
null
null
null
UTF-8
Java
false
false
1,130
java
package Hoorcollege.Gui; import java.util.EventObject; public class FormEvent extends EventObject { private String naam; private String occupation; private AgeCategorie ageCat; private String emplCat; private boolean citizenCheck; private String taxId; private String gender; public FormEvent(Object source, String t1, String t2,AgeCategorie ac, String emplCat, boolean check,String taxId,String gender){ super(source); this.naam = t1; this.occupation = t2; this.ageCat = ac; this.emplCat = emplCat; this.citizenCheck = check; this.taxId = taxId; this.gender = gender; } public String getNaam() { return naam; } public String getOccupation() { return occupation; } public AgeCategorie getAgeCat() { return ageCat; } public String getEmplCat(){ return emplCat; } public String getGender(){ return gender; } public boolean isCitizenCheck() { return citizenCheck; } public String getTaxId() { return taxId; } }
[ "niels.vitse@student.ehb.be" ]
niels.vitse@student.ehb.be
6abc8d0a843d07e5ec7910d2d6195ec0974b29d8
de22a91871ed4b7d9eef026533213a51de88d06b
/Fundamentals/Basics/BasicJavaTest.java
7d5ac6639835fd12526316cf9ac75bf88dad5f47
[]
no_license
Amazon-Lab206-Java/Primel
37c0845b79dc5be84dd3f0a6f3e07b73ac0e11da
f47d6fd4b915abeacb69306e6bfbbe7df0d23997
refs/heads/master
2021-08-24T08:23:01.063130
2017-12-08T21:17:03
2017-12-08T21:17:03
111,562,416
0
0
null
null
null
null
UTF-8
Java
false
false
708
java
import java.util.ArrayList; public class BasicJavaTest { public static void main(String[] args){ BasicJava basics = new BasicJava(); basics.printAll(); basics.printOdds(); basics.printSum(); int[] arr = {1, 3, 5, 7, 9, 13}; basics.arrayIter(arr); basics.findMax(arr); basics.getAvg(arr); basics.oddArray(); basics.greaterThan(arr, 5); ArrayList<Integer> newArr = new ArrayList<Integer>(); newArr.add(1); newArr.add(5); newArr.add(10); newArr.add(-2); basics.squared(newArr); basics.noNegs(newArr); basics.minMaxAvg(arr); basics.toFront(arr); } }
[ "rimelp@amazon.com" ]
rimelp@amazon.com
86e1c9abf93c86882596646b7ec8fe02289cff51
d4a66f65524001d0b33d90f6d839981bf6f8c67c
/src/test/java/com/illud/redalert/repository/timezone/DateTimeWrapperRepository.java
f2a3e3b3ba45e86160a144351836dcb0be64bb1e
[]
no_license
illudtechzone/redAlert-Gateway
ea80fa5429d7a74f56addd7024aa75f2ba9d314f
f4ac4737526d3f195a8978497d27c145c0e74895
refs/heads/master
2023-05-14T14:36:20.082351
2019-07-22T06:58:24
2019-07-22T06:58:24
189,348,490
0
0
null
2023-05-01T06:08:43
2019-05-30T05:02:06
Java
UTF-8
Java
false
false
337
java
package com.illud.redalert.repository.timezone; import org.springframework.data.jpa.repository.JpaRepository; import org.springframework.stereotype.Repository; /** * Spring Data JPA repository for the DateTimeWrapper entity. */ @Repository public interface DateTimeWrapperRepository extends JpaRepository<DateTimeWrapper, Long> { }
[ "prince.k.c@lxisoft.com" ]
prince.k.c@lxisoft.com
8f904dc620435426060428435e38ec37947e1c1d
b55c539f9e8c068f3b5428ef37a32eb9cb0d2082
/src/main/java/interpreter/interpreter/variables/StringVar.java
bdc8dd763fd3adbf4d68a987a47e1f730bd337ad
[]
no_license
Fffatigue/StepByStepGuuInterpreter
e1da08f786fb8e2dab705662c1fce051cc433a01
8be222fa1eb9a457622151558dd1676498de3714
refs/heads/master
2020-05-24T23:01:27.559747
2019-05-20T08:07:44
2019-05-20T08:07:44
187,506,859
0
0
null
null
null
null
UTF-8
Java
false
false
247
java
package interpreter.interpreter.variables; public class StringVar extends Variable<String> { public StringVar(String var) { super( var ); } @Override public String printVariable() { return getVariable(); } }
[ "fffatigue@gmail.com" ]
fffatigue@gmail.com
d49ddb886d455e092c7399b56ff5066777faa26a
e0e7c6fb5931a9cbd946b42f1e9a16d6cf7b47e0
/smtp-test/src/test/java/com/mast/client/SimpleMailTest.java
5d5b94d7440e887519a5a1626218c963fcfbaa96
[]
no_license
748079585/mq
430a5cb71dccda9a9e8dbc370388f945345da2e4
fe3136e60863615bf34947576d6ecbb8c66999cc
refs/heads/master
2022-11-20T19:54:35.655518
2020-07-20T07:45:49
2020-07-20T07:45:49
281,002,260
0
0
null
null
null
null
UTF-8
Java
false
false
1,844
java
package com.mast.client; import java.io.IOException; import java.util.HashMap; import java.util.Map; import javax.mail.MessagingException; import org.junit.Test; import org.junit.runner.RunWith; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; import com.mast.client.model.MailProperties; import com.mast.client.service.MailService; import freemarker.template.TemplateException; @SpringBootTest @RunWith(SpringJUnit4ClassRunner.class) public class SimpleMailTest { @Autowired private MailService mailService; @Test public void sendMail() { MailProperties mailPropertie = MailProperties.builder().from("748079585@qq.com").to("748079585@qq.com").build(); mailService.sendSimpleMail("测试Springboot发送邮件", "发送邮件...", mailPropertie); } @Test public void testMail() throws MessagingException { MailProperties mailPropertie = MailProperties.builder().from("748079585@qq.com").to("748079585@qq.com").build(); Map<String, String> attachmentMap = new HashMap<>(); attachmentMap.put("附件", "file.txt的绝对路径"); mailService.sendHtmlMail("测试Springboot发送带附件的邮件", "欢迎进入<a href=\"http://www.baidu.com\">百度首页</a>", attachmentMap, mailPropertie); } @Test public void testFreemarkerMail() throws MessagingException, IOException, TemplateException { MailProperties mailPropertie = MailProperties.builder().from("748079585@qq.com").to("748079585@qq.com").build(); Map<String, Object> params = new HashMap<>(); params.put("username", "Cay"); params.put("aaa", "aaa111"); params.put("bbb", "bbb111"); mailService.sendTemplateMail("测试Springboot发送模版邮件", params,mailPropertie); } }
[ "748079585@qq.com" ]
748079585@qq.com
4938430e1a88976df973e97c76b853fc9571d6c4
fd3341a3aff59195f717f575b3582ea6767f3564
/C86-S3-Ppk-springmvc/src/main/java/com/yc/damai/bean/Result.java
ae0f94b2c2e3d8afff69038d172ba1b5805e6c84
[]
no_license
PK-git27/C86-Ppk
7963324e807195ad2624b611fe8afd985e232dcd
d8c7c0f1645aa1d40ca5902eddf0dc094f11af03
refs/heads/master
2022-12-12T14:10:45.395010
2020-09-14T12:07:47
2020-09-14T12:07:47
285,532,225
0
0
null
null
null
null
UTF-8
Java
false
false
824
java
package com.yc.damai.bean; public class Result { private int code; //0失败,1成功 private String msg; //返回的信息 private Object data; //返回的数据 public Result() { } public Result(int code, String msg, Object data) { this.code = code; this.msg = msg; this.data = data; } public Result(int code, String msg) { this.code = code; this.msg = msg; } public int getCode() { return code; } public void setCode(int code) { this.code = code; } public String getMsg() { return msg; } public void setMsg(String msg) { this.msg = msg; } public Object getData() { return data; } public void setData(Object data) { this.data = data; } @Override public String toString() { return "Result [code=" + code + ", msg=" + msg + ", data=" + data + "]"; } }
[ "pk@DESKTOP-V98436E" ]
pk@DESKTOP-V98436E
2741a487513a178e6e9be8e516d2f184674f4e00
6d02a80328189cc0e754ef696b41de793a2138e8
/Android Splash Screen_Login_Signup/Android Main File/java/in/tech2ground/myapp/Login.java
06b328114bcaa8a071090c287249eb46844d706e
[]
no_license
gaajoshi/Learn-Android
4aa5c30c25fe184579f813a73aec5fd44dce03cb
7fefc26d89dd21378cc7e8cef190eb710eb2737a
refs/heads/master
2021-01-19T07:06:26.814124
2017-08-28T09:57:59
2017-08-28T09:57:59
87,521,355
0
0
null
2017-04-07T08:07:07
2017-04-07T08:07:07
null
UTF-8
Java
false
false
4,109
java
package in.tech2ground.myapp; import android.content.Context; import android.content.Intent; import android.content.SharedPreferences; import android.os.Bundle; import android.support.v7.app.AppCompatActivity; import android.view.View; import android.widget.Button; import android.widget.EditText; import android.widget.Toast; import com.android.volley.AuthFailureError; import com.android.volley.Request; import com.android.volley.RequestQueue; import com.android.volley.Response; import com.android.volley.VolleyError; import com.android.volley.toolbox.StringRequest; import com.android.volley.toolbox.Volley; import java.util.HashMap; import java.util.Map; public class Login extends AppCompatActivity { public static final String LOGIN_URL="http://rahulkr.esy.es/UserRegistration/login.php"; public static final String KEY_EMAIL="email"; public static final String KEY_PASSWORD="password"; public static final String LOGIN_SUCCESS="success"; public static final String SHARED_PREF_NAME="tech"; public static final String EMAIL_SHARED_PREF="email"; public static final String LOGGEDIN_SHARED_PREF="loggedin"; private EditText editTextEmail; private EditText editTextPassword; private Button BtnLogin; private boolean loggedIn=false; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_login); editTextEmail=(EditText)findViewById(R.id.editText_email); editTextPassword=(EditText)findViewById(R.id.editText_password); BtnLogin=(Button)findViewById(R.id.btn_login); BtnLogin.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { login(); } }); } private void login() { final String email = editTextEmail.getText().toString().trim(); final String password = editTextPassword.getText().toString().trim(); StringRequest stringRequest = new StringRequest(Request.Method.POST, LOGIN_URL, new Response.Listener<String>() { @Override public void onResponse(String response) { if(response.trim().equalsIgnoreCase(LOGIN_SUCCESS)){ SharedPreferences sharedPreferences = Login.this.getSharedPreferences(SHARED_PREF_NAME, Context.MODE_PRIVATE); SharedPreferences.Editor editor = sharedPreferences.edit(); editor.putBoolean(LOGGEDIN_SHARED_PREF, true); editor.putString(EMAIL_SHARED_PREF, email); editor.commit(); Intent intent = new Intent(Login.this, MainActivity.class); startActivity(intent); }else{ Toast.makeText(Login.this, "Invalid username or password", Toast.LENGTH_LONG).show(); } } }, new Response.ErrorListener() { @Override public void onErrorResponse(VolleyError error) { } }){ @Override protected Map<String, String> getParams() throws AuthFailureError { Map<String,String> prams = new HashMap<>(); prams.put(KEY_EMAIL, email); prams.put(KEY_PASSWORD, password); return prams; } }; RequestQueue requestQueue = Volley.newRequestQueue(this); requestQueue.add(stringRequest); } @Override protected void onResume() { super.onResume(); SharedPreferences sharedPreferences = getSharedPreferences(SHARED_PREF_NAME,Context.MODE_PRIVATE); loggedIn = sharedPreferences.getBoolean(LOGGEDIN_SHARED_PREF, false); if(loggedIn){ Intent intent = new Intent(Login.this, MainActivity.class); startActivity(intent); } } }
[ "daphu786@gmail.com" ]
daphu786@gmail.com
93e34ede7394268b107837d22196f2ed696ca4a5
ec3a518a75515d2b3584c10b6460069615dddda2
/ysb/src/main/java/ysb/ddit/encrypt/kisa/seed/StringUtil.java
9c1de39385cf0e597ed13ee7fff178172bf8910b
[]
no_license
sbeeeeeeen/jspBoard
14befd55fd8219281ee049dcefbf9936e9403eff
0d3ff9b124716ce4e98b4caad3a65795c0927c91
refs/heads/master
2020-03-24T06:05:49.898364
2018-08-06T05:16:23
2018-08-06T05:16:23
142,515,631
0
0
null
null
null
null
UTF-8
Java
false
false
490
java
package ysb.ddit.encrypt.kisa.seed; public class StringUtil { /** * (length - str.length) 만큼 앞에 0을 추가한다. * @param str * @param length * @return */ public static String addZero (String str, int length) { String temp = ""; for (int i = str.length(); i < length; i++) temp += "0"; temp += str; return temp; } public static boolean isEmpty(String str) { if(str == null || str.length() == 0) { return true; }else { return false; } } }
[ "s_been929@daum.net" ]
s_been929@daum.net
d9f5aac15bf1954a0f11876c13bf79520ca9b943
0cb2a6de8b9db7ae9b2805183a3f2f21da5f8394
/src/main/java/com/shijing/nopainnogain/designpattern/statuspattern/DispenseState.java
918e2034416de1c4f7e504a01014c9f060d5f74f
[]
no_license
shijingoooo/noPainnoGain
83acaab2c5dbc78daf517e9d8ff8ac78d6a59042
81fc5f177c3c66f481b1281af1959871bc938395
refs/heads/master
2022-08-14T00:08:22.699297
2022-07-25T03:03:01
2022-07-25T03:03:01
194,254,171
0
0
null
2022-07-25T02:33:06
2019-06-28T10:20:41
Java
UTF-8
Java
false
false
1,034
java
package com.shijing.nopainnogain.designpattern.statuspattern; /** * @description: * @author: shijing * @create: 2020-01-16 22:15 **/ public class DispenseState extends State{ private Activity activity; public DispenseState(Activity activity) { this.activity = activity; } // @Override public void deduceMoney() { System.out.println("不能扣除积分"); } @Override public boolean raffle() { System.out.println("不能抽奖"); return false; } // 发放奖品 @Override public void dispensePrize() { if (activity.getCount() > 0) { System.out.println("恭喜中奖了"); // 改变状态为不能抽奖 activity.setState(activity.getNoRaffleState()); } else { System.out.println("很遗憾,奖品发送完了"); // 改变状态为奖品发送完毕,后面我们就不可以抽奖 activity.setState(activity.getDispenseOutState()); } } }
[ "shijingoooo@gmail.com" ]
shijingoooo@gmail.com
545a87d959068cb769d5af0e6c452aae41ba2a8e
3f195f2c190f9ced2c4c3a2f8118e86f46c85bc7
/designpatterns/designpatterns/src/cn/hncu/adaptor/ITarget.java
39ca7cca5dc8d2bfc50e0e1012e578778a1de431
[]
no_license
ThomasNJa/miscellaneous
99d4208dc5a82a33489769ec04a4b7024a67a90c
c1cbcd91c2198911cf339476f49f978ddf397750
refs/heads/master
2021-06-26T15:52:04.977497
2017-09-13T03:09:48
2017-09-13T03:09:48
103,346,991
0
0
null
null
null
null
UTF-8
Java
false
false
101
java
package cn.hncu.adaptor; public interface ITarget { public void run(); public void fly(); }
[ "375125383@qq.com" ]
375125383@qq.com
03c83809922251f1f2d5c10d554e4c3eb26c53b7
c4c8c4bfecea071e7791df65405b0a0e63b277de
/src/main/java/br/com/postmon/PostmonApplication.java
ae22a88f8d1837597b74e27dc9e6b0656fe9a9a4
[]
no_license
MatheusWilliam31/consumer-api-postmon
55f2e031ed6e6578959385a964c7ea79619ddba9
174a5bc642a12520d561bcf018a22cecab4ed64a
refs/heads/main
2023-06-02T20:00:23.234052
2021-06-16T22:37:13
2021-06-16T22:37:13
376,982,475
0
0
null
null
null
null
UTF-8
Java
false
false
309
java
package br.com.postmon; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; @SpringBootApplication public class PostmonApplication { public static void main(String[] args) { SpringApplication.run(PostmonApplication.class, args); } }
[ "matheus-loose@m.loose" ]
matheus-loose@m.loose
b55448744f534fd4d9e8abab1dcf62f91a4c22bd
a0fb635d5316fe7d427b71ae661ed65eca136d85
/src/main/java/com/azkabanconn/utils/SpringContextUtil.java
822a9ab91e575c0d5f4f07631eecf358f983d493
[]
no_license
CzyerChen/azkabanApi
aba103de42deca4166a3aae1719c70d24cb56f4e
6dcad9c58818a189c8fcd8785a048e0a01e0aa9d
refs/heads/master
2022-06-24T08:53:26.807358
2020-03-13T05:45:22
2020-03-13T05:45:22
246,973,855
0
0
null
2022-06-17T02:59:28
2020-03-13T02:40:22
Java
UTF-8
Java
false
false
1,308
java
package com.azkabanconn.utils; import org.springframework.beans.BeansException; import org.springframework.context.ApplicationContext; import org.springframework.context.ApplicationContextAware; import org.springframework.stereotype.Component; /** * @author: claire on 2019-06-21 - 15:24 **/ @Component public class SpringContextUtil implements ApplicationContextAware { private static ApplicationContext applicationContext; @Override public void setApplicationContext(ApplicationContext applicationContext) throws BeansException { SpringContextUtil.applicationContext = applicationContext; } public static Object getBean(String name) { return applicationContext.getBean(name); } public static <T> T getBean(Class<T> clazz){ return applicationContext.getBean(clazz); } public static <T> T getBean(String name, Class<T> requiredType) { return applicationContext.getBean(name, requiredType); } public static boolean containsBean(String name) { return applicationContext.containsBean(name); } public static boolean isSingleton(String name) { return applicationContext.isSingleton(name); } public static Class<?> getType(String name) { return applicationContext.getType(name); } }
[ "clairelove.chen@gmail.com" ]
clairelove.chen@gmail.com
13fcde848e6cf8fdc752671493679875daaeb48f
897e746aa02a7f2c360c26cb0201b9ce308692ea
/Employee_CRUD/src/main/java/com/employee/service/EmployeeService.java
e663e251a5325acb921c11f198507383ac3ee41f
[]
no_license
Madhusudhanp456/Flash
1f93657ef3188afe1074cb53fe4c371a3eaf1228
27da58c24558fa9dd8e2ec619cf4bbd4a2bb8c2c
refs/heads/master
2022-12-29T15:54:08.741883
2020-10-18T12:41:39
2020-10-18T12:41:39
277,499,794
0
0
null
2020-10-18T12:41:41
2020-07-06T09:31:51
Rich Text Format
UTF-8
Java
false
false
1,148
java
package com.employee.service; import com.employee.beans.*; import java.util.ArrayList; import java.util.Arrays; import java.util.List; import org.springframework.stereotype.Service; @Service public class EmployeeService { public List<Employee> emps=new ArrayList<Employee>( Arrays.asList(new Employee("101","Madhu","Java Developer",61500), new Employee("102","Dedeepya","dot Net Developer",30500), new Employee("103","Ashwitha","System Engineer",29500), new Employee("104","Chetan","Senior Java Developer",70500)) ); public List<Employee> getEmployees(){ return emps; } public Employee getEmployeeById(String empid) { return emps.stream().filter(e->e.getEmpid().equals(empid)).findFirst().get(); } public void addEmployee(Employee emp) { emps.add(emp); } public void updateEmployee( String empid, Employee emp) { for(int i=0; i<emps.size();i++) { Employee e=emps.get(i); if(e.getEmpid().equals(empid)) { emps.set(i, emp); } } } public void deleteEmployee(String empid) { emps.removeIf(e->e.getEmpid().equals(empid)); } }
[ "MadhusudhanPickli@DESKTOP-127EIBP" ]
MadhusudhanPickli@DESKTOP-127EIBP
d2192c261ddd69e43aa3389896d9a85ffebe157e
5b2aa3ecca861ece5909b0c5602a091b9c24262b
/decisionserver/weightwatcher/src/main/java/com/redhat/weightwatcher/Participant.java
67c0dd607d298d86463fcf034de997965ea903fa
[]
no_license
StefanoPicozzi/eBook
bd57ed08fd0dc830dc899212d26ddb8b4847f02d
0c4df431e15011f0981566110604997d16bb7c3e
refs/heads/master
2020-12-04T18:30:10.173741
2016-08-28T10:42:48
2016-08-28T10:42:48
66,707,826
0
0
null
null
null
null
UTF-8
Java
false
false
1,158
java
package com.redhat.weightwatcher; /** * This class was automatically generated by the data modeler tool. */ public class Participant implements java.io.Serializable { static final long serialVersionUID = 1L; @org.kie.api.definition.type.Label("User ID") private int userid; @org.kie.api.definition.type.Label("User Name") private java.lang.String username; @org.kie.api.definition.type.Label(value = "Program ID") private int programid; public Participant() { } public int getUserid() { return this.userid; } public void setUserid(int userid) { this.userid = userid; } public java.lang.String getUsername() { return this.username; } public void setUsername(java.lang.String username) { this.username = username; } public int getProgramid() { return this.programid; } public void setProgramid(int programid) { this.programid = programid; } public Participant(int programid, int userid, java.lang.String username) { this.userid = userid; this.username = username; this.programid = programid; } }
[ "stefanopicozzi@Stefanos-MacBook-Pro.local" ]
stefanopicozzi@Stefanos-MacBook-Pro.local
09c7e348f795c510f2b309ab6a62f858a2773696
9eca248a334d444b8a377a5f59323ae6e7483ce6
/src/hu/csfulop/javaswing/dialogs/NewPlayerDialog.java
1d16e1eefd522117a637b928fcb96b8c19e5656e
[]
no_license
csabe812/DartsyApp
f00ed97f31ad320a4acdd7574cdd93eefbc797b4
721a7c076e8037d9cb269fd467be20240237f9ad
refs/heads/master
2021-01-19T06:18:52.419165
2017-09-19T15:40:51
2017-09-19T15:40:51
100,635,719
0
0
null
null
null
null
UTF-8
Java
false
false
1,510
java
package hu.csfulop.javaswing.dialogs; import java.awt.GridLayout; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import javax.swing.JButton; import javax.swing.JDialog; import javax.swing.JLabel; import javax.swing.JTextField; import hu.csfulop.javaswing.config.DataClass; public class NewPlayerDialog extends JDialog implements ActionListener { private static final long serialVersionUID = 1L; private GridLayout gridLayout; private JTextField jtf; private NewGameDialog ngd; public NewPlayerDialog(NewGameDialog ngd) { this.ngd = ngd; this.setTitle(DataClass.newGameDialog); this.gridLayout = new GridLayout(2, 2); this.setLayout(this.gridLayout); initItems(); this.pack(); this.setLocationRelativeTo(null); this.setVisible(true); } public void initItems() { JLabel jl = new JLabel(DataClass.playerName); this.add(jl); this.jtf = new JTextField(); this.add(this.jtf); JButton jb = new JButton(DataClass.okButton); this.add(jb); jb.addActionListener(this); jb = new JButton(DataClass.cancelButton); this.add(jb); jb.addActionListener(this); } @Override public void actionPerformed(ActionEvent e) { if(e.getActionCommand().equals(DataClass.cancelButton)) { this.setVisible(false); } else if(e.getActionCommand().equals(DataClass.okButton)) { QueryClass.insert(this.jtf.getText()); QueryClass.selectAll(this.ngd.getPlayerOne()); QueryClass.selectAll(this.ngd.getPlayerTwo()); this.setVisible(false); } } }
[ "csafulop@gmail.com" ]
csafulop@gmail.com
b47d5c675386a1e1e58cdf348fe20ba824930cc8
20eb62855cb3962c2d36fda4377dfd47d82eb777
/newEvaluatedBugs/Jsoup_42_buggy/mutated/429/TokeniserState.java
6d59a036987cfd0a3c4a21edd41b62eb5763724c
[]
no_license
ozzydong/CapGen
356746618848065cce4e253e5d3c381baa85044a
0ba0321b6b1191443276021f1997833342f02515
refs/heads/master
2023-03-18T20:12:02.923428
2020-08-21T03:08:28
2020-08-21T03:08:28
null
0
0
null
null
null
null
UTF-8
Java
false
false
61,180
java
package org.jsoup.parser; /** * States and transition activations for the Tokeniser. */ enum TokeniserState { Data { // in data state, gather characters until a character reference or tag is found void read(Tokeniser t, CharacterReader r) { switch (r.current()) { case '&': t.advanceTransition(CharacterReferenceInData); break; case '<': t.advanceTransition(TagOpen); break; case nullChar: t.error(this); // NOT replacement character (oddly?) t.emit(r.consume()); break; case eof: t.emit(new Token.EOF()); break; default: String data = r.consumeToAny('&', '<', nullChar); t.emit(data); break; } } }, CharacterReferenceInData { // from & in data void read(Tokeniser t, CharacterReader r) { Character c = t.consumeCharacterReference(null, false); if (c == null) t.emit('&'); else t.emit(c); t.transition(Data); } }, Rcdata { /// handles data in title, textarea etc void read(Tokeniser t, CharacterReader r) { switch (r.current()) { case '&': t.advanceTransition(CharacterReferenceInRcdata); break; case '<': t.advanceTransition(RcdataLessthanSign); break; case nullChar: t.error(this); r.advance(); t.emit(replacementChar); break; case eof: t.emit(new Token.EOF()); break; default: String data = r.consumeToAny('&', '<', nullChar); t.emit(data); break; } } }, CharacterReferenceInRcdata { void read(Tokeniser t, CharacterReader r) { Character c = t.consumeCharacterReference(null, false); if (c == null) t.emit('&'); else t.emit(c); t.transition(Rcdata); } }, Rawtext { void read(Tokeniser t, CharacterReader r) { switch (r.current()) { case '<': t.advanceTransition(RawtextLessthanSign); break; case nullChar: t.error(this); r.advance(); t.emit(replacementChar); break; case eof: t.emit(new Token.EOF()); break; default: String data = r.consumeToAny('<', nullChar); t.emit(data); break; } } }, ScriptData { void read(Tokeniser t, CharacterReader r) { switch (r.current()) { case '<': t.advanceTransition(ScriptDataLessthanSign); break; case nullChar: t.error(this); r.advance(); t.emit(replacementChar); break; case eof: t.emit(new Token.EOF()); break; default: String data = r.consumeToAny('<', nullChar); t.emit(data); break; } } }, PLAINTEXT { void read(Tokeniser t, CharacterReader r) { switch (r.current()) { case nullChar: t.error(this); r.advance(); t.emit(replacementChar); break; case eof: t.emit(new Token.EOF()); break; default: String data = r.consumeTo(nullChar); t.emit(data); break; } } }, TagOpen { // from < in data void read(Tokeniser t, CharacterReader r) { switch (r.current()) { case '!': t.advanceTransition(MarkupDeclarationOpen); break; case '/': t.advanceTransition(EndTagOpen); break; case '?': t.advanceTransition(BogusComment); break; default: if (r.matchesLetter()) { t.createTagPending(true); t.transition(TagName); } else { t.error(this); t.emit('<'); // char that got us here t.transition(Data); } break; } } }, EndTagOpen { void read(Tokeniser t, CharacterReader r) { if (r.isEmpty()) { t.eofError(this); t.emit("</"); t.transition(Data); } else if (r.matchesLetter()) { t.createTagPending(false); t.transition(TagName); } else if (r.matches('>')) { t.error(this); t.advanceTransition(Data); } else { t.error(this); t.advanceTransition(BogusComment); } } }, TagName { // from < or </ in data, will have start or end tag pending void read(Tokeniser t, CharacterReader r) { // previous TagOpen state did NOT consume, will have a letter char in current String tagName = r.consumeToAny('\t', '\n', '\f', ' ', '/', '>', nullChar).toLowerCase(); t.tagPending.appendTagName(tagName); switch (r.consume()) { case '\t': case '\n': case '\f': case ' ': t.transition(BeforeAttributeName); break; case '/': t.transition(SelfClosingStartTag); break; case '>': t.emitTagPending(); t.transition(Data); break; case nullChar: // replacement t.tagPending.appendTagName(replacementStr); break; case eof: // should emit pending tag? t.eofError(this); t.transition(Data); // no default, as covered with above consumeToAny } } }, RcdataLessthanSign { // from < in rcdata void read(Tokeniser t, CharacterReader r) { if (r.matches('/')) { t.createTempBuffer(); t.advanceTransition(RCDATAEndTagOpen); } else if (r.matchesLetter() && !r.containsIgnoreCase("</" + t.appropriateEndTagName())) { // diverge from spec: got a start tag, but there's no appropriate end tag (</title>), so rather than // consuming to EOF; break out here t.tagPending = new Token.EndTag(t.appropriateEndTagName()); t.emitTagPending(); r.unconsume(); // undo "<" t.transition(Data); } else { t.emit("<"); t.transition(Rcdata); } } }, RCDATAEndTagOpen { void read(Tokeniser t, CharacterReader r) { if (r.matchesLetter()) { t.createTagPending(false); t.tagPending.appendTagName(Character.toLowerCase(r.current())); t.dataBuffer.append(Character.toLowerCase(r.current())); t.advanceTransition(RCDATAEndTagName); } else { t.emit("</"); t.transition(Rcdata); } } }, RCDATAEndTagName { void read(Tokeniser t, CharacterReader r) { if (r.matchesLetter()) { String name = r.consumeLetterSequence(); t.tagPending.appendTagName(name.toLowerCase()); t.dataBuffer.append(name); return; } char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': if (t.isAppropriateEndTagToken()) t.transition(BeforeAttributeName); else anythingElse(t, r); break; case '/': if (t.isAppropriateEndTagToken()) t.transition(SelfClosingStartTag); else anythingElse(t, r); break; case '>': if (t.isAppropriateEndTagToken()) { t.emitTagPending(); t.transition(Data); } else anythingElse(t, r); break; default: anythingElse(t, r); } } private void anythingElse(Tokeniser t, CharacterReader r) { t.emit("</" + t.dataBuffer.toString()); t.transition(Rcdata); } }, RawtextLessthanSign { void read(Tokeniser t, CharacterReader r) { if (r.matches('/')) { t.createTempBuffer(); t.advanceTransition(RawtextEndTagOpen); } else { t.emit('<'); t.transition(Rawtext); } } }, RawtextEndTagOpen { void read(Tokeniser t, CharacterReader r) { if (r.matchesLetter()) { t.createTagPending(false); t.transition(RawtextEndTagName); } else { t.emit("</"); t.transition(Rawtext); } } }, RawtextEndTagName { void read(Tokeniser t, CharacterReader r) { if (r.matchesLetter()) { String name = r.consumeLetterSequence(); t.tagPending.appendTagName(name.toLowerCase()); t.dataBuffer.append(name); return; } if (t.isAppropriateEndTagToken() && !r.isEmpty()) { char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': t.transition(BeforeAttributeName); break; case '/': t.transition(SelfClosingStartTag); break; case '>': t.emitTagPending(); t.transition(Data); break; default: t.dataBuffer.append(c); anythingElse(t, r); } } else anythingElse(t, r); } private void anythingElse(Tokeniser t, CharacterReader r) { t.emit("</" + t.dataBuffer.toString()); t.transition(Rawtext); } }, ScriptDataLessthanSign { void read(Tokeniser t, CharacterReader r) { switch (r.consume()) { case '/': t.createTempBuffer(); t.transition(ScriptDataEndTagOpen); break; case '!': t.emit("<!"); t.transition(ScriptDataEscapeStart); break; default: t.emit("<"); r.unconsume(); t.transition(ScriptData); } } }, ScriptDataEndTagOpen { void read(Tokeniser t, CharacterReader r) { if (r.matchesLetter()) { t.createTagPending(false); t.transition(org.jsoup.parser.TokeniserState.Comment); } else { t.emit("</"); t.transition(ScriptData); } } }, ScriptDataEndTagName { void read(Tokeniser t, CharacterReader r) { if (r.matchesLetter()) { String name = r.consumeLetterSequence(); t.tagPending.appendTagName(name.toLowerCase()); t.dataBuffer.append(name); return; } if (t.isAppropriateEndTagToken() && !r.isEmpty()) { char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': t.transition(BeforeAttributeName); break; case '/': t.transition(SelfClosingStartTag); break; case '>': t.emitTagPending(); t.transition(Data); break; default: t.dataBuffer.append(c); anythingElse(t, r); } } else { anythingElse(t, r); } } private void anythingElse(Tokeniser t, CharacterReader r) { t.emit("</" + t.dataBuffer.toString()); t.transition(ScriptData); } }, ScriptDataEscapeStart { void read(Tokeniser t, CharacterReader r) { if (r.matches('-')) { t.emit('-'); t.advanceTransition(ScriptDataEscapeStartDash); } else { t.transition(ScriptData); } } }, ScriptDataEscapeStartDash { void read(Tokeniser t, CharacterReader r) { if (r.matches('-')) { t.emit('-'); t.advanceTransition(ScriptDataEscapedDashDash); } else { t.transition(ScriptData); } } }, ScriptDataEscaped { void read(Tokeniser t, CharacterReader r) { if (r.isEmpty()) { t.eofError(this); t.transition(Data); return; } switch (r.current()) { case '-': t.emit('-'); t.advanceTransition(ScriptDataEscapedDash); break; case '<': t.advanceTransition(ScriptDataEscapedLessthanSign); break; case nullChar: t.error(this); r.advance(); t.emit(replacementChar); break; default: String data = r.consumeToAny('-', '<', nullChar); t.emit(data); } } }, ScriptDataEscapedDash { void read(Tokeniser t, CharacterReader r) { if (r.isEmpty()) { t.eofError(this); t.transition(Data); return; } char c = r.consume(); switch (c) { case '-': t.emit(c); t.transition(ScriptDataEscapedDashDash); break; case '<': t.transition(ScriptDataEscapedLessthanSign); break; case nullChar: t.error(this); t.emit(replacementChar); t.transition(ScriptDataEscaped); break; default: t.emit(c); t.transition(ScriptDataEscaped); } } }, ScriptDataEscapedDashDash { void read(Tokeniser t, CharacterReader r) { if (r.isEmpty()) { t.eofError(this); t.transition(Data); return; } char c = r.consume(); switch (c) { case '-': t.emit(c); break; case '<': t.transition(ScriptDataEscapedLessthanSign); break; case '>': t.emit(c); t.transition(ScriptData); break; case nullChar: t.error(this); t.emit(replacementChar); t.transition(ScriptDataEscaped); break; default: t.emit(c); t.transition(ScriptDataEscaped); } } }, ScriptDataEscapedLessthanSign { void read(Tokeniser t, CharacterReader r) { if (r.matchesLetter()) { t.createTempBuffer(); t.dataBuffer.append(Character.toLowerCase(r.current())); t.emit("<" + r.current()); t.advanceTransition(ScriptDataDoubleEscapeStart); } else if (r.matches('/')) { t.createTempBuffer(); t.advanceTransition(ScriptDataEscapedEndTagOpen); } else { t.emit('<'); t.transition(ScriptDataEscaped); } } }, ScriptDataEscapedEndTagOpen { void read(Tokeniser t, CharacterReader r) { if (r.matchesLetter()) { t.createTagPending(false); t.tagPending.appendTagName(Character.toLowerCase(r.current())); t.dataBuffer.append(r.current()); t.advanceTransition(ScriptDataEscapedEndTagName); } else { t.emit("</"); t.transition(ScriptDataEscaped); } } }, ScriptDataEscapedEndTagName { void read(Tokeniser t, CharacterReader r) { if (r.matchesLetter()) { String name = r.consumeLetterSequence(); t.tagPending.appendTagName(name.toLowerCase()); t.dataBuffer.append(name); r.advance(); return; } if (t.isAppropriateEndTagToken() && !r.isEmpty()) { char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': t.transition(BeforeAttributeName); break; case '/': t.transition(SelfClosingStartTag); break; case '>': t.emitTagPending(); t.transition(Data); break; default: t.dataBuffer.append(c); anythingElse(t, r); break; } } else { anythingElse(t, r); } } private void anythingElse(Tokeniser t, CharacterReader r) { t.emit("</" + t.dataBuffer.toString()); t.transition(ScriptDataEscaped); } }, ScriptDataDoubleEscapeStart { void read(Tokeniser t, CharacterReader r) { if (r.matchesLetter()) { String name = r.consumeLetterSequence(); t.dataBuffer.append(name.toLowerCase()); t.emit(name); return; } char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': case '/': case '>': if (t.dataBuffer.toString().equals("script")) t.transition(ScriptDataDoubleEscaped); else t.transition(ScriptDataEscaped); t.emit(c); break; default: r.unconsume(); t.transition(ScriptDataEscaped); } } }, ScriptDataDoubleEscaped { void read(Tokeniser t, CharacterReader r) { char c = r.current(); switch (c) { case '-': t.emit(c); t.advanceTransition(ScriptDataDoubleEscapedDash); break; case '<': t.emit(c); t.advanceTransition(ScriptDataDoubleEscapedLessthanSign); break; case nullChar: t.error(this); r.advance(); t.emit(replacementChar); break; case eof: t.eofError(this); t.transition(Data); break; default: String data = r.consumeToAny('-', '<', nullChar); t.emit(data); } } }, ScriptDataDoubleEscapedDash { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '-': t.emit(c); t.transition(ScriptDataDoubleEscapedDashDash); break; case '<': t.emit(c); t.transition(ScriptDataDoubleEscapedLessthanSign); break; case nullChar: t.error(this); t.emit(replacementChar); t.transition(ScriptDataDoubleEscaped); break; case eof: t.eofError(this); t.transition(Data); break; default: t.emit(c); t.transition(ScriptDataDoubleEscaped); } } }, ScriptDataDoubleEscapedDashDash { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '-': t.emit(c); break; case '<': t.emit(c); t.transition(ScriptDataDoubleEscapedLessthanSign); break; case '>': t.emit(c); t.transition(ScriptData); break; case nullChar: t.error(this); t.emit(replacementChar); t.transition(ScriptDataDoubleEscaped); break; case eof: t.eofError(this); t.transition(Data); break; default: t.emit(c); t.transition(ScriptDataDoubleEscaped); } } }, ScriptDataDoubleEscapedLessthanSign { void read(Tokeniser t, CharacterReader r) { if (r.matches('/')) { t.emit('/'); t.createTempBuffer(); t.advanceTransition(ScriptDataDoubleEscapeEnd); } else { t.transition(ScriptDataDoubleEscaped); } } }, ScriptDataDoubleEscapeEnd { void read(Tokeniser t, CharacterReader r) { if (r.matchesLetter()) { String name = r.consumeLetterSequence(); t.dataBuffer.append(name.toLowerCase()); t.emit(name); return; } char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': case '/': case '>': if (t.dataBuffer.toString().equals("script")) t.transition(ScriptDataEscaped); else t.transition(ScriptDataDoubleEscaped); t.emit(c); break; default: r.unconsume(); t.transition(ScriptDataDoubleEscaped); } } }, BeforeAttributeName { // from tagname <xxx void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': break; // ignore whitespace case '/': t.transition(SelfClosingStartTag); break; case '>': t.emitTagPending(); t.transition(Data); break; case nullChar: t.error(this); t.tagPending.newAttribute(); r.unconsume(); t.transition(AttributeName); break; case eof: t.eofError(this); t.transition(Data); break; case '"': case '\'': case '<': case '=': t.error(this); t.tagPending.newAttribute(); t.tagPending.appendAttributeName(c); t.transition(AttributeName); break; default: // A-Z, anything else t.tagPending.newAttribute(); r.unconsume(); t.transition(AttributeName); } } }, AttributeName { // from before attribute name void read(Tokeniser t, CharacterReader r) { String name = r.consumeToAny('\t', '\n', '\f', ' ', '/', '=', '>', nullChar, '"', '\'', '<'); t.tagPending.appendAttributeName(name.toLowerCase()); char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': t.transition(AfterAttributeName); break; case '/': t.transition(SelfClosingStartTag); break; case '=': t.transition(BeforeAttributeValue); break; case '>': t.emitTagPending(); t.transition(Data); break; case nullChar: t.error(this); t.tagPending.appendAttributeName(replacementChar); break; case eof: t.eofError(this); t.transition(Data); break; case '"': case '\'': case '<': t.error(this); t.tagPending.appendAttributeName(c); // no default, as covered in consumeToAny } } }, AfterAttributeName { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': // ignore break; case '/': t.transition(SelfClosingStartTag); break; case '=': t.transition(BeforeAttributeValue); break; case '>': t.emitTagPending(); t.transition(Data); break; case nullChar: t.error(this); t.tagPending.appendAttributeName(replacementChar); t.transition(AttributeName); break; case eof: t.eofError(this); t.transition(Data); break; case '"': case '\'': case '<': t.error(this); t.tagPending.newAttribute(); t.tagPending.appendAttributeName(c); t.transition(AttributeName); break; default: // A-Z, anything else t.tagPending.newAttribute(); r.unconsume(); t.transition(AttributeName); } } }, BeforeAttributeValue { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': // ignore break; case '"': t.transition(AttributeValue_doubleQuoted); break; case '&': r.unconsume(); t.transition(AttributeValue_unquoted); break; case '\'': t.transition(AttributeValue_singleQuoted); break; case nullChar: t.error(this); t.tagPending.appendAttributeValue(replacementChar); t.transition(AttributeValue_unquoted); break; case eof: t.eofError(this); t.transition(Data); break; case '>': t.error(this); t.emitTagPending(); t.transition(Data); break; case '<': case '=': case '`': t.error(this); t.tagPending.appendAttributeValue(c); t.transition(AttributeValue_unquoted); break; default: r.unconsume(); t.transition(AttributeValue_unquoted); } } }, AttributeValue_doubleQuoted { void read(Tokeniser t, CharacterReader r) { String value = r.consumeToAny('"', '&', nullChar); if (value.length() > 0) t.tagPending.appendAttributeValue(value); char c = r.consume(); switch (c) { case '"': t.transition(AfterAttributeValue_quoted); break; case '&': Character ref = t.consumeCharacterReference('"', true); if (ref != null) t.tagPending.appendAttributeValue(ref); else t.tagPending.appendAttributeValue('&'); break; case nullChar: t.error(this); t.tagPending.appendAttributeValue(replacementChar); break; case eof: t.eofError(this); t.transition(Data); break; // no default, handled in consume to any above } } }, AttributeValue_singleQuoted { void read(Tokeniser t, CharacterReader r) { String value = r.consumeToAny('\'', '&', nullChar); if (value.length() > 0) t.tagPending.appendAttributeValue(value); char c = r.consume(); switch (c) { case '\'': t.transition(AfterAttributeValue_quoted); break; case '&': Character ref = t.consumeCharacterReference('\'', true); if (ref != null) t.tagPending.appendAttributeValue(ref); else t.tagPending.appendAttributeValue('&'); break; case nullChar: t.error(this); t.tagPending.appendAttributeValue(replacementChar); break; case eof: t.eofError(this); t.transition(Data); break; // no default, handled in consume to any above } } }, AttributeValue_unquoted { void read(Tokeniser t, CharacterReader r) { String value = r.consumeToAny('\t', '\n', '\f', ' ', '&', '>', nullChar, '"', '\'', '<', '=', '`'); if (value.length() > 0) t.tagPending.appendAttributeValue(value); char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': t.transition(BeforeAttributeName); break; case '&': Character ref = t.consumeCharacterReference('>', true); if (ref != null) t.tagPending.appendAttributeValue(ref); else t.tagPending.appendAttributeValue('&'); break; case '>': t.emitTagPending(); t.transition(Data); break; case nullChar: t.error(this); t.tagPending.appendAttributeValue(replacementChar); break; case eof: t.eofError(this); t.transition(Data); break; case '"': case '\'': case '<': case '=': case '`': t.error(this); t.tagPending.appendAttributeValue(c); break; // no default, handled in consume to any above } } }, // CharacterReferenceInAttributeValue state handled inline AfterAttributeValue_quoted { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': t.transition(BeforeAttributeName); break; case '/': t.transition(SelfClosingStartTag); break; case '>': t.emitTagPending(); t.transition(Data); break; case eof: t.eofError(this); t.transition(Data); break; default: t.error(this); r.unconsume(); t.transition(BeforeAttributeName); } } }, SelfClosingStartTag { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '>': t.tagPending.selfClosing = true; t.emitTagPending(); t.transition(Data); break; case eof: t.eofError(this); t.transition(Data); break; default: t.error(this); t.transition(BeforeAttributeName); } } }, BogusComment { void read(Tokeniser t, CharacterReader r) { // todo: handle bogus comment starting from eof. when does that trigger? // rewind to capture character that lead us here r.unconsume(); Token.Comment comment = new Token.Comment(); comment.data.append(r.consumeTo('>')); // todo: replace nullChar with replaceChar t.emit(comment); t.advanceTransition(Data); } }, MarkupDeclarationOpen { void read(Tokeniser t, CharacterReader r) { if (r.matchConsume("--")) { t.createCommentPending(); t.transition(CommentStart); } else if (r.matchConsumeIgnoreCase("DOCTYPE")) { t.transition(Doctype); } else if (r.matchConsume("[CDATA[")) { // todo: should actually check current namepspace, and only non-html allows cdata. until namespace // is implemented properly, keep handling as cdata //} else if (!t.currentNodeInHtmlNS() && r.matchConsume("[CDATA[")) { t.transition(CdataSection); } else { t.error(this); t.advanceTransition(BogusComment); // advance so this character gets in bogus comment data's rewind } } }, CommentStart { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '-': t.transition(CommentStartDash); break; case nullChar: t.error(this); t.commentPending.data.append(replacementChar); t.transition(Comment); break; case '>': t.error(this); t.emitCommentPending(); t.transition(Data); break; case eof: t.eofError(this); t.emitCommentPending(); t.transition(Data); break; default: t.commentPending.data.append(c); t.transition(Comment); } } }, CommentStartDash { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '-': t.transition(CommentStartDash); break; case nullChar: t.error(this); t.commentPending.data.append(replacementChar); t.transition(Comment); break; case '>': t.error(this); t.emitCommentPending(); t.transition(Data); break; case eof: t.eofError(this); t.emitCommentPending(); t.transition(Data); break; default: t.commentPending.data.append(c); t.transition(Comment); } } }, Comment { void read(Tokeniser t, CharacterReader r) { char c = r.current(); switch (c) { case '-': t.advanceTransition(CommentEndDash); break; case nullChar: t.error(this); r.advance(); t.commentPending.data.append(replacementChar); break; case eof: t.eofError(this); t.emitCommentPending(); t.transition(Data); break; default: t.commentPending.data.append(r.consumeToAny('-', nullChar)); } } }, CommentEndDash { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '-': t.transition(CommentEnd); break; case nullChar: t.error(this); t.commentPending.data.append('-').append(replacementChar); t.transition(Comment); break; case eof: t.eofError(this); t.emitCommentPending(); t.transition(Data); break; default: t.commentPending.data.append('-').append(c); t.transition(Comment); } } }, CommentEnd { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '>': t.emitCommentPending(); t.transition(Data); break; case nullChar: t.error(this); t.commentPending.data.append("--").append(replacementChar); t.transition(Comment); break; case '!': t.error(this); t.transition(CommentEndBang); break; case '-': t.error(this); t.commentPending.data.append('-'); break; case eof: t.eofError(this); t.emitCommentPending(); t.transition(Data); break; default: t.error(this); t.commentPending.data.append("--").append(c); t.transition(Comment); } } }, CommentEndBang { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '-': t.commentPending.data.append("--!"); t.transition(CommentEndDash); break; case '>': t.emitCommentPending(); t.transition(Data); break; case nullChar: t.error(this); t.commentPending.data.append("--!").append(replacementChar); t.transition(Comment); break; case eof: t.eofError(this); t.emitCommentPending(); t.transition(Data); break; default: t.commentPending.data.append("--!").append(c); t.transition(Comment); } } }, Doctype { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': t.transition(BeforeDoctypeName); break; case eof: t.eofError(this); t.createDoctypePending(); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; default: t.error(this); t.transition(BeforeDoctypeName); } } }, BeforeDoctypeName { void read(Tokeniser t, CharacterReader r) { if (r.matchesLetter()) { t.createDoctypePending(); t.transition(DoctypeName); return; } char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': break; // ignore whitespace case nullChar: t.error(this); t.doctypePending.name.append(replacementChar); t.transition(DoctypeName); break; case eof: t.eofError(this); t.createDoctypePending(); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; default: t.createDoctypePending(); t.doctypePending.name.append(c); t.transition(DoctypeName); } } }, DoctypeName { void read(Tokeniser t, CharacterReader r) { if (r.matchesLetter()) { String name = r.consumeLetterSequence(); t.doctypePending.name.append(name.toLowerCase()); return; } char c = r.consume(); switch (c) { case '>': t.emitDoctypePending(); t.transition(Data); break; case '\t': case '\n': case '\f': case ' ': t.transition(AfterDoctypeName); break; case nullChar: t.error(this); t.doctypePending.name.append(replacementChar); break; case eof: t.eofError(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; default: t.doctypePending.name.append(c); } } }, AfterDoctypeName { void read(Tokeniser t, CharacterReader r) { if (r.isEmpty()) { t.eofError(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); return; } if (r.matchesAny('\t', '\n', '\f', ' ')) r.advance(); // ignore whitespace else if (r.matches('>')) { t.emitDoctypePending(); t.advanceTransition(Data); } else if (r.matchConsumeIgnoreCase("PUBLIC")) { t.transition(AfterDoctypePublicKeyword); } else if (r.matchConsumeIgnoreCase("SYSTEM")) { t.transition(AfterDoctypeSystemKeyword); } else { t.error(this); t.doctypePending.forceQuirks = true; t.advanceTransition(BogusDoctype); } } }, AfterDoctypePublicKeyword { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': t.transition(BeforeDoctypePublicIdentifier); break; case '"': t.error(this); // set public id to empty string t.transition(DoctypePublicIdentifier_doubleQuoted); break; case '\'': t.error(this); // set public id to empty string t.transition(DoctypePublicIdentifier_singleQuoted); break; case '>': t.error(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; case eof: t.eofError(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; default: t.error(this); t.doctypePending.forceQuirks = true; t.transition(BogusDoctype); } } }, BeforeDoctypePublicIdentifier { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': break; case '"': // set public id to empty string t.transition(DoctypePublicIdentifier_doubleQuoted); break; case '\'': // set public id to empty string t.transition(DoctypePublicIdentifier_singleQuoted); break; case '>': t.error(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; case eof: t.eofError(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; default: t.error(this); t.doctypePending.forceQuirks = true; t.transition(BogusDoctype); } } }, DoctypePublicIdentifier_doubleQuoted { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '"': t.transition(AfterDoctypePublicIdentifier); break; case nullChar: t.error(this); t.doctypePending.publicIdentifier.append(replacementChar); break; case '>': t.error(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; case eof: t.eofError(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; default: t.doctypePending.publicIdentifier.append(c); } } }, DoctypePublicIdentifier_singleQuoted { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '\'': t.transition(AfterDoctypePublicIdentifier); break; case nullChar: t.error(this); t.doctypePending.publicIdentifier.append(replacementChar); break; case '>': t.error(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; case eof: t.eofError(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; default: t.doctypePending.publicIdentifier.append(c); } } }, AfterDoctypePublicIdentifier { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': t.transition(BetweenDoctypePublicAndSystemIdentifiers); break; case '>': t.emitDoctypePending(); t.transition(Data); break; case '"': t.error(this); // system id empty t.transition(DoctypeSystemIdentifier_doubleQuoted); break; case '\'': t.error(this); // system id empty t.transition(DoctypeSystemIdentifier_singleQuoted); break; case eof: t.eofError(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; default: t.error(this); t.doctypePending.forceQuirks = true; t.transition(BogusDoctype); } } }, BetweenDoctypePublicAndSystemIdentifiers { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': break; case '>': t.emitDoctypePending(); t.transition(Data); break; case '"': t.error(this); // system id empty t.transition(DoctypeSystemIdentifier_doubleQuoted); break; case '\'': t.error(this); // system id empty t.transition(DoctypeSystemIdentifier_singleQuoted); break; case eof: t.eofError(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; default: t.error(this); t.doctypePending.forceQuirks = true; t.transition(BogusDoctype); } } }, AfterDoctypeSystemKeyword { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': t.transition(BeforeDoctypeSystemIdentifier); break; case '>': t.error(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; case '"': t.error(this); // system id empty t.transition(DoctypeSystemIdentifier_doubleQuoted); break; case '\'': t.error(this); // system id empty t.transition(DoctypeSystemIdentifier_singleQuoted); break; case eof: t.eofError(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; default: t.error(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); } } }, BeforeDoctypeSystemIdentifier { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': break; case '"': // set system id to empty string t.transition(DoctypeSystemIdentifier_doubleQuoted); break; case '\'': // set public id to empty string t.transition(DoctypeSystemIdentifier_singleQuoted); break; case '>': t.error(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; case eof: t.eofError(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; default: t.error(this); t.doctypePending.forceQuirks = true; t.transition(BogusDoctype); } } }, DoctypeSystemIdentifier_doubleQuoted { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '"': t.transition(AfterDoctypeSystemIdentifier); break; case nullChar: t.error(this); t.doctypePending.systemIdentifier.append(replacementChar); break; case '>': t.error(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; case eof: t.eofError(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; default: t.doctypePending.systemIdentifier.append(c); } } }, DoctypeSystemIdentifier_singleQuoted { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '\'': t.transition(AfterDoctypeSystemIdentifier); break; case nullChar: t.error(this); t.doctypePending.systemIdentifier.append(replacementChar); break; case '>': t.error(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; case eof: t.eofError(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; default: t.doctypePending.systemIdentifier.append(c); } } }, AfterDoctypeSystemIdentifier { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '\t': case '\n': case '\f': case ' ': break; case '>': t.emitDoctypePending(); t.transition(Data); break; case eof: t.eofError(this); t.doctypePending.forceQuirks = true; t.emitDoctypePending(); t.transition(Data); break; default: t.error(this); t.transition(BogusDoctype); // NOT force quirks } } }, BogusDoctype { void read(Tokeniser t, CharacterReader r) { char c = r.consume(); switch (c) { case '>': t.emitDoctypePending(); t.transition(Data); break; case eof: t.emitDoctypePending(); t.transition(Data); break; default: // ignore char break; } } }, CdataSection { void read(Tokeniser t, CharacterReader r) { String data = r.consumeTo("]]>"); t.emit(data); r.matchConsume("]]>"); t.transition(Data); } }; abstract void read(Tokeniser t, CharacterReader r); private static final char nullChar = '\u0000'; private static final char replacementChar = Tokeniser.replacementChar; private static final String replacementStr = String.valueOf(Tokeniser.replacementChar); private static final char eof = CharacterReader.EOF; }
[ "justinwm@163.com" ]
justinwm@163.com
9b4e0f90556fc61204969f42180fe8e251649fcf
ed054b18b05112ae6244160ab737b83a78af7ff8
/app/src/main/java/com/tingtongg/tingtongg/LocalitySelectorFragment.java
b2a405f5b700e2da498a6dcc4005012739c82ef3
[]
no_license
TEJ227/tingtongg.com
4b1d8cb275470595b3cb3a1fdddfd5f212295db7
e6dc058b31aca0fa6967d6771a68789bd7c81b13
refs/heads/master
2016-08-12T11:51:45.038548
2015-10-09T07:17:53
2015-10-09T07:17:53
43,939,061
0
0
null
null
null
null
UTF-8
Java
false
false
7,541
java
package com.tingtongg.tingtongg; import android.content.Intent; import android.net.Uri; import android.os.AsyncTask; import android.os.Bundle; import android.support.v4.app.Fragment; import android.util.Log; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.AdapterView; import android.widget.ArrayAdapter; import android.widget.ListView; import org.json.JSONArray; import org.json.JSONException; import org.json.JSONObject; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; import java.net.HttpURLConnection; import java.net.URL; import java.util.ArrayList; import java.util.Arrays; import java.util.List; /** * A placeholder fragment containing a simple view. */ public class LocalitySelectorFragment extends Fragment { private ArrayAdapter<String> forecastAdapter; public LocalitySelectorFragment() { } @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { String[] forecastArray = { "loading.." }; FetchWeatherTask weatherTask = new FetchWeatherTask(); weatherTask.execute("1"); //This is a Comment List<String> weekForecast = new ArrayList<String>(Arrays.asList(forecastArray)); forecastAdapter = new ArrayAdapter<String> ( getActivity(), R.layout.list_item_forecast, R.id.list_item_forecast_textview, weekForecast ); View rootView = inflater.inflate(R.layout.fragment_locality_selector, container, false); ListView listView = (ListView) rootView.findViewById(R.id.listview_forecast); listView.setAdapter(forecastAdapter); listView.setOnItemClickListener(new AdapterView.OnItemClickListener() { @Override public void onItemClick(AdapterView<?> parent, View view, int position, long id) { String locality=forecastAdapter.getItem(position); Intent loc_detail = new Intent(getActivity(),LocalityDetails.class).putExtra(Intent.EXTRA_TEXT,locality); startActivity(loc_detail); } }); return rootView; } // Inner Class public class FetchWeatherTask extends AsyncTask<String, Void, String[]> { private final String LOG_TAG = FetchWeatherTask.class.getSimpleName(); private String[] getLocalityDataFromJson(String forecastJsonStr) throws JSONException { final String OWM_LIST = "Locations"; final String OWM_DESCRIPTION = "location_nm"; JSONObject forecastJson = new JSONObject(forecastJsonStr); JSONArray weatherArray = forecastJson.getJSONArray(OWM_LIST); int len = weatherArray.length(); String[] resultStrs = new String[len]; int[] idArray=new int[len]; for(int i =0; i < len; i++) { JSONObject location = weatherArray.getJSONObject(i); String location_nm = location.getString(OWM_DESCRIPTION); int location_id=location.getInt("location_id"); resultStrs[i] = location_nm + "\n id=" + location_id; idArray[i] = location_id; } for (String s : resultStrs) { Log.v(LOG_TAG, "Forecast entry: " + s); } Log.v(LOG_TAG, "Forecast entry: Reached here"); return resultStrs ; } @Override protected String[] doInBackground(String... params) { if (params.length == 0) { return null; } // These two need to be declared outside the try/catch // so that they can be closed in the finally block. HttpURLConnection urlConnection = null; BufferedReader reader = null; // Will contain the raw JSON response as a string. String forecastJsonStr = null; // String format = "JSON"; try { // Construct the URL for the OpenWeatherMap query // Possible parameters are available at OWM's forecast API page, at // http://openweathermap.org/API#forecast //URL url = new URL("http://tej227.pythonanywhere.com/location/1/JSON"); final String FORECAST_BASE_URL = "http://tej227.pythonanywhere.com/location/1/JSON"; final String QUERY_PARAM = "q"; Uri builtUri = Uri.parse(FORECAST_BASE_URL).buildUpon() .appendQueryParameter(QUERY_PARAM, params[0]) .build(); URL url = new URL(builtUri.toString()); Log.v(LOG_TAG, "Built URI " + builtUri.toString()); // Create the request to OpenWeatherMap, and open the connection urlConnection = (HttpURLConnection) url.openConnection(); urlConnection.setRequestMethod("GET"); urlConnection.connect(); // Read the input stream into a String InputStream inputStream = urlConnection.getInputStream(); StringBuffer buffer = new StringBuffer(); if (inputStream == null) { // Nothing to do. forecastJsonStr = null; } reader = new BufferedReader(new InputStreamReader(inputStream)); String line; while ((line = reader.readLine()) != null) { // Since it's JSON, adding a newline isn't necessary (it won't affect parsing) // But it does make debugging a *lot* easier if you print out the completed // buffer for debugging. buffer.append(line + "\n"); } if (buffer.length() == 0) { // Stream was empty. No point in parsing. forecastJsonStr = null; } forecastJsonStr = buffer.toString(); Log.v(LOG_TAG,"Forecast JSON String:" + forecastJsonStr); } catch (IOException e) { Log.e("PlaceholderFragment", "Error ", e); // If the code didn't successfully get the weather data, there's no point in attempting // to parse it. forecastJsonStr = null; } finally{ if (urlConnection != null) { urlConnection.disconnect(); } if (reader != null) { try { reader.close(); } catch (final IOException e) { Log.e("PlaceholderFragment", "Error closing stream", e); } } } try { return getLocalityDataFromJson(forecastJsonStr); } catch(JSONException e) { Log.e(LOG_TAG,e.getMessage(),e); e.printStackTrace(); } return null; } @Override protected void onPostExecute(String[] result) { if (result != null){ forecastAdapter.clear(); for(String resultStr : result){ forecastAdapter.add(resultStr); } } } } }
[ "tejasgujar@gmail.com" ]
tejasgujar@gmail.com
f87775b9d75d33f0a7b73c7d7cda303b792291fd
306d7739c05a068e68ecda54928af95c96af060b
/Marketplace/paymentmode.backend/src/main/java/co/edu/uniandes/csw/miso4204/paymentmode/logic/dto/PaymentModePageDTO.java
fc3b320d501c94e47450ebc8bbbd7910591c5762
[]
no_license
valegrajales/miso4204_marketplace
3fe29c1e73626bb80c90ebfcdd0711850fc4cbd4
71664e0e57735fb801e1bd938b55fec449f2ead0
refs/heads/master
2021-01-20T04:17:17.102729
2014-11-26T12:34:37
2014-11-26T12:34:37
26,509,643
0
1
null
null
null
null
UTF-8
Java
false
false
1,472
java
/* ======================================================================== * Copyright 2014 miso4204 * * Licensed under the MIT, The MIT License (MIT) * Copyright (c) 2014 miso4204 Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. * ======================================================================== Source generated by CrudMaker version 1.0.0.qualifier */ package co.edu.uniandes.csw.miso4204.paymentmode.logic.dto; public class PaymentModePageDTO extends _PaymentModePageDTO { }
[ "kaosterra@gmail.com" ]
kaosterra@gmail.com
8e126d6611cb61b90bd98b0d3552301cbaaec3b6
8d759350237fd7111b1e9d30a71a4a108ea46525
/ogpIngest/src/main/java/org/OpenGeoPortal/Ingest/MetadataUploadSubmitter.java
3182fe4a4e735664db5b5020b615d0213a059fe7
[]
no_license
borchert/ogpIngest
a7197f11ec86225c2f421d5f5a7e112ccf7b5032
610930d99cd06f13020f7ac5b9681a7c2bac36ab
refs/heads/master
2021-01-15T16:05:29.735739
2015-03-04T17:42:13
2015-03-04T17:42:13
31,665,222
0
1
null
2015-03-04T15:51:44
2015-03-04T15:51:44
null
UTF-8
Java
false
false
381
java
package org.OpenGeoPortal.Ingest; import java.io.File; import java.util.List; import java.util.Set; import java.util.UUID; import org.OpenGeoPortal.Ingest.AbstractSolrIngest.MetadataElement; public interface MetadataUploadSubmitter { UUID runIngestJob(String sessionId, String institution, Set<MetadataElement> requiredFields, String options, List<File> uploadedFiles); }
[ "chrissbarnett@gmail.com" ]
chrissbarnett@gmail.com
575484185141e5cf72146462a5fa177af3301af8
55042d6a62a329d6e2ab268f00c80663d868aeb5
/src/chap18/complex2/Model2.java
4cfd23f46bbd5f4935e74f6bfb04ccdd7d28d1e5
[]
no_license
wkdalswn11/jsp20201103
92e38add2490ef35396d15a72b22a1e083f892cb
6dd2d410401fadd423d7d037435bef2d21c78b21
refs/heads/master
2023-01-20T07:42:37.676515
2020-12-02T08:52:48
2020-12-02T08:52:48
309,549,728
0
0
null
null
null
null
UTF-8
Java
false
false
198
java
package chap18.complex2; import java.util.Date; public class Model2 implements ModelInterface{ @Override public Object execute() { // TODO Auto-generated method stub return new Date(); } }
[ "wkdalswn133@naver.com" ]
wkdalswn133@naver.com
b79b07c45aed1c77be10e4d2dbb781a3ec4f8429
1304e89ff01886f0ecd24da733f7c97863edd8c9
/src/main/java/org/insset/client/service/RomanConverterServiceAsync.java
87486ef8008e1ea506970fb3b7037c5700cc8a58
[]
no_license
SerreauJovann/ClculatorInsset
1348b661b0e94c46bb44779d10c985051f00f8fb
4223aeab1b7bbed51f998a85608d8c465073d196
refs/heads/master
2020-04-05T07:25:32.026739
2018-11-09T14:38:49
2018-11-09T14:38:49
156,674,957
0
0
null
2018-11-09T14:38:50
2018-11-08T08:32:52
Java
UTF-8
Java
false
false
574
java
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package org.insset.client.service; import com.google.gwt.user.client.rpc.AsyncCallback; /** * * @author user */ public interface RomanConverterServiceAsync { void convertRomanToArabe(String nbr, AsyncCallback<Integer> callback); void convertArabeToRoman(Integer nbr, AsyncCallback<String> callback); void convertDateYears(String nbr, AsyncCallback<String> callback); }
[ "morgan.jouard@gmail.com" ]
morgan.jouard@gmail.com
fe3438fa6e4733c917f17f54a7d2c75efb69a913
67b90eb50da2bedcfa5c049ea0b5a440a855776c
/hospital sysytem/src/java/user/login.java
1c6f95dd14051446d3a7b16b9017b9e6e852750d
[]
no_license
pndesilva/Hospital-System-Java-EE-Tomcat
8e4d8d004595d98cbd1434c74722f64c567683b8
21c3e7a1927bf2ad0f3c55043f15203004878855
refs/heads/main
2023-04-17T06:17:33.138639
2021-03-14T18:54:51
2021-03-14T18:54:51
null
0
0
null
null
null
null
UTF-8
Java
false
false
3,811
java
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package user; import java.io.IOException; import java.io.PrintWriter; import java.sql.Connection; import java.sql.DriverManager; import java.sql.ResultSet; import java.sql.Statement; import javax.servlet.ServletException; import javax.servlet.http.HttpServlet; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; /** * * @author Kavindu Yasintha */ public class login extends HttpServlet { /** * Processes requests for both HTTP <code>GET</code> and <code>POST</code> * methods. * * @param request servlet request * @param response servlet response * @throws ServletException if a servlet-specific error occurs * @throws IOException if an I/O error occurs */ protected void processRequest(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { response.setContentType("text/html;charset=UTF-8"); try (PrintWriter out = response.getWriter()) { /* TODO output your page here. You may use following sample code. */ out.println("<!DOCTYPE html>"); out.println("<html>"); out.println("<head>"); out.println("<title>Servlet login</title>"); out.println("</head>"); out.println("<body>"); String password = request.getParameter("password"); String username = request.getParameter("username"); try { Class.forName("com.mysql.jdbc.Driver"); Connection conn = DriverManager.getConnection("jdbc:mysql://localhost:3306/HospitalManagment", "root", "password"); Statement st=conn.createStatement(); ResultSet rs=st.executeQuery("select * from user where username='"+username+"' and password='"+password+"'"); try{ rs.next(); if(rs.getString("password").equals(password)&&rs.getString("username").equals(username)) { response.sendRedirect("dashbord.jsp?username="+username); } else{ out.println("Invalid password or username."); } } catch (Exception e) { e.printStackTrace(); } } catch(Exception e) { System.out.print(e); e.printStackTrace(); } out.println("</body>"); out.println("</html>"); } } // <editor-fold defaultstate="collapsed" desc="HttpServlet methods. Click on the + sign on the left to edit the code."> /** * Handles the HTTP <code>GET</code> method. * * @param request servlet request * @param response servlet response * @throws ServletException if a servlet-specific error occurs * @throws IOException if an I/O error occurs */ @Override protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { processRequest(request, response); } /** * Handles the HTTP <code>POST</code> method. * * @param request servlet request * @param response servlet response * @throws ServletException if a servlet-specific error occurs * @throws IOException if an I/O error occurs */ @Override protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { processRequest(request, response); } /** * Returns a short description of the servlet. * * @return a String containing servlet description */ @Override public String getServletInfo() { return "Short description"; }// </editor-fold> }
[ "skysilva@students.nsbm.lk" ]
skysilva@students.nsbm.lk
66867945c172680c0d29f74a2bb189f6c06cf40c
71476821c4925fb50e4f4d6dcead610a92dd9fc5
/services/hrdb/src/com/testproject/hrdb/service/HrdbQueryExecutorService.java
175f36a61f3b018eb2650debe65fd21a966803c5
[]
no_license
wavemakerapps/testProject
d9ec87787d9d963905af811a830908fda674ea42
b180a79ca27570d9873de0ae597028e6d35aec65
refs/heads/master
2020-05-25T04:56:21.593850
2019-05-20T12:42:21
2019-05-20T12:42:21
187,638,530
0
0
null
null
null
null
UTF-8
Java
false
false
507
java
/*Copyright (c) 2019-2020 wavemaker.com All Rights Reserved. This software is the confidential and proprietary information of wavemaker.com You shall not disclose such Confidential Information and shall use it only in accordance with the terms of the source code license agreement you entered into with wavemaker.com*/ package com.testproject.hrdb.service; /*This is a Studio Managed File. DO NOT EDIT THIS FILE. Your changes may be reverted by Studio.*/ public interface HrdbQueryExecutorService { }
[ "Tejaswi.maryala@wavemaker.com" ]
Tejaswi.maryala@wavemaker.com
ea0c818110edb0b607f1c1ccb20a3b39efeb047f
1ff8608e08948b965821c5d22485d65130ba6495
/app/src/main/java/com/example/atlantatour/ChopsLobsterBarData.java
790b43581cbaae41db711cb856c2a92d8e7b7cc6
[]
no_license
aniisunny/Atlanta-Tour
7b569986f790604b89a5e5d73559ddbcbfbe1a28
cdf09493788395a98f529afcb3cf2f62955d0191
refs/heads/master
2020-06-30T19:33:10.015085
2019-08-07T17:03:09
2019-08-07T17:03:09
200,928,584
0
0
null
null
null
null
UTF-8
Java
false
false
887
java
package com.example.atlantatour; public class ChopsLobsterBarData { private int imageResourceId; private String name; private String address; private String celebrityName; private String about; public ChopsLobsterBarData(int imageResourceId, String name, String address, String celebrityName, String about) { this.imageResourceId = imageResourceId; this.name = name; this.address = address; this.celebrityName = celebrityName; this.about = about; } public int getImageResourceId(){ return imageResourceId; } public String getName() { return name; } public String getAddress() { return address; } public String getCelebrityName() { return celebrityName; } public String getAbout() { return about; } }
[ "40550530+aniisunny@users.noreply.github.com" ]
40550530+aniisunny@users.noreply.github.com
ca5503d3b259c0f25ba2bdd26d793e3d18707221
972ee8e62531016f791c04f07e329ce329ca0d5a
/app/src/main/java/com/example/jay/farm/MainActivity.java
5fd942217de1a54a4af5a97af717d099788e8168
[]
no_license
jaytnw1/SmartFarmApp_SciWeek_2018
bdaac8d772b484a61fc65b44603e81bf799b35f2
23faad3faedfd62b980b727fe43685f7986bb2cf
refs/heads/master
2021-09-25T09:12:02.657735
2018-10-20T09:19:32
2018-10-20T09:19:32
null
0
0
null
null
null
null
UTF-8
Java
false
false
3,368
java
package com.example.jay.farm; import android.app.Activity; import android.support.annotation.NonNull; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.view.View; import android.view.Window; import android.widget.ImageButton; import android.widget.TextView; import com.google.firebase.database.DataSnapshot; import com.google.firebase.database.DatabaseError; import com.google.firebase.database.DatabaseReference; import com.google.firebase.database.FirebaseDatabase; import com.google.firebase.database.ValueEventListener; public class MainActivity extends Activity { TextView Tem,Hum; ImageButton btLight,btMisk; String chkL="ON",chkM="ON"; DatabaseReference mRootRef = FirebaseDatabase.getInstance().getReference(); DatabaseReference TempFarm = mRootRef.child("TempFarm"); DatabaseReference HumFarm = mRootRef.child("HumFarm"); DatabaseReference MiskFence = mRootRef.child("WaterFarm"); DatabaseReference LightFarm = mRootRef.child("LightFarm"); @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); requestWindowFeature(Window.FEATURE_NO_TITLE); setContentView(R.layout.activity_main); Tem = (TextView) findViewById(R.id.tem); Hum = (TextView) findViewById(R.id.hum); btLight =(ImageButton) findViewById(R.id.btLight); btMisk =(ImageButton) findViewById(R.id.btMisk); TempFarm.addValueEventListener(new ValueEventListener() { @Override public void onDataChange(@NonNull DataSnapshot dataSnapshot) { String temm = dataSnapshot.getValue(String.class); Tem.setText(temm); } @Override public void onCancelled(@NonNull DatabaseError databaseError) { } }); HumFarm.addValueEventListener(new ValueEventListener() { @Override public void onDataChange(@NonNull DataSnapshot dataSnapshot) { String temm = dataSnapshot.getValue(String.class); Hum.setText(temm); } @Override public void onCancelled(@NonNull DatabaseError databaseError) { } }); btLight.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { if(chkL == "OFF" ){ btLight.setImageResource(R.mipmap.light); LightFarm.setValue("OFF"); chkL = "ON"; }else if(chkL == "ON" ) { btLight.setImageResource(R.mipmap.light_click); LightFarm.setValue("ON"); chkL = "OFF"; } } }); btMisk.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { if(chkM == "OFF" ){ btMisk.setImageResource(R.mipmap.misk); MiskFence.setValue("OFF"); chkM = "ON"; }else if(chkM == "ON" ) { btMisk.setImageResource(R.mipmap.misk_click); MiskFence.setValue("ON"); chkM = "OFF"; } } }); } }
[ "thanawut@kkumail.com" ]
thanawut@kkumail.com
9a99fb540f0bfafa1b49db3c5ab0e4d1167adc1c
02850891f62cb09a72928c22078f8f374d245c6f
/Inteprete/src/inteprete/JError.java
f4311f53c74c54abfadfeac98251d9e2760e208d
[]
no_license
201504242/c2
daf5e3ab09f0ee5fb7a78d5faad2eeec3b6c54e4
52ac91aa5a6b6228a1db72fc699a917580552b22
refs/heads/master
2020-06-06T01:10:40.184424
2019-06-24T15:29:53
2019-06-24T15:29:53
192,597,190
0
0
null
null
null
null
UTF-8
Java
false
false
1,176
java
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package inteprete; import java.util.LinkedList; /** * * @author p_ab1 */ public class JError { private String tipoError; private int linea; private int columna; private String desc; public JError(String tipoError, int linea, int columna, String desc) { this.tipoError = tipoError; this.linea = linea; this.columna = columna; this.desc = desc; } public String getTipoError() { return tipoError; } public void setTipoError(String tipoError) { this.tipoError = tipoError; } public int getLinea() { return linea; } public void setLinea(int linea) { this.linea = linea; } public int getColumna() { return columna; } public void setColumna(int columna) { this.columna = columna; } public String getDesc() { return desc; } public void setDesc(String desc) { this.desc = desc; } }
[ "201504242@ingenieria.usac.edu.gt" ]
201504242@ingenieria.usac.edu.gt
76a92fba9f58674f6bf7649f58e6d19725ef8ee2
777857df282075d8e2dcacebf5da10a73bd734ef
/src/MyPro04/cn/sxt/oo/TestEncapsulation2.java
5b6c83eb3b1e4339b88fadd9ed7ee6922a3c4e1f
[]
no_license
zhouyuanp/TestJava
32bf58d5d95f6a74eb0d9259e9f92014313a5be9
6483f519c910e8ae9e4b4faaa5277a40a6223628
refs/heads/master
2020-05-01T17:51:17.346261
2019-12-29T13:22:28
2019-12-29T13:22:28
177,610,375
0
0
null
null
null
null
UTF-8
Java
false
false
503
java
package src.MyPro04.cn.sxt.oo; import MyPro04.cn.sxt.oo2.Human; public class TestEncapsulation2 { public static void main(String[] arge){ Human h = new Human(); // h.age = 13; // h.name = "zhouyuanpeng"; //name 为default 属性,不能被不同包的类访问 h.sayAge(); //public 修饰不同的包和类都能用 } } class Girl extends Human { //Girl 位于不同的包中,且是Human的子类 void sayGood(){ System.out.println(height); } }
[ "zyp112490@163.com" ]
zyp112490@163.com
b21138e537111a90cf2e2853aa5596dff1ab1ea0
becb65ea0d05fe9edcfdcdc8823c6bdf1e5eb3a3
/outplatform-provider-manager-9001/src/main/java/com/rongli/common/util/captcha/Randoms.java
6eba040dafa4ce41fbcfe51fd0ddf6f4f3065216
[]
no_license
1204432129/outplatform
548d23a97acf3afdf099ee30e62b9b0394f56967
4ff37c131bc4c403a204b2ddf7ed08fe3b693f01
refs/heads/master
2023-01-13T06:20:31.283465
2020-11-23T02:34:43
2020-11-23T02:34:43
309,846,215
0
1
null
null
null
null
UTF-8
Java
false
false
1,079
java
package com.rongli.common.util.captcha; import java.util.Random; /** * <p>随机工具类</p> * @version:1.0 */ public class Randoms { private static final Random RANDOM = new Random(); //定义验证码字符.去除了O和I等容易混淆的字母 public static final char ALPHA[]={'A','B','C','D','E','F','G','H','G','K','M','N','P','Q','R','S','T','U','V','W','X','Y','Z' ,'a','b','c','d','e','f','g','h','i','j','k','m','n','p','q','r','s','t','u','v','w','x','y','z','2','3','4','5','6','7','8','9'}; /** * 产生两个数之间的随机数 * @param min 小数 * @param max 比min大的数 * @return int 随机数字 */ public static int num(int min, int max) { return min + RANDOM.nextInt(max - min); } /** * 产生0--num的随机数,不包括num * @param num 数字 * @return int 随机数字 */ public static int num(int num) { return RANDOM.nextInt(num); } public static char alpha() { return ALPHA[num(0, ALPHA.length)]; } }
[ "1204432129@qq.com" ]
1204432129@qq.com
83888dd7c72ae59e52f5a622becb10edb9ee005d
5c42d61c41aa0594f0598f951ac69bb891f10a26
/swtbot.example.view/src/swtbot/example/view/Activator.java
adcb8e20224e4c018f080c94c25ad8ecec8fbb86
[]
no_license
LorenzoBettini/swtbot-example
898b0737edfe19ed719bfaf9096c2b4381dc64e5
cafb9b53e7680273bf7005a7b88a318fb06bfedb
refs/heads/master
2021-05-04T10:09:00.444778
2017-11-14T20:12:25
2017-11-14T20:16:53
47,764,839
1
1
null
2017-11-14T20:15:49
2015-12-10T13:50:54
Java
UTF-8
Java
false
false
1,360
java
package swtbot.example.view; import org.eclipse.jface.resource.ImageDescriptor; import org.eclipse.ui.plugin.AbstractUIPlugin; import org.osgi.framework.BundleContext; /** * The activator class controls the plug-in life cycle */ public class Activator extends AbstractUIPlugin { // The plug-in ID public static final String PLUGIN_ID = "swtbot.example.view"; //$NON-NLS-1$ // The shared instance private static Activator plugin; /** * The constructor */ public Activator() { } /* * (non-Javadoc) * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext) */ public void start(BundleContext context) throws Exception { super.start(context); plugin = this; } /* * (non-Javadoc) * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext) */ public void stop(BundleContext context) throws Exception { plugin = null; super.stop(context); } /** * Returns the shared instance * * @return the shared instance */ public static Activator getDefault() { return plugin; } /** * Returns an image descriptor for the image file at the given * plug-in relative path * * @param path the path * @return the image descriptor */ public static ImageDescriptor getImageDescriptor(String path) { return imageDescriptorFromPlugin(PLUGIN_ID, path); } }
[ "lorenzo.bettini@gmail.com" ]
lorenzo.bettini@gmail.com
67feb2685856e6e078f36f4a510841156a9fbec7
a5d31a3a80a3833741695d0602ef166ca64d2bba
/customer-manage/src/main/java/com/dingtai/customermager/entity/response/GetLoginUserInfoResp.java
b65da2a2bb86fd81870fe7c94403bbbd8e6ca9aa
[]
no_license
1027866388/dingtaiback
52f8bcd50cf71fc405b1c9e7935862e0bc1cba94
b5868b39bcf915efa20b43f1c1c50bc20216d196
refs/heads/master
2022-10-25T20:44:39.850700
2020-02-25T13:59:51
2020-02-25T13:59:51
242,983,599
0
2
null
2022-10-12T20:37:11
2020-02-25T11:29:30
Java
UTF-8
Java
false
false
1,805
java
package com.dingtai.customermager.entity.response; import io.swagger.annotations.ApiModelProperty; /** * 获取登录用户信息 * * @author wangyanhui * @date 2018-04-25 11:12 */ public class GetLoginUserInfoResp { /** * 用户id */ @ApiModelProperty(value = "用户id", name = "userId") private Long userId; /** * 真实姓名 */ @ApiModelProperty(value = "真实姓名", name = "realName") private String realName; /** * 手机号 */ @ApiModelProperty(value = "手机号", name = "mobile") private String mobile; /** * 邮箱 */ @ApiModelProperty(value = "邮箱", name = "email") private String email; /** * 用户名 */ @ApiModelProperty(value = "用户名", name = "userName") private String userName; /** * 令牌 */ @ApiModelProperty(value = "令牌", name = "token") private String token; public Long getUserId() { return userId; } public void setUserId(Long userId) { this.userId = userId; } public String getRealName() { return realName; } public void setRealName(String realName) { this.realName = realName; } public String getMobile() { return mobile; } public void setMobile(String mobile) { this.mobile = mobile; } public String getEmail() { return email; } public void setEmail(String email) { this.email = email; } public String getUserName() { return userName; } public void setUserName(String userName) { this.userName = userName; } public String getToken() { return token; } public void setToken(String token) { this.token = token; } }
[ "wangyanhui@cmss.chinamobile.com" ]
wangyanhui@cmss.chinamobile.com
6192df0c0d53c1cf694b22dbb6059427c2a8fa56
d1d7d8b72713398a6053f077984e88613f6c99ec
/bukkit/src/main/java/de/themoep/resourcepacksplugin/bukkit/events/ResourcePackSelectEvent.java
44c76582c64678e8248cd489b5ad8f0552a7be4a
[]
no_license
JHXSMatthew/ResourcepacksPlugins
3c34d3124ab05233b6677ef992d3a7f6250a5410
8d72fc99f4170e6eb4f7b4bdb95235b8694acf12
refs/heads/master
2021-01-18T19:45:43.637840
2016-06-09T20:53:57
2016-06-09T20:53:57
62,421,714
1
0
null
2016-07-01T21:55:33
2016-07-01T21:55:33
null
UTF-8
Java
false
false
1,642
java
package de.themoep.resourcepacksplugin.bukkit.events; import de.themoep.resourcepacksplugin.core.ResourcePack; import de.themoep.resourcepacksplugin.core.events.IResourcePackSelectEvent; import org.bukkit.event.Event; import org.bukkit.event.HandlerList; import java.util.UUID; /** * Created by Phoenix616 on 18.04.2015. */ public class ResourcePackSelectEvent extends Event implements IResourcePackSelectEvent { private static final HandlerList handlers = new HandlerList(); private final UUID playerId; private ResourcePack pack; private Status status;; public ResourcePackSelectEvent(UUID playerId, ResourcePack pack) { this.playerId = playerId; setPack(pack); } public ResourcePackSelectEvent(UUID playerId, ResourcePack pack, Status status) { this.playerId = playerId; this.pack = pack; this.status = status; } public UUID getPlayerId() { return playerId; } public ResourcePack getPack() { return pack; } public void setPack(ResourcePack pack) { this.pack = pack; if(pack != null) { status = Status.SUCCESS; } else { status = Status.UNKNOWN; } } @Override public Status getStatus() { return status; } @Override public void setStatus(Status status) { this.status = status; if(status != Status.SUCCESS) { pack = null; } } @Override public HandlerList getHandlers() { return handlers; } public static HandlerList getHandlerList() { return handlers; } }
[ "Phoenix616@users.noreply.github.com" ]
Phoenix616@users.noreply.github.com
d4c99a0a1deb46d5cc54840ef2b9786b48855df5
b9beee9fe60473fd7f0657eaeb54182108f0ae21
/spring-cloud-2020/cloud-provider-payment-8001/src/main/java/cn/ac/hwy/springcloud/utils/MessageResult.java
a978ffb84d65314447188f965b96d0a95a37d023
[ "Apache-2.0" ]
permissive
HWYWL/spring-cloud-examples
40fb647c1f5f0f6f8de0048358ba3e4ced7e288f
ea22a7e29eb78a43069af218b700773e6930b26a
refs/heads/master
2022-08-15T23:21:49.098129
2022-07-08T06:37:06
2022-07-08T06:37:06
129,830,682
0
0
Apache-2.0
2022-07-08T06:37:07
2018-04-17T01:56:23
Java
UTF-8
Java
false
false
1,878
java
package cn.ac.hwy.springcloud.utils; /** * 统一返回数据格式 * @author YI * @date 2018-8-22 11:25:56 */ public class MessageResult<T> { private int code = 0; private String msg = "数据读取成功!"; private int count; private T data; public MessageResult() { super(); } public MessageResult(int code, String msg, int count, T data) { this.code = code; this.msg = msg; this.count = count; this.data = data; } public static MessageResult ok() { return new MessageResult(); } public static MessageResult ok(Object data) { MessageResult result = new MessageResult(); result.setData(data); return result; } public static MessageResult errorMsg(String msg) { return new MessageResult(-1, msg, 0, null); } public static MessageResult errorMap(Object data) { return new MessageResult(-1, "ERROR:出错啦,么么哒!!!", 0, data); } public static MessageResult errorTokenMsg(String msg) { return new MessageResult(-1, msg, 0, null); } public int getCode() { return code; } public void setCode(int code) { this.code = code; } public String getMsg() { return msg; } public void setMsg(String msg) { this.msg = msg; } public int getCount() { return count; } public void setCount(int count) { this.count = count; } public T getData() { return data; } public void setData(T data) { this.data = data; } @Override public String toString() { return "MessageResult{" + "code=" + code + ", msg='" + msg + '\'' + ", count=" + count + ", data=" + data + '}'; } }
[ "ilovey_hwy@163.com" ]
ilovey_hwy@163.com
26fc941bbc42a4f8687c037e7cf1e932d247c0b6
9bf6dee1407f112cebf42443e0f492e89d0d3fbc
/gameserver/data/scripts/system/handlers/quest/charlirunerks_daemons/_46510SnufflerSaboteur.java
ac5c732823eff4974b339ffc5f5502ac643e0bc2
[]
no_license
vavavr00m/aion-source
6caef6738fee6d4898fcb66079ea63da46f5c9c0
8ce4c356d860cf54e5f3fe4a799197725acffc3b
refs/heads/master
2021-01-10T02:08:43.965463
2011-08-22T10:47:12
2011-08-22T10:47:12
50,949,918
1
0
null
null
null
null
UTF-8
Java
false
false
2,842
java
/* * This file is part of aion-unique * * aion-engine is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * aion-unique is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Lesser Public License for more details. * * You should have received a copy of the GNU Lesser Public License * along with aion-unique. If not, see <http://www.gnu.org/licenses/>. */ package quest.charlirunerks_daemons; import org.openaion.gameserver.model.EmotionType; import org.openaion.gameserver.model.gameobjects.Npc; import org.openaion.gameserver.model.gameobjects.VisibleObject; import org.openaion.gameserver.model.gameobjects.player.Player; import org.openaion.gameserver.quest.handlers.QuestHandler; import org.openaion.gameserver.quest.model.QuestCookie; import org.openaion.gameserver.quest.model.QuestState; import org.openaion.gameserver.quest.model.QuestStatus; import org.openaion.gameserver.services.QuestService; public class _46510SnufflerSaboteur extends QuestHandler { private final static int questId = 46510; public _46510SnufflerSaboteur() { super(questId); } @Override public boolean onDialogEvent(QuestCookie env) { Player player = env.getPlayer(); QuestState qs = player.getQuestStateList().getQuestState(questId); if(defaultQuestStartDaily(env)) return true; if(qs == null) return false; if(qs.getStatus() == QuestStatus.START) { if(env.getTargetId() == 700774) return defaultQuestUseNpc(env, 0, 1, EmotionType.NEUTRALMODE2, EmotionType.START_LOOT, true); } if(defaultQuestRewardDialog(env, 799882, 10002) || defaultQuestRewardDialog(env, 799883, 10002)) return true; else return false; } @Override public boolean onKillEvent(QuestCookie env) { return defaultQuestOnKillEvent(env, 216641, 0, true); } @Override public void QuestUseNpcInsideFunction(QuestCookie env) { Player player = env.getPlayer(); VisibleObject vO = env.getVisibleObject(); if(vO instanceof Npc) { Npc trap = (Npc)vO; if(trap.getNpcId() == 700774) QuestService.addNewSpawn(player.getWorldId(), player.getInstanceId(), 216641, trap.getX(), trap.getY(), trap.getZ(), (byte) 0, true); } } @Override public void register() { qe.setNpcQuestData(700774).addOnTalkEvent(questId); qe.setNpcQuestData(799882).addOnTalkEvent(questId); qe.setNpcQuestData(799883).addOnTalkEvent(questId); qe.setNpcQuestData(216641).addOnKillEvent(questId); } }
[ "tomulescu@gmail.com" ]
tomulescu@gmail.com
1003908fe5deeb3a78b89549fa9f6dfe7e623354
129f58086770fc74c171e9c1edfd63b4257210f3
/src/testcases/CWE129_Improper_Validation_of_Array_Index/CWE129_Improper_Validation_of_Array_Index__getCookies_Servlet_array_read_check_min_75a.java
408c9d130a9deaf2fc84590a409f3b6522be0827
[]
no_license
glopezGitHub/Android23
1bd0b6a6c7ce3c7439a74f1e4dcef2c4c0fac4ba
6215d0684c4fbdc7217ccfbedfccfca69824cc5e
refs/heads/master
2023-03-07T15:14:59.447795
2023-02-06T13:59:49
2023-02-06T13:59:49
6,856,387
0
3
null
2023-02-06T18:38:17
2012-11-25T22:04:23
Java
UTF-8
Java
false
false
7,974
java
/* TEMPLATE GENERATED TESTCASE FILE Filename: CWE129_Improper_Validation_of_Array_Index__getCookies_Servlet_array_read_check_min_75a.java Label Definition File: CWE129_Improper_Validation_of_Array_Index.label.xml Template File: sources-sinks-75a.tmpl.java */ /* * @description * CWE: 129 Improper Validation of Array Index * BadSource: getCookies_Servlet Read data from the first cookie using getCookies() * GoodSource: A hardcoded non-zero, non-min, non-max, even number * Sinks: array_read_check_min * GoodSink: Read from array after verifying that data is at least 0 and less than array.length * BadSink : Read from array after verifying that data is at least 0 (but not verifying that data less than array.length) * Flow Variant: 75 Data flow: data passed in a serialized object from one method to another in different source files in the same package * * */ package testcases.CWE129_Improper_Validation_of_Array_Index; import testcasesupport.*; import java.io.ByteArrayOutputStream; import java.io.ObjectOutput; import java.io.ObjectOutputStream; import java.io.IOException; import java.util.logging.Level; import java.util.logging.Logger; import java.sql.*; import javax.servlet.http.*; import javax.servlet.http.*; import java.util.logging.Level; import java.util.logging.Logger; public class CWE129_Improper_Validation_of_Array_Index__getCookies_Servlet_array_read_check_min_75a extends AbstractTestCaseServlet { public void bad(HttpServletRequest request, HttpServletResponse response) throws Throwable { int data; data = Integer.MIN_VALUE; /* initialize data in case there are no cookies */ /* Read data from cookies */ { Cookie cookieSources[] = request.getCookies(); if (cookieSources != null) { /* POTENTIAL FLAW: Read data from the first cookie value */ String s_data = cookieSources[0].getValue(); try { data = Integer.parseInt(s_data.trim()); } catch(NumberFormatException nfe) { IO.logger.log(Level.WARNING, "Number format exception reading data from cookie", nfe); } } } // serialize data to a byte array ByteArrayOutputStream baos = null; ObjectOutput out = null; try { baos = new ByteArrayOutputStream() ; out = new ObjectOutputStream(baos) ; out.writeObject(data); byte[] data_serialized = baos.toByteArray(); (new CWE129_Improper_Validation_of_Array_Index__getCookies_Servlet_array_read_check_min_75b()).bad_sink(data_serialized , request, response ); } catch (IOException e) { IO.logger.log(Level.WARNING, "IOException in serialization", e); } finally { // clean up stream writing objects try { if (out != null) { out.close(); } } catch (IOException ioe) { IO.logger.log(Level.WARNING, "Error closing ObjectOutputStream", ioe); } try { if (baos != null) { baos.close(); } } catch (IOException ioe) { IO.logger.log(Level.WARNING, "Error closing ByteArrayOutputStream", ioe); } } } public void good(HttpServletRequest request, HttpServletResponse response) throws Throwable { goodG2B(request, response); goodB2G(request, response); } /* goodG2B() - use GoodSource and BadSink */ private void goodG2B(HttpServletRequest request, HttpServletResponse response) throws Throwable { int data; /* FIX: Use a hardcoded number that won't cause underflow, overflow, divide by zero, or loss-of-precision issues */ data = 2; // serialize data to a byte array ByteArrayOutputStream baos = null; ObjectOutput out = null; try { baos = new ByteArrayOutputStream() ; out = new ObjectOutputStream(baos) ; out.writeObject(data); byte[] data_serialized = baos.toByteArray(); (new CWE129_Improper_Validation_of_Array_Index__getCookies_Servlet_array_read_check_min_75b()).goodG2B_sink(data_serialized , request, response ); } catch (IOException e) { IO.logger.log(Level.WARNING, "IOException in serialization", e); } finally { // clean up stream writing objects try { if (out != null) { out.close(); } } catch (IOException ioe) { IO.logger.log(Level.WARNING, "Error closing ObjectOutputStream", ioe); } try { if (baos != null) { baos.close(); } } catch (IOException ioe) { IO.logger.log(Level.WARNING, "Error closing ByteArrayOutputStream", ioe); } } } /* goodB2G() - use BadSource and GoodSink */ private void goodB2G(HttpServletRequest request, HttpServletResponse response) throws Throwable { int data; data = Integer.MIN_VALUE; /* initialize data in case there are no cookies */ /* Read data from cookies */ { Cookie cookieSources[] = request.getCookies(); if (cookieSources != null) { /* POTENTIAL FLAW: Read data from the first cookie value */ String s_data = cookieSources[0].getValue(); try { data = Integer.parseInt(s_data.trim()); } catch(NumberFormatException nfe) { IO.logger.log(Level.WARNING, "Number format exception reading data from cookie", nfe); } } } // serialize data to a byte array ByteArrayOutputStream baos = null; ObjectOutput out = null; try { baos = new ByteArrayOutputStream() ; out = new ObjectOutputStream(baos) ; out.writeObject(data); byte[] data_serialized = baos.toByteArray(); (new CWE129_Improper_Validation_of_Array_Index__getCookies_Servlet_array_read_check_min_75b()).goodB2G_sink(data_serialized , request, response ); } catch (IOException e) { IO.logger.log(Level.WARNING, "IOException in serialization", e); } finally { // clean up stream writing objects try { if (out != null) { out.close(); } } catch (IOException ioe) { IO.logger.log(Level.WARNING, "Error closing ObjectOutputStream", ioe); } try { if (baos != null) { baos.close(); } } catch (IOException ioe) { IO.logger.log(Level.WARNING, "Error closing ByteArrayOutputStream", ioe); } } } /* Below is the main(). It is only used when building this testcase on its own for testing or for building a binary to use in testing binary analysis tools. It is not used when compiling all the testcases as one application, which is how source code analysis tools are tested. */ public static void main(String[] args) throws ClassNotFoundException, InstantiationException, IllegalAccessException { mainFromParent(args); } }
[ "guillermo.pando@gmail.com" ]
guillermo.pando@gmail.com
7cc04b99b934ae428177d1b2c23d7f9969500f31
f9a6b01dde5f64c5549bf491f03821b69804c925
/src/com/lrf/feature/Son.java
dfd51c7d2691405fec964b0165cab8afa9602135
[]
no_license
lirf2018/javaproject
d0feb8a4d8cc6777e620ead3fb5273b90a880424
f8078d1c06741ca7b3a376b0adbb3aa159899f9f
refs/heads/master
2020-06-17T11:16:15.226540
2019-07-09T01:17:51
2019-07-09T01:17:51
195,908,003
0
0
null
null
null
null
UTF-8
Java
false
false
622
java
package com.lrf.feature; /** * 创建人: lirf * 创建时间: 2019/3/7 13:47 * 功能介绍: */ public class Son extends ParentA { /** * @param a * @return void * @desc 子类重载父类方法 * 父类中不存在该方法,向上转型后,父类是不能引用该方法的 */ public void fun1(String a) { System.out.println("Son 的 Fun1..."); fun2(); } /** * 子类重写父类方法 * 指向子类的父类引用调用fun2时,必定是调用该方法 */ public void fun2() { System.out.println("Son 的Fun2..."); } }
[ "512164882@qq.com" ]
512164882@qq.com
9f001dbee53e0e16c10cce7652813feefae6f228
5b96abeef33c16081304512dbb139224883aafd0
/Sistema de Judocas/test/org/fpij/jitakyoei/view/gui/EnderecoPanelTest.java
2cfaf81a65f0e5b6a75e4b044f1d1b7bac6d255c
[]
no_license
Yuri-Bigaton/Sistema-de-Judocas
4b84dad349f7dd2e698e2d9813166b96bd5deadd
5723d5691805af50045cc912d8eec85edc3fea63
refs/heads/master
2020-05-18T06:50:13.603790
2019-05-27T14:34:36
2019-05-27T14:34:36
184,246,838
0
0
null
2019-05-26T21:51:40
2019-04-30T11:03:12
Java
UTF-8
Java
false
false
3,738
java
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package org.fpij.jitakyoei.view.gui; import javax.swing.JTextField; import org.junit.After; import org.junit.AfterClass; import org.junit.Before; import org.junit.BeforeClass; import org.junit.Test; import static org.junit.Assert.*; /** * * @author 31756123 */ public class EnderecoPanelTest { public EnderecoPanelTest() { } @BeforeClass public static void setUpClass() { } @AfterClass public static void tearDownClass() { } @Before public void setUp() { } @After public void tearDown() { } /** * Test of getRua method, of class EnderecoPanel. */ @Test public void testGetRua() { System.out.println("getRua"); EnderecoPanel instance = new EnderecoPanel(); JTextField expResult = null; JTextField result = instance.getRua(); assertEquals(expResult, result); // TODO review the generated test code and remove the default call to fail. fail("The test case is a prototype."); } /** * Test of getNumero method, of class EnderecoPanel. */ @Test public void testGetNumero() { System.out.println("getNumero"); EnderecoPanel instance = new EnderecoPanel(); JTextField expResult = null; JTextField result = instance.getNumero(); assertEquals(expResult, result); // TODO review the generated test code and remove the default call to fail. fail("The test case is a prototype."); } /** * Test of getBairro method, of class EnderecoPanel. */ @Test public void testGetBairro() { System.out.println("getBairro"); EnderecoPanel instance = new EnderecoPanel(); JTextField expResult = null; JTextField result = instance.getBairro(); assertEquals(expResult, result); // TODO review the generated test code and remove the default call to fail. fail("The test case is a prototype."); } /** * Test of getCidade method, of class EnderecoPanel. */ @Test public void testGetCidade() { System.out.println("getCidade"); EnderecoPanel instance = new EnderecoPanel(); JTextField expResult = null; JTextField result = instance.getCidade(); assertEquals(expResult, result); // TODO review the generated test code and remove the default call to fail. fail("The test case is a prototype."); } /** * Test of getEstado method, of class EnderecoPanel. */ @Test public void testGetEstado() { System.out.println("getEstado"); EnderecoPanel instance = new EnderecoPanel(); JTextField expResult = null; JTextField result = instance.getEstado(); assertEquals(expResult, result); // TODO review the generated test code and remove the default call to fail. fail("The test case is a prototype."); } /** * Test of getCep method, of class EnderecoPanel. */ @Test public void testGetCep() { System.out.println("getCep"); EnderecoPanel instance = new EnderecoPanel(); JTextField expResult = null; JTextField result = instance.getCep(); assertEquals(expResult, result); // TODO review the generated test code and remove the default call to fail. fail("The test case is a prototype."); } }
[ "31756123@087830-P33S105.MackSP.br" ]
31756123@087830-P33S105.MackSP.br
87f61f76e511d7d39ee166a64d8043b67bb3fd1c
628a83504b94c68484099b11c9f41e5f8c1bdf89
/src/main/java/com/aug3/sys/rmi/IConfigMgr.java
00f10140bd2a41fd055d11cdb571ed5a5cfd4fe4
[]
no_license
xialei/aug3-sys
57f7b56de5b994cb9d3536eafca127470201acef
fe2fcbb1bf4834c13a798f4d3e9d70bb6a3a8626
refs/heads/master
2021-01-10T19:23:39.981091
2011-12-05T15:11:19
2011-12-05T15:11:19
2,916,875
0
0
null
null
null
null
UTF-8
Java
false
false
2,446
java
package com.aug3.sys.rmi; import java.rmi.Remote; import java.util.Map; import com.aug3.sys.AppContext; import com.aug3.sys.cfg.ConfigType; import com.aug3.sys.cfg.ValueSet; import com.aug3.sys.cfg.ValueSetLookupInfo; /** * * provides remote access to the configuration server. It is an wrapper around * the LocalConfigServer class, mostly delegating calls to it. * * stub * */ public interface IConfigMgr extends Remote { public static final String SERVICE_NAME = "configMgr"; /** * Gets the ValueSet for the given lookup info * * @param li * - the lookup info * @return value set * @throws Exception * */ public ValueSet getValueSet(ValueSetLookupInfo li) throws Exception; /** * Gets the Value for the given lookup info and value name * * @param li * - the lookup info * @param key * - the configuration value key * @return configuration value * @throws Exception * */ public Object getValue(ValueSetLookupInfo li, String key) throws Exception; /** * Sets the ValueSet in storage * * @param li * - the lookup info * @param vs * - value set * @throws Exception * */ public void setValueSet(ValueSetLookupInfo li, ValueSet vs) throws Exception; /** * Sets the Value in storage * * @param li * - the lookup info * @param key * - the configuration value key * @param val * - the configuration value * @throws Exception * */ public void setValue(ValueSetLookupInfo li, String key, Object val) throws Exception; /** * Retrieves the contents of the configuration file specified. No cache for * this file * * @param ctx * the name of the company, use "defaultcompany.com" if you want * default values. * @param filename * the name of the file you want. * @return the contents of the file or null if no file is found. * */ public String getTextFile(AppContext ctx, String filename) throws Exception; /** * Retrieves the timestamp of the configuration file. * */ public Long getLastModified(AppContext ctx, String filename) throws Exception; /** * Retrieves a map of config types * */ public Map<String, ConfigType> getConfigTypes() throws Exception; /** * Method used to check if access to the bean is working properly. * */ public boolean isAlive(); }
[ "lxia@hp.com" ]
lxia@hp.com
9eeb78db5ba78b86306210b2124991ea3da941e4
d10598f7effdb3e7c39590bbced5ede1bb8fcf57
/app/src/main/java/com/fanchen/imovie/view/video_new/Clarity.java
dda9e7a5f57a6c95cf5d49e4eee09ca46485e963
[]
no_license
ycyranqingjjs/Bangumi
6f32235e2b4dba1cc9a48439cd27444aa628cbeb
dddc1772ef5f05072b4865b05b727a7ec541b68c
refs/heads/master
2020-04-07T23:31:26.314885
2018-10-24T06:17:08
2018-10-24T06:17:08
null
0
0
null
null
null
null
UTF-8
Java
false
false
404
java
package com.fanchen.imovie.view.video_new; /** * 清晰度 */ public class Clarity { public String grade; // 清晰度等级 public String p; // 270P、480P、720P、1080P、4K ... public String videoUrl; // 视频链接地址 public Clarity(String grade, String p, String videoUrl) { this.grade = grade; this.p = p; this.videoUrl = videoUrl; } }
[ "happy1993_chen@sina.cn" ]
happy1993_chen@sina.cn
3eb600c258e0e0f70af104ebf3da592a9586975d
d88ce1f2df3cd0e49a52905617454e19fd8acbad
/AuntSystem/src/main/java/com/cyx/util/CheckJz.java
dfc8bff9ddcc9bcba87540c2df4d427ea83f28f1
[]
no_license
choisound/AuntSystem
c8417af14d7e137983bcf755ac9d4efcccddec72
6ee1cb97827b4f5f71c05d40a81268f9bdeb89b5
refs/heads/master
2021-04-26T23:00:46.145022
2018-03-05T12:16:09
2018-03-05T12:16:09
123,913,350
0
0
null
null
null
null
UTF-8
Java
false
false
901
java
package com.cyx.util; import java.util.List; import ch.hsr.geohash.GeoHash; import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSONObject; public class CheckJz { public static boolean check(String str){ HttpRequest hr=new HttpRequest(); String strs=hr.sendPost("http://www.hoapi.com/index.php/Home/Api/check", "str="+str+"&token="+"7f1f8782c3985a6bb9824cb6ff70dd38"); JSON.toJSON(strs); JSONObject parseObject = JSON.parseObject(strs); System.out.println(parseObject); return parseObject.getBooleanValue("status"); } public static String LongLatExchange(String auntAddress){ String []ps=auntAddress.split(","); double j=Double.parseDouble(ps[0]); double w=Double.parseDouble(ps[1]); int precision = 10; GeoHash geoHash = GeoHash.withCharacterPrecision(w,j,precision); String auntAddress1=geoHash.toBase32(); return auntAddress1; } }
[ "choisound@qq.com" ]
choisound@qq.com
ad6d955b17cb093a3398613349ab5a62aedb5620
3e73c26a2702495bb7fdeea5272f1cbe4d7b5234
/src/htl/diplomarbeit/ksm/view/NachKalkulationController.java
04a59bae81ff2400bf5a1d379e83fc7974b0cb5c
[]
no_license
buenaflor/KSM-K-chenstudiomanager
c885f2528c863350ed2c2110084a6774cd14639e
2b95193c942e0b69885b2e610319e278b1155623
refs/heads/master
2021-08-29T12:22:48.510940
2017-12-14T00:22:03
2017-12-14T00:22:03
114,182,496
0
0
null
null
null
null
UTF-8
Java
false
false
918
java
package htl.diplomarbeit.ksm.view; import htl.diplomarbeit.ksm.model.NachKalkulation; import javafx.collections.FXCollections; import javafx.collections.ObservableList; import javafx.fxml.FXML; import javafx.scene.control.Alert; import javafx.scene.control.Alert.AlertType; import javafx.scene.control.Button; import javafx.scene.control.TableView; import javafx.scene.layout.Background; import javafx.stage.Stage; public class NachKalkulationController { Stage dialogStage; ObservableList data = FXCollections.observableArrayList(); @FXML private Button addLine_btn; @FXML private TableView nachkalk_table; public void setDialogStage(Stage dialogStage){ this.dialogStage = dialogStage; } @FXML private void initialize(){ nachkalk_table.setStyle("-fx-background-color:red"); } @FXML private void addLine(){ data.add(new NachKalkulation()); nachkalk_table.setItems(data); } }
[ "giancarlo_buenaflor@yahoo.com" ]
giancarlo_buenaflor@yahoo.com
aed884fc98600e8678a2156406f23d95c4b55360
7a57a137b7b7a23879f890302ab7b6de19112de8
/jaxos/src/main/java/org/axesoft/jaxos/network/protobuff/PaxosMessage.java
256896e0f51de08f8acf6e1e6f4dbaf015098c77
[ "Apache-2.0" ]
permissive
stone-guru/tans
45ceef51b05498716455c03315b85ccb58459b48
99d648bd9f66b2ae88dcead7a46835c2378c2b70
refs/heads/master
2022-12-24T03:24:15.838387
2020-02-23T05:08:43
2020-02-23T05:08:43
240,415,999
1
0
Apache-2.0
2022-12-14T20:30:50
2020-02-14T02:57:04
Java
UTF-8
Java
false
true
419,435
java
// Generated by the protocol buffer compiler. DO NOT EDIT! // source: paxos-msg.proto package org.axesoft.jaxos.network.protobuff; public final class PaxosMessage { private PaxosMessage() {} public static void registerAllExtensions( com.google.protobuf.ExtensionRegistryLite registry) { } public static void registerAllExtensions( com.google.protobuf.ExtensionRegistry registry) { registerAllExtensions( (com.google.protobuf.ExtensionRegistryLite) registry); } /** * Protobuf enum {@code org.axesoft.jaxos.network.protobuff.Code} */ public enum Code implements com.google.protobuf.ProtocolMessageEnum { /** * <code>NONE = 0;</code> */ NONE(0), /** * <code>JOIN_REQ = 1;</code> */ JOIN_REQ(1), /** * <code>JOIN_RES = 2;</code> */ JOIN_RES(2), /** * <code>PREPARE_REQ = 3;</code> */ PREPARE_REQ(3), /** * <code>PREPARE_RES = 4;</code> */ PREPARE_RES(4), /** * <code>ACCEPT_REQ = 5;</code> */ ACCEPT_REQ(5), /** * <code>ACCEPT_RES = 6;</code> */ ACCEPT_RES(6), /** * <pre> *NOOP=10; * </pre> * * <code>CHOSEN_NOTIFY = 7;</code> */ CHOSEN_NOTIFY(7), /** * <code>LEARN_REQ = 11;</code> */ LEARN_REQ(11), /** * <code>LEARN_RES = 12;</code> */ LEARN_RES(12), UNRECOGNIZED(-1), ; /** * <code>NONE = 0;</code> */ public static final int NONE_VALUE = 0; /** * <code>JOIN_REQ = 1;</code> */ public static final int JOIN_REQ_VALUE = 1; /** * <code>JOIN_RES = 2;</code> */ public static final int JOIN_RES_VALUE = 2; /** * <code>PREPARE_REQ = 3;</code> */ public static final int PREPARE_REQ_VALUE = 3; /** * <code>PREPARE_RES = 4;</code> */ public static final int PREPARE_RES_VALUE = 4; /** * <code>ACCEPT_REQ = 5;</code> */ public static final int ACCEPT_REQ_VALUE = 5; /** * <code>ACCEPT_RES = 6;</code> */ public static final int ACCEPT_RES_VALUE = 6; /** * <pre> *NOOP=10; * </pre> * * <code>CHOSEN_NOTIFY = 7;</code> */ public static final int CHOSEN_NOTIFY_VALUE = 7; /** * <code>LEARN_REQ = 11;</code> */ public static final int LEARN_REQ_VALUE = 11; /** * <code>LEARN_RES = 12;</code> */ public static final int LEARN_RES_VALUE = 12; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static Code valueOf(int value) { return forNumber(value); } public static Code forNumber(int value) { switch (value) { case 0: return NONE; case 1: return JOIN_REQ; case 2: return JOIN_RES; case 3: return PREPARE_REQ; case 4: return PREPARE_RES; case 5: return ACCEPT_REQ; case 6: return ACCEPT_RES; case 7: return CHOSEN_NOTIFY; case 11: return LEARN_REQ; case 12: return LEARN_RES; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap<Code> internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap< Code> internalValueMap = new com.google.protobuf.Internal.EnumLiteMap<Code>() { public Code findValueByNumber(int number) { return Code.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.getDescriptor().getEnumTypes().get(0); } private static final Code[] VALUES = values(); public static Code valueOf( com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException( "EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private Code(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:org.axesoft.jaxos.network.protobuff.Code) } /** * Protobuf enum {@code org.axesoft.jaxos.network.protobuff.ValueType} */ public enum ValueType implements com.google.protobuf.ProtocolMessageEnum { /** * <code>NOTHING = 0;</code> */ NOTHING(0), /** * <code>APPLICATION = 1;</code> */ APPLICATION(1), /** * <code>NOOP = 2;</code> */ NOOP(2), UNRECOGNIZED(-1), ; /** * <code>NOTHING = 0;</code> */ public static final int NOTHING_VALUE = 0; /** * <code>APPLICATION = 1;</code> */ public static final int APPLICATION_VALUE = 1; /** * <code>NOOP = 2;</code> */ public static final int NOOP_VALUE = 2; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static ValueType valueOf(int value) { return forNumber(value); } public static ValueType forNumber(int value) { switch (value) { case 0: return NOTHING; case 1: return APPLICATION; case 2: return NOOP; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap<ValueType> internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap< ValueType> internalValueMap = new com.google.protobuf.Internal.EnumLiteMap<ValueType>() { public ValueType findValueByNumber(int number) { return ValueType.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.getDescriptor().getEnumTypes().get(1); } private static final ValueType[] VALUES = values(); public static ValueType valueOf( com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException( "EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private ValueType(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:org.axesoft.jaxos.network.protobuff.ValueType) } public interface DataGramOrBuilder extends // @@protoc_insertion_point(interface_extends:org.axesoft.jaxos.network.protobuff.DataGram) com.google.protobuf.MessageOrBuilder { /** * <code>optional .org.axesoft.jaxos.network.protobuff.Code code = 1;</code> */ int getCodeValue(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.Code code = 1;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.Code getCode(); /** * <code>optional int32 sender = 2;</code> */ int getSender(); /** * <code>optional int64 timestamp = 3;</code> */ long getTimestamp(); /** * <code>optional bytes body = 4;</code> */ com.google.protobuf.ByteString getBody(); } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.DataGram} */ public static final class DataGram extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:org.axesoft.jaxos.network.protobuff.DataGram) DataGramOrBuilder { // Use DataGram.newBuilder() to construct. private DataGram(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { super(builder); } private DataGram() { code_ = 0; sender_ = 0; timestamp_ = 0L; body_ = com.google.protobuf.ByteString.EMPTY; } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private DataGram( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 8: { int rawValue = input.readEnum(); code_ = rawValue; break; } case 16: { sender_ = input.readInt32(); break; } case 24: { timestamp_ = input.readInt64(); break; } case 34: { body_ = input.readBytes(); break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_DataGram_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_DataGram_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram.Builder.class); } public static final int CODE_FIELD_NUMBER = 1; private int code_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.Code code = 1;</code> */ public int getCodeValue() { return code_; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.Code code = 1;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.Code getCode() { org.axesoft.jaxos.network.protobuff.PaxosMessage.Code result = org.axesoft.jaxos.network.protobuff.PaxosMessage.Code.valueOf(code_); return result == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.Code.UNRECOGNIZED : result; } public static final int SENDER_FIELD_NUMBER = 2; private int sender_; /** * <code>optional int32 sender = 2;</code> */ public int getSender() { return sender_; } public static final int TIMESTAMP_FIELD_NUMBER = 3; private long timestamp_; /** * <code>optional int64 timestamp = 3;</code> */ public long getTimestamp() { return timestamp_; } public static final int BODY_FIELD_NUMBER = 4; private com.google.protobuf.ByteString body_; /** * <code>optional bytes body = 4;</code> */ public com.google.protobuf.ByteString getBody() { return body_; } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (code_ != org.axesoft.jaxos.network.protobuff.PaxosMessage.Code.NONE.getNumber()) { output.writeEnum(1, code_); } if (sender_ != 0) { output.writeInt32(2, sender_); } if (timestamp_ != 0L) { output.writeInt64(3, timestamp_); } if (!body_.isEmpty()) { output.writeBytes(4, body_); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (code_ != org.axesoft.jaxos.network.protobuff.PaxosMessage.Code.NONE.getNumber()) { size += com.google.protobuf.CodedOutputStream .computeEnumSize(1, code_); } if (sender_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(2, sender_); } if (timestamp_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(3, timestamp_); } if (!body_.isEmpty()) { size += com.google.protobuf.CodedOutputStream .computeBytesSize(4, body_); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram)) { return super.equals(obj); } org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram other = (org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram) obj; boolean result = true; result = result && code_ == other.code_; result = result && (getSender() == other.getSender()); result = result && (getTimestamp() == other.getTimestamp()); result = result && getBody() .equals(other.getBody()); return result; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + CODE_FIELD_NUMBER; hash = (53 * hash) + code_; hash = (37 * hash) + SENDER_FIELD_NUMBER; hash = (53 * hash) + getSender(); hash = (37 * hash) + TIMESTAMP_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getTimestamp()); hash = (37 * hash) + BODY_FIELD_NUMBER; hash = (53 * hash) + getBody().hashCode(); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.DataGram} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements // @@protoc_insertion_point(builder_implements:org.axesoft.jaxos.network.protobuff.DataGram) org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGramOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_DataGram_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_DataGram_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram.Builder.class); } // Construct using org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } public Builder clear() { super.clear(); code_ = 0; sender_ = 0; timestamp_ = 0L; body_ = com.google.protobuf.ByteString.EMPTY; return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_DataGram_descriptor; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram getDefaultInstanceForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram.getDefaultInstance(); } public org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram build() { org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram buildPartial() { org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram result = new org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram(this); result.code_ = code_; result.sender_ = sender_; result.timestamp_ = timestamp_; result.body_ = body_; onBuilt(); return result; } public Builder clone() { return (Builder) super.clone(); } public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.setField(field, value); } public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return (Builder) super.clearField(field); } public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return (Builder) super.clearOneof(oneof); } public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) { return (Builder) super.setRepeatedField(field, index, value); } public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram) { return mergeFrom((org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram other) { if (other == org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram.getDefaultInstance()) return this; if (other.code_ != 0) { setCodeValue(other.getCodeValue()); } if (other.getSender() != 0) { setSender(other.getSender()); } if (other.getTimestamp() != 0L) { setTimestamp(other.getTimestamp()); } if (other.getBody() != com.google.protobuf.ByteString.EMPTY) { setBody(other.getBody()); } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int code_ = 0; /** * <code>optional .org.axesoft.jaxos.network.protobuff.Code code = 1;</code> */ public int getCodeValue() { return code_; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.Code code = 1;</code> */ public Builder setCodeValue(int value) { code_ = value; onChanged(); return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.Code code = 1;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.Code getCode() { org.axesoft.jaxos.network.protobuff.PaxosMessage.Code result = org.axesoft.jaxos.network.protobuff.PaxosMessage.Code.valueOf(code_); return result == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.Code.UNRECOGNIZED : result; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.Code code = 1;</code> */ public Builder setCode(org.axesoft.jaxos.network.protobuff.PaxosMessage.Code value) { if (value == null) { throw new NullPointerException(); } code_ = value.getNumber(); onChanged(); return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.Code code = 1;</code> */ public Builder clearCode() { code_ = 0; onChanged(); return this; } private int sender_ ; /** * <code>optional int32 sender = 2;</code> */ public int getSender() { return sender_; } /** * <code>optional int32 sender = 2;</code> */ public Builder setSender(int value) { sender_ = value; onChanged(); return this; } /** * <code>optional int32 sender = 2;</code> */ public Builder clearSender() { sender_ = 0; onChanged(); return this; } private long timestamp_ ; /** * <code>optional int64 timestamp = 3;</code> */ public long getTimestamp() { return timestamp_; } /** * <code>optional int64 timestamp = 3;</code> */ public Builder setTimestamp(long value) { timestamp_ = value; onChanged(); return this; } /** * <code>optional int64 timestamp = 3;</code> */ public Builder clearTimestamp() { timestamp_ = 0L; onChanged(); return this; } private com.google.protobuf.ByteString body_ = com.google.protobuf.ByteString.EMPTY; /** * <code>optional bytes body = 4;</code> */ public com.google.protobuf.ByteString getBody() { return body_; } /** * <code>optional bytes body = 4;</code> */ public Builder setBody(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } body_ = value; onChanged(); return this; } /** * <code>optional bytes body = 4;</code> */ public Builder clearBody() { body_ = getDefaultInstance().getBody(); onChanged(); return this; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:org.axesoft.jaxos.network.protobuff.DataGram) } // @@protoc_insertion_point(class_scope:org.axesoft.jaxos.network.protobuff.DataGram) private static final org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram(); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser<DataGram> PARSER = new com.google.protobuf.AbstractParser<DataGram>() { public DataGram parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new DataGram(input, extensionRegistry); } }; public static com.google.protobuf.Parser<DataGram> parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser<DataGram> getParserForType() { return PARSER; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.DataGram getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface JoinReqOrBuilder extends // @@protoc_insertion_point(interface_extends:org.axesoft.jaxos.network.protobuff.JoinReq) com.google.protobuf.MessageOrBuilder { /** * <code>optional bytes token = 1;</code> */ com.google.protobuf.ByteString getToken(); /** * <code>optional bytes hostname = 2;</code> */ com.google.protobuf.ByteString getHostname(); /** * <code>optional int32 partitionNumber = 3;</code> */ int getPartitionNumber(); /** * <code>optional bytes jaxosMessageVersion = 4;</code> */ com.google.protobuf.ByteString getJaxosMessageVersion(); /** * <code>optional bytes appMessageVersion = 5;</code> */ com.google.protobuf.ByteString getAppMessageVersion(); /** * <code>optional bytes destHostname = 6;</code> */ com.google.protobuf.ByteString getDestHostname(); } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.JoinReq} */ public static final class JoinReq extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:org.axesoft.jaxos.network.protobuff.JoinReq) JoinReqOrBuilder { // Use JoinReq.newBuilder() to construct. private JoinReq(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { super(builder); } private JoinReq() { token_ = com.google.protobuf.ByteString.EMPTY; hostname_ = com.google.protobuf.ByteString.EMPTY; partitionNumber_ = 0; jaxosMessageVersion_ = com.google.protobuf.ByteString.EMPTY; appMessageVersion_ = com.google.protobuf.ByteString.EMPTY; destHostname_ = com.google.protobuf.ByteString.EMPTY; } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private JoinReq( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 10: { token_ = input.readBytes(); break; } case 18: { hostname_ = input.readBytes(); break; } case 24: { partitionNumber_ = input.readInt32(); break; } case 34: { jaxosMessageVersion_ = input.readBytes(); break; } case 42: { appMessageVersion_ = input.readBytes(); break; } case 50: { destHostname_ = input.readBytes(); break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_JoinReq_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_JoinReq_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq.Builder.class); } public static final int TOKEN_FIELD_NUMBER = 1; private com.google.protobuf.ByteString token_; /** * <code>optional bytes token = 1;</code> */ public com.google.protobuf.ByteString getToken() { return token_; } public static final int HOSTNAME_FIELD_NUMBER = 2; private com.google.protobuf.ByteString hostname_; /** * <code>optional bytes hostname = 2;</code> */ public com.google.protobuf.ByteString getHostname() { return hostname_; } public static final int PARTITIONNUMBER_FIELD_NUMBER = 3; private int partitionNumber_; /** * <code>optional int32 partitionNumber = 3;</code> */ public int getPartitionNumber() { return partitionNumber_; } public static final int JAXOSMESSAGEVERSION_FIELD_NUMBER = 4; private com.google.protobuf.ByteString jaxosMessageVersion_; /** * <code>optional bytes jaxosMessageVersion = 4;</code> */ public com.google.protobuf.ByteString getJaxosMessageVersion() { return jaxosMessageVersion_; } public static final int APPMESSAGEVERSION_FIELD_NUMBER = 5; private com.google.protobuf.ByteString appMessageVersion_; /** * <code>optional bytes appMessageVersion = 5;</code> */ public com.google.protobuf.ByteString getAppMessageVersion() { return appMessageVersion_; } public static final int DESTHOSTNAME_FIELD_NUMBER = 6; private com.google.protobuf.ByteString destHostname_; /** * <code>optional bytes destHostname = 6;</code> */ public com.google.protobuf.ByteString getDestHostname() { return destHostname_; } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!token_.isEmpty()) { output.writeBytes(1, token_); } if (!hostname_.isEmpty()) { output.writeBytes(2, hostname_); } if (partitionNumber_ != 0) { output.writeInt32(3, partitionNumber_); } if (!jaxosMessageVersion_.isEmpty()) { output.writeBytes(4, jaxosMessageVersion_); } if (!appMessageVersion_.isEmpty()) { output.writeBytes(5, appMessageVersion_); } if (!destHostname_.isEmpty()) { output.writeBytes(6, destHostname_); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!token_.isEmpty()) { size += com.google.protobuf.CodedOutputStream .computeBytesSize(1, token_); } if (!hostname_.isEmpty()) { size += com.google.protobuf.CodedOutputStream .computeBytesSize(2, hostname_); } if (partitionNumber_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(3, partitionNumber_); } if (!jaxosMessageVersion_.isEmpty()) { size += com.google.protobuf.CodedOutputStream .computeBytesSize(4, jaxosMessageVersion_); } if (!appMessageVersion_.isEmpty()) { size += com.google.protobuf.CodedOutputStream .computeBytesSize(5, appMessageVersion_); } if (!destHostname_.isEmpty()) { size += com.google.protobuf.CodedOutputStream .computeBytesSize(6, destHostname_); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq)) { return super.equals(obj); } org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq other = (org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq) obj; boolean result = true; result = result && getToken() .equals(other.getToken()); result = result && getHostname() .equals(other.getHostname()); result = result && (getPartitionNumber() == other.getPartitionNumber()); result = result && getJaxosMessageVersion() .equals(other.getJaxosMessageVersion()); result = result && getAppMessageVersion() .equals(other.getAppMessageVersion()); result = result && getDestHostname() .equals(other.getDestHostname()); return result; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + TOKEN_FIELD_NUMBER; hash = (53 * hash) + getToken().hashCode(); hash = (37 * hash) + HOSTNAME_FIELD_NUMBER; hash = (53 * hash) + getHostname().hashCode(); hash = (37 * hash) + PARTITIONNUMBER_FIELD_NUMBER; hash = (53 * hash) + getPartitionNumber(); hash = (37 * hash) + JAXOSMESSAGEVERSION_FIELD_NUMBER; hash = (53 * hash) + getJaxosMessageVersion().hashCode(); hash = (37 * hash) + APPMESSAGEVERSION_FIELD_NUMBER; hash = (53 * hash) + getAppMessageVersion().hashCode(); hash = (37 * hash) + DESTHOSTNAME_FIELD_NUMBER; hash = (53 * hash) + getDestHostname().hashCode(); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.JoinReq} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements // @@protoc_insertion_point(builder_implements:org.axesoft.jaxos.network.protobuff.JoinReq) org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReqOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_JoinReq_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_JoinReq_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq.Builder.class); } // Construct using org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } public Builder clear() { super.clear(); token_ = com.google.protobuf.ByteString.EMPTY; hostname_ = com.google.protobuf.ByteString.EMPTY; partitionNumber_ = 0; jaxosMessageVersion_ = com.google.protobuf.ByteString.EMPTY; appMessageVersion_ = com.google.protobuf.ByteString.EMPTY; destHostname_ = com.google.protobuf.ByteString.EMPTY; return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_JoinReq_descriptor; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq getDefaultInstanceForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq.getDefaultInstance(); } public org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq build() { org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq buildPartial() { org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq result = new org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq(this); result.token_ = token_; result.hostname_ = hostname_; result.partitionNumber_ = partitionNumber_; result.jaxosMessageVersion_ = jaxosMessageVersion_; result.appMessageVersion_ = appMessageVersion_; result.destHostname_ = destHostname_; onBuilt(); return result; } public Builder clone() { return (Builder) super.clone(); } public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.setField(field, value); } public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return (Builder) super.clearField(field); } public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return (Builder) super.clearOneof(oneof); } public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) { return (Builder) super.setRepeatedField(field, index, value); } public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq) { return mergeFrom((org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq other) { if (other == org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq.getDefaultInstance()) return this; if (other.getToken() != com.google.protobuf.ByteString.EMPTY) { setToken(other.getToken()); } if (other.getHostname() != com.google.protobuf.ByteString.EMPTY) { setHostname(other.getHostname()); } if (other.getPartitionNumber() != 0) { setPartitionNumber(other.getPartitionNumber()); } if (other.getJaxosMessageVersion() != com.google.protobuf.ByteString.EMPTY) { setJaxosMessageVersion(other.getJaxosMessageVersion()); } if (other.getAppMessageVersion() != com.google.protobuf.ByteString.EMPTY) { setAppMessageVersion(other.getAppMessageVersion()); } if (other.getDestHostname() != com.google.protobuf.ByteString.EMPTY) { setDestHostname(other.getDestHostname()); } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private com.google.protobuf.ByteString token_ = com.google.protobuf.ByteString.EMPTY; /** * <code>optional bytes token = 1;</code> */ public com.google.protobuf.ByteString getToken() { return token_; } /** * <code>optional bytes token = 1;</code> */ public Builder setToken(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } token_ = value; onChanged(); return this; } /** * <code>optional bytes token = 1;</code> */ public Builder clearToken() { token_ = getDefaultInstance().getToken(); onChanged(); return this; } private com.google.protobuf.ByteString hostname_ = com.google.protobuf.ByteString.EMPTY; /** * <code>optional bytes hostname = 2;</code> */ public com.google.protobuf.ByteString getHostname() { return hostname_; } /** * <code>optional bytes hostname = 2;</code> */ public Builder setHostname(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } hostname_ = value; onChanged(); return this; } /** * <code>optional bytes hostname = 2;</code> */ public Builder clearHostname() { hostname_ = getDefaultInstance().getHostname(); onChanged(); return this; } private int partitionNumber_ ; /** * <code>optional int32 partitionNumber = 3;</code> */ public int getPartitionNumber() { return partitionNumber_; } /** * <code>optional int32 partitionNumber = 3;</code> */ public Builder setPartitionNumber(int value) { partitionNumber_ = value; onChanged(); return this; } /** * <code>optional int32 partitionNumber = 3;</code> */ public Builder clearPartitionNumber() { partitionNumber_ = 0; onChanged(); return this; } private com.google.protobuf.ByteString jaxosMessageVersion_ = com.google.protobuf.ByteString.EMPTY; /** * <code>optional bytes jaxosMessageVersion = 4;</code> */ public com.google.protobuf.ByteString getJaxosMessageVersion() { return jaxosMessageVersion_; } /** * <code>optional bytes jaxosMessageVersion = 4;</code> */ public Builder setJaxosMessageVersion(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } jaxosMessageVersion_ = value; onChanged(); return this; } /** * <code>optional bytes jaxosMessageVersion = 4;</code> */ public Builder clearJaxosMessageVersion() { jaxosMessageVersion_ = getDefaultInstance().getJaxosMessageVersion(); onChanged(); return this; } private com.google.protobuf.ByteString appMessageVersion_ = com.google.protobuf.ByteString.EMPTY; /** * <code>optional bytes appMessageVersion = 5;</code> */ public com.google.protobuf.ByteString getAppMessageVersion() { return appMessageVersion_; } /** * <code>optional bytes appMessageVersion = 5;</code> */ public Builder setAppMessageVersion(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } appMessageVersion_ = value; onChanged(); return this; } /** * <code>optional bytes appMessageVersion = 5;</code> */ public Builder clearAppMessageVersion() { appMessageVersion_ = getDefaultInstance().getAppMessageVersion(); onChanged(); return this; } private com.google.protobuf.ByteString destHostname_ = com.google.protobuf.ByteString.EMPTY; /** * <code>optional bytes destHostname = 6;</code> */ public com.google.protobuf.ByteString getDestHostname() { return destHostname_; } /** * <code>optional bytes destHostname = 6;</code> */ public Builder setDestHostname(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } destHostname_ = value; onChanged(); return this; } /** * <code>optional bytes destHostname = 6;</code> */ public Builder clearDestHostname() { destHostname_ = getDefaultInstance().getDestHostname(); onChanged(); return this; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:org.axesoft.jaxos.network.protobuff.JoinReq) } // @@protoc_insertion_point(class_scope:org.axesoft.jaxos.network.protobuff.JoinReq) private static final org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq(); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser<JoinReq> PARSER = new com.google.protobuf.AbstractParser<JoinReq>() { public JoinReq parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new JoinReq(input, extensionRegistry); } }; public static com.google.protobuf.Parser<JoinReq> parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser<JoinReq> getParserForType() { return PARSER; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinReq getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface JoinResOrBuilder extends // @@protoc_insertion_point(interface_extends:org.axesoft.jaxos.network.protobuff.JoinRes) com.google.protobuf.MessageOrBuilder { /** * <code>optional int32 result = 1;</code> */ int getResult(); /** * <code>optional bytes msg = 2;</code> */ com.google.protobuf.ByteString getMsg(); } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.JoinRes} */ public static final class JoinRes extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:org.axesoft.jaxos.network.protobuff.JoinRes) JoinResOrBuilder { // Use JoinRes.newBuilder() to construct. private JoinRes(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { super(builder); } private JoinRes() { result_ = 0; msg_ = com.google.protobuf.ByteString.EMPTY; } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private JoinRes( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 8: { result_ = input.readInt32(); break; } case 18: { msg_ = input.readBytes(); break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_JoinRes_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_JoinRes_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes.Builder.class); } public static final int RESULT_FIELD_NUMBER = 1; private int result_; /** * <code>optional int32 result = 1;</code> */ public int getResult() { return result_; } public static final int MSG_FIELD_NUMBER = 2; private com.google.protobuf.ByteString msg_; /** * <code>optional bytes msg = 2;</code> */ public com.google.protobuf.ByteString getMsg() { return msg_; } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (result_ != 0) { output.writeInt32(1, result_); } if (!msg_.isEmpty()) { output.writeBytes(2, msg_); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (result_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(1, result_); } if (!msg_.isEmpty()) { size += com.google.protobuf.CodedOutputStream .computeBytesSize(2, msg_); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes)) { return super.equals(obj); } org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes other = (org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes) obj; boolean result = true; result = result && (getResult() == other.getResult()); result = result && getMsg() .equals(other.getMsg()); return result; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + RESULT_FIELD_NUMBER; hash = (53 * hash) + getResult(); hash = (37 * hash) + MSG_FIELD_NUMBER; hash = (53 * hash) + getMsg().hashCode(); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.JoinRes} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements // @@protoc_insertion_point(builder_implements:org.axesoft.jaxos.network.protobuff.JoinRes) org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinResOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_JoinRes_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_JoinRes_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes.Builder.class); } // Construct using org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } public Builder clear() { super.clear(); result_ = 0; msg_ = com.google.protobuf.ByteString.EMPTY; return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_JoinRes_descriptor; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes getDefaultInstanceForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes.getDefaultInstance(); } public org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes build() { org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes buildPartial() { org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes result = new org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes(this); result.result_ = result_; result.msg_ = msg_; onBuilt(); return result; } public Builder clone() { return (Builder) super.clone(); } public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.setField(field, value); } public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return (Builder) super.clearField(field); } public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return (Builder) super.clearOneof(oneof); } public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) { return (Builder) super.setRepeatedField(field, index, value); } public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes) { return mergeFrom((org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes other) { if (other == org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes.getDefaultInstance()) return this; if (other.getResult() != 0) { setResult(other.getResult()); } if (other.getMsg() != com.google.protobuf.ByteString.EMPTY) { setMsg(other.getMsg()); } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int result_ ; /** * <code>optional int32 result = 1;</code> */ public int getResult() { return result_; } /** * <code>optional int32 result = 1;</code> */ public Builder setResult(int value) { result_ = value; onChanged(); return this; } /** * <code>optional int32 result = 1;</code> */ public Builder clearResult() { result_ = 0; onChanged(); return this; } private com.google.protobuf.ByteString msg_ = com.google.protobuf.ByteString.EMPTY; /** * <code>optional bytes msg = 2;</code> */ public com.google.protobuf.ByteString getMsg() { return msg_; } /** * <code>optional bytes msg = 2;</code> */ public Builder setMsg(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } msg_ = value; onChanged(); return this; } /** * <code>optional bytes msg = 2;</code> */ public Builder clearMsg() { msg_ = getDefaultInstance().getMsg(); onChanged(); return this; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:org.axesoft.jaxos.network.protobuff.JoinRes) } // @@protoc_insertion_point(class_scope:org.axesoft.jaxos.network.protobuff.JoinRes) private static final org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes(); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser<JoinRes> PARSER = new com.google.protobuf.AbstractParser<JoinRes>() { public JoinRes parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new JoinRes(input, extensionRegistry); } }; public static com.google.protobuf.Parser<JoinRes> parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser<JoinRes> getParserForType() { return PARSER; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.JoinRes getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface BallotValueOrBuilder extends // @@protoc_insertion_point(interface_extends:org.axesoft.jaxos.network.protobuff.BallotValue) com.google.protobuf.MessageOrBuilder { /** * <code>optional int64 id = 1;</code> */ long getId(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.ValueType type = 2;</code> */ int getTypeValue(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.ValueType type = 2;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.ValueType getType(); /** * <code>optional bytes content = 3;</code> */ com.google.protobuf.ByteString getContent(); } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.BallotValue} */ public static final class BallotValue extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:org.axesoft.jaxos.network.protobuff.BallotValue) BallotValueOrBuilder { // Use BallotValue.newBuilder() to construct. private BallotValue(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { super(builder); } private BallotValue() { id_ = 0L; type_ = 0; content_ = com.google.protobuf.ByteString.EMPTY; } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private BallotValue( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 8: { id_ = input.readInt64(); break; } case 16: { int rawValue = input.readEnum(); type_ = rawValue; break; } case 26: { content_ = input.readBytes(); break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_BallotValue_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_BallotValue_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder.class); } public static final int ID_FIELD_NUMBER = 1; private long id_; /** * <code>optional int64 id = 1;</code> */ public long getId() { return id_; } public static final int TYPE_FIELD_NUMBER = 2; private int type_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.ValueType type = 2;</code> */ public int getTypeValue() { return type_; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ValueType type = 2;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ValueType getType() { org.axesoft.jaxos.network.protobuff.PaxosMessage.ValueType result = org.axesoft.jaxos.network.protobuff.PaxosMessage.ValueType.valueOf(type_); return result == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.ValueType.UNRECOGNIZED : result; } public static final int CONTENT_FIELD_NUMBER = 3; private com.google.protobuf.ByteString content_; /** * <code>optional bytes content = 3;</code> */ public com.google.protobuf.ByteString getContent() { return content_; } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (id_ != 0L) { output.writeInt64(1, id_); } if (type_ != org.axesoft.jaxos.network.protobuff.PaxosMessage.ValueType.NOTHING.getNumber()) { output.writeEnum(2, type_); } if (!content_.isEmpty()) { output.writeBytes(3, content_); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (id_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(1, id_); } if (type_ != org.axesoft.jaxos.network.protobuff.PaxosMessage.ValueType.NOTHING.getNumber()) { size += com.google.protobuf.CodedOutputStream .computeEnumSize(2, type_); } if (!content_.isEmpty()) { size += com.google.protobuf.CodedOutputStream .computeBytesSize(3, content_); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue)) { return super.equals(obj); } org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue other = (org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue) obj; boolean result = true; result = result && (getId() == other.getId()); result = result && type_ == other.type_; result = result && getContent() .equals(other.getContent()); return result; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + ID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getId()); hash = (37 * hash) + TYPE_FIELD_NUMBER; hash = (53 * hash) + type_; hash = (37 * hash) + CONTENT_FIELD_NUMBER; hash = (53 * hash) + getContent().hashCode(); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.BallotValue} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements // @@protoc_insertion_point(builder_implements:org.axesoft.jaxos.network.protobuff.BallotValue) org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_BallotValue_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_BallotValue_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder.class); } // Construct using org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } public Builder clear() { super.clear(); id_ = 0L; type_ = 0; content_ = com.google.protobuf.ByteString.EMPTY; return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_BallotValue_descriptor; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue getDefaultInstanceForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.getDefaultInstance(); } public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue build() { org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue buildPartial() { org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue result = new org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue(this); result.id_ = id_; result.type_ = type_; result.content_ = content_; onBuilt(); return result; } public Builder clone() { return (Builder) super.clone(); } public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.setField(field, value); } public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return (Builder) super.clearField(field); } public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return (Builder) super.clearOneof(oneof); } public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) { return (Builder) super.setRepeatedField(field, index, value); } public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue) { return mergeFrom((org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue other) { if (other == org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.getDefaultInstance()) return this; if (other.getId() != 0L) { setId(other.getId()); } if (other.type_ != 0) { setTypeValue(other.getTypeValue()); } if (other.getContent() != com.google.protobuf.ByteString.EMPTY) { setContent(other.getContent()); } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private long id_ ; /** * <code>optional int64 id = 1;</code> */ public long getId() { return id_; } /** * <code>optional int64 id = 1;</code> */ public Builder setId(long value) { id_ = value; onChanged(); return this; } /** * <code>optional int64 id = 1;</code> */ public Builder clearId() { id_ = 0L; onChanged(); return this; } private int type_ = 0; /** * <code>optional .org.axesoft.jaxos.network.protobuff.ValueType type = 2;</code> */ public int getTypeValue() { return type_; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ValueType type = 2;</code> */ public Builder setTypeValue(int value) { type_ = value; onChanged(); return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ValueType type = 2;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ValueType getType() { org.axesoft.jaxos.network.protobuff.PaxosMessage.ValueType result = org.axesoft.jaxos.network.protobuff.PaxosMessage.ValueType.valueOf(type_); return result == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.ValueType.UNRECOGNIZED : result; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ValueType type = 2;</code> */ public Builder setType(org.axesoft.jaxos.network.protobuff.PaxosMessage.ValueType value) { if (value == null) { throw new NullPointerException(); } type_ = value.getNumber(); onChanged(); return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ValueType type = 2;</code> */ public Builder clearType() { type_ = 0; onChanged(); return this; } private com.google.protobuf.ByteString content_ = com.google.protobuf.ByteString.EMPTY; /** * <code>optional bytes content = 3;</code> */ public com.google.protobuf.ByteString getContent() { return content_; } /** * <code>optional bytes content = 3;</code> */ public Builder setContent(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } content_ = value; onChanged(); return this; } /** * <code>optional bytes content = 3;</code> */ public Builder clearContent() { content_ = getDefaultInstance().getContent(); onChanged(); return this; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:org.axesoft.jaxos.network.protobuff.BallotValue) } // @@protoc_insertion_point(class_scope:org.axesoft.jaxos.network.protobuff.BallotValue) private static final org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue(); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser<BallotValue> PARSER = new com.google.protobuf.AbstractParser<BallotValue>() { public BallotValue parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new BallotValue(input, extensionRegistry); } }; public static com.google.protobuf.Parser<BallotValue> parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser<BallotValue> getParserForType() { return PARSER; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface ChosenInfoOrBuilder extends // @@protoc_insertion_point(interface_extends:org.axesoft.jaxos.network.protobuff.ChosenInfo) com.google.protobuf.MessageOrBuilder { /** * <code>optional int64 instanceId = 1;</code> */ long getInstanceId(); /** * <code>optional int64 ballotId = 2;</code> */ long getBallotId(); /** * <code>optional int64 elapsedMillis = 3;</code> */ long getElapsedMillis(); } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.ChosenInfo} */ public static final class ChosenInfo extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:org.axesoft.jaxos.network.protobuff.ChosenInfo) ChosenInfoOrBuilder { // Use ChosenInfo.newBuilder() to construct. private ChosenInfo(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { super(builder); } private ChosenInfo() { instanceId_ = 0L; ballotId_ = 0L; elapsedMillis_ = 0L; } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private ChosenInfo( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 8: { instanceId_ = input.readInt64(); break; } case 16: { ballotId_ = input.readInt64(); break; } case 24: { elapsedMillis_ = input.readInt64(); break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_ChosenInfo_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_ChosenInfo_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder.class); } public static final int INSTANCEID_FIELD_NUMBER = 1; private long instanceId_; /** * <code>optional int64 instanceId = 1;</code> */ public long getInstanceId() { return instanceId_; } public static final int BALLOTID_FIELD_NUMBER = 2; private long ballotId_; /** * <code>optional int64 ballotId = 2;</code> */ public long getBallotId() { return ballotId_; } public static final int ELAPSEDMILLIS_FIELD_NUMBER = 3; private long elapsedMillis_; /** * <code>optional int64 elapsedMillis = 3;</code> */ public long getElapsedMillis() { return elapsedMillis_; } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (instanceId_ != 0L) { output.writeInt64(1, instanceId_); } if (ballotId_ != 0L) { output.writeInt64(2, ballotId_); } if (elapsedMillis_ != 0L) { output.writeInt64(3, elapsedMillis_); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (instanceId_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(1, instanceId_); } if (ballotId_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(2, ballotId_); } if (elapsedMillis_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(3, elapsedMillis_); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo)) { return super.equals(obj); } org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo other = (org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo) obj; boolean result = true; result = result && (getInstanceId() == other.getInstanceId()); result = result && (getBallotId() == other.getBallotId()); result = result && (getElapsedMillis() == other.getElapsedMillis()); return result; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + INSTANCEID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getInstanceId()); hash = (37 * hash) + BALLOTID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getBallotId()); hash = (37 * hash) + ELAPSEDMILLIS_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getElapsedMillis()); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.ChosenInfo} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements // @@protoc_insertion_point(builder_implements:org.axesoft.jaxos.network.protobuff.ChosenInfo) org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_ChosenInfo_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_ChosenInfo_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder.class); } // Construct using org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } public Builder clear() { super.clear(); instanceId_ = 0L; ballotId_ = 0L; elapsedMillis_ = 0L; return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_ChosenInfo_descriptor; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo getDefaultInstanceForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.getDefaultInstance(); } public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo build() { org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo buildPartial() { org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo result = new org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo(this); result.instanceId_ = instanceId_; result.ballotId_ = ballotId_; result.elapsedMillis_ = elapsedMillis_; onBuilt(); return result; } public Builder clone() { return (Builder) super.clone(); } public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.setField(field, value); } public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return (Builder) super.clearField(field); } public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return (Builder) super.clearOneof(oneof); } public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) { return (Builder) super.setRepeatedField(field, index, value); } public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo) { return mergeFrom((org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo other) { if (other == org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.getDefaultInstance()) return this; if (other.getInstanceId() != 0L) { setInstanceId(other.getInstanceId()); } if (other.getBallotId() != 0L) { setBallotId(other.getBallotId()); } if (other.getElapsedMillis() != 0L) { setElapsedMillis(other.getElapsedMillis()); } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private long instanceId_ ; /** * <code>optional int64 instanceId = 1;</code> */ public long getInstanceId() { return instanceId_; } /** * <code>optional int64 instanceId = 1;</code> */ public Builder setInstanceId(long value) { instanceId_ = value; onChanged(); return this; } /** * <code>optional int64 instanceId = 1;</code> */ public Builder clearInstanceId() { instanceId_ = 0L; onChanged(); return this; } private long ballotId_ ; /** * <code>optional int64 ballotId = 2;</code> */ public long getBallotId() { return ballotId_; } /** * <code>optional int64 ballotId = 2;</code> */ public Builder setBallotId(long value) { ballotId_ = value; onChanged(); return this; } /** * <code>optional int64 ballotId = 2;</code> */ public Builder clearBallotId() { ballotId_ = 0L; onChanged(); return this; } private long elapsedMillis_ ; /** * <code>optional int64 elapsedMillis = 3;</code> */ public long getElapsedMillis() { return elapsedMillis_; } /** * <code>optional int64 elapsedMillis = 3;</code> */ public Builder setElapsedMillis(long value) { elapsedMillis_ = value; onChanged(); return this; } /** * <code>optional int64 elapsedMillis = 3;</code> */ public Builder clearElapsedMillis() { elapsedMillis_ = 0L; onChanged(); return this; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:org.axesoft.jaxos.network.protobuff.ChosenInfo) } // @@protoc_insertion_point(class_scope:org.axesoft.jaxos.network.protobuff.ChosenInfo) private static final org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo(); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser<ChosenInfo> PARSER = new com.google.protobuf.AbstractParser<ChosenInfo>() { public ChosenInfo parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new ChosenInfo(input, extensionRegistry); } }; public static com.google.protobuf.Parser<ChosenInfo> parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser<ChosenInfo> getParserForType() { return PARSER; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface PrepareReqOrBuilder extends // @@protoc_insertion_point(interface_extends:org.axesoft.jaxos.network.protobuff.PrepareReq) com.google.protobuf.MessageOrBuilder { /** * <code>optional int32 squadId = 1;</code> */ int getSquadId(); /** * <code>optional int64 instanceId = 2;</code> */ long getInstanceId(); /** * <code>optional int32 round = 3;</code> */ int getRound(); /** * <code>optional int32 proposal = 4;</code> */ int getProposal(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 5;</code> */ boolean hasChosenInfo(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 5;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo getChosenInfo(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 5;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder getChosenInfoOrBuilder(); } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.PrepareReq} */ public static final class PrepareReq extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:org.axesoft.jaxos.network.protobuff.PrepareReq) PrepareReqOrBuilder { // Use PrepareReq.newBuilder() to construct. private PrepareReq(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { super(builder); } private PrepareReq() { squadId_ = 0; instanceId_ = 0L; round_ = 0; proposal_ = 0; } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private PrepareReq( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 8: { squadId_ = input.readInt32(); break; } case 16: { instanceId_ = input.readInt64(); break; } case 24: { round_ = input.readInt32(); break; } case 32: { proposal_ = input.readInt32(); break; } case 42: { org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder subBuilder = null; if (chosenInfo_ != null) { subBuilder = chosenInfo_.toBuilder(); } chosenInfo_ = input.readMessage(org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(chosenInfo_); chosenInfo_ = subBuilder.buildPartial(); } break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_PrepareReq_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_PrepareReq_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq.Builder.class); } public static final int SQUADID_FIELD_NUMBER = 1; private int squadId_; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } public static final int INSTANCEID_FIELD_NUMBER = 2; private long instanceId_; /** * <code>optional int64 instanceId = 2;</code> */ public long getInstanceId() { return instanceId_; } public static final int ROUND_FIELD_NUMBER = 3; private int round_; /** * <code>optional int32 round = 3;</code> */ public int getRound() { return round_; } public static final int PROPOSAL_FIELD_NUMBER = 4; private int proposal_; /** * <code>optional int32 proposal = 4;</code> */ public int getProposal() { return proposal_; } public static final int CHOSENINFO_FIELD_NUMBER = 5; private org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo chosenInfo_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 5;</code> */ public boolean hasChosenInfo() { return chosenInfo_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 5;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo getChosenInfo() { return chosenInfo_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.getDefaultInstance() : chosenInfo_; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 5;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder getChosenInfoOrBuilder() { return getChosenInfo(); } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (squadId_ != 0) { output.writeInt32(1, squadId_); } if (instanceId_ != 0L) { output.writeInt64(2, instanceId_); } if (round_ != 0) { output.writeInt32(3, round_); } if (proposal_ != 0) { output.writeInt32(4, proposal_); } if (chosenInfo_ != null) { output.writeMessage(5, getChosenInfo()); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (squadId_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(1, squadId_); } if (instanceId_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(2, instanceId_); } if (round_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(3, round_); } if (proposal_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(4, proposal_); } if (chosenInfo_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(5, getChosenInfo()); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq)) { return super.equals(obj); } org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq other = (org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq) obj; boolean result = true; result = result && (getSquadId() == other.getSquadId()); result = result && (getInstanceId() == other.getInstanceId()); result = result && (getRound() == other.getRound()); result = result && (getProposal() == other.getProposal()); result = result && (hasChosenInfo() == other.hasChosenInfo()); if (hasChosenInfo()) { result = result && getChosenInfo() .equals(other.getChosenInfo()); } return result; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + SQUADID_FIELD_NUMBER; hash = (53 * hash) + getSquadId(); hash = (37 * hash) + INSTANCEID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getInstanceId()); hash = (37 * hash) + ROUND_FIELD_NUMBER; hash = (53 * hash) + getRound(); hash = (37 * hash) + PROPOSAL_FIELD_NUMBER; hash = (53 * hash) + getProposal(); if (hasChosenInfo()) { hash = (37 * hash) + CHOSENINFO_FIELD_NUMBER; hash = (53 * hash) + getChosenInfo().hashCode(); } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.PrepareReq} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements // @@protoc_insertion_point(builder_implements:org.axesoft.jaxos.network.protobuff.PrepareReq) org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReqOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_PrepareReq_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_PrepareReq_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq.Builder.class); } // Construct using org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } public Builder clear() { super.clear(); squadId_ = 0; instanceId_ = 0L; round_ = 0; proposal_ = 0; if (chosenInfoBuilder_ == null) { chosenInfo_ = null; } else { chosenInfo_ = null; chosenInfoBuilder_ = null; } return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_PrepareReq_descriptor; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq getDefaultInstanceForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq.getDefaultInstance(); } public org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq build() { org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq buildPartial() { org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq result = new org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq(this); result.squadId_ = squadId_; result.instanceId_ = instanceId_; result.round_ = round_; result.proposal_ = proposal_; if (chosenInfoBuilder_ == null) { result.chosenInfo_ = chosenInfo_; } else { result.chosenInfo_ = chosenInfoBuilder_.build(); } onBuilt(); return result; } public Builder clone() { return (Builder) super.clone(); } public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.setField(field, value); } public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return (Builder) super.clearField(field); } public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return (Builder) super.clearOneof(oneof); } public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) { return (Builder) super.setRepeatedField(field, index, value); } public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq) { return mergeFrom((org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq other) { if (other == org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq.getDefaultInstance()) return this; if (other.getSquadId() != 0) { setSquadId(other.getSquadId()); } if (other.getInstanceId() != 0L) { setInstanceId(other.getInstanceId()); } if (other.getRound() != 0) { setRound(other.getRound()); } if (other.getProposal() != 0) { setProposal(other.getProposal()); } if (other.hasChosenInfo()) { mergeChosenInfo(other.getChosenInfo()); } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int squadId_ ; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } /** * <code>optional int32 squadId = 1;</code> */ public Builder setSquadId(int value) { squadId_ = value; onChanged(); return this; } /** * <code>optional int32 squadId = 1;</code> */ public Builder clearSquadId() { squadId_ = 0; onChanged(); return this; } private long instanceId_ ; /** * <code>optional int64 instanceId = 2;</code> */ public long getInstanceId() { return instanceId_; } /** * <code>optional int64 instanceId = 2;</code> */ public Builder setInstanceId(long value) { instanceId_ = value; onChanged(); return this; } /** * <code>optional int64 instanceId = 2;</code> */ public Builder clearInstanceId() { instanceId_ = 0L; onChanged(); return this; } private int round_ ; /** * <code>optional int32 round = 3;</code> */ public int getRound() { return round_; } /** * <code>optional int32 round = 3;</code> */ public Builder setRound(int value) { round_ = value; onChanged(); return this; } /** * <code>optional int32 round = 3;</code> */ public Builder clearRound() { round_ = 0; onChanged(); return this; } private int proposal_ ; /** * <code>optional int32 proposal = 4;</code> */ public int getProposal() { return proposal_; } /** * <code>optional int32 proposal = 4;</code> */ public Builder setProposal(int value) { proposal_ = value; onChanged(); return this; } /** * <code>optional int32 proposal = 4;</code> */ public Builder clearProposal() { proposal_ = 0; onChanged(); return this; } private org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo chosenInfo_ = null; private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder> chosenInfoBuilder_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 5;</code> */ public boolean hasChosenInfo() { return chosenInfoBuilder_ != null || chosenInfo_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 5;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo getChosenInfo() { if (chosenInfoBuilder_ == null) { return chosenInfo_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.getDefaultInstance() : chosenInfo_; } else { return chosenInfoBuilder_.getMessage(); } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 5;</code> */ public Builder setChosenInfo(org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo value) { if (chosenInfoBuilder_ == null) { if (value == null) { throw new NullPointerException(); } chosenInfo_ = value; onChanged(); } else { chosenInfoBuilder_.setMessage(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 5;</code> */ public Builder setChosenInfo( org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder builderForValue) { if (chosenInfoBuilder_ == null) { chosenInfo_ = builderForValue.build(); onChanged(); } else { chosenInfoBuilder_.setMessage(builderForValue.build()); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 5;</code> */ public Builder mergeChosenInfo(org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo value) { if (chosenInfoBuilder_ == null) { if (chosenInfo_ != null) { chosenInfo_ = org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.newBuilder(chosenInfo_).mergeFrom(value).buildPartial(); } else { chosenInfo_ = value; } onChanged(); } else { chosenInfoBuilder_.mergeFrom(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 5;</code> */ public Builder clearChosenInfo() { if (chosenInfoBuilder_ == null) { chosenInfo_ = null; onChanged(); } else { chosenInfo_ = null; chosenInfoBuilder_ = null; } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 5;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder getChosenInfoBuilder() { onChanged(); return getChosenInfoFieldBuilder().getBuilder(); } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 5;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder getChosenInfoOrBuilder() { if (chosenInfoBuilder_ != null) { return chosenInfoBuilder_.getMessageOrBuilder(); } else { return chosenInfo_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.getDefaultInstance() : chosenInfo_; } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 5;</code> */ private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder> getChosenInfoFieldBuilder() { if (chosenInfoBuilder_ == null) { chosenInfoBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder>( getChosenInfo(), getParentForChildren(), isClean()); chosenInfo_ = null; } return chosenInfoBuilder_; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:org.axesoft.jaxos.network.protobuff.PrepareReq) } // @@protoc_insertion_point(class_scope:org.axesoft.jaxos.network.protobuff.PrepareReq) private static final org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq(); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser<PrepareReq> PARSER = new com.google.protobuf.AbstractParser<PrepareReq>() { public PrepareReq parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new PrepareReq(input, extensionRegistry); } }; public static com.google.protobuf.Parser<PrepareReq> parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser<PrepareReq> getParserForType() { return PARSER; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareReq getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface PrepareResOrBuilder extends // @@protoc_insertion_point(interface_extends:org.axesoft.jaxos.network.protobuff.PrepareRes) com.google.protobuf.MessageOrBuilder { /** * <code>optional int32 squadId = 1;</code> */ int getSquadId(); /** * <code>optional int64 instanceId = 2;</code> */ long getInstanceId(); /** * <code>optional int32 round = 3;</code> */ int getRound(); /** * <code>optional int32 result = 4;</code> */ int getResult(); /** * <code>optional int32 maxProposal = 5;</code> */ int getMaxProposal(); /** * <code>optional int32 acceptedProposal = 6;</code> */ int getAcceptedProposal(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue acceptedValue = 7;</code> */ boolean hasAcceptedValue(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue acceptedValue = 7;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue getAcceptedValue(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue acceptedValue = 7;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder getAcceptedValueOrBuilder(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ boolean hasChosenInfo(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo getChosenInfo(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder getChosenInfoOrBuilder(); } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.PrepareRes} */ public static final class PrepareRes extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:org.axesoft.jaxos.network.protobuff.PrepareRes) PrepareResOrBuilder { // Use PrepareRes.newBuilder() to construct. private PrepareRes(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { super(builder); } private PrepareRes() { squadId_ = 0; instanceId_ = 0L; round_ = 0; result_ = 0; maxProposal_ = 0; acceptedProposal_ = 0; } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private PrepareRes( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 8: { squadId_ = input.readInt32(); break; } case 16: { instanceId_ = input.readInt64(); break; } case 24: { round_ = input.readInt32(); break; } case 32: { result_ = input.readInt32(); break; } case 40: { maxProposal_ = input.readInt32(); break; } case 48: { acceptedProposal_ = input.readInt32(); break; } case 58: { org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder subBuilder = null; if (acceptedValue_ != null) { subBuilder = acceptedValue_.toBuilder(); } acceptedValue_ = input.readMessage(org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(acceptedValue_); acceptedValue_ = subBuilder.buildPartial(); } break; } case 66: { org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder subBuilder = null; if (chosenInfo_ != null) { subBuilder = chosenInfo_.toBuilder(); } chosenInfo_ = input.readMessage(org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(chosenInfo_); chosenInfo_ = subBuilder.buildPartial(); } break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_PrepareRes_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_PrepareRes_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes.Builder.class); } public static final int SQUADID_FIELD_NUMBER = 1; private int squadId_; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } public static final int INSTANCEID_FIELD_NUMBER = 2; private long instanceId_; /** * <code>optional int64 instanceId = 2;</code> */ public long getInstanceId() { return instanceId_; } public static final int ROUND_FIELD_NUMBER = 3; private int round_; /** * <code>optional int32 round = 3;</code> */ public int getRound() { return round_; } public static final int RESULT_FIELD_NUMBER = 4; private int result_; /** * <code>optional int32 result = 4;</code> */ public int getResult() { return result_; } public static final int MAXPROPOSAL_FIELD_NUMBER = 5; private int maxProposal_; /** * <code>optional int32 maxProposal = 5;</code> */ public int getMaxProposal() { return maxProposal_; } public static final int ACCEPTEDPROPOSAL_FIELD_NUMBER = 6; private int acceptedProposal_; /** * <code>optional int32 acceptedProposal = 6;</code> */ public int getAcceptedProposal() { return acceptedProposal_; } public static final int ACCEPTEDVALUE_FIELD_NUMBER = 7; private org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue acceptedValue_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue acceptedValue = 7;</code> */ public boolean hasAcceptedValue() { return acceptedValue_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue acceptedValue = 7;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue getAcceptedValue() { return acceptedValue_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.getDefaultInstance() : acceptedValue_; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue acceptedValue = 7;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder getAcceptedValueOrBuilder() { return getAcceptedValue(); } public static final int CHOSENINFO_FIELD_NUMBER = 8; private org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo chosenInfo_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public boolean hasChosenInfo() { return chosenInfo_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo getChosenInfo() { return chosenInfo_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.getDefaultInstance() : chosenInfo_; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder getChosenInfoOrBuilder() { return getChosenInfo(); } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (squadId_ != 0) { output.writeInt32(1, squadId_); } if (instanceId_ != 0L) { output.writeInt64(2, instanceId_); } if (round_ != 0) { output.writeInt32(3, round_); } if (result_ != 0) { output.writeInt32(4, result_); } if (maxProposal_ != 0) { output.writeInt32(5, maxProposal_); } if (acceptedProposal_ != 0) { output.writeInt32(6, acceptedProposal_); } if (acceptedValue_ != null) { output.writeMessage(7, getAcceptedValue()); } if (chosenInfo_ != null) { output.writeMessage(8, getChosenInfo()); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (squadId_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(1, squadId_); } if (instanceId_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(2, instanceId_); } if (round_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(3, round_); } if (result_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(4, result_); } if (maxProposal_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(5, maxProposal_); } if (acceptedProposal_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(6, acceptedProposal_); } if (acceptedValue_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(7, getAcceptedValue()); } if (chosenInfo_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(8, getChosenInfo()); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes)) { return super.equals(obj); } org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes other = (org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes) obj; boolean result = true; result = result && (getSquadId() == other.getSquadId()); result = result && (getInstanceId() == other.getInstanceId()); result = result && (getRound() == other.getRound()); result = result && (getResult() == other.getResult()); result = result && (getMaxProposal() == other.getMaxProposal()); result = result && (getAcceptedProposal() == other.getAcceptedProposal()); result = result && (hasAcceptedValue() == other.hasAcceptedValue()); if (hasAcceptedValue()) { result = result && getAcceptedValue() .equals(other.getAcceptedValue()); } result = result && (hasChosenInfo() == other.hasChosenInfo()); if (hasChosenInfo()) { result = result && getChosenInfo() .equals(other.getChosenInfo()); } return result; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + SQUADID_FIELD_NUMBER; hash = (53 * hash) + getSquadId(); hash = (37 * hash) + INSTANCEID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getInstanceId()); hash = (37 * hash) + ROUND_FIELD_NUMBER; hash = (53 * hash) + getRound(); hash = (37 * hash) + RESULT_FIELD_NUMBER; hash = (53 * hash) + getResult(); hash = (37 * hash) + MAXPROPOSAL_FIELD_NUMBER; hash = (53 * hash) + getMaxProposal(); hash = (37 * hash) + ACCEPTEDPROPOSAL_FIELD_NUMBER; hash = (53 * hash) + getAcceptedProposal(); if (hasAcceptedValue()) { hash = (37 * hash) + ACCEPTEDVALUE_FIELD_NUMBER; hash = (53 * hash) + getAcceptedValue().hashCode(); } if (hasChosenInfo()) { hash = (37 * hash) + CHOSENINFO_FIELD_NUMBER; hash = (53 * hash) + getChosenInfo().hashCode(); } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.PrepareRes} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements // @@protoc_insertion_point(builder_implements:org.axesoft.jaxos.network.protobuff.PrepareRes) org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareResOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_PrepareRes_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_PrepareRes_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes.Builder.class); } // Construct using org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } public Builder clear() { super.clear(); squadId_ = 0; instanceId_ = 0L; round_ = 0; result_ = 0; maxProposal_ = 0; acceptedProposal_ = 0; if (acceptedValueBuilder_ == null) { acceptedValue_ = null; } else { acceptedValue_ = null; acceptedValueBuilder_ = null; } if (chosenInfoBuilder_ == null) { chosenInfo_ = null; } else { chosenInfo_ = null; chosenInfoBuilder_ = null; } return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_PrepareRes_descriptor; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes getDefaultInstanceForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes.getDefaultInstance(); } public org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes build() { org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes buildPartial() { org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes result = new org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes(this); result.squadId_ = squadId_; result.instanceId_ = instanceId_; result.round_ = round_; result.result_ = result_; result.maxProposal_ = maxProposal_; result.acceptedProposal_ = acceptedProposal_; if (acceptedValueBuilder_ == null) { result.acceptedValue_ = acceptedValue_; } else { result.acceptedValue_ = acceptedValueBuilder_.build(); } if (chosenInfoBuilder_ == null) { result.chosenInfo_ = chosenInfo_; } else { result.chosenInfo_ = chosenInfoBuilder_.build(); } onBuilt(); return result; } public Builder clone() { return (Builder) super.clone(); } public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.setField(field, value); } public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return (Builder) super.clearField(field); } public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return (Builder) super.clearOneof(oneof); } public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) { return (Builder) super.setRepeatedField(field, index, value); } public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes) { return mergeFrom((org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes other) { if (other == org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes.getDefaultInstance()) return this; if (other.getSquadId() != 0) { setSquadId(other.getSquadId()); } if (other.getInstanceId() != 0L) { setInstanceId(other.getInstanceId()); } if (other.getRound() != 0) { setRound(other.getRound()); } if (other.getResult() != 0) { setResult(other.getResult()); } if (other.getMaxProposal() != 0) { setMaxProposal(other.getMaxProposal()); } if (other.getAcceptedProposal() != 0) { setAcceptedProposal(other.getAcceptedProposal()); } if (other.hasAcceptedValue()) { mergeAcceptedValue(other.getAcceptedValue()); } if (other.hasChosenInfo()) { mergeChosenInfo(other.getChosenInfo()); } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int squadId_ ; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } /** * <code>optional int32 squadId = 1;</code> */ public Builder setSquadId(int value) { squadId_ = value; onChanged(); return this; } /** * <code>optional int32 squadId = 1;</code> */ public Builder clearSquadId() { squadId_ = 0; onChanged(); return this; } private long instanceId_ ; /** * <code>optional int64 instanceId = 2;</code> */ public long getInstanceId() { return instanceId_; } /** * <code>optional int64 instanceId = 2;</code> */ public Builder setInstanceId(long value) { instanceId_ = value; onChanged(); return this; } /** * <code>optional int64 instanceId = 2;</code> */ public Builder clearInstanceId() { instanceId_ = 0L; onChanged(); return this; } private int round_ ; /** * <code>optional int32 round = 3;</code> */ public int getRound() { return round_; } /** * <code>optional int32 round = 3;</code> */ public Builder setRound(int value) { round_ = value; onChanged(); return this; } /** * <code>optional int32 round = 3;</code> */ public Builder clearRound() { round_ = 0; onChanged(); return this; } private int result_ ; /** * <code>optional int32 result = 4;</code> */ public int getResult() { return result_; } /** * <code>optional int32 result = 4;</code> */ public Builder setResult(int value) { result_ = value; onChanged(); return this; } /** * <code>optional int32 result = 4;</code> */ public Builder clearResult() { result_ = 0; onChanged(); return this; } private int maxProposal_ ; /** * <code>optional int32 maxProposal = 5;</code> */ public int getMaxProposal() { return maxProposal_; } /** * <code>optional int32 maxProposal = 5;</code> */ public Builder setMaxProposal(int value) { maxProposal_ = value; onChanged(); return this; } /** * <code>optional int32 maxProposal = 5;</code> */ public Builder clearMaxProposal() { maxProposal_ = 0; onChanged(); return this; } private int acceptedProposal_ ; /** * <code>optional int32 acceptedProposal = 6;</code> */ public int getAcceptedProposal() { return acceptedProposal_; } /** * <code>optional int32 acceptedProposal = 6;</code> */ public Builder setAcceptedProposal(int value) { acceptedProposal_ = value; onChanged(); return this; } /** * <code>optional int32 acceptedProposal = 6;</code> */ public Builder clearAcceptedProposal() { acceptedProposal_ = 0; onChanged(); return this; } private org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue acceptedValue_ = null; private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder> acceptedValueBuilder_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue acceptedValue = 7;</code> */ public boolean hasAcceptedValue() { return acceptedValueBuilder_ != null || acceptedValue_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue acceptedValue = 7;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue getAcceptedValue() { if (acceptedValueBuilder_ == null) { return acceptedValue_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.getDefaultInstance() : acceptedValue_; } else { return acceptedValueBuilder_.getMessage(); } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue acceptedValue = 7;</code> */ public Builder setAcceptedValue(org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue value) { if (acceptedValueBuilder_ == null) { if (value == null) { throw new NullPointerException(); } acceptedValue_ = value; onChanged(); } else { acceptedValueBuilder_.setMessage(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue acceptedValue = 7;</code> */ public Builder setAcceptedValue( org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder builderForValue) { if (acceptedValueBuilder_ == null) { acceptedValue_ = builderForValue.build(); onChanged(); } else { acceptedValueBuilder_.setMessage(builderForValue.build()); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue acceptedValue = 7;</code> */ public Builder mergeAcceptedValue(org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue value) { if (acceptedValueBuilder_ == null) { if (acceptedValue_ != null) { acceptedValue_ = org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.newBuilder(acceptedValue_).mergeFrom(value).buildPartial(); } else { acceptedValue_ = value; } onChanged(); } else { acceptedValueBuilder_.mergeFrom(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue acceptedValue = 7;</code> */ public Builder clearAcceptedValue() { if (acceptedValueBuilder_ == null) { acceptedValue_ = null; onChanged(); } else { acceptedValue_ = null; acceptedValueBuilder_ = null; } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue acceptedValue = 7;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder getAcceptedValueBuilder() { onChanged(); return getAcceptedValueFieldBuilder().getBuilder(); } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue acceptedValue = 7;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder getAcceptedValueOrBuilder() { if (acceptedValueBuilder_ != null) { return acceptedValueBuilder_.getMessageOrBuilder(); } else { return acceptedValue_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.getDefaultInstance() : acceptedValue_; } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue acceptedValue = 7;</code> */ private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder> getAcceptedValueFieldBuilder() { if (acceptedValueBuilder_ == null) { acceptedValueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder>( getAcceptedValue(), getParentForChildren(), isClean()); acceptedValue_ = null; } return acceptedValueBuilder_; } private org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo chosenInfo_ = null; private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder> chosenInfoBuilder_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public boolean hasChosenInfo() { return chosenInfoBuilder_ != null || chosenInfo_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo getChosenInfo() { if (chosenInfoBuilder_ == null) { return chosenInfo_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.getDefaultInstance() : chosenInfo_; } else { return chosenInfoBuilder_.getMessage(); } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public Builder setChosenInfo(org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo value) { if (chosenInfoBuilder_ == null) { if (value == null) { throw new NullPointerException(); } chosenInfo_ = value; onChanged(); } else { chosenInfoBuilder_.setMessage(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public Builder setChosenInfo( org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder builderForValue) { if (chosenInfoBuilder_ == null) { chosenInfo_ = builderForValue.build(); onChanged(); } else { chosenInfoBuilder_.setMessage(builderForValue.build()); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public Builder mergeChosenInfo(org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo value) { if (chosenInfoBuilder_ == null) { if (chosenInfo_ != null) { chosenInfo_ = org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.newBuilder(chosenInfo_).mergeFrom(value).buildPartial(); } else { chosenInfo_ = value; } onChanged(); } else { chosenInfoBuilder_.mergeFrom(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public Builder clearChosenInfo() { if (chosenInfoBuilder_ == null) { chosenInfo_ = null; onChanged(); } else { chosenInfo_ = null; chosenInfoBuilder_ = null; } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder getChosenInfoBuilder() { onChanged(); return getChosenInfoFieldBuilder().getBuilder(); } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder getChosenInfoOrBuilder() { if (chosenInfoBuilder_ != null) { return chosenInfoBuilder_.getMessageOrBuilder(); } else { return chosenInfo_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.getDefaultInstance() : chosenInfo_; } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder> getChosenInfoFieldBuilder() { if (chosenInfoBuilder_ == null) { chosenInfoBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder>( getChosenInfo(), getParentForChildren(), isClean()); chosenInfo_ = null; } return chosenInfoBuilder_; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:org.axesoft.jaxos.network.protobuff.PrepareRes) } // @@protoc_insertion_point(class_scope:org.axesoft.jaxos.network.protobuff.PrepareRes) private static final org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes(); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser<PrepareRes> PARSER = new com.google.protobuf.AbstractParser<PrepareRes>() { public PrepareRes parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new PrepareRes(input, extensionRegistry); } }; public static com.google.protobuf.Parser<PrepareRes> parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser<PrepareRes> getParserForType() { return PARSER; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.PrepareRes getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface AcceptReqOrBuilder extends // @@protoc_insertion_point(interface_extends:org.axesoft.jaxos.network.protobuff.AcceptReq) com.google.protobuf.MessageOrBuilder { /** * <code>optional int32 squadId = 1;</code> */ int getSquadId(); /** * <code>optional int64 instanceId = 2;</code> */ long getInstanceId(); /** * <code>optional int32 round = 3;</code> */ int getRound(); /** * <code>optional int32 proposal = 4;</code> */ int getProposal(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 5;</code> */ boolean hasValue(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 5;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue getValue(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 5;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder getValueOrBuilder(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 6;</code> */ boolean hasChosenInfo(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 6;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo getChosenInfo(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 6;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder getChosenInfoOrBuilder(); } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.AcceptReq} */ public static final class AcceptReq extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:org.axesoft.jaxos.network.protobuff.AcceptReq) AcceptReqOrBuilder { // Use AcceptReq.newBuilder() to construct. private AcceptReq(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { super(builder); } private AcceptReq() { squadId_ = 0; instanceId_ = 0L; round_ = 0; proposal_ = 0; } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private AcceptReq( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 8: { squadId_ = input.readInt32(); break; } case 16: { instanceId_ = input.readInt64(); break; } case 24: { round_ = input.readInt32(); break; } case 32: { proposal_ = input.readInt32(); break; } case 42: { org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder subBuilder = null; if (value_ != null) { subBuilder = value_.toBuilder(); } value_ = input.readMessage(org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(value_); value_ = subBuilder.buildPartial(); } break; } case 50: { org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder subBuilder = null; if (chosenInfo_ != null) { subBuilder = chosenInfo_.toBuilder(); } chosenInfo_ = input.readMessage(org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(chosenInfo_); chosenInfo_ = subBuilder.buildPartial(); } break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_AcceptReq_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_AcceptReq_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq.Builder.class); } public static final int SQUADID_FIELD_NUMBER = 1; private int squadId_; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } public static final int INSTANCEID_FIELD_NUMBER = 2; private long instanceId_; /** * <code>optional int64 instanceId = 2;</code> */ public long getInstanceId() { return instanceId_; } public static final int ROUND_FIELD_NUMBER = 3; private int round_; /** * <code>optional int32 round = 3;</code> */ public int getRound() { return round_; } public static final int PROPOSAL_FIELD_NUMBER = 4; private int proposal_; /** * <code>optional int32 proposal = 4;</code> */ public int getProposal() { return proposal_; } public static final int VALUE_FIELD_NUMBER = 5; private org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue value_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 5;</code> */ public boolean hasValue() { return value_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 5;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue getValue() { return value_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.getDefaultInstance() : value_; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 5;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder getValueOrBuilder() { return getValue(); } public static final int CHOSENINFO_FIELD_NUMBER = 6; private org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo chosenInfo_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 6;</code> */ public boolean hasChosenInfo() { return chosenInfo_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 6;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo getChosenInfo() { return chosenInfo_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.getDefaultInstance() : chosenInfo_; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 6;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder getChosenInfoOrBuilder() { return getChosenInfo(); } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (squadId_ != 0) { output.writeInt32(1, squadId_); } if (instanceId_ != 0L) { output.writeInt64(2, instanceId_); } if (round_ != 0) { output.writeInt32(3, round_); } if (proposal_ != 0) { output.writeInt32(4, proposal_); } if (value_ != null) { output.writeMessage(5, getValue()); } if (chosenInfo_ != null) { output.writeMessage(6, getChosenInfo()); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (squadId_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(1, squadId_); } if (instanceId_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(2, instanceId_); } if (round_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(3, round_); } if (proposal_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(4, proposal_); } if (value_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(5, getValue()); } if (chosenInfo_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(6, getChosenInfo()); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq)) { return super.equals(obj); } org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq other = (org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq) obj; boolean result = true; result = result && (getSquadId() == other.getSquadId()); result = result && (getInstanceId() == other.getInstanceId()); result = result && (getRound() == other.getRound()); result = result && (getProposal() == other.getProposal()); result = result && (hasValue() == other.hasValue()); if (hasValue()) { result = result && getValue() .equals(other.getValue()); } result = result && (hasChosenInfo() == other.hasChosenInfo()); if (hasChosenInfo()) { result = result && getChosenInfo() .equals(other.getChosenInfo()); } return result; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + SQUADID_FIELD_NUMBER; hash = (53 * hash) + getSquadId(); hash = (37 * hash) + INSTANCEID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getInstanceId()); hash = (37 * hash) + ROUND_FIELD_NUMBER; hash = (53 * hash) + getRound(); hash = (37 * hash) + PROPOSAL_FIELD_NUMBER; hash = (53 * hash) + getProposal(); if (hasValue()) { hash = (37 * hash) + VALUE_FIELD_NUMBER; hash = (53 * hash) + getValue().hashCode(); } if (hasChosenInfo()) { hash = (37 * hash) + CHOSENINFO_FIELD_NUMBER; hash = (53 * hash) + getChosenInfo().hashCode(); } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.AcceptReq} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements // @@protoc_insertion_point(builder_implements:org.axesoft.jaxos.network.protobuff.AcceptReq) org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReqOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_AcceptReq_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_AcceptReq_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq.Builder.class); } // Construct using org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } public Builder clear() { super.clear(); squadId_ = 0; instanceId_ = 0L; round_ = 0; proposal_ = 0; if (valueBuilder_ == null) { value_ = null; } else { value_ = null; valueBuilder_ = null; } if (chosenInfoBuilder_ == null) { chosenInfo_ = null; } else { chosenInfo_ = null; chosenInfoBuilder_ = null; } return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_AcceptReq_descriptor; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq getDefaultInstanceForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq.getDefaultInstance(); } public org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq build() { org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq buildPartial() { org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq result = new org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq(this); result.squadId_ = squadId_; result.instanceId_ = instanceId_; result.round_ = round_; result.proposal_ = proposal_; if (valueBuilder_ == null) { result.value_ = value_; } else { result.value_ = valueBuilder_.build(); } if (chosenInfoBuilder_ == null) { result.chosenInfo_ = chosenInfo_; } else { result.chosenInfo_ = chosenInfoBuilder_.build(); } onBuilt(); return result; } public Builder clone() { return (Builder) super.clone(); } public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.setField(field, value); } public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return (Builder) super.clearField(field); } public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return (Builder) super.clearOneof(oneof); } public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) { return (Builder) super.setRepeatedField(field, index, value); } public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq) { return mergeFrom((org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq other) { if (other == org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq.getDefaultInstance()) return this; if (other.getSquadId() != 0) { setSquadId(other.getSquadId()); } if (other.getInstanceId() != 0L) { setInstanceId(other.getInstanceId()); } if (other.getRound() != 0) { setRound(other.getRound()); } if (other.getProposal() != 0) { setProposal(other.getProposal()); } if (other.hasValue()) { mergeValue(other.getValue()); } if (other.hasChosenInfo()) { mergeChosenInfo(other.getChosenInfo()); } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int squadId_ ; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } /** * <code>optional int32 squadId = 1;</code> */ public Builder setSquadId(int value) { squadId_ = value; onChanged(); return this; } /** * <code>optional int32 squadId = 1;</code> */ public Builder clearSquadId() { squadId_ = 0; onChanged(); return this; } private long instanceId_ ; /** * <code>optional int64 instanceId = 2;</code> */ public long getInstanceId() { return instanceId_; } /** * <code>optional int64 instanceId = 2;</code> */ public Builder setInstanceId(long value) { instanceId_ = value; onChanged(); return this; } /** * <code>optional int64 instanceId = 2;</code> */ public Builder clearInstanceId() { instanceId_ = 0L; onChanged(); return this; } private int round_ ; /** * <code>optional int32 round = 3;</code> */ public int getRound() { return round_; } /** * <code>optional int32 round = 3;</code> */ public Builder setRound(int value) { round_ = value; onChanged(); return this; } /** * <code>optional int32 round = 3;</code> */ public Builder clearRound() { round_ = 0; onChanged(); return this; } private int proposal_ ; /** * <code>optional int32 proposal = 4;</code> */ public int getProposal() { return proposal_; } /** * <code>optional int32 proposal = 4;</code> */ public Builder setProposal(int value) { proposal_ = value; onChanged(); return this; } /** * <code>optional int32 proposal = 4;</code> */ public Builder clearProposal() { proposal_ = 0; onChanged(); return this; } private org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue value_ = null; private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder> valueBuilder_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 5;</code> */ public boolean hasValue() { return valueBuilder_ != null || value_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 5;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue getValue() { if (valueBuilder_ == null) { return value_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.getDefaultInstance() : value_; } else { return valueBuilder_.getMessage(); } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 5;</code> */ public Builder setValue(org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue value) { if (valueBuilder_ == null) { if (value == null) { throw new NullPointerException(); } value_ = value; onChanged(); } else { valueBuilder_.setMessage(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 5;</code> */ public Builder setValue( org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder builderForValue) { if (valueBuilder_ == null) { value_ = builderForValue.build(); onChanged(); } else { valueBuilder_.setMessage(builderForValue.build()); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 5;</code> */ public Builder mergeValue(org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue value) { if (valueBuilder_ == null) { if (value_ != null) { value_ = org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.newBuilder(value_).mergeFrom(value).buildPartial(); } else { value_ = value; } onChanged(); } else { valueBuilder_.mergeFrom(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 5;</code> */ public Builder clearValue() { if (valueBuilder_ == null) { value_ = null; onChanged(); } else { value_ = null; valueBuilder_ = null; } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 5;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder getValueBuilder() { onChanged(); return getValueFieldBuilder().getBuilder(); } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 5;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder getValueOrBuilder() { if (valueBuilder_ != null) { return valueBuilder_.getMessageOrBuilder(); } else { return value_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.getDefaultInstance() : value_; } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 5;</code> */ private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder> getValueFieldBuilder() { if (valueBuilder_ == null) { valueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder>( getValue(), getParentForChildren(), isClean()); value_ = null; } return valueBuilder_; } private org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo chosenInfo_ = null; private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder> chosenInfoBuilder_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 6;</code> */ public boolean hasChosenInfo() { return chosenInfoBuilder_ != null || chosenInfo_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 6;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo getChosenInfo() { if (chosenInfoBuilder_ == null) { return chosenInfo_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.getDefaultInstance() : chosenInfo_; } else { return chosenInfoBuilder_.getMessage(); } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 6;</code> */ public Builder setChosenInfo(org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo value) { if (chosenInfoBuilder_ == null) { if (value == null) { throw new NullPointerException(); } chosenInfo_ = value; onChanged(); } else { chosenInfoBuilder_.setMessage(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 6;</code> */ public Builder setChosenInfo( org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder builderForValue) { if (chosenInfoBuilder_ == null) { chosenInfo_ = builderForValue.build(); onChanged(); } else { chosenInfoBuilder_.setMessage(builderForValue.build()); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 6;</code> */ public Builder mergeChosenInfo(org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo value) { if (chosenInfoBuilder_ == null) { if (chosenInfo_ != null) { chosenInfo_ = org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.newBuilder(chosenInfo_).mergeFrom(value).buildPartial(); } else { chosenInfo_ = value; } onChanged(); } else { chosenInfoBuilder_.mergeFrom(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 6;</code> */ public Builder clearChosenInfo() { if (chosenInfoBuilder_ == null) { chosenInfo_ = null; onChanged(); } else { chosenInfo_ = null; chosenInfoBuilder_ = null; } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 6;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder getChosenInfoBuilder() { onChanged(); return getChosenInfoFieldBuilder().getBuilder(); } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 6;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder getChosenInfoOrBuilder() { if (chosenInfoBuilder_ != null) { return chosenInfoBuilder_.getMessageOrBuilder(); } else { return chosenInfo_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.getDefaultInstance() : chosenInfo_; } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 6;</code> */ private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder> getChosenInfoFieldBuilder() { if (chosenInfoBuilder_ == null) { chosenInfoBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder>( getChosenInfo(), getParentForChildren(), isClean()); chosenInfo_ = null; } return chosenInfoBuilder_; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:org.axesoft.jaxos.network.protobuff.AcceptReq) } // @@protoc_insertion_point(class_scope:org.axesoft.jaxos.network.protobuff.AcceptReq) private static final org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq(); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser<AcceptReq> PARSER = new com.google.protobuf.AbstractParser<AcceptReq>() { public AcceptReq parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new AcceptReq(input, extensionRegistry); } }; public static com.google.protobuf.Parser<AcceptReq> parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser<AcceptReq> getParserForType() { return PARSER; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptReq getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface AcceptResOrBuilder extends // @@protoc_insertion_point(interface_extends:org.axesoft.jaxos.network.protobuff.AcceptRes) com.google.protobuf.MessageOrBuilder { /** * <code>optional int32 squadId = 1;</code> */ int getSquadId(); /** * <code>optional int64 instanceId = 2;</code> */ long getInstanceId(); /** * <code>optional int32 round = 3;</code> */ int getRound(); /** * <code>optional int32 result = 4;</code> */ int getResult(); /** * <code>optional int32 maxProposal = 5;</code> */ int getMaxProposal(); /** * <code>optional int64 acceptedBallotId = 6;</code> */ long getAcceptedBallotId(); /** * <code>optional int64 chosenInstanceId = 7;</code> */ long getChosenInstanceId(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ boolean hasChosenInfo(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo getChosenInfo(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder getChosenInfoOrBuilder(); } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.AcceptRes} */ public static final class AcceptRes extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:org.axesoft.jaxos.network.protobuff.AcceptRes) AcceptResOrBuilder { // Use AcceptRes.newBuilder() to construct. private AcceptRes(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { super(builder); } private AcceptRes() { squadId_ = 0; instanceId_ = 0L; round_ = 0; result_ = 0; maxProposal_ = 0; acceptedBallotId_ = 0L; chosenInstanceId_ = 0L; } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private AcceptRes( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 8: { squadId_ = input.readInt32(); break; } case 16: { instanceId_ = input.readInt64(); break; } case 24: { round_ = input.readInt32(); break; } case 32: { result_ = input.readInt32(); break; } case 40: { maxProposal_ = input.readInt32(); break; } case 48: { acceptedBallotId_ = input.readInt64(); break; } case 56: { chosenInstanceId_ = input.readInt64(); break; } case 66: { org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder subBuilder = null; if (chosenInfo_ != null) { subBuilder = chosenInfo_.toBuilder(); } chosenInfo_ = input.readMessage(org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(chosenInfo_); chosenInfo_ = subBuilder.buildPartial(); } break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_AcceptRes_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_AcceptRes_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes.Builder.class); } public static final int SQUADID_FIELD_NUMBER = 1; private int squadId_; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } public static final int INSTANCEID_FIELD_NUMBER = 2; private long instanceId_; /** * <code>optional int64 instanceId = 2;</code> */ public long getInstanceId() { return instanceId_; } public static final int ROUND_FIELD_NUMBER = 3; private int round_; /** * <code>optional int32 round = 3;</code> */ public int getRound() { return round_; } public static final int RESULT_FIELD_NUMBER = 4; private int result_; /** * <code>optional int32 result = 4;</code> */ public int getResult() { return result_; } public static final int MAXPROPOSAL_FIELD_NUMBER = 5; private int maxProposal_; /** * <code>optional int32 maxProposal = 5;</code> */ public int getMaxProposal() { return maxProposal_; } public static final int ACCEPTEDBALLOTID_FIELD_NUMBER = 6; private long acceptedBallotId_; /** * <code>optional int64 acceptedBallotId = 6;</code> */ public long getAcceptedBallotId() { return acceptedBallotId_; } public static final int CHOSENINSTANCEID_FIELD_NUMBER = 7; private long chosenInstanceId_; /** * <code>optional int64 chosenInstanceId = 7;</code> */ public long getChosenInstanceId() { return chosenInstanceId_; } public static final int CHOSENINFO_FIELD_NUMBER = 8; private org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo chosenInfo_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public boolean hasChosenInfo() { return chosenInfo_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo getChosenInfo() { return chosenInfo_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.getDefaultInstance() : chosenInfo_; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder getChosenInfoOrBuilder() { return getChosenInfo(); } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (squadId_ != 0) { output.writeInt32(1, squadId_); } if (instanceId_ != 0L) { output.writeInt64(2, instanceId_); } if (round_ != 0) { output.writeInt32(3, round_); } if (result_ != 0) { output.writeInt32(4, result_); } if (maxProposal_ != 0) { output.writeInt32(5, maxProposal_); } if (acceptedBallotId_ != 0L) { output.writeInt64(6, acceptedBallotId_); } if (chosenInstanceId_ != 0L) { output.writeInt64(7, chosenInstanceId_); } if (chosenInfo_ != null) { output.writeMessage(8, getChosenInfo()); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (squadId_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(1, squadId_); } if (instanceId_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(2, instanceId_); } if (round_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(3, round_); } if (result_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(4, result_); } if (maxProposal_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(5, maxProposal_); } if (acceptedBallotId_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(6, acceptedBallotId_); } if (chosenInstanceId_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(7, chosenInstanceId_); } if (chosenInfo_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(8, getChosenInfo()); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes)) { return super.equals(obj); } org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes other = (org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes) obj; boolean result = true; result = result && (getSquadId() == other.getSquadId()); result = result && (getInstanceId() == other.getInstanceId()); result = result && (getRound() == other.getRound()); result = result && (getResult() == other.getResult()); result = result && (getMaxProposal() == other.getMaxProposal()); result = result && (getAcceptedBallotId() == other.getAcceptedBallotId()); result = result && (getChosenInstanceId() == other.getChosenInstanceId()); result = result && (hasChosenInfo() == other.hasChosenInfo()); if (hasChosenInfo()) { result = result && getChosenInfo() .equals(other.getChosenInfo()); } return result; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + SQUADID_FIELD_NUMBER; hash = (53 * hash) + getSquadId(); hash = (37 * hash) + INSTANCEID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getInstanceId()); hash = (37 * hash) + ROUND_FIELD_NUMBER; hash = (53 * hash) + getRound(); hash = (37 * hash) + RESULT_FIELD_NUMBER; hash = (53 * hash) + getResult(); hash = (37 * hash) + MAXPROPOSAL_FIELD_NUMBER; hash = (53 * hash) + getMaxProposal(); hash = (37 * hash) + ACCEPTEDBALLOTID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getAcceptedBallotId()); hash = (37 * hash) + CHOSENINSTANCEID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getChosenInstanceId()); if (hasChosenInfo()) { hash = (37 * hash) + CHOSENINFO_FIELD_NUMBER; hash = (53 * hash) + getChosenInfo().hashCode(); } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.AcceptRes} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements // @@protoc_insertion_point(builder_implements:org.axesoft.jaxos.network.protobuff.AcceptRes) org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptResOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_AcceptRes_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_AcceptRes_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes.Builder.class); } // Construct using org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } public Builder clear() { super.clear(); squadId_ = 0; instanceId_ = 0L; round_ = 0; result_ = 0; maxProposal_ = 0; acceptedBallotId_ = 0L; chosenInstanceId_ = 0L; if (chosenInfoBuilder_ == null) { chosenInfo_ = null; } else { chosenInfo_ = null; chosenInfoBuilder_ = null; } return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_AcceptRes_descriptor; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes getDefaultInstanceForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes.getDefaultInstance(); } public org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes build() { org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes buildPartial() { org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes result = new org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes(this); result.squadId_ = squadId_; result.instanceId_ = instanceId_; result.round_ = round_; result.result_ = result_; result.maxProposal_ = maxProposal_; result.acceptedBallotId_ = acceptedBallotId_; result.chosenInstanceId_ = chosenInstanceId_; if (chosenInfoBuilder_ == null) { result.chosenInfo_ = chosenInfo_; } else { result.chosenInfo_ = chosenInfoBuilder_.build(); } onBuilt(); return result; } public Builder clone() { return (Builder) super.clone(); } public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.setField(field, value); } public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return (Builder) super.clearField(field); } public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return (Builder) super.clearOneof(oneof); } public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) { return (Builder) super.setRepeatedField(field, index, value); } public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes) { return mergeFrom((org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes other) { if (other == org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes.getDefaultInstance()) return this; if (other.getSquadId() != 0) { setSquadId(other.getSquadId()); } if (other.getInstanceId() != 0L) { setInstanceId(other.getInstanceId()); } if (other.getRound() != 0) { setRound(other.getRound()); } if (other.getResult() != 0) { setResult(other.getResult()); } if (other.getMaxProposal() != 0) { setMaxProposal(other.getMaxProposal()); } if (other.getAcceptedBallotId() != 0L) { setAcceptedBallotId(other.getAcceptedBallotId()); } if (other.getChosenInstanceId() != 0L) { setChosenInstanceId(other.getChosenInstanceId()); } if (other.hasChosenInfo()) { mergeChosenInfo(other.getChosenInfo()); } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int squadId_ ; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } /** * <code>optional int32 squadId = 1;</code> */ public Builder setSquadId(int value) { squadId_ = value; onChanged(); return this; } /** * <code>optional int32 squadId = 1;</code> */ public Builder clearSquadId() { squadId_ = 0; onChanged(); return this; } private long instanceId_ ; /** * <code>optional int64 instanceId = 2;</code> */ public long getInstanceId() { return instanceId_; } /** * <code>optional int64 instanceId = 2;</code> */ public Builder setInstanceId(long value) { instanceId_ = value; onChanged(); return this; } /** * <code>optional int64 instanceId = 2;</code> */ public Builder clearInstanceId() { instanceId_ = 0L; onChanged(); return this; } private int round_ ; /** * <code>optional int32 round = 3;</code> */ public int getRound() { return round_; } /** * <code>optional int32 round = 3;</code> */ public Builder setRound(int value) { round_ = value; onChanged(); return this; } /** * <code>optional int32 round = 3;</code> */ public Builder clearRound() { round_ = 0; onChanged(); return this; } private int result_ ; /** * <code>optional int32 result = 4;</code> */ public int getResult() { return result_; } /** * <code>optional int32 result = 4;</code> */ public Builder setResult(int value) { result_ = value; onChanged(); return this; } /** * <code>optional int32 result = 4;</code> */ public Builder clearResult() { result_ = 0; onChanged(); return this; } private int maxProposal_ ; /** * <code>optional int32 maxProposal = 5;</code> */ public int getMaxProposal() { return maxProposal_; } /** * <code>optional int32 maxProposal = 5;</code> */ public Builder setMaxProposal(int value) { maxProposal_ = value; onChanged(); return this; } /** * <code>optional int32 maxProposal = 5;</code> */ public Builder clearMaxProposal() { maxProposal_ = 0; onChanged(); return this; } private long acceptedBallotId_ ; /** * <code>optional int64 acceptedBallotId = 6;</code> */ public long getAcceptedBallotId() { return acceptedBallotId_; } /** * <code>optional int64 acceptedBallotId = 6;</code> */ public Builder setAcceptedBallotId(long value) { acceptedBallotId_ = value; onChanged(); return this; } /** * <code>optional int64 acceptedBallotId = 6;</code> */ public Builder clearAcceptedBallotId() { acceptedBallotId_ = 0L; onChanged(); return this; } private long chosenInstanceId_ ; /** * <code>optional int64 chosenInstanceId = 7;</code> */ public long getChosenInstanceId() { return chosenInstanceId_; } /** * <code>optional int64 chosenInstanceId = 7;</code> */ public Builder setChosenInstanceId(long value) { chosenInstanceId_ = value; onChanged(); return this; } /** * <code>optional int64 chosenInstanceId = 7;</code> */ public Builder clearChosenInstanceId() { chosenInstanceId_ = 0L; onChanged(); return this; } private org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo chosenInfo_ = null; private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder> chosenInfoBuilder_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public boolean hasChosenInfo() { return chosenInfoBuilder_ != null || chosenInfo_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo getChosenInfo() { if (chosenInfoBuilder_ == null) { return chosenInfo_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.getDefaultInstance() : chosenInfo_; } else { return chosenInfoBuilder_.getMessage(); } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public Builder setChosenInfo(org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo value) { if (chosenInfoBuilder_ == null) { if (value == null) { throw new NullPointerException(); } chosenInfo_ = value; onChanged(); } else { chosenInfoBuilder_.setMessage(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public Builder setChosenInfo( org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder builderForValue) { if (chosenInfoBuilder_ == null) { chosenInfo_ = builderForValue.build(); onChanged(); } else { chosenInfoBuilder_.setMessage(builderForValue.build()); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public Builder mergeChosenInfo(org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo value) { if (chosenInfoBuilder_ == null) { if (chosenInfo_ != null) { chosenInfo_ = org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.newBuilder(chosenInfo_).mergeFrom(value).buildPartial(); } else { chosenInfo_ = value; } onChanged(); } else { chosenInfoBuilder_.mergeFrom(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public Builder clearChosenInfo() { if (chosenInfoBuilder_ == null) { chosenInfo_ = null; onChanged(); } else { chosenInfo_ = null; chosenInfoBuilder_ = null; } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder getChosenInfoBuilder() { onChanged(); return getChosenInfoFieldBuilder().getBuilder(); } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder getChosenInfoOrBuilder() { if (chosenInfoBuilder_ != null) { return chosenInfoBuilder_.getMessageOrBuilder(); } else { return chosenInfo_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.getDefaultInstance() : chosenInfo_; } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.ChosenInfo chosenInfo = 8;</code> */ private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder> getChosenInfoFieldBuilder() { if (chosenInfoBuilder_ == null) { chosenInfoBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfo.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.ChosenInfoOrBuilder>( getChosenInfo(), getParentForChildren(), isClean()); chosenInfo_ = null; } return chosenInfoBuilder_; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:org.axesoft.jaxos.network.protobuff.AcceptRes) } // @@protoc_insertion_point(class_scope:org.axesoft.jaxos.network.protobuff.AcceptRes) private static final org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes(); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser<AcceptRes> PARSER = new com.google.protobuf.AbstractParser<AcceptRes>() { public AcceptRes parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new AcceptRes(input, extensionRegistry); } }; public static com.google.protobuf.Parser<AcceptRes> parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser<AcceptRes> getParserForType() { return PARSER; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptRes getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface AcceptedNotifyOrBuilder extends // @@protoc_insertion_point(interface_extends:org.axesoft.jaxos.network.protobuff.AcceptedNotify) com.google.protobuf.MessageOrBuilder { /** * <code>optional int32 squadId = 1;</code> */ int getSquadId(); /** * <code>optional int64 instanceId = 2;</code> */ long getInstanceId(); /** * <code>optional int32 proposal = 3;</code> */ int getProposal(); /** * <code>optional int64 ballotId = 4;</code> */ long getBallotId(); } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.AcceptedNotify} */ public static final class AcceptedNotify extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:org.axesoft.jaxos.network.protobuff.AcceptedNotify) AcceptedNotifyOrBuilder { // Use AcceptedNotify.newBuilder() to construct. private AcceptedNotify(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { super(builder); } private AcceptedNotify() { squadId_ = 0; instanceId_ = 0L; proposal_ = 0; ballotId_ = 0L; } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private AcceptedNotify( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 8: { squadId_ = input.readInt32(); break; } case 16: { instanceId_ = input.readInt64(); break; } case 24: { proposal_ = input.readInt32(); break; } case 32: { ballotId_ = input.readInt64(); break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_AcceptedNotify_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_AcceptedNotify_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify.Builder.class); } public static final int SQUADID_FIELD_NUMBER = 1; private int squadId_; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } public static final int INSTANCEID_FIELD_NUMBER = 2; private long instanceId_; /** * <code>optional int64 instanceId = 2;</code> */ public long getInstanceId() { return instanceId_; } public static final int PROPOSAL_FIELD_NUMBER = 3; private int proposal_; /** * <code>optional int32 proposal = 3;</code> */ public int getProposal() { return proposal_; } public static final int BALLOTID_FIELD_NUMBER = 4; private long ballotId_; /** * <code>optional int64 ballotId = 4;</code> */ public long getBallotId() { return ballotId_; } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (squadId_ != 0) { output.writeInt32(1, squadId_); } if (instanceId_ != 0L) { output.writeInt64(2, instanceId_); } if (proposal_ != 0) { output.writeInt32(3, proposal_); } if (ballotId_ != 0L) { output.writeInt64(4, ballotId_); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (squadId_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(1, squadId_); } if (instanceId_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(2, instanceId_); } if (proposal_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(3, proposal_); } if (ballotId_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(4, ballotId_); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify)) { return super.equals(obj); } org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify other = (org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify) obj; boolean result = true; result = result && (getSquadId() == other.getSquadId()); result = result && (getInstanceId() == other.getInstanceId()); result = result && (getProposal() == other.getProposal()); result = result && (getBallotId() == other.getBallotId()); return result; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + SQUADID_FIELD_NUMBER; hash = (53 * hash) + getSquadId(); hash = (37 * hash) + INSTANCEID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getInstanceId()); hash = (37 * hash) + PROPOSAL_FIELD_NUMBER; hash = (53 * hash) + getProposal(); hash = (37 * hash) + BALLOTID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getBallotId()); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.AcceptedNotify} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements // @@protoc_insertion_point(builder_implements:org.axesoft.jaxos.network.protobuff.AcceptedNotify) org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotifyOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_AcceptedNotify_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_AcceptedNotify_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify.Builder.class); } // Construct using org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } public Builder clear() { super.clear(); squadId_ = 0; instanceId_ = 0L; proposal_ = 0; ballotId_ = 0L; return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_AcceptedNotify_descriptor; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify getDefaultInstanceForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify.getDefaultInstance(); } public org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify build() { org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify buildPartial() { org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify result = new org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify(this); result.squadId_ = squadId_; result.instanceId_ = instanceId_; result.proposal_ = proposal_; result.ballotId_ = ballotId_; onBuilt(); return result; } public Builder clone() { return (Builder) super.clone(); } public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.setField(field, value); } public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return (Builder) super.clearField(field); } public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return (Builder) super.clearOneof(oneof); } public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) { return (Builder) super.setRepeatedField(field, index, value); } public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify) { return mergeFrom((org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify other) { if (other == org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify.getDefaultInstance()) return this; if (other.getSquadId() != 0) { setSquadId(other.getSquadId()); } if (other.getInstanceId() != 0L) { setInstanceId(other.getInstanceId()); } if (other.getProposal() != 0) { setProposal(other.getProposal()); } if (other.getBallotId() != 0L) { setBallotId(other.getBallotId()); } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int squadId_ ; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } /** * <code>optional int32 squadId = 1;</code> */ public Builder setSquadId(int value) { squadId_ = value; onChanged(); return this; } /** * <code>optional int32 squadId = 1;</code> */ public Builder clearSquadId() { squadId_ = 0; onChanged(); return this; } private long instanceId_ ; /** * <code>optional int64 instanceId = 2;</code> */ public long getInstanceId() { return instanceId_; } /** * <code>optional int64 instanceId = 2;</code> */ public Builder setInstanceId(long value) { instanceId_ = value; onChanged(); return this; } /** * <code>optional int64 instanceId = 2;</code> */ public Builder clearInstanceId() { instanceId_ = 0L; onChanged(); return this; } private int proposal_ ; /** * <code>optional int32 proposal = 3;</code> */ public int getProposal() { return proposal_; } /** * <code>optional int32 proposal = 3;</code> */ public Builder setProposal(int value) { proposal_ = value; onChanged(); return this; } /** * <code>optional int32 proposal = 3;</code> */ public Builder clearProposal() { proposal_ = 0; onChanged(); return this; } private long ballotId_ ; /** * <code>optional int64 ballotId = 4;</code> */ public long getBallotId() { return ballotId_; } /** * <code>optional int64 ballotId = 4;</code> */ public Builder setBallotId(long value) { ballotId_ = value; onChanged(); return this; } /** * <code>optional int64 ballotId = 4;</code> */ public Builder clearBallotId() { ballotId_ = 0L; onChanged(); return this; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:org.axesoft.jaxos.network.protobuff.AcceptedNotify) } // @@protoc_insertion_point(class_scope:org.axesoft.jaxos.network.protobuff.AcceptedNotify) private static final org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify(); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser<AcceptedNotify> PARSER = new com.google.protobuf.AbstractParser<AcceptedNotify>() { public AcceptedNotify parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new AcceptedNotify(input, extensionRegistry); } }; public static com.google.protobuf.Parser<AcceptedNotify> parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser<AcceptedNotify> getParserForType() { return PARSER; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.AcceptedNotify getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface LearnReqOrBuilder extends // @@protoc_insertion_point(interface_extends:org.axesoft.jaxos.network.protobuff.LearnReq) com.google.protobuf.MessageOrBuilder { /** * <code>optional int32 squadId = 1;</code> */ int getSquadId(); /** * <code>optional int64 lowInstanceId = 2;</code> */ long getLowInstanceId(); } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.LearnReq} */ public static final class LearnReq extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:org.axesoft.jaxos.network.protobuff.LearnReq) LearnReqOrBuilder { // Use LearnReq.newBuilder() to construct. private LearnReq(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { super(builder); } private LearnReq() { squadId_ = 0; lowInstanceId_ = 0L; } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private LearnReq( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 8: { squadId_ = input.readInt32(); break; } case 16: { lowInstanceId_ = input.readInt64(); break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_LearnReq_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_LearnReq_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq.Builder.class); } public static final int SQUADID_FIELD_NUMBER = 1; private int squadId_; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } public static final int LOWINSTANCEID_FIELD_NUMBER = 2; private long lowInstanceId_; /** * <code>optional int64 lowInstanceId = 2;</code> */ public long getLowInstanceId() { return lowInstanceId_; } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (squadId_ != 0) { output.writeInt32(1, squadId_); } if (lowInstanceId_ != 0L) { output.writeInt64(2, lowInstanceId_); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (squadId_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(1, squadId_); } if (lowInstanceId_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(2, lowInstanceId_); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq)) { return super.equals(obj); } org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq other = (org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq) obj; boolean result = true; result = result && (getSquadId() == other.getSquadId()); result = result && (getLowInstanceId() == other.getLowInstanceId()); return result; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + SQUADID_FIELD_NUMBER; hash = (53 * hash) + getSquadId(); hash = (37 * hash) + LOWINSTANCEID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getLowInstanceId()); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.LearnReq} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements // @@protoc_insertion_point(builder_implements:org.axesoft.jaxos.network.protobuff.LearnReq) org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReqOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_LearnReq_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_LearnReq_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq.Builder.class); } // Construct using org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } public Builder clear() { super.clear(); squadId_ = 0; lowInstanceId_ = 0L; return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_LearnReq_descriptor; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq getDefaultInstanceForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq.getDefaultInstance(); } public org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq build() { org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq buildPartial() { org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq result = new org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq(this); result.squadId_ = squadId_; result.lowInstanceId_ = lowInstanceId_; onBuilt(); return result; } public Builder clone() { return (Builder) super.clone(); } public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.setField(field, value); } public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return (Builder) super.clearField(field); } public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return (Builder) super.clearOneof(oneof); } public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) { return (Builder) super.setRepeatedField(field, index, value); } public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq) { return mergeFrom((org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq other) { if (other == org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq.getDefaultInstance()) return this; if (other.getSquadId() != 0) { setSquadId(other.getSquadId()); } if (other.getLowInstanceId() != 0L) { setLowInstanceId(other.getLowInstanceId()); } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int squadId_ ; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } /** * <code>optional int32 squadId = 1;</code> */ public Builder setSquadId(int value) { squadId_ = value; onChanged(); return this; } /** * <code>optional int32 squadId = 1;</code> */ public Builder clearSquadId() { squadId_ = 0; onChanged(); return this; } private long lowInstanceId_ ; /** * <code>optional int64 lowInstanceId = 2;</code> */ public long getLowInstanceId() { return lowInstanceId_; } /** * <code>optional int64 lowInstanceId = 2;</code> */ public Builder setLowInstanceId(long value) { lowInstanceId_ = value; onChanged(); return this; } /** * <code>optional int64 lowInstanceId = 2;</code> */ public Builder clearLowInstanceId() { lowInstanceId_ = 0L; onChanged(); return this; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:org.axesoft.jaxos.network.protobuff.LearnReq) } // @@protoc_insertion_point(class_scope:org.axesoft.jaxos.network.protobuff.LearnReq) private static final org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq(); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser<LearnReq> PARSER = new com.google.protobuf.AbstractParser<LearnReq>() { public LearnReq parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new LearnReq(input, extensionRegistry); } }; public static com.google.protobuf.Parser<LearnReq> parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser<LearnReq> getParserForType() { return PARSER; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnReq getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface LearnResOrBuilder extends // @@protoc_insertion_point(interface_extends:org.axesoft.jaxos.network.protobuff.LearnRes) com.google.protobuf.MessageOrBuilder { /** * <code>optional int32 squadId = 1;</code> */ int getSquadId(); /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ java.util.List<org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance> getInstanceList(); /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance getInstance(int index); /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ int getInstanceCount(); /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ java.util.List<? extends org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder> getInstanceOrBuilderList(); /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder getInstanceOrBuilder( int index); /** * <code>optional .org.axesoft.jaxos.network.protobuff.CheckPoint checkPoint = 3;</code> */ boolean hasCheckPoint(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.CheckPoint checkPoint = 3;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint getCheckPoint(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.CheckPoint checkPoint = 3;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPointOrBuilder getCheckPointOrBuilder(); } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.LearnRes} */ public static final class LearnRes extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:org.axesoft.jaxos.network.protobuff.LearnRes) LearnResOrBuilder { // Use LearnRes.newBuilder() to construct. private LearnRes(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { super(builder); } private LearnRes() { squadId_ = 0; instance_ = java.util.Collections.emptyList(); } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private LearnRes( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 8: { squadId_ = input.readInt32(); break; } case 18: { if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { instance_ = new java.util.ArrayList<org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance>(); mutable_bitField0_ |= 0x00000002; } instance_.add( input.readMessage(org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.parser(), extensionRegistry)); break; } case 26: { org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.Builder subBuilder = null; if (checkPoint_ != null) { subBuilder = checkPoint_.toBuilder(); } checkPoint_ = input.readMessage(org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(checkPoint_); checkPoint_ = subBuilder.buildPartial(); } break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) { instance_ = java.util.Collections.unmodifiableList(instance_); } makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_LearnRes_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_LearnRes_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes.Builder.class); } private int bitField0_; public static final int SQUADID_FIELD_NUMBER = 1; private int squadId_; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } public static final int INSTANCE_FIELD_NUMBER = 2; private java.util.List<org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance> instance_; /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public java.util.List<org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance> getInstanceList() { return instance_; } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public java.util.List<? extends org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder> getInstanceOrBuilderList() { return instance_; } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public int getInstanceCount() { return instance_.size(); } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance getInstance(int index) { return instance_.get(index); } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder getInstanceOrBuilder( int index) { return instance_.get(index); } public static final int CHECKPOINT_FIELD_NUMBER = 3; private org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint checkPoint_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.CheckPoint checkPoint = 3;</code> */ public boolean hasCheckPoint() { return checkPoint_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.CheckPoint checkPoint = 3;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint getCheckPoint() { return checkPoint_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.getDefaultInstance() : checkPoint_; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.CheckPoint checkPoint = 3;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPointOrBuilder getCheckPointOrBuilder() { return getCheckPoint(); } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (squadId_ != 0) { output.writeInt32(1, squadId_); } for (int i = 0; i < instance_.size(); i++) { output.writeMessage(2, instance_.get(i)); } if (checkPoint_ != null) { output.writeMessage(3, getCheckPoint()); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (squadId_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(1, squadId_); } for (int i = 0; i < instance_.size(); i++) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(2, instance_.get(i)); } if (checkPoint_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(3, getCheckPoint()); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes)) { return super.equals(obj); } org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes other = (org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes) obj; boolean result = true; result = result && (getSquadId() == other.getSquadId()); result = result && getInstanceList() .equals(other.getInstanceList()); result = result && (hasCheckPoint() == other.hasCheckPoint()); if (hasCheckPoint()) { result = result && getCheckPoint() .equals(other.getCheckPoint()); } return result; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + SQUADID_FIELD_NUMBER; hash = (53 * hash) + getSquadId(); if (getInstanceCount() > 0) { hash = (37 * hash) + INSTANCE_FIELD_NUMBER; hash = (53 * hash) + getInstanceList().hashCode(); } if (hasCheckPoint()) { hash = (37 * hash) + CHECKPOINT_FIELD_NUMBER; hash = (53 * hash) + getCheckPoint().hashCode(); } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.LearnRes} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements // @@protoc_insertion_point(builder_implements:org.axesoft.jaxos.network.protobuff.LearnRes) org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnResOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_LearnRes_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_LearnRes_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes.Builder.class); } // Construct using org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { getInstanceFieldBuilder(); } } public Builder clear() { super.clear(); squadId_ = 0; if (instanceBuilder_ == null) { instance_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000002); } else { instanceBuilder_.clear(); } if (checkPointBuilder_ == null) { checkPoint_ = null; } else { checkPoint_ = null; checkPointBuilder_ = null; } return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_LearnRes_descriptor; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes getDefaultInstanceForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes.getDefaultInstance(); } public org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes build() { org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes buildPartial() { org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes result = new org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes(this); int from_bitField0_ = bitField0_; int to_bitField0_ = 0; result.squadId_ = squadId_; if (instanceBuilder_ == null) { if (((bitField0_ & 0x00000002) == 0x00000002)) { instance_ = java.util.Collections.unmodifiableList(instance_); bitField0_ = (bitField0_ & ~0x00000002); } result.instance_ = instance_; } else { result.instance_ = instanceBuilder_.build(); } if (checkPointBuilder_ == null) { result.checkPoint_ = checkPoint_; } else { result.checkPoint_ = checkPointBuilder_.build(); } result.bitField0_ = to_bitField0_; onBuilt(); return result; } public Builder clone() { return (Builder) super.clone(); } public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.setField(field, value); } public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return (Builder) super.clearField(field); } public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return (Builder) super.clearOneof(oneof); } public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) { return (Builder) super.setRepeatedField(field, index, value); } public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes) { return mergeFrom((org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes other) { if (other == org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes.getDefaultInstance()) return this; if (other.getSquadId() != 0) { setSquadId(other.getSquadId()); } if (instanceBuilder_ == null) { if (!other.instance_.isEmpty()) { if (instance_.isEmpty()) { instance_ = other.instance_; bitField0_ = (bitField0_ & ~0x00000002); } else { ensureInstanceIsMutable(); instance_.addAll(other.instance_); } onChanged(); } } else { if (!other.instance_.isEmpty()) { if (instanceBuilder_.isEmpty()) { instanceBuilder_.dispose(); instanceBuilder_ = null; instance_ = other.instance_; bitField0_ = (bitField0_ & ~0x00000002); instanceBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getInstanceFieldBuilder() : null; } else { instanceBuilder_.addAllMessages(other.instance_); } } } if (other.hasCheckPoint()) { mergeCheckPoint(other.getCheckPoint()); } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int bitField0_; private int squadId_ ; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } /** * <code>optional int32 squadId = 1;</code> */ public Builder setSquadId(int value) { squadId_ = value; onChanged(); return this; } /** * <code>optional int32 squadId = 1;</code> */ public Builder clearSquadId() { squadId_ = 0; onChanged(); return this; } private java.util.List<org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance> instance_ = java.util.Collections.emptyList(); private void ensureInstanceIsMutable() { if (!((bitField0_ & 0x00000002) == 0x00000002)) { instance_ = new java.util.ArrayList<org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance>(instance_); bitField0_ |= 0x00000002; } } private com.google.protobuf.RepeatedFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance, org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder> instanceBuilder_; /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public java.util.List<org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance> getInstanceList() { if (instanceBuilder_ == null) { return java.util.Collections.unmodifiableList(instance_); } else { return instanceBuilder_.getMessageList(); } } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public int getInstanceCount() { if (instanceBuilder_ == null) { return instance_.size(); } else { return instanceBuilder_.getCount(); } } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance getInstance(int index) { if (instanceBuilder_ == null) { return instance_.get(index); } else { return instanceBuilder_.getMessage(index); } } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public Builder setInstance( int index, org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance value) { if (instanceBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureInstanceIsMutable(); instance_.set(index, value); onChanged(); } else { instanceBuilder_.setMessage(index, value); } return this; } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public Builder setInstance( int index, org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder builderForValue) { if (instanceBuilder_ == null) { ensureInstanceIsMutable(); instance_.set(index, builderForValue.build()); onChanged(); } else { instanceBuilder_.setMessage(index, builderForValue.build()); } return this; } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public Builder addInstance(org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance value) { if (instanceBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureInstanceIsMutable(); instance_.add(value); onChanged(); } else { instanceBuilder_.addMessage(value); } return this; } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public Builder addInstance( int index, org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance value) { if (instanceBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureInstanceIsMutable(); instance_.add(index, value); onChanged(); } else { instanceBuilder_.addMessage(index, value); } return this; } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public Builder addInstance( org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder builderForValue) { if (instanceBuilder_ == null) { ensureInstanceIsMutable(); instance_.add(builderForValue.build()); onChanged(); } else { instanceBuilder_.addMessage(builderForValue.build()); } return this; } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public Builder addInstance( int index, org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder builderForValue) { if (instanceBuilder_ == null) { ensureInstanceIsMutable(); instance_.add(index, builderForValue.build()); onChanged(); } else { instanceBuilder_.addMessage(index, builderForValue.build()); } return this; } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public Builder addAllInstance( java.lang.Iterable<? extends org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance> values) { if (instanceBuilder_ == null) { ensureInstanceIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll( values, instance_); onChanged(); } else { instanceBuilder_.addAllMessages(values); } return this; } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public Builder clearInstance() { if (instanceBuilder_ == null) { instance_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000002); onChanged(); } else { instanceBuilder_.clear(); } return this; } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public Builder removeInstance(int index) { if (instanceBuilder_ == null) { ensureInstanceIsMutable(); instance_.remove(index); onChanged(); } else { instanceBuilder_.remove(index); } return this; } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder getInstanceBuilder( int index) { return getInstanceFieldBuilder().getBuilder(index); } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder getInstanceOrBuilder( int index) { if (instanceBuilder_ == null) { return instance_.get(index); } else { return instanceBuilder_.getMessageOrBuilder(index); } } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public java.util.List<? extends org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder> getInstanceOrBuilderList() { if (instanceBuilder_ != null) { return instanceBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(instance_); } } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder addInstanceBuilder() { return getInstanceFieldBuilder().addBuilder( org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.getDefaultInstance()); } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder addInstanceBuilder( int index) { return getInstanceFieldBuilder().addBuilder( index, org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.getDefaultInstance()); } /** * <code>repeated .org.axesoft.jaxos.network.protobuff.Instance instance = 2;</code> */ public java.util.List<org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder> getInstanceBuilderList() { return getInstanceFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance, org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder> getInstanceFieldBuilder() { if (instanceBuilder_ == null) { instanceBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance, org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder>( instance_, ((bitField0_ & 0x00000002) == 0x00000002), getParentForChildren(), isClean()); instance_ = null; } return instanceBuilder_; } private org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint checkPoint_ = null; private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint, org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPointOrBuilder> checkPointBuilder_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.CheckPoint checkPoint = 3;</code> */ public boolean hasCheckPoint() { return checkPointBuilder_ != null || checkPoint_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.CheckPoint checkPoint = 3;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint getCheckPoint() { if (checkPointBuilder_ == null) { return checkPoint_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.getDefaultInstance() : checkPoint_; } else { return checkPointBuilder_.getMessage(); } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.CheckPoint checkPoint = 3;</code> */ public Builder setCheckPoint(org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint value) { if (checkPointBuilder_ == null) { if (value == null) { throw new NullPointerException(); } checkPoint_ = value; onChanged(); } else { checkPointBuilder_.setMessage(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.CheckPoint checkPoint = 3;</code> */ public Builder setCheckPoint( org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.Builder builderForValue) { if (checkPointBuilder_ == null) { checkPoint_ = builderForValue.build(); onChanged(); } else { checkPointBuilder_.setMessage(builderForValue.build()); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.CheckPoint checkPoint = 3;</code> */ public Builder mergeCheckPoint(org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint value) { if (checkPointBuilder_ == null) { if (checkPoint_ != null) { checkPoint_ = org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.newBuilder(checkPoint_).mergeFrom(value).buildPartial(); } else { checkPoint_ = value; } onChanged(); } else { checkPointBuilder_.mergeFrom(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.CheckPoint checkPoint = 3;</code> */ public Builder clearCheckPoint() { if (checkPointBuilder_ == null) { checkPoint_ = null; onChanged(); } else { checkPoint_ = null; checkPointBuilder_ = null; } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.CheckPoint checkPoint = 3;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.Builder getCheckPointBuilder() { onChanged(); return getCheckPointFieldBuilder().getBuilder(); } /** * <code>optional .org.axesoft.jaxos.network.protobuff.CheckPoint checkPoint = 3;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPointOrBuilder getCheckPointOrBuilder() { if (checkPointBuilder_ != null) { return checkPointBuilder_.getMessageOrBuilder(); } else { return checkPoint_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.getDefaultInstance() : checkPoint_; } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.CheckPoint checkPoint = 3;</code> */ private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint, org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPointOrBuilder> getCheckPointFieldBuilder() { if (checkPointBuilder_ == null) { checkPointBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint, org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPointOrBuilder>( getCheckPoint(), getParentForChildren(), isClean()); checkPoint_ = null; } return checkPointBuilder_; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:org.axesoft.jaxos.network.protobuff.LearnRes) } // @@protoc_insertion_point(class_scope:org.axesoft.jaxos.network.protobuff.LearnRes) private static final org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes(); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser<LearnRes> PARSER = new com.google.protobuf.AbstractParser<LearnRes>() { public LearnRes parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new LearnRes(input, extensionRegistry); } }; public static com.google.protobuf.Parser<LearnRes> parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser<LearnRes> getParserForType() { return PARSER; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.LearnRes getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface InstanceOrBuilder extends // @@protoc_insertion_point(interface_extends:org.axesoft.jaxos.network.protobuff.Instance) com.google.protobuf.MessageOrBuilder { /** * <code>optional int32 squadId = 1;</code> */ int getSquadId(); /** * <code>optional int64 instanceId = 2;</code> */ long getInstanceId(); /** * <code>optional int32 proposal = 3;</code> */ int getProposal(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 4;</code> */ boolean hasValue(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 4;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue getValue(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 4;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder getValueOrBuilder(); } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.Instance} */ public static final class Instance extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:org.axesoft.jaxos.network.protobuff.Instance) InstanceOrBuilder { // Use Instance.newBuilder() to construct. private Instance(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { super(builder); } private Instance() { squadId_ = 0; instanceId_ = 0L; proposal_ = 0; } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private Instance( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 8: { squadId_ = input.readInt32(); break; } case 16: { instanceId_ = input.readInt64(); break; } case 24: { proposal_ = input.readInt32(); break; } case 34: { org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder subBuilder = null; if (value_ != null) { subBuilder = value_.toBuilder(); } value_ = input.readMessage(org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(value_); value_ = subBuilder.buildPartial(); } break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_Instance_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_Instance_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder.class); } public static final int SQUADID_FIELD_NUMBER = 1; private int squadId_; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } public static final int INSTANCEID_FIELD_NUMBER = 2; private long instanceId_; /** * <code>optional int64 instanceId = 2;</code> */ public long getInstanceId() { return instanceId_; } public static final int PROPOSAL_FIELD_NUMBER = 3; private int proposal_; /** * <code>optional int32 proposal = 3;</code> */ public int getProposal() { return proposal_; } public static final int VALUE_FIELD_NUMBER = 4; private org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue value_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 4;</code> */ public boolean hasValue() { return value_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 4;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue getValue() { return value_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.getDefaultInstance() : value_; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 4;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder getValueOrBuilder() { return getValue(); } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (squadId_ != 0) { output.writeInt32(1, squadId_); } if (instanceId_ != 0L) { output.writeInt64(2, instanceId_); } if (proposal_ != 0) { output.writeInt32(3, proposal_); } if (value_ != null) { output.writeMessage(4, getValue()); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (squadId_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(1, squadId_); } if (instanceId_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(2, instanceId_); } if (proposal_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(3, proposal_); } if (value_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(4, getValue()); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance)) { return super.equals(obj); } org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance other = (org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance) obj; boolean result = true; result = result && (getSquadId() == other.getSquadId()); result = result && (getInstanceId() == other.getInstanceId()); result = result && (getProposal() == other.getProposal()); result = result && (hasValue() == other.hasValue()); if (hasValue()) { result = result && getValue() .equals(other.getValue()); } return result; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + SQUADID_FIELD_NUMBER; hash = (53 * hash) + getSquadId(); hash = (37 * hash) + INSTANCEID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getInstanceId()); hash = (37 * hash) + PROPOSAL_FIELD_NUMBER; hash = (53 * hash) + getProposal(); if (hasValue()) { hash = (37 * hash) + VALUE_FIELD_NUMBER; hash = (53 * hash) + getValue().hashCode(); } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.Instance} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements // @@protoc_insertion_point(builder_implements:org.axesoft.jaxos.network.protobuff.Instance) org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_Instance_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_Instance_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder.class); } // Construct using org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } public Builder clear() { super.clear(); squadId_ = 0; instanceId_ = 0L; proposal_ = 0; if (valueBuilder_ == null) { value_ = null; } else { value_ = null; valueBuilder_ = null; } return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_Instance_descriptor; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance getDefaultInstanceForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.getDefaultInstance(); } public org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance build() { org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance buildPartial() { org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance result = new org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance(this); result.squadId_ = squadId_; result.instanceId_ = instanceId_; result.proposal_ = proposal_; if (valueBuilder_ == null) { result.value_ = value_; } else { result.value_ = valueBuilder_.build(); } onBuilt(); return result; } public Builder clone() { return (Builder) super.clone(); } public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.setField(field, value); } public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return (Builder) super.clearField(field); } public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return (Builder) super.clearOneof(oneof); } public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) { return (Builder) super.setRepeatedField(field, index, value); } public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance) { return mergeFrom((org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance other) { if (other == org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.getDefaultInstance()) return this; if (other.getSquadId() != 0) { setSquadId(other.getSquadId()); } if (other.getInstanceId() != 0L) { setInstanceId(other.getInstanceId()); } if (other.getProposal() != 0) { setProposal(other.getProposal()); } if (other.hasValue()) { mergeValue(other.getValue()); } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int squadId_ ; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } /** * <code>optional int32 squadId = 1;</code> */ public Builder setSquadId(int value) { squadId_ = value; onChanged(); return this; } /** * <code>optional int32 squadId = 1;</code> */ public Builder clearSquadId() { squadId_ = 0; onChanged(); return this; } private long instanceId_ ; /** * <code>optional int64 instanceId = 2;</code> */ public long getInstanceId() { return instanceId_; } /** * <code>optional int64 instanceId = 2;</code> */ public Builder setInstanceId(long value) { instanceId_ = value; onChanged(); return this; } /** * <code>optional int64 instanceId = 2;</code> */ public Builder clearInstanceId() { instanceId_ = 0L; onChanged(); return this; } private int proposal_ ; /** * <code>optional int32 proposal = 3;</code> */ public int getProposal() { return proposal_; } /** * <code>optional int32 proposal = 3;</code> */ public Builder setProposal(int value) { proposal_ = value; onChanged(); return this; } /** * <code>optional int32 proposal = 3;</code> */ public Builder clearProposal() { proposal_ = 0; onChanged(); return this; } private org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue value_ = null; private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder> valueBuilder_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 4;</code> */ public boolean hasValue() { return valueBuilder_ != null || value_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 4;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue getValue() { if (valueBuilder_ == null) { return value_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.getDefaultInstance() : value_; } else { return valueBuilder_.getMessage(); } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 4;</code> */ public Builder setValue(org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue value) { if (valueBuilder_ == null) { if (value == null) { throw new NullPointerException(); } value_ = value; onChanged(); } else { valueBuilder_.setMessage(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 4;</code> */ public Builder setValue( org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder builderForValue) { if (valueBuilder_ == null) { value_ = builderForValue.build(); onChanged(); } else { valueBuilder_.setMessage(builderForValue.build()); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 4;</code> */ public Builder mergeValue(org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue value) { if (valueBuilder_ == null) { if (value_ != null) { value_ = org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.newBuilder(value_).mergeFrom(value).buildPartial(); } else { value_ = value; } onChanged(); } else { valueBuilder_.mergeFrom(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 4;</code> */ public Builder clearValue() { if (valueBuilder_ == null) { value_ = null; onChanged(); } else { value_ = null; valueBuilder_ = null; } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 4;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder getValueBuilder() { onChanged(); return getValueFieldBuilder().getBuilder(); } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 4;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder getValueOrBuilder() { if (valueBuilder_ != null) { return valueBuilder_.getMessageOrBuilder(); } else { return value_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.getDefaultInstance() : value_; } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.BallotValue value = 4;</code> */ private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder> getValueFieldBuilder() { if (valueBuilder_ == null) { valueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValue.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.BallotValueOrBuilder>( getValue(), getParentForChildren(), isClean()); value_ = null; } return valueBuilder_; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:org.axesoft.jaxos.network.protobuff.Instance) } // @@protoc_insertion_point(class_scope:org.axesoft.jaxos.network.protobuff.Instance) private static final org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance(); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser<Instance> PARSER = new com.google.protobuf.AbstractParser<Instance>() { public Instance parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new Instance(input, extensionRegistry); } }; public static com.google.protobuf.Parser<Instance> parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser<Instance> getParserForType() { return PARSER; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface SquadChosenOrBuilder extends // @@protoc_insertion_point(interface_extends:org.axesoft.jaxos.network.protobuff.SquadChosen) com.google.protobuf.MessageOrBuilder { /** * <code>optional int32 squadId = 1;</code> */ int getSquadId(); /** * <code>optional int64 instanceId = 2;</code> */ long getInstanceId(); } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.SquadChosen} */ public static final class SquadChosen extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:org.axesoft.jaxos.network.protobuff.SquadChosen) SquadChosenOrBuilder { // Use SquadChosen.newBuilder() to construct. private SquadChosen(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { super(builder); } private SquadChosen() { squadId_ = 0; instanceId_ = 0L; } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private SquadChosen( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 8: { squadId_ = input.readInt32(); break; } case 16: { instanceId_ = input.readInt64(); break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_SquadChosen_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_SquadChosen_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen.Builder.class); } public static final int SQUADID_FIELD_NUMBER = 1; private int squadId_; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } public static final int INSTANCEID_FIELD_NUMBER = 2; private long instanceId_; /** * <code>optional int64 instanceId = 2;</code> */ public long getInstanceId() { return instanceId_; } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (squadId_ != 0) { output.writeInt32(1, squadId_); } if (instanceId_ != 0L) { output.writeInt64(2, instanceId_); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (squadId_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(1, squadId_); } if (instanceId_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(2, instanceId_); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen)) { return super.equals(obj); } org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen other = (org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen) obj; boolean result = true; result = result && (getSquadId() == other.getSquadId()); result = result && (getInstanceId() == other.getInstanceId()); return result; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + SQUADID_FIELD_NUMBER; hash = (53 * hash) + getSquadId(); hash = (37 * hash) + INSTANCEID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getInstanceId()); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.SquadChosen} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements // @@protoc_insertion_point(builder_implements:org.axesoft.jaxos.network.protobuff.SquadChosen) org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosenOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_SquadChosen_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_SquadChosen_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen.Builder.class); } // Construct using org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } public Builder clear() { super.clear(); squadId_ = 0; instanceId_ = 0L; return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_SquadChosen_descriptor; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen getDefaultInstanceForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen.getDefaultInstance(); } public org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen build() { org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen buildPartial() { org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen result = new org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen(this); result.squadId_ = squadId_; result.instanceId_ = instanceId_; onBuilt(); return result; } public Builder clone() { return (Builder) super.clone(); } public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.setField(field, value); } public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return (Builder) super.clearField(field); } public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return (Builder) super.clearOneof(oneof); } public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) { return (Builder) super.setRepeatedField(field, index, value); } public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen) { return mergeFrom((org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen other) { if (other == org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen.getDefaultInstance()) return this; if (other.getSquadId() != 0) { setSquadId(other.getSquadId()); } if (other.getInstanceId() != 0L) { setInstanceId(other.getInstanceId()); } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int squadId_ ; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } /** * <code>optional int32 squadId = 1;</code> */ public Builder setSquadId(int value) { squadId_ = value; onChanged(); return this; } /** * <code>optional int32 squadId = 1;</code> */ public Builder clearSquadId() { squadId_ = 0; onChanged(); return this; } private long instanceId_ ; /** * <code>optional int64 instanceId = 2;</code> */ public long getInstanceId() { return instanceId_; } /** * <code>optional int64 instanceId = 2;</code> */ public Builder setInstanceId(long value) { instanceId_ = value; onChanged(); return this; } /** * <code>optional int64 instanceId = 2;</code> */ public Builder clearInstanceId() { instanceId_ = 0L; onChanged(); return this; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:org.axesoft.jaxos.network.protobuff.SquadChosen) } // @@protoc_insertion_point(class_scope:org.axesoft.jaxos.network.protobuff.SquadChosen) private static final org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen(); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser<SquadChosen> PARSER = new com.google.protobuf.AbstractParser<SquadChosen>() { public SquadChosen parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new SquadChosen(input, extensionRegistry); } }; public static com.google.protobuf.Parser<SquadChosen> parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser<SquadChosen> getParserForType() { return PARSER; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface CheckPointOrBuilder extends // @@protoc_insertion_point(interface_extends:org.axesoft.jaxos.network.protobuff.CheckPoint) com.google.protobuf.MessageOrBuilder { /** * <code>optional int32 squadId = 1;</code> */ int getSquadId(); /** * <code>optional int64 timestamp = 2;</code> */ long getTimestamp(); /** * <code>optional bytes content = 3;</code> */ com.google.protobuf.ByteString getContent(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.Instance lastInstance = 4;</code> */ boolean hasLastInstance(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.Instance lastInstance = 4;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance getLastInstance(); /** * <code>optional .org.axesoft.jaxos.network.protobuff.Instance lastInstance = 4;</code> */ org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder getLastInstanceOrBuilder(); } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.CheckPoint} */ public static final class CheckPoint extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:org.axesoft.jaxos.network.protobuff.CheckPoint) CheckPointOrBuilder { // Use CheckPoint.newBuilder() to construct. private CheckPoint(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { super(builder); } private CheckPoint() { squadId_ = 0; timestamp_ = 0L; content_ = com.google.protobuf.ByteString.EMPTY; } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private CheckPoint( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 8: { squadId_ = input.readInt32(); break; } case 16: { timestamp_ = input.readInt64(); break; } case 26: { content_ = input.readBytes(); break; } case 34: { org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder subBuilder = null; if (lastInstance_ != null) { subBuilder = lastInstance_.toBuilder(); } lastInstance_ = input.readMessage(org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(lastInstance_); lastInstance_ = subBuilder.buildPartial(); } break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_CheckPoint_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_CheckPoint_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.Builder.class); } public static final int SQUADID_FIELD_NUMBER = 1; private int squadId_; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } public static final int TIMESTAMP_FIELD_NUMBER = 2; private long timestamp_; /** * <code>optional int64 timestamp = 2;</code> */ public long getTimestamp() { return timestamp_; } public static final int CONTENT_FIELD_NUMBER = 3; private com.google.protobuf.ByteString content_; /** * <code>optional bytes content = 3;</code> */ public com.google.protobuf.ByteString getContent() { return content_; } public static final int LASTINSTANCE_FIELD_NUMBER = 4; private org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance lastInstance_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.Instance lastInstance = 4;</code> */ public boolean hasLastInstance() { return lastInstance_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.Instance lastInstance = 4;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance getLastInstance() { return lastInstance_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.getDefaultInstance() : lastInstance_; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.Instance lastInstance = 4;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder getLastInstanceOrBuilder() { return getLastInstance(); } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (squadId_ != 0) { output.writeInt32(1, squadId_); } if (timestamp_ != 0L) { output.writeInt64(2, timestamp_); } if (!content_.isEmpty()) { output.writeBytes(3, content_); } if (lastInstance_ != null) { output.writeMessage(4, getLastInstance()); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (squadId_ != 0) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(1, squadId_); } if (timestamp_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(2, timestamp_); } if (!content_.isEmpty()) { size += com.google.protobuf.CodedOutputStream .computeBytesSize(3, content_); } if (lastInstance_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(4, getLastInstance()); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint)) { return super.equals(obj); } org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint other = (org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint) obj; boolean result = true; result = result && (getSquadId() == other.getSquadId()); result = result && (getTimestamp() == other.getTimestamp()); result = result && getContent() .equals(other.getContent()); result = result && (hasLastInstance() == other.hasLastInstance()); if (hasLastInstance()) { result = result && getLastInstance() .equals(other.getLastInstance()); } return result; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); hash = (37 * hash) + SQUADID_FIELD_NUMBER; hash = (53 * hash) + getSquadId(); hash = (37 * hash) + TIMESTAMP_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getTimestamp()); hash = (37 * hash) + CONTENT_FIELD_NUMBER; hash = (53 * hash) + getContent().hashCode(); if (hasLastInstance()) { hash = (37 * hash) + LASTINSTANCE_FIELD_NUMBER; hash = (53 * hash) + getLastInstance().hashCode(); } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.axesoft.jaxos.network.protobuff.CheckPoint} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements // @@protoc_insertion_point(builder_implements:org.axesoft.jaxos.network.protobuff.CheckPoint) org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPointOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_CheckPoint_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_CheckPoint_fieldAccessorTable .ensureFieldAccessorsInitialized( org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.class, org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.Builder.class); } // Construct using org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } public Builder clear() { super.clear(); squadId_ = 0; timestamp_ = 0L; content_ = com.google.protobuf.ByteString.EMPTY; if (lastInstanceBuilder_ == null) { lastInstance_ = null; } else { lastInstance_ = null; lastInstanceBuilder_ = null; } return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.internal_static_org_axesoft_jaxos_network_protobuff_CheckPoint_descriptor; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint getDefaultInstanceForType() { return org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.getDefaultInstance(); } public org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint build() { org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint buildPartial() { org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint result = new org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint(this); result.squadId_ = squadId_; result.timestamp_ = timestamp_; result.content_ = content_; if (lastInstanceBuilder_ == null) { result.lastInstance_ = lastInstance_; } else { result.lastInstance_ = lastInstanceBuilder_.build(); } onBuilt(); return result; } public Builder clone() { return (Builder) super.clone(); } public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.setField(field, value); } public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return (Builder) super.clearField(field); } public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return (Builder) super.clearOneof(oneof); } public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) { return (Builder) super.setRepeatedField(field, index, value); } public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, Object value) { return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint) { return mergeFrom((org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint other) { if (other == org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint.getDefaultInstance()) return this; if (other.getSquadId() != 0) { setSquadId(other.getSquadId()); } if (other.getTimestamp() != 0L) { setTimestamp(other.getTimestamp()); } if (other.getContent() != com.google.protobuf.ByteString.EMPTY) { setContent(other.getContent()); } if (other.hasLastInstance()) { mergeLastInstance(other.getLastInstance()); } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int squadId_ ; /** * <code>optional int32 squadId = 1;</code> */ public int getSquadId() { return squadId_; } /** * <code>optional int32 squadId = 1;</code> */ public Builder setSquadId(int value) { squadId_ = value; onChanged(); return this; } /** * <code>optional int32 squadId = 1;</code> */ public Builder clearSquadId() { squadId_ = 0; onChanged(); return this; } private long timestamp_ ; /** * <code>optional int64 timestamp = 2;</code> */ public long getTimestamp() { return timestamp_; } /** * <code>optional int64 timestamp = 2;</code> */ public Builder setTimestamp(long value) { timestamp_ = value; onChanged(); return this; } /** * <code>optional int64 timestamp = 2;</code> */ public Builder clearTimestamp() { timestamp_ = 0L; onChanged(); return this; } private com.google.protobuf.ByteString content_ = com.google.protobuf.ByteString.EMPTY; /** * <code>optional bytes content = 3;</code> */ public com.google.protobuf.ByteString getContent() { return content_; } /** * <code>optional bytes content = 3;</code> */ public Builder setContent(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } content_ = value; onChanged(); return this; } /** * <code>optional bytes content = 3;</code> */ public Builder clearContent() { content_ = getDefaultInstance().getContent(); onChanged(); return this; } private org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance lastInstance_ = null; private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance, org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder> lastInstanceBuilder_; /** * <code>optional .org.axesoft.jaxos.network.protobuff.Instance lastInstance = 4;</code> */ public boolean hasLastInstance() { return lastInstanceBuilder_ != null || lastInstance_ != null; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.Instance lastInstance = 4;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance getLastInstance() { if (lastInstanceBuilder_ == null) { return lastInstance_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.getDefaultInstance() : lastInstance_; } else { return lastInstanceBuilder_.getMessage(); } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.Instance lastInstance = 4;</code> */ public Builder setLastInstance(org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance value) { if (lastInstanceBuilder_ == null) { if (value == null) { throw new NullPointerException(); } lastInstance_ = value; onChanged(); } else { lastInstanceBuilder_.setMessage(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.Instance lastInstance = 4;</code> */ public Builder setLastInstance( org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder builderForValue) { if (lastInstanceBuilder_ == null) { lastInstance_ = builderForValue.build(); onChanged(); } else { lastInstanceBuilder_.setMessage(builderForValue.build()); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.Instance lastInstance = 4;</code> */ public Builder mergeLastInstance(org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance value) { if (lastInstanceBuilder_ == null) { if (lastInstance_ != null) { lastInstance_ = org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.newBuilder(lastInstance_).mergeFrom(value).buildPartial(); } else { lastInstance_ = value; } onChanged(); } else { lastInstanceBuilder_.mergeFrom(value); } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.Instance lastInstance = 4;</code> */ public Builder clearLastInstance() { if (lastInstanceBuilder_ == null) { lastInstance_ = null; onChanged(); } else { lastInstance_ = null; lastInstanceBuilder_ = null; } return this; } /** * <code>optional .org.axesoft.jaxos.network.protobuff.Instance lastInstance = 4;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder getLastInstanceBuilder() { onChanged(); return getLastInstanceFieldBuilder().getBuilder(); } /** * <code>optional .org.axesoft.jaxos.network.protobuff.Instance lastInstance = 4;</code> */ public org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder getLastInstanceOrBuilder() { if (lastInstanceBuilder_ != null) { return lastInstanceBuilder_.getMessageOrBuilder(); } else { return lastInstance_ == null ? org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.getDefaultInstance() : lastInstance_; } } /** * <code>optional .org.axesoft.jaxos.network.protobuff.Instance lastInstance = 4;</code> */ private com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance, org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder> getLastInstanceFieldBuilder() { if (lastInstanceBuilder_ == null) { lastInstanceBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance, org.axesoft.jaxos.network.protobuff.PaxosMessage.Instance.Builder, org.axesoft.jaxos.network.protobuff.PaxosMessage.InstanceOrBuilder>( getLastInstance(), getParentForChildren(), isClean()); lastInstance_ = null; } return lastInstanceBuilder_; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:org.axesoft.jaxos.network.protobuff.CheckPoint) } // @@protoc_insertion_point(class_scope:org.axesoft.jaxos.network.protobuff.CheckPoint) private static final org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint(); } public static org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser<CheckPoint> PARSER = new com.google.protobuf.AbstractParser<CheckPoint>() { public CheckPoint parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new CheckPoint(input, extensionRegistry); } }; public static com.google.protobuf.Parser<CheckPoint> parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser<CheckPoint> getParserForType() { return PARSER; } public org.axesoft.jaxos.network.protobuff.PaxosMessage.CheckPoint getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } private static final com.google.protobuf.Descriptors.Descriptor internal_static_org_axesoft_jaxos_network_protobuff_DataGram_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_org_axesoft_jaxos_network_protobuff_DataGram_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_org_axesoft_jaxos_network_protobuff_JoinReq_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_org_axesoft_jaxos_network_protobuff_JoinReq_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_org_axesoft_jaxos_network_protobuff_JoinRes_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_org_axesoft_jaxos_network_protobuff_JoinRes_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_org_axesoft_jaxos_network_protobuff_BallotValue_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_org_axesoft_jaxos_network_protobuff_BallotValue_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_org_axesoft_jaxos_network_protobuff_ChosenInfo_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_org_axesoft_jaxos_network_protobuff_ChosenInfo_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_org_axesoft_jaxos_network_protobuff_PrepareReq_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_org_axesoft_jaxos_network_protobuff_PrepareReq_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_org_axesoft_jaxos_network_protobuff_PrepareRes_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_org_axesoft_jaxos_network_protobuff_PrepareRes_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_org_axesoft_jaxos_network_protobuff_AcceptReq_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_org_axesoft_jaxos_network_protobuff_AcceptReq_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_org_axesoft_jaxos_network_protobuff_AcceptRes_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_org_axesoft_jaxos_network_protobuff_AcceptRes_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_org_axesoft_jaxos_network_protobuff_AcceptedNotify_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_org_axesoft_jaxos_network_protobuff_AcceptedNotify_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_org_axesoft_jaxos_network_protobuff_LearnReq_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_org_axesoft_jaxos_network_protobuff_LearnReq_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_org_axesoft_jaxos_network_protobuff_LearnRes_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_org_axesoft_jaxos_network_protobuff_LearnRes_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_org_axesoft_jaxos_network_protobuff_Instance_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_org_axesoft_jaxos_network_protobuff_Instance_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_org_axesoft_jaxos_network_protobuff_SquadChosen_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_org_axesoft_jaxos_network_protobuff_SquadChosen_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_org_axesoft_jaxos_network_protobuff_CheckPoint_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_org_axesoft_jaxos_network_protobuff_CheckPoint_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; } private static com.google.protobuf.Descriptors.FileDescriptor descriptor; static { java.lang.String[] descriptorData = { "\n\017paxos-msg.proto\022#org.axesoft.jaxos.net" + "work.protobuff\"t\n\010DataGram\0227\n\004code\030\001 \001(\016" + "2).org.axesoft.jaxos.network.protobuff.C" + "ode\022\016\n\006sender\030\002 \001(\005\022\021\n\ttimestamp\030\003 \001(\003\022\014" + "\n\004body\030\004 \001(\014\"\221\001\n\007JoinReq\022\r\n\005token\030\001 \001(\014\022" + "\020\n\010hostname\030\002 \001(\014\022\027\n\017partitionNumber\030\003 \001" + "(\005\022\033\n\023jaxosMessageVersion\030\004 \001(\014\022\031\n\021appMe" + "ssageVersion\030\005 \001(\014\022\024\n\014destHostname\030\006 \001(\014" + "\"&\n\007JoinRes\022\016\n\006result\030\001 \001(\005\022\013\n\003msg\030\002 \001(\014" + "\"h\n\013BallotValue\022\n\n\002id\030\001 \001(\003\022<\n\004type\030\002 \001(", "\0162..org.axesoft.jaxos.network.protobuff." + "ValueType\022\017\n\007content\030\003 \001(\014\"I\n\nChosenInfo" + "\022\022\n\ninstanceId\030\001 \001(\003\022\020\n\010ballotId\030\002 \001(\003\022\025" + "\n\relapsedMillis\030\003 \001(\003\"\227\001\n\nPrepareReq\022\017\n\007" + "squadId\030\001 \001(\005\022\022\n\ninstanceId\030\002 \001(\003\022\r\n\005rou" + "nd\030\003 \001(\005\022\020\n\010proposal\030\004 \001(\005\022C\n\nchosenInfo" + "\030\005 \001(\0132/.org.axesoft.jaxos.network.proto" + "buff.ChosenInfo\"\215\002\n\nPrepareRes\022\017\n\007squadI" + "d\030\001 \001(\005\022\022\n\ninstanceId\030\002 \001(\003\022\r\n\005round\030\003 \001" + "(\005\022\016\n\006result\030\004 \001(\005\022\023\n\013maxProposal\030\005 \001(\005\022", "\030\n\020acceptedProposal\030\006 \001(\005\022G\n\racceptedVal" + "ue\030\007 \001(\01320.org.axesoft.jaxos.network.pro" + "tobuff.BallotValue\022C\n\nchosenInfo\030\010 \001(\0132/" + ".org.axesoft.jaxos.network.protobuff.Cho" + "senInfo\"\327\001\n\tAcceptReq\022\017\n\007squadId\030\001 \001(\005\022\022" + "\n\ninstanceId\030\002 \001(\003\022\r\n\005round\030\003 \001(\005\022\020\n\010pro" + "posal\030\004 \001(\005\022?\n\005value\030\005 \001(\01320.org.axesoft" + ".jaxos.network.protobuff.BallotValue\022C\n\n" + "chosenInfo\030\006 \001(\0132/.org.axesoft.jaxos.net" + "work.protobuff.ChosenInfo\"\335\001\n\tAcceptRes\022", "\017\n\007squadId\030\001 \001(\005\022\022\n\ninstanceId\030\002 \001(\003\022\r\n\005" + "round\030\003 \001(\005\022\016\n\006result\030\004 \001(\005\022\023\n\013maxPropos" + "al\030\005 \001(\005\022\030\n\020acceptedBallotId\030\006 \001(\003\022\030\n\020ch" + "osenInstanceId\030\007 \001(\003\022C\n\nchosenInfo\030\010 \001(\013" + "2/.org.axesoft.jaxos.network.protobuff.C" + "hosenInfo\"Y\n\016AcceptedNotify\022\017\n\007squadId\030\001" + " \001(\005\022\022\n\ninstanceId\030\002 \001(\003\022\020\n\010proposal\030\003 \001" + "(\005\022\020\n\010ballotId\030\004 \001(\003\"2\n\010LearnReq\022\017\n\007squa" + "dId\030\001 \001(\005\022\025\n\rlowInstanceId\030\002 \001(\003\"\241\001\n\010Lea" + "rnRes\022\017\n\007squadId\030\001 \001(\005\022?\n\010instance\030\002 \003(\013", "2-.org.axesoft.jaxos.network.protobuff.I" + "nstance\022C\n\ncheckPoint\030\003 \001(\0132/.org.axesof" + "t.jaxos.network.protobuff.CheckPoint\"\202\001\n" + "\010Instance\022\017\n\007squadId\030\001 \001(\005\022\022\n\ninstanceId" + "\030\002 \001(\003\022\020\n\010proposal\030\003 \001(\005\022?\n\005value\030\004 \001(\0132" + "0.org.axesoft.jaxos.network.protobuff.Ba" + "llotValue\"2\n\013SquadChosen\022\017\n\007squadId\030\001 \001(" + "\005\022\022\n\ninstanceId\030\002 \001(\003\"\206\001\n\nCheckPoint\022\017\n\007" + "squadId\030\001 \001(\005\022\021\n\ttimestamp\030\002 \001(\003\022\017\n\007cont" + "ent\030\003 \001(\014\022C\n\014lastInstance\030\004 \001(\0132-.org.ax", "esoft.jaxos.network.protobuff.Instance*\237" + "\001\n\004Code\022\010\n\004NONE\020\000\022\014\n\010JOIN_REQ\020\001\022\014\n\010JOIN_" + "RES\020\002\022\017\n\013PREPARE_REQ\020\003\022\017\n\013PREPARE_RES\020\004\022" + "\016\n\nACCEPT_REQ\020\005\022\016\n\nACCEPT_RES\020\006\022\021\n\rCHOSE" + "N_NOTIFY\020\007\022\r\n\tLEARN_REQ\020\013\022\r\n\tLEARN_RES\020\014" + "*3\n\tValueType\022\013\n\007NOTHING\020\000\022\017\n\013APPLICATIO" + "N\020\001\022\010\n\004NOOP\020\002B\016B\014PaxosMessageb\006proto3" }; com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner = new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() { public com.google.protobuf.ExtensionRegistry assignDescriptors( com.google.protobuf.Descriptors.FileDescriptor root) { descriptor = root; return null; } }; com.google.protobuf.Descriptors.FileDescriptor .internalBuildGeneratedFileFrom(descriptorData, new com.google.protobuf.Descriptors.FileDescriptor[] { }, assigner); internal_static_org_axesoft_jaxos_network_protobuff_DataGram_descriptor = getDescriptor().getMessageTypes().get(0); internal_static_org_axesoft_jaxos_network_protobuff_DataGram_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_org_axesoft_jaxos_network_protobuff_DataGram_descriptor, new java.lang.String[] { "Code", "Sender", "Timestamp", "Body", }); internal_static_org_axesoft_jaxos_network_protobuff_JoinReq_descriptor = getDescriptor().getMessageTypes().get(1); internal_static_org_axesoft_jaxos_network_protobuff_JoinReq_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_org_axesoft_jaxos_network_protobuff_JoinReq_descriptor, new java.lang.String[] { "Token", "Hostname", "PartitionNumber", "JaxosMessageVersion", "AppMessageVersion", "DestHostname", }); internal_static_org_axesoft_jaxos_network_protobuff_JoinRes_descriptor = getDescriptor().getMessageTypes().get(2); internal_static_org_axesoft_jaxos_network_protobuff_JoinRes_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_org_axesoft_jaxos_network_protobuff_JoinRes_descriptor, new java.lang.String[] { "Result", "Msg", }); internal_static_org_axesoft_jaxos_network_protobuff_BallotValue_descriptor = getDescriptor().getMessageTypes().get(3); internal_static_org_axesoft_jaxos_network_protobuff_BallotValue_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_org_axesoft_jaxos_network_protobuff_BallotValue_descriptor, new java.lang.String[] { "Id", "Type", "Content", }); internal_static_org_axesoft_jaxos_network_protobuff_ChosenInfo_descriptor = getDescriptor().getMessageTypes().get(4); internal_static_org_axesoft_jaxos_network_protobuff_ChosenInfo_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_org_axesoft_jaxos_network_protobuff_ChosenInfo_descriptor, new java.lang.String[] { "InstanceId", "BallotId", "ElapsedMillis", }); internal_static_org_axesoft_jaxos_network_protobuff_PrepareReq_descriptor = getDescriptor().getMessageTypes().get(5); internal_static_org_axesoft_jaxos_network_protobuff_PrepareReq_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_org_axesoft_jaxos_network_protobuff_PrepareReq_descriptor, new java.lang.String[] { "SquadId", "InstanceId", "Round", "Proposal", "ChosenInfo", }); internal_static_org_axesoft_jaxos_network_protobuff_PrepareRes_descriptor = getDescriptor().getMessageTypes().get(6); internal_static_org_axesoft_jaxos_network_protobuff_PrepareRes_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_org_axesoft_jaxos_network_protobuff_PrepareRes_descriptor, new java.lang.String[] { "SquadId", "InstanceId", "Round", "Result", "MaxProposal", "AcceptedProposal", "AcceptedValue", "ChosenInfo", }); internal_static_org_axesoft_jaxos_network_protobuff_AcceptReq_descriptor = getDescriptor().getMessageTypes().get(7); internal_static_org_axesoft_jaxos_network_protobuff_AcceptReq_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_org_axesoft_jaxos_network_protobuff_AcceptReq_descriptor, new java.lang.String[] { "SquadId", "InstanceId", "Round", "Proposal", "Value", "ChosenInfo", }); internal_static_org_axesoft_jaxos_network_protobuff_AcceptRes_descriptor = getDescriptor().getMessageTypes().get(8); internal_static_org_axesoft_jaxos_network_protobuff_AcceptRes_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_org_axesoft_jaxos_network_protobuff_AcceptRes_descriptor, new java.lang.String[] { "SquadId", "InstanceId", "Round", "Result", "MaxProposal", "AcceptedBallotId", "ChosenInstanceId", "ChosenInfo", }); internal_static_org_axesoft_jaxos_network_protobuff_AcceptedNotify_descriptor = getDescriptor().getMessageTypes().get(9); internal_static_org_axesoft_jaxos_network_protobuff_AcceptedNotify_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_org_axesoft_jaxos_network_protobuff_AcceptedNotify_descriptor, new java.lang.String[] { "SquadId", "InstanceId", "Proposal", "BallotId", }); internal_static_org_axesoft_jaxos_network_protobuff_LearnReq_descriptor = getDescriptor().getMessageTypes().get(10); internal_static_org_axesoft_jaxos_network_protobuff_LearnReq_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_org_axesoft_jaxos_network_protobuff_LearnReq_descriptor, new java.lang.String[] { "SquadId", "LowInstanceId", }); internal_static_org_axesoft_jaxos_network_protobuff_LearnRes_descriptor = getDescriptor().getMessageTypes().get(11); internal_static_org_axesoft_jaxos_network_protobuff_LearnRes_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_org_axesoft_jaxos_network_protobuff_LearnRes_descriptor, new java.lang.String[] { "SquadId", "Instance", "CheckPoint", }); internal_static_org_axesoft_jaxos_network_protobuff_Instance_descriptor = getDescriptor().getMessageTypes().get(12); internal_static_org_axesoft_jaxos_network_protobuff_Instance_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_org_axesoft_jaxos_network_protobuff_Instance_descriptor, new java.lang.String[] { "SquadId", "InstanceId", "Proposal", "Value", }); internal_static_org_axesoft_jaxos_network_protobuff_SquadChosen_descriptor = getDescriptor().getMessageTypes().get(13); internal_static_org_axesoft_jaxos_network_protobuff_SquadChosen_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_org_axesoft_jaxos_network_protobuff_SquadChosen_descriptor, new java.lang.String[] { "SquadId", "InstanceId", }); internal_static_org_axesoft_jaxos_network_protobuff_CheckPoint_descriptor = getDescriptor().getMessageTypes().get(14); internal_static_org_axesoft_jaxos_network_protobuff_CheckPoint_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_org_axesoft_jaxos_network_protobuff_CheckPoint_descriptor, new java.lang.String[] { "SquadId", "Timestamp", "Content", "LastInstance", }); } // @@protoc_insertion_point(outer_class_scope) }
[ "redbison@126.com" ]
redbison@126.com
03234704fe6e8ffa1a97da50173dc387e1678604
46be6922b789bd4b1666bc791e25ab93b0193d02
/jcoro-app/src/test/java/org/jcoro/tests/TryCatchTest.java
571d807369d9be3f51e53a782a5a966838c2367c
[]
no_license
elw00d/jcoro
d55aa270f60afcb3850cc818391f53bc04d3c7cb
7997b332b27390822d43ca0bce4fd4c26f0b5578
refs/heads/trunk
2020-12-24T19:18:50.520618
2016-04-30T09:21:33
2016-04-30T09:21:33
38,458,316
13
3
null
2015-07-14T21:24:56
2015-07-02T21:40:27
Java
UTF-8
Java
false
false
961
java
package org.jcoro.tests; import org.jcoro.Await; import org.jcoro.Coro; import org.jcoro.ICoroRunnable; import org.jcoro.Async; import org.junit.Test; /** * todo : testify this * * @author elwood */ public class TryCatchTest { public static void main(String[] args) { new TryCatchTest().testCatch(); } @Test public void testCatch() { final Coro coro = Coro.initSuspended(new ICoroRunnable() { @Override @Async(@Await("yield")) public void run() { Coro coro = Coro.get(); try { foo(); coro.yield(); // unreachable System.out.println("unreachable"); } catch (RuntimeException e) { System.out.println("Catched exc"); } } }); coro.resume(); } public void foo() { throw new RuntimeException(); } }
[ "elwood.su@gmail.com" ]
elwood.su@gmail.com
e96ee8f2063b40548238942c82a632dd9f6c3f55
8b744c662e2194ed22dcde31ec1b17b03f3f9f30
/app/src/main/java/com/example/mijin/hue/ProjectTab/Tab2/ProjectTabFragment2.java
c23aba3508b897af710c8ca81591d0feb0051353
[]
no_license
HA2016/Hue
8dd1011ac183f19f39c3358a80da6bb16c2b1cb4
daeb964030e93a9e5bda316ebb6a8179fbc0617c
refs/heads/master
2021-07-08T15:04:35.418563
2017-10-07T03:27:05
2017-10-07T03:27:05
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,055
java
package com.example.mijin.hue.ProjectTab.Tab2; import android.content.Intent; import android.os.Bundle; import android.support.annotation.Nullable; import android.support.v4.app.Fragment; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.AdapterView; import android.widget.ListView; import com.example.mijin.hue.R; import java.util.Date; /** * Created by mijin on 2017-10-03. */ public class ProjectTabFragment2 extends Fragment { View tab2; public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) { tab2 = inflater.inflate(R.layout.fragment_project_tab2, container, false); ListView listView = (ListView) tab2.findViewById(R.id.documentList); DocumentViewAdapter adapter; adapter = new DocumentViewAdapter(); listView.setAdapter(adapter); adapter.addItem("회의문서#10", new Date(), new Date(), "dd, aa, cc"); adapter.addItem("회의문서#9", new Date(), new Date(), "dd, cc"); adapter.addItem("회의문서#8", new Date(), new Date(), "dd"); adapter.addItem("회의문서#7", new Date(), new Date(), "dd"); adapter.addItem("회의문서#6", new Date(), new Date(), "dd"); adapter.addItem("회의문서#5", new Date(), new Date(), "dd"); adapter.addItem("회의문서#4", new Date(), new Date(), "dd"); adapter.addItem("회의문서#3", new Date(), new Date(), "dd"); adapter.addItem("회의문서#2", new Date(), new Date(), "dd"); adapter.addItem("회의문서#1", new Date(), new Date(), "dd"); listView.setOnItemClickListener(new AdapterView.OnItemClickListener(){ @Override public void onItemClick(AdapterView<?> adapterView, View view, int i, long l) { Intent intent = new Intent(tab2.getContext(), DocumentDetailActivity.class); startActivity(intent); } }); return tab2; } }
[ "30946850+Bobgoodd@users.noreply.github.com" ]
30946850+Bobgoodd@users.noreply.github.com
8e48626b0a48cb39213dc1c0939f5e68b5cb3ad9
09dc524d12f831b1e7893a14877840026a657784
/TrafficColector/src/ro/pub/acs/traffic/utils/CryptTool.java
4cd2314ad27e8e57d75e5e3f1a5c70b484d52057
[]
no_license
cristian9radu/Traffic-Collector
f25a57dad888f73fe64bf45a918b5d74561f5278
27ef222e0eab16af6aec98ecdcc160c18ce780e5
refs/heads/master
2016-09-05T19:02:42.477041
2015-01-17T19:51:06
2015-01-17T19:51:06
29,403,634
0
0
null
null
null
null
UTF-8
Java
false
false
2,759
java
package ro.pub.acs.traffic.utils; import javax.crypto.Cipher; import javax.crypto.SecretKey; import javax.crypto.SecretKeyFactory; import javax.crypto.spec.DESedeKeySpec; import javax.crypto.spec.IvParameterSpec; import android.util.*; public class CryptTool { private static final String SHARED_KEY = "XtHVMwLjtxq5ilOpSGHmc2PSvoQ9W0wv9taPREsj"; private static String algorithm = "DESede"; private static String transformation = "DESede/CBC/PKCS5Padding"; private SecretKey key; private IvParameterSpec iv; public CryptTool(){ DESedeKeySpec keySpec; byte[] keyValue = SHARED_KEY.getBytes(); try { keySpec = new DESedeKeySpec(keyValue); /* Initialization Vector of 8 bytes set to zero. */ iv = new IvParameterSpec(new byte[8]); key = SecretKeyFactory.getInstance(algorithm).generateSecret(keySpec); } catch (Exception e) { e.printStackTrace(); } } public String encrypt(String str) { String encryptedString = null; try { Cipher encrypter = Cipher.getInstance(transformation); encrypter.init(Cipher.ENCRYPT_MODE, key, iv); byte[] input = str.getBytes("UTF-8"); byte[] encrypted = encrypter.doFinal(input); encryptedString = Base64.encodeToString(encrypted, Base64.NO_WRAP); } catch (Exception e) { e.printStackTrace(); } return encryptedString; } public String decrypt(String encryptedString) { String decryptedText=null; try { Cipher decrypter = Cipher.getInstance(transformation); decrypter.init(Cipher.DECRYPT_MODE, key, iv); byte[] encryptedText = Base64.decode(encryptedString, Base64.NO_WRAP); byte[] plainText = decrypter.doFinal(encryptedText); decryptedText= bytes2String(plainText); } catch (Exception e) { e.printStackTrace(); } return decryptedText; } /** * Returns String From An Array Of Bytes */ public static String bytes2String(byte[] bytes) { StringBuffer stringBuffer = new StringBuffer(); for (int i = 0; i < bytes.length; i++) { stringBuffer.append((char) bytes[i]); } return stringBuffer.toString(); } /** * Testing The DESede Encryption And Decryption Technique */ public static void main(String args []) throws Exception { CryptTool myEncryptor= new CryptTool(); String stringToEncrypt="bitbestebita"; String encrypted = myEncryptor.encrypt(stringToEncrypt); String decrypted = myEncryptor.decrypt(encrypted); System.out.println("String To Encrypt: "+stringToEncrypt); System.out.println("Encrypted Value :" + encrypted); System.out.println("Decrypted Value :"+decrypted); } }
[ "cristisor87@yahoo.com" ]
cristisor87@yahoo.com
f161728fabacc6c266035221cdd819b7c627862b
a39165b1b533a90a9583c7ef5b3df491b807d448
/src/Beans/beans/produtos/BeanProduto.java
1cf4e0bdefca1dccbea9e177ba86203b9c7ea886
[]
no_license
thiaguerd/fisiotec
23488c72d8e0b5e6ce689b5dd8d7ed598a8e921e
ca09a657546521e5cf4306f57f5252e4874f0675
refs/heads/main
2023-01-05T09:11:49.846832
2020-10-28T23:43:51
2020-10-28T23:43:51
308,167,326
0
0
null
null
null
null
UTF-8
Java
false
false
18,988
java
package beans.produtos; import beans.listas.BeanListProdutos; import beans.listas.BeanListUnidades; import cp.estoque.CPAlertasQuantidadeProduto; import cp.estoque.CPProduto; import cp.estoque.CPUnidadeDeMedida; import cp.estoque.entrada.CPEntradaProduto; import cp.estoque.saida.CPSaidaProduto; import cp.grafico.entrada.custom.CPGraficoEntradaCustomProdutos; import cp.grafico.entrada.preDeterminado.CPGraficoEntradaPreDeterminadoProdutos; import cp.grafico.entradasaida.custom.CPGraficoEntradaSaidaCustomProdutos; import cp.grafico.entradasaida.preDeterminado.CPGraficoEntradaSaidaPreDeterminadoProdutos; import cp.grafico.saida.custom.CPGraficoSaidaCustomProdutos; import cp.grafico.saida.preDeterminado.CPGraficoSaidaPreDeterminadoProdutos; import dao.estoque.DaoAlertasQuantidadeProduto; import dao.estoque.DaoProduto; import dao.estoque.DaoUnidadeDeMedida; import dao.estoque.entrada.DaoEntradaProduto; import dao.estoque.saida.DaoSaidaProduto; import dao.grafico.entrada.custom.DaoGraficoEntradaCustomProdutos; import dao.grafico.entrada.preDeterminada.DaoGraficoEntradaPreDeterminadaProdutos; import dao.grafico.entradaSaida.custom.DaoGraficoEntradaSaidaCustomProdutos; import dao.grafico.entradaSaida.preDeterminada.DaoGraficoEntradaSaidaPreDeterminadoProdutos; import dao.grafico.saida.custom.DaoGraficoSaidaCustomProdutos; import dao.grafico.saida.predeterminada.DaoGraficoSaidaPredeterminadaProdutos; import java.io.Serializable; import java.util.LinkedList; import java.util.List; import javax.faces.bean.ManagedBean; import javax.faces.bean.ViewScoped; import utilidades.mensagens.UtilMensagens; @ManagedBean(name = "prod") @ViewScoped public class BeanProduto implements Serializable { private static final long serialVersionUID = 1L; private List<String> tiposDeBuscarPorNome = new LinkedList<>(); private int posTiposDeBuscarPorNome = 0; //#DELETAR 0 - simples | 1 - completa private String deletarCompletamente = "0"; //#MEDIDA private double medidaMenor; private double medidaMaior; //#QUANIDADE private int quantidadeMenor; private int quantidadeMaior; private String operadorLogicoDaMedida = "e"; private String operadorLogicoDaQuantidade = "e"; private String resultadoTextualBusca = ""; //REVISTO public void updateProduto(CPUnidadeDeMedida unidade, BeanListProdutos lp) { lp.getProdutoManipulado().setUnidadeDeMedida(unidade); lp.getProdutoManipulado().setId(lp.getProdutoManipulado().getId()); lp.removeProdIndexDaListProd(); lp.addProdutoNaLista(lp.getProdutoManipulado()); } public void mergeUnidade(BeanListUnidades u) { DaoUnidadeDeMedida.merge(u.getUnidade()); UtilMensagens.ok(UtilMensagens.unidadeRegistrada); u.setUnidade(new CPUnidadeDeMedida()); } public void pesquisaAvancada(BeanListProdutos lp, BeanListUnidades lu) { resultadoTextualBusca = "Buscando por"; lp.zeraManipulados(); for (CPProduto produtoDaVez : lp.getProdutos()) { /* * lógica do validador: pode usar ou não um filtro e se usado, pode * excluir ou incluir um produto se não se usa o filtro = 0 se usa o * filtro e inclui = 1 se usa o filtro e exclui = 2 */ //validando pelo nome boolean validaPeloNome = true; if (!lp.getProdutoManipulado().getNome().equals("")) { switch (posTiposDeBuscarPorNome) { case 0: if (!produtoDaVez.getNome().toLowerCase().startsWith(lp.getProdutoManipulado().getNome().toLowerCase())) { validaPeloNome = false; } break; case 1: if (!produtoDaVez.getNome().toLowerCase().contains(lp.getProdutoManipulado().getNome().toLowerCase())) { validaPeloNome = false; } break; case 2: if (!produtoDaVez.getNome().toLowerCase().endsWith(lp.getProdutoManipulado().getNome().toLowerCase())) { validaPeloNome = false; } break; } } //validando pela unidade boolean validaPelaUnidade = false; if (lu.getIndexSListaUnidade().isEmpty()) {//há algum validador de unidade? validaPelaUnidade = true; } else if (lu.getIndexSListaUnidade().contains("qualquer")) {//entre eles há o validador "qualquer?" validaPelaUnidade = true; } else if (lu.getIdUnidadesIndexadas().contains(produtoDaVez.getId())) {//confere se o ID da unidade do produto da vez está entre os validadores validaPelaUnidade = true; } //Validadando pela medida boolean validaPelaMedida = true; if (medidaMaior != 0 && medidaMenor != 0) { if (operadorLogicoDaMedida.equals("e")) { if (!(produtoDaVez.getMedida() > medidaMaior && produtoDaVez.getMedida() < medidaMenor)) { validaPelaMedida = false; } } else { if (!(produtoDaVez.getMedida() > medidaMaior || produtoDaVez.getMedida() < medidaMenor)) { validaPelaMedida = false; } } } else { if (medidaMaior != 0) { if (!(produtoDaVez.getMedida() > medidaMaior)) { validaPelaMedida = false; } } if (medidaMenor != 0) { if (!(produtoDaVez.getMedida() < medidaMenor)) { validaPelaMedida = false; } } } //validando pela quantidade boolean validaPelaQuantidade = true; if (quantidadeMaior != 0 && quantidadeMenor != 0) { if (operadorLogicoDaMedida.equals("e")) { if (!(produtoDaVez.getQuantidadeEmStoque() > quantidadeMaior && produtoDaVez.getQuantidadeEmStoque() < quantidadeMenor)) { validaPelaQuantidade = false; } } else { if (!(produtoDaVez.getQuantidadeEmStoque() > quantidadeMaior || produtoDaVez.getQuantidadeEmStoque() < quantidadeMenor)) { validaPelaQuantidade = false; } } } else { if (quantidadeMaior != 0) { if (!(produtoDaVez.getQuantidadeEmStoque() > quantidadeMaior)) { validaPelaQuantidade = false; } } if (quantidadeMenor != 0) { if (!(produtoDaVez.getQuantidadeEmStoque() < quantidadeMenor)) { validaPelaQuantidade = false; } } } //confere validadores if (validaPeloNome && validaPelaUnidade && validaPelaMedida && validaPelaQuantidade) { lp.addProdutoNaListaManipulada(produtoDaVez); } } //escrevendo consulta textutual //nome if (!lp.getProdutoManipulado().getNome().equals("")) { resultadoTextualBusca += " produtos que"; switch (posTiposDeBuscarPorNome) { case 0: resultadoTextualBusca += " iniciam seus nomes com \"" + lp.getProdutoManipulado().getNome() + "\""; break; case 1: resultadoTextualBusca += " possuam em seus nomes: \"" + lp.getProdutoManipulado().getNome() + "\""; break; case 2: resultadoTextualBusca += " terminem seus nomes com \"" + lp.getProdutoManipulado().getNome() + "\""; break; } } else { resultadoTextualBusca += " produtos com qualquer nome"; } //unidade //se há mais de um selecionado resultadoTextualBusca += " que a unidade seja"; if (lu.getIndexSListaUnidade().size() > 0) { //se um dos selecionado é qualquer if (!lu.getIndexSListaUnidade().contains("qualquer")) { //se há mais de um selecionado if (lu.getIndexSListaUnidade().size() > 1) { for (String index : lu.getIndexSListaUnidade()) { if (lu.getIndexSListaUnidade().indexOf(index) == lu.getIndexSListaUnidade().size() - 1) { resultadoTextualBusca += " \"" + lu.getUnidades().get(Integer.parseInt(index)).getNome() + "\""; } else { resultadoTextualBusca += " \"" + lu.getUnidades().get(Integer.parseInt(index)).getNome() + "\", ou que seja"; } } } else { resultadoTextualBusca += " \"" + lu.getUnidades().get(Integer.parseInt(lu.getIndexSListaUnidade().get(0))).getNome() + "\""; } } else { resultadoTextualBusca += " qualquer uma"; } } else { resultadoTextualBusca += " qualquer uma"; } //medida resultadoTextualBusca += ", que a medida seja"; if (medidaMaior != 0 && medidaMenor != 0) { if (operadorLogicoDaMedida.equals("e")) { resultadoTextualBusca += " maior que: " + medidaMaior + " e menor que: " + medidaMenor; } else { resultadoTextualBusca += " maior que: " + medidaMaior + " ou menor que: " + medidaMenor; } } else { if (medidaMaior != 0) { resultadoTextualBusca += " maior que: " + medidaMaior + ""; } else { if (medidaMenor != 0) { resultadoTextualBusca += " menor que: " + medidaMenor + ""; } else { resultadoTextualBusca += " qualquer uma"; } } } //quantidade resultadoTextualBusca += ", que a quantidade seja"; //se há algo em ambos campos if (quantidadeMaior != 0 && quantidadeMenor != 0) { // se o operador seja E if (operadorLogicoDaQuantidade.equals("e")) { resultadoTextualBusca += " maior que: " + quantidadeMaior + " e menor que: " + quantidadeMenor; } else { resultadoTextualBusca += " maior que: " + quantidadeMaior + " ou menor que: " + quantidadeMenor; } } else { if (quantidadeMaior != 0) { resultadoTextualBusca += " maior que: " + quantidadeMaior + ""; } else { if (quantidadeMenor != 0) { resultadoTextualBusca += " menor que: " + quantidadeMenor + ""; } else { resultadoTextualBusca += " qualquer uma"; } } } UtilMensagens.info(UtilMensagens.buscaRealizada.replace("VR1", lp.getProdutosManipulados().size() + " resultados.")); } public void pesquisaSimples(BeanListProdutos lp) { lp.zeraManipulados(); for (CPProduto p : lp.getProdutos()) { if (p.getNome().toLowerCase().startsWith(lp.getProdutoManipulado().getNome().toLowerCase())) { lp.getProdutosManipulados().add(p); } } if (lp.getProdutosManipulados().isEmpty()) { UtilMensagens.alerta(UtilMensagens.buscaVazia); } else { UtilMensagens.ok(UtilMensagens.buscaRealizada.replace("VR1", lp.getProdutosManipulados().size() + " resultados.")); } } public void mergProduto(BeanListProdutos lp, BeanListUnidades lu) { lp.getProdutoManipulado().setUnidadeDeMedida(lu.unidadeManipuladaPos()); DaoProduto.merge(lp.getProdutoManipulado()); lp.setProdutoManipulado(new CPProduto()); lu.setPosManipulado(-1); UtilMensagens.ok(UtilMensagens.produtoCadastrado); } public void deletaProduto(BeanListProdutos lp) { //CPProduto está relacionado com outras 7 (SEIS) tabelas //# CPSaidaProduto List<CPSaidaProduto> buscaPorProdutos = DaoSaidaProduto.buscaPorProdutos(lp.getProdutoManipulado()); for (CPSaidaProduto sp : buscaPorProdutos) { DaoSaidaProduto.delete(sp); } System.out.println("deletou CPSaidaProduto " + buscaPorProdutos.size()); //# CPEntradaProduto List<CPEntradaProduto> buscaPorProduto = DaoEntradaProduto.buscaPorProduto(lp.getProdutoManipulado()); for (CPEntradaProduto ep : buscaPorProduto) { DaoEntradaProduto.delete(ep); } System.out.println("deletou CPEntradaProduto " + buscaPorProduto.size()); //# CPGraficoSaidaCustomProdutos //# CPGraficoSaidaPreDeterminadoProdutos List<CPGraficoSaidaCustomProdutos> porProdutos = new DaoGraficoSaidaCustomProdutos().getPorProdutos(lp.getProdutoManipulado()); List<CPGraficoSaidaPreDeterminadoProdutos> porProdutos1 = new DaoGraficoSaidaPredeterminadaProdutos().getPorProdutos(lp.getProdutoManipulado()); for (CPGraficoSaidaPreDeterminadoProdutos cpgspdp : porProdutos1) { new DaoGraficoSaidaPredeterminadaProdutos().deleta(cpgspdp); } System.out.println("deletou CPGraficoSaidaPreDeterminadoProdutos " + porProdutos1.size()); for (CPGraficoSaidaCustomProdutos xx : porProdutos) { new DaoGraficoSaidaCustomProdutos().deleta(xx); } System.out.println("deletou CPGraficoSaidaCustomProdutos " + porProdutos.size()); //# CPGraficoEntradaPreDeterminadoProdutos //# CPGraficoEntradaCustomProdutos List<CPGraficoEntradaCustomProdutos> porProdutos2 = new DaoGraficoEntradaCustomProdutos().getPorProdutos(lp.getProdutoManipulado()); for (CPGraficoEntradaCustomProdutos xx : porProdutos2) { new DaoGraficoEntradaCustomProdutos().deleta(xx); } System.out.println("deletou CPGraficoEntradaCustomProdutos " + porProdutos2.size()); List<CPGraficoEntradaPreDeterminadoProdutos> porProdutos3 = new DaoGraficoEntradaPreDeterminadaProdutos().getPorProdutos(lp.getProdutoManipulado()); for (CPGraficoEntradaPreDeterminadoProdutos xx : porProdutos3) { new DaoGraficoEntradaPreDeterminadaProdutos().deleta(xx); } System.out.println("deletou CPGraficoEntradaPreDeterminadoProdutos " + porProdutos3.size()); //# entrada saida custom e pre List<CPGraficoEntradaSaidaCustomProdutos> porProdutos4 = new DaoGraficoEntradaSaidaCustomProdutos().getPorProdutos(lp.getProdutoManipulado()); List<CPGraficoEntradaSaidaPreDeterminadoProdutos> porProdutos5 = new DaoGraficoEntradaSaidaPreDeterminadoProdutos().getPorProdutos(lp.getProdutoManipulado()); for (CPGraficoEntradaSaidaCustomProdutos xx : porProdutos4) { new DaoGraficoEntradaSaidaCustomProdutos().deleta(xx); } System.out.println("deletou CPGraficoEntradaSaidaCustomProdutos " + porProdutos4.size()); for (CPGraficoEntradaSaidaPreDeterminadoProdutos xx : porProdutos5) { new DaoGraficoEntradaSaidaPreDeterminadoProdutos().deleta(xx); } System.out.println("deletou CPGraficoEntradaSaidaPreDeterminadoProdutos " + porProdutos5.size()); //alertas List<CPAlertasQuantidadeProduto> porProduto = DaoAlertasQuantidadeProduto.getPorProdutoAll(lp.getProdutoManipulado()); for (CPAlertasQuantidadeProduto xx : porProduto) { DaoAlertasQuantidadeProduto.deleta(xx); } System.out.println("deletou CPAlertasQuantidadeProduto " + porProduto.size()); DaoProduto.deleta(lp.getProdutoManipulado()); UtilMensagens.ok(UtilMensagens.produtoRemovido); } public void updateProduto(BeanListProdutos p, BeanListUnidades u) { if (!(p.getProdutoManipulado().getUnidadeDeMedida().getId() == u.unidadeReferenteAoId().getId())) { p.getProdutoManipulado().setUnidadeDeMedida(u.unidadeReferenteAoId()); } DaoProduto.merge(p.getProdutoManipulado()); p.atualizaProdutoNaLista(p.getProdutoManipulado()); UtilMensagens.ok(UtilMensagens.produtoAtualizado); } //Get e Set public BeanProduto() { tiposDeBuscarPorNome.add("Inicie com"); tiposDeBuscarPorNome.add("Contenha"); tiposDeBuscarPorNome.add("Termine com"); } public int getPosTiposDeBuscarPorNome() { return posTiposDeBuscarPorNome; } public void setPosTiposDeBuscarPorNome(int posTiposDeBuscarPorNome) { this.posTiposDeBuscarPorNome = posTiposDeBuscarPorNome; } public List<String> getTiposDeBuscarPorNome() { return tiposDeBuscarPorNome; } public void setTiposDeBuscarPorNome(List<String> tiposDeBuscarPorNome) { this.tiposDeBuscarPorNome = tiposDeBuscarPorNome; } public double getMedidaMaior() { return medidaMaior; } public void setMedidaMaior(double medidaMaior) { this.medidaMaior = medidaMaior; } public double getMedidaMenor() { return medidaMenor; } public void setMedidaMenor(double medidaMenor) { this.medidaMenor = medidaMenor; } public int getQuantidadeMaior() { return quantidadeMaior; } public void setQuantidadeMaior(int quantidadeMaior) { this.quantidadeMaior = quantidadeMaior; } public int getQuantidadeMenor() { return quantidadeMenor; } public void setQuantidadeMenor(int quantidadeMenor) { this.quantidadeMenor = quantidadeMenor; } public String getOperadorLogicoDaMedida() { return operadorLogicoDaMedida; } public void setOperadorLogicoDaMedida(String operadorLogicoDaMedida) { this.operadorLogicoDaMedida = operadorLogicoDaMedida; } public String getOperadorLogicoDaQuantidade() { return operadorLogicoDaQuantidade; } public void setOperadorLogicoDaQuantidade(String operadorLogicoDaQuantidade) { this.operadorLogicoDaQuantidade = operadorLogicoDaQuantidade; } public String getResultadoTextualBusca() { return resultadoTextualBusca; } public void setResultadoTextualBusca(String resultadoTextualBusca) { this.resultadoTextualBusca = resultadoTextualBusca; } public String getDeletarCompletamente() { return deletarCompletamente; } public void setDeletarCompletamente(String deletarCompletamente) { this.deletarCompletamente = deletarCompletamente; } }
[ "mail@thiago.pro" ]
mail@thiago.pro
a95b5eb84a59714be9517d491b399d98c79219f9
ff7c59759059536c9e2e9c459e19af512985ee4d
/src/test/integration/mx/bancomer/core/client/full/ConfigurationTest.java
3c6eb4daa5cb67579f9947b6c260e14f34506794
[ "Apache-2.0" ]
permissive
gusLopezC/BBVA-JAVA
e6ad09ba0cba72a53cb29a1de7f506c4610c548a
2ad7881e9d1948880c537bd18ad38f671713550f
refs/heads/master
2023-07-07T02:14:01.305030
2019-06-26T23:05:51
2019-06-26T23:05:51
278,940,597
0
0
Apache-2.0
2022-12-24T20:54:33
2020-07-11T20:57:12
null
UTF-8
Java
false
false
2,758
java
/* * Copyright 2013 Opencard 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 mx.bbva.core.client.full; import mx.bbva.client.core.BbvaAPI; import mx.bbva.client.exceptions.ServiceException; import mx.bbva.client.exceptions.ServiceUnavailableException; import org.junit.Ignore; import org.junit.Test; import java.util.TimeZone; import static mx.bbva.core.client.TestConstans.*; import static org.junit.Assert.*; /** * @author elopez */ public class ConfigurationTest { @Test public void testNoAPIKey() throws Exception { BbvaAPI api = new BbvaAPI(ENDPOINT.replace("https", "http"), null, MERCHANT_ID); try { api.customers().list(null); fail(); } catch (ServiceException e) { assertEquals(401, e.getHttpCode().intValue()); } TimeZone.setDefault(TimeZone.getTimeZone("Mexico/General")); } @Ignore @Test public void testForceHttps() throws Exception { BbvaAPI api = new BbvaAPI(ENDPOINT.replace("https", "http"), API_KEY, MERCHANT_ID); assertNotNull(api.customers().list(null)); } @Test(expected = ServiceUnavailableException.class) public void testNoConnection() throws Exception { BbvaAPI api = new BbvaAPI("http://localhost:9090", API_KEY, MERCHANT_ID); api.customers().list(null); } @Ignore @Test public void testAddHttps() throws Exception { BbvaAPI api = new BbvaAPI(ENDPOINT.replace("https://", ""), API_KEY, MERCHANT_ID); assertNotNull(api.customers().list(null)); } @Test(expected = IllegalArgumentException.class) public void testNullMerchant() throws Exception { new BbvaAPI(ENDPOINT.replace("https://", ""), API_KEY, null); } @Test public void testWrongMerchant() throws Exception { BbvaAPI api = new BbvaAPI(ENDPOINT, API_KEY, "notexists"); try { api.customers().list(null); fail(); } catch (ServiceException e) { assertEquals(401, e.getHttpCode().intValue()); } } @Test(expected = IllegalArgumentException.class) public void testNullLocation() throws Exception { new BbvaAPI(null, API_KEY, MERCHANT_ID); } }
[ "manuel.guevara@openpay.mx" ]
manuel.guevara@openpay.mx