jmessage_flutter 0.2.0

QQ Group pub package

jmessage_flutter #

安装 #

在工程 pubspec.yaml 中加入 dependencies

dependencies:
  jmessage_flutter: 0.2.0

配置 #

/android/app/build.gradle 中添加下列代码:

android {
    ......
    defaultConfig {
        applicationId "com.xxx.xxx" //JPush上注册的包名.
        ......

        ndk {
            //选择要添加的对应cpu类型的.so库。
            abiFilters 'armeabi', 'armeabi-v7a', 'armeabi-v8a'
            // 还可以添加 'x86', 'x86_64', 'mips', 'mips64'
        }

        manifestPlaceholders = [
            JPUSH_PKGNAME : applicationId,
            JPUSH_APPKEY : "你的appkey", //JPush上注册的包名对应的appkey.
            JPUSH_CHANNEL : "developer-default", //暂时填写默认值即可.
        ]
        ......
    }
    ......
}

使用 #

import 'package:jmessage_flutter/jmessage_flutter.dart';

APIs #

注意 : 需要先调用 JmessageFlutter().init 来初始化插件,才能保证其它功能正常工作。

参考

0.2.0 #

fix: 1、新增:消息撤回类型消息; 2、修复:Group 和 GroupInfo 属性 maxMemberCount 改为 int 类型; 3、修复:获取我的群组 crash

0.1.0 #

fix: 1、修复:createMessage 方法中经纬度为 int 的错误; 2、修复:在 Android 下 GroupInfo 的属性 maxMemberCount 为 int 的错误; 3、修复:消息撤回事件回调中 message 为 null 的错误; 4、修复:监听不到入群申请通知事件的 bug ;

0.0.20 #

fix: 1、修改: sendLocationMessage 方法经纬度参数改为 double 类型

0.0.19 #

fix: 1、修复:Android 接收消息时 flutter 没回调问题 2、适配 Android 最新 SDK 3、修改代码书写错误

0.0.18 #

fix: 1、添加 iOS 端 apns 注册方法 2、修复:Android 端 serverMessageId 超过 int 存储范围问题; 3、更新到最新版本 JMessage SDK

0.0.17 #

fix: 1、修复IOS发送文件消息获取不到文件问题

0.0.16 #

fix: 1、修复发送自定义消息解析失败的bug 2、修复安卓端exitConversation没有回调的问题。 3、升级安卓端JMessage sdk版本2.8.2

0.0.15 #

fix: 1.修复getHistoryMessages 安卓和ios的消息排序不一致 2.修复updateMyInfo 的参数缺失问题。

0.0.14 #

fix: contact event username is null bug

0.0.13 #

feature: getHistoryMessages parameters add isDescend-option.

0.0.12 #

feature: onLoginStateChanged add user_kicked event.

0.0.11 #

fix: jmessage login api remove without avatar path error.

0.0.10 #

fix: updateGroupInfo update desc error. new feature: add extras field in JMConversationInfo.

0.0.9 #

fix: JMConversationInfo getHistoryMessages helper function

0.0.8 #

fix: group.maxMemberCount type

0.0.7 #

new feature: add message.state property

0.0.6 #

fix: voice message error new feature: add createMessage and sendMessage api

0.0.5 #

fix: login state changed not fire in android

0.0.4 #

fix:isSend 返回 null 的情况。

0.0.3 #

fix:android isSend 返回错误。

0.0.2 #

fix:swift 工程集成报错。

0.0.1 #

第一个版本。

example/README.md

jmessage_flutter_example #

Demonstrates how to use the jmessage_flutter plugin.

Getting Started #

For help getting started with Flutter, view our online documentation.

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  jmessage_flutter: ^0.2.0

2. Install it

You can install packages from the command line:

with Flutter:


$ flutter pub get

Alternatively, your editor might support flutter pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:jmessage_flutter/jmessage_flutter.dart';
  
Popularity:
Describes how popular the package is relative to other packages. [more]
72
Health:
Code health derived from static analysis. [more]
96
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
84
Overall:
Weighted score of the above. [more]
82
Learn more about scoring.

We analyzed this package on Aug 20, 2019, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.4.0
  • pana: 0.12.19
  • Flutter: 1.7.8+hotfix.4

Platforms

Detected platforms: Flutter

References Flutter, and has no conflicting libraries.

Health issues and suggestions

Document public APIs. (-0.25 points)

495 out of 508 API elements have no dartdoc comment.Providing good documentation for libraries, classes, functions, and other API elements improves code readability and helps developers find and use your API.

Fix lib/jmessage_flutter.dart. (-3.45 points)

Analysis of lib/jmessage_flutter.dart reported 7 hints, including:

line 1386 col 18: Equality operator == invocation with references of unrelated types.

line 1387 col 27: Equality operator == invocation with references of unrelated types.

line 1445 col 17: Override hashCode if overriding ==.

line 1464 col 17: Override hashCode if overriding ==.

line 1572 col 17: Override hashCode if overriding ==.

Maintenance suggestions

The package description is too short. (-16 points)

Add more detail to the description field of pubspec.yaml. Use 60 to 180 characters to describe the package, what it does, and its target use case.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.0.0-dev.68.0 <3.0.0
flutter 0.0.0
platform ^2.0.0 2.2.1
Transitive dependencies
collection 1.14.11 1.14.12
meta 1.1.6 1.1.7
sky_engine 0.0.99
typed_data 1.1.6
vector_math 2.0.8
Dev dependencies
flutter_test
mockito ^3.0.0
test ^1.3.0