This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * 解决listview向上滑动刷新的bug | |
| */ | |
| mListView.setOnScrollListener(new AbsListView.OnScrollListener() { | |
| @Override | |
| public void onScrollStateChanged(AbsListView view, int scrollState) { | |
| } | |
| @Override |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * <p>Helper class for managing multiple running embedded activities in the same | |
| * process. This class is not normally used directly, but rather created for | |
| * you as part of the {@link android.app.ActivityGroup} implementation. | |
| * | |
| * @see ActivityGroup | |
| * | |
| * @deprecated Use the new {@link Fragment} and {@link FragmentManager} APIs | |
| * instead; these are also | |
| * available on older platforms through the Android compatibility package. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public String reverseString(String data){ | |
| return new StringBuffer(data).reverse().toString(); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public boolean eMailValidations(String emailstring){ | |
| Pattern emailPattern = Pattern.compile(".+@.+\\.[a-z]+"); | |
| Matcher emailMatcher = emailPattern.matcher(emailstring); | |
| return emailMatcher.matches(); | |
| } | |
| //call method | |
| eMailValidations("jet@jet.com"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.example; | |
| import java.util.ArrayList; | |
| import java.util.List; | |
| public class MyClass { | |
| public static void main(String[] args){ | |
| UserBuild mUserBuild = new UserBuild("INTEGER"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| private Toolbar toolbar; | |
| @Override | |
| protected void onCreate(Bundle savedInstanceState) { | |
| super.onCreate(savedInstanceState); | |
| setContentView(getLayoutResource()); | |
| toolbar = (Toolbar) findViewById(R.id.toolbar); | |
| if (toolbar != null) { | |
| setSupportActionBar(toolbar); |
NewerOlder