草庐IT

interface-design

全部标签

git使用push命令报错-error: failed to push some refs to ‘https://gitee.com/MFLU/graduation_design.git‘

当我们使用git操作向远程仓库push代码时,可能会报错:hint:nothavelocally.Thisisusuallycausedbyanotherrepositorypushinghint:tothesameref.Youmaywanttofirstintegratetheremotechangeshint:(e.g.,'gitpull...')beforepushingagain.hint:Seethe'Noteaboutfast-forwards'in'gitpush--help'fordetails.主要原因如下:       这个错误信息通常是由于远程仓库包含了本地仓库中没有的

Android.Views.InflateException : Binary XML file line #17: Error inflating class android. 支持.design.internal.NavigationMenuItemView

我在使用Xamarin的Android项目中使用Material抽屉导航。我一直在尝试将两个Framelayout添加到drawerlayout中,以便我可以切换不同fragment的内容,请参见下面的xml:主要Activity:protectedoverridevoidOnCreate(Android_OS.Bundlebundle){base.OnCreate(bundle);SetContentView(Resource.Layout.activity_main);drawerLayout=FindViewById(Resource.Id.drawer_layout);//Se

android - 在将控制权转移到端点 0 之前,您是否必须声明一个接口(interface)?

我有一个游戏Controller连接到我的Android设备,它有1个接口(interface),端点中断。我知道Android在枚举端点时会列出端点0(控制端点),而且我知道我可以通过任何其他端点发送它来将控制转移到端点0。我的问题是:在进行此控制权转移之前,我是否需要声明一个接口(interface)(任何接口(interface))?Android框架是否要求您在与端点0(技术上不属于任何接口(interface))对话之前获得对接口(interface)的独占访问权? 最佳答案 是的。您会看到,如果不强制声明接口(inter

java - 安全异常 : Binder invocation to an incorrect interface on signed APK

我正在开发一个位置感知应用程序。我将GooglePlay位置服务和Googlemap集成到我的应用程序中。我的应用程序在Debug模式下运行没有问题。当我在Release模式下生成签名的APK并运行应用程序时,它在启动时崩溃并出现以下异常:Process:com.example.akif,PID:4233java.lang.RuntimeException:Unabletoresumeactivity{com.example.akif/com.example.akif.activities.MainActivity}:java.lang.SecurityException:Binder

Altium Designer 20 Gerber文件的输出

AltiumDesigner20Gerber文件的输出一、输出装配图二、输出BOM表三、输出Gerber文件四、输出钻孔文件五、输出坐标文件六、输出IPC网表一、输出装配图二、输出BOM表三、输出Gerber文件四、输出钻孔文件五、输出坐标文件六、输出IPC网表

android - Android 中用于 Material Design 的百分比颜色

在Google的Material设计规范中,我看到颜色指定为百分比:Toconveyahierarchyofinformation,youcanusedifferentshadesfortext.Thestandardalphavaluefortextonawhitebackgroundis87%(#000000).Secondarytext,whichislowerinthevisualhierarchy,shouldhaveanalphavalueof54%(#000000).我不明白这些百分比是如何计算的。例如,如果背景颜色是白色,那么文字的颜色是什么?如果我的背景是#607D8

java - 如何在 Android 单元测试中调用测试监听器接口(interface)

我的Android应用程序中有以下(示例)结构,我正在尝试为其编写单元测试:classEventMonitor{privateIEventListenermEventListener;publicvoidsetEventListener(IEventListenerlistener){mEventListener=listener;}publicvoiddoStuff(Objectparam){//SomelogicheremEventListener.doStuff1();//Somemorelogicif(param==condition){mEventListener.doStu

android - 将接口(interface)放在 bundle 中以启动新 Activity

我需要从具有两个不同模型的2个不同屏幕开始一个Activity,但是,两个模型都有一些共享信息,这是我在新Activity中需要的信息。问题是我不能让这些模型从同一个父模型扩展,因为其中一个模型已经扩展了一个父模型。我考虑过创建一个包含共享方法的接口(interface),但是如果我这样做了,那么如何将该接口(interface)放入启动下一个Activity所需的包中?我添加了一些简化的代码以阐明我的情况:publicclassAextendsModelimplementsCustomInterface{Stringname;Stringaddress;publicStringget

java - Gson反序列化接口(interface)到它的类实现

我正在使用Retrofit2.1.0和converter-gson:2.1.0并单独使用gson:2.6.2以便自定义序列化/反序列化。问题是我的POJO应该隐藏在接口(interface)后面,我想告诉Gson哪个类应该是反序列化接口(interface)。反序列化/序列化后Retrofit应该可以返回接口(interface)。如果我可以利用泛型并轻松创建一种方法来告诉Gson或Retrofit将FooInterface序列化/反序列化为FooClass,那就太好了。 最佳答案 我假设您想为所有接口(interface)及其各自

android - NoClassDefFoundError : android. support.design.internal.NavigationMenu on Android 4.2.2 (wiko)

我正在尝试使用Android支持设计库(版本23.0.1)和类NavigationMenu(我将此类用作布局中的XML标记)。当我在Android4.3的三星或Android5.x或6.0的Nexus上执行我的应用程序时一切正常,但是当我在Android4.2.2的WikoRainbow上执行应用程序时,它崩溃并显示以下内容异常:java.lang.RuntimeException:UnabletostartactivityComponentInfo{applicationId/package.MainActivity}:android.view.InflateException:Bi