小编mas*_*720的帖子

.net 5 的 Docker 镜像

通常我将以下图像用于 .net core 3.1 并且它工作正常。

FROM mcr.microsoft.com/dotnet/core/aspnet:3.1-buster-slim AS base
FROM mcr.microsoft.com/dotnet/core/sdk:3.1-buster AS build
Run Code Online (Sandbox Code Playgroud)

我出于实验原因启动了一个新的 .net 5 项目并创建dockerfile了以下内容

FROM mcr.microsoft.com/dotnet/core/aspnet:5.0-buster-slim AS base 
FROM mcr.microsoft.com/dotnet/core/sdk:5.0-buster AS build
Run Code Online (Sandbox Code Playgroud)

并有以下问题:

 => ERROR [internal] load metadata for mcr.microsoft.com/dotnet/core/sdk:5.0-buster                           0.2s
 => ERROR [internal] load metadata for mcr.microsoft.com/dotnet/core/aspnet:5.0-buster-slim                   0.2s
 => CANCELED [build 1/7] FROM mcr.microsoft.com/dotnet/core/sdk:5.0-buster                                    0.0s
 => => resolve mcr.microsoft.com/dotnet/core/sdk:5.0-buster                                                   0.0s
 => [internal] load build context                                                                             0.0s
 => ERROR [base 1/2] FROM mcr.microsoft.com/dotnet/core/aspnet:5.0-buster-slim                                0.0s
 => => resolve mcr.microsoft.com/dotnet/core/aspnet:5.0-buster-slim
Run Code Online (Sandbox Code Playgroud)

docker .net-5

24
推荐指数
2
解决办法
2万
查看次数

带有两个editText的浮动标签

我希望实现像这样的东西.带有两个编辑文本的浮动标签.我也使用TextInputLayout过其他一些图书馆,但都只接受单身儿童EditText.任何帮助表示赞赏.

在此输入图像描述

两个编辑文本都必须是可聚焦的,并且提示从第二个上升.

android android-edittext material-design android-textinputlayout

10
推荐指数
2
解决办法
2946
查看次数

与现有视频合并视图

我想将视图与现有视频合并,然后从中获取视频。例如,Textview在视频上添加带有的文本。许多社交媒体应用(例如tik tok和instagram)都可以看到此功能。

他们是如何做到的,有人知道了吗?目前,我只有TextviewScalableVideoView,但Idk如何将它们合并为视频。

java video android android-layout

9
推荐指数
1
解决办法
120
查看次数

Map <String,List <Object >>的Collectors.toMap无法解析

我有这种代码和平工作正常,需要一个Map<String, List<Device>>时间并返回相同的数据结构:

Stream<Map.Entry<String, List<Device>>> results = device.getDeviceMapList().entrySet().stream();

Map<String, List<Device>> sortedMap = new HashMap<String, List<Device>>();

results.forEach(e -> {
    e.getValue().sort(Comparator.comparing(Device::getStationTimeStamp));
    sortedMap.put(e.getKey(), e.getValue());
});
Run Code Online (Sandbox Code Playgroud)

现在我尝试使用Collectors.toMap并没有成功:

Map<String, List<Device>> sortedMap = results.forEach(e -> {
    e.getValue().stream()
            .sorted(Comparator.comparing(Device::getStationTimeStamp))
            .collect(Collectors.toMap(e.getKey(), ArrayList<Device>::new));

});
Run Code Online (Sandbox Code Playgroud)

这部分.collect(Collectors.toMap(e.getKey(), ArrayList<Device>::new));是我试过的,它不完全正确,我做错了什么?

java java-8 java-stream

4
推荐指数
1
解决办法
379
查看次数