@Override
  protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);

    intent = getIntent();

    originalPicturePath = intent.getStringExtra(INTENT_ORIGINAL_PICTURE_PATH);
    cuttedWidth = intent.getIntExtra(INTENT_CUT_WIDTH, 0);
    cuttedHeight = intent.getIntExtra(INTENT_CUT_HEIGHT, 0);
    if (cuttedWidth <= 0) {
      cuttedWidth = cuttedHeight;
    }
    if (cuttedHeight <= 0) {
      cuttedHeight = cuttedWidth;
    }

    if (StringUtil.isNotEmpty(originalPicturePath, true) == false || cuttedWidth <= 0) {
      Log.e(
          TAG,
          "onCreate  StringUtil.isNotEmpty(originalPicturePath, true)"
              + " == false || cuttedWidth <= 0 >> finish(); return;");
      showShortToast("图片不存在,请先选择图片");
      finish();
      return;
    }

    // 功能归类分区方法,必须调用<<<<<<<<<<
    initData();
    initView();
    initEvent();
    // 功能归类分区方法,必须调用>>>>>>>>>>

  }
  /**
   * 判断是否已存
   *
   * @param key
   * @return
   */
  public boolean isContain(String key) {
    if (StringUtil.isNotEmpty(key, true) == false) {
      Log.e(TAG, "isContain StringUtil.isNotEmpty(key, true) == false >> return false;");
      return false;
    }

    return sp.contains(StringUtil.getTrimedString(key));
  }
  /**
   * 保存
   *
   * @param key
   * @param value
   */
  public void save(String key, T value) {
    if (StringUtil.isNotEmpty(key, true) == false || value == null) {
      Log.e(TAG, "save StringUtil.isNotEmpty(key, true) == false || value == null >> return;");
      return;
    }
    key = StringUtil.getTrimedString(key);

    sp.edit().remove(key).putString(key, Json.toJSONString(value)).commit();
  }
  /**
   * 获取
   *
   * @param key
   * @return
   */
  public T get(String key) {
    if (StringUtil.isNotEmpty(key, true) == false) {
      Log.e(
          TAG,
          "get (sp == null" + " || StringUtil.isNotEmpty(key, true) == false >> return null; ");
      return null;
    }

    return Json.parseObject(sp.getString(StringUtil.getTrimedString(key), null), clazz);
  }
  @Override
  public void initData() { // 必须调用
    super.initData();

    intent = getIntent();
    packageName = intent.getStringExtra(INTENT_PACKAGE_NAME);

    intentType = intent.getIntExtra(INTENT_TYPE, 0);
    if (StringUtil.isNotEmpty(intent.getStringExtra(INTENT_KEY), true)) {
      tvEditTextInfoTitle.setText(StringUtil.getCurrentString());
    }
    etEditTextInfo.setSingleLine(intentType != TYPE_NOTE);

    switch (intentType) {
      case TYPE_NICK:
        MaxLen = 20;
        break;
      case TYPE_PHONE:
        etEditTextInfo.setInputType(InputType.TYPE_CLASS_PHONE);
        MaxLen = 11;
        break;
      case TYPE_EMAIL:
        etEditTextInfo.setInputType(InputType.TYPE_TEXT_VARIATION_EMAIL_ADDRESS);
        MaxLen = 60;
        break;
      case TYPE_WEBSITE:
        etEditTextInfo.setInputType(InputType.TYPE_TEXT_VARIATION_WEB_EDIT_TEXT);
        MaxLen = 60;
        break;
      case TYPE_MAILADDRESS:
        MaxLen = 60;
        break;
      case TYPE_PROFESSION:
        tvEditTextInfoRemind.setText("所属行业");
        MaxLen = 15;
      case TYPE_NOTE:
        MaxLen = 100;
        break;
      default:
        MaxLen = 30;
        break;
    }
    etEditTextInfo.setMaxEms(MaxLen);
    tvEditTextInfoRemind.setText("限" + MaxLen / 2 + "个字(或" + MaxLen + "个字符)");

    if (intentType == TYPE_MAILADDRESS || intentType == TYPE_USUALADDRESS) {
      tvEditTextInfoPlace.setVisibility(View.VISIBLE);
      CommonUtil.toActivity(
          context,
          PlacePickerWindow.createIntent(context, packageName, 2),
          REQUEST_TO_PLACE_PICKER,
          false);
    }
  }
  /**
   * 删除
   *
   * @param key
   */
  public void delete(String key) {
    if (StringUtil.isNotEmpty(key, true) == false) {
      Log.e(
          TAG,
          "deleteGroup  context == null "
              + " || StringUtil.isNotEmpty(groupName, true) == fal >> return;");
      return;
    }

    sp.edit().remove(StringUtil.getTrimedString(key)).commit();
  }