展开菜单
首页 精品内容 本月促销 装机必备 Windows PDF教程 macOS软件 IOS软件 Android AI 专题
全部分类

当前位置:

首页 > 编程开发 > 怎么使用Java实现多任务执行助手

怎么使用Java实现多任务执行助手

1.多线程执行任务类packagecom.visy.threadpool;importcom.visy.executor.ExecutorFactory;importjava.util.ArrayList;importjava.util.Iterator;importjava.util.List;importjava.util.concurrent.Callable;importjava.util.concurrent.ExecutionException;importjava.util.concurre

本文目录

    1.多线程执行任务类

    package com.visy.threadpool;
    
    import com.visy.executor.ExecutorFactory;
    import java.util.ArrayList;
    import java.util.Iterator;
    import java.util.List;
    import java.util.concurrent.Callable;
    import java.util.concurrent.ExecutionException;
    import java.util.concurrent.Future;
    import java.util.concurrent.ThreadPoolExecutor;
    import java.util.concurrent.TimeUnit;
    import org.springframework.context.annotation.Configuration;
    
    @Configuration
    public class ThreadPoolConfig {
        private TheadPoolProperties theadPoolProperties;
        private ThreadPoolExecutor executor;
        private ThreadPoolExecutor executorChild;
    
        public ThreadPoolConfig(TheadPoolProperties theadPoolProperties) {
            this.theadPoolProperties = theadPoolProperties;
            this.executor = ExecutorFactory.getInstance().getThreadPoolExecutor("ThreadPoolConfig-service", theadPoolProperties.getQueueSize(), theadPoolProperties.getCoreThreadNum(), theadPoolProperties.getMaxPoolSize());
            this.executorChild = ExecutorFactory.getInstance().getThreadPoolExecutor("ThreadPoolConfig-service-child", theadPoolProperties.getQueueSize(), theadPoolProperties.getCoreThreadNum(), theadPoolProperties.getMaxPoolSize());
        }
    
        public  List doConcurrentTask(List> taskList, ThreadPoolExecutor... executorChilds) {
            if (taskList != null && !taskList.isEmpty()) {
                List resultList = new ArrayList();
                List futureList = null;
    
                try {
                    if (this.executor.getQueue().size() >= this.theadPoolProperties.getQueueSize()) {
                        throw new RuntimeException("queue size bigger than 100, now size is " + this.executor.getQueue().size());
                    }
    
                    if (executorChilds != null && executorChilds.length > 0 && executorChilds[0] != null) {
                        futureList = executorChilds[0].invokeAll(taskList);
                    } else {
                        futureList = this.executor.invokeAll(taskList, (long)this.theadPoolProperties.getTimeOut(), TimeUnit.SECONDS);
                    }
                } catch (InterruptedException var6) {
                    var6.printStackTrace();
                }
    
                this.doFutureList(resultList, futureList);
                return resultList;
            } else {
                return null;
            }
        }
    
         void doFutureList(List resultList, List> futureList) {
            if (futureList != null) {
                Iterator var3 = futureList.iterator();
    
                while(var3.hasNext()) {
                    Future future = (Future)var3.next();
    
                    try {
                        resultList.add(future.get());
                    } catch (ExecutionException | InterruptedException var6) {
                        var6.printStackTrace();
                    }
                }
            }
    
        }
    
        public  void doVoidConcurrentTask(List> taskList) {
            if (taskList != null && !taskList.isEmpty()) {
                Iterator var2 = taskList.iterator();
    
                while(var2.hasNext()) {
                    Callable call = (Callable)var2.next();
                    this.executor.submit(call);
                }
    
            }
        }
    
        public TheadPoolProperties getTheadPoolProperties() {
            return this.theadPoolProperties;
        }
    
        public ThreadPoolExecutor getExecutor() {
            return this.executor;
        }
    
        public ThreadPoolExecutor getExecutorChild() {
            return this.executorChild;
        }
    
        public void setTheadPoolProperties(TheadPoolProperties theadPoolProperties) {
            this.theadPoolProperties = theadPoolProperties;
        }
    
        public void setExecutor(ThreadPoolExecutor executor) {
            this.executor = executor;
        }
    
        public void setExecutorChild(ThreadPoolExecutor executorChild) {
            this.executorChild = executorChild;
        }
    
        public boolean equals(Object o) {
            if (o == this) {
                return true;
            } else if (!(o instanceof ThreadPoolConfig)) {
                return false;
            } else {
                ThreadPoolConfig other = (ThreadPoolConfig)o;
                if (!other.canEqual(this)) {
                    return false;
                } else {
                    label47: {
                        Object this$theadPoolProperties = this.getTheadPoolProperties();
                        Object other$theadPoolProperties = other.getTheadPoolProperties();
                        if (this$theadPoolProperties == null) {
                            if (other$theadPoolProperties == null) {
                                break label47;
                            }
                        } else if (this$theadPoolProperties.equals(other$theadPoolProperties)) {
                            break label47;
                        }
    
                        return false;
                    }
    
                    Object this$executor = this.getExecutor();
                    Object other$executor = other.getExecutor();
                    if (this$executor == null) {
                        if (other$executor != null) {
                            return false;
                        }
                    } else if (!this$executor.equals(other$executor)) {
                        return false;
                    }
    
                    Object this$executorChild = this.getExecutorChild();
                    Object other$executorChild = other.getExecutorChild();
                    if (this$executorChild == null) {
                        if (other$executorChild != null) {
                            return false;
                        }
                    } else if (!this$executorChild.equals(other$executorChild)) {
                        return false;
                    }
    
                    return true;
                }
            }
        }
    
        protected boolean canEqual(Object other) {
            return other instanceof ThreadPoolConfig;
        }
    
        public int hashCode() {
            int PRIME = true;
            int result = 1;
            Object $theadPoolProperties = this.getTheadPoolProperties();
            int result = result * 59 + ($theadPoolProperties == null ? 43 : $theadPoolProperties.hashCode());
            Object $executor = this.getExecutor();
            result = result * 59 + ($executor == null ? 43 : $executor.hashCode());
            Object $executorChild = this.getExecutorChild();
            result = result * 59 + ($executorChild == null ? 43 : $executorChild.hashCode());
            return result;
        }
    
        public String toString() {
            return "ThreadPoolConfig(theadPoolProperties=" + this.getTheadPoolProperties() + ", executor=" + this.getExecutor() + ", executorChild=" + this.getExecutorChild() + ")";
        }
    }

    2.执行器工厂类

    package com.visy.executor;
    
    import java.util.Map;
    import java.util.concurrent.Callable;
    import java.util.concurrent.ConcurrentHashMap;
    import java.util.concurrent.Future;
    import java.util.concurrent.ThreadPoolExecutor;
    import org.apache.commons.lang.StringUtils;
    import org.slf4j.Logger;
    import org.slf4j.LoggerFactory;
    
    public class ExecutorFactory {
        private static final Logger logger = LoggerFactory.getLogger(ExecutorFactory.class);
        private static final Map threadPoolExecutorMap = new ConcurrentHashMap();
        private static final int DEFAULT_QUEUE_SIZE = 1000;
        private static final String DEFAULT_EXECUTOR_NAME = "default-executor";
        private static final int MAX_THREAD_NUM = 100;
        private static final int CORE_THREAD_NUM = 1;
        private static volatile ExecutorFactory instance;
    
        private ExecutorFactory() {
        }
    
        public static ExecutorFactory getInstance() {
            if (instance == null) {
                Class var0 = ExecutorFactory.class;
                synchronized(ExecutorFactory.class) {
                    if (instance == null) {
                        instance = new ExecutorFactory();
                    }
                }
            }
    
            return instance;
        }
    
        public ThreadPoolExecutor getThreadPoolExecutorByName(String name) {
            return (ThreadPoolExecutor)threadPoolExecutorMap.get(name);
        }
    
        public static Map getThreadPoolExecutorMap() {
            return threadPoolExecutorMap;
        }
    
        public ThreadPoolExecutor getThreadPoolExecutor(String threadPoolExecutorName, int queueSize, int coreThreadNum, int maxPoolSize) {
            if (StringUtils.isBlank(threadPoolExecutorName)) {
                throw new IllegalArgumentException("thread name empty");
            } else {
                if (!threadPoolExecutorMap.containsKey(threadPoolExecutorName)) {
                    Class var5 = ExecutorFactory.class;
                    synchronized(ExecutorFactory.class) {
                        if (!threadPoolExecutorMap.containsKey(threadPoolExecutorName)) {
                            ThreadPoolExecutor executor = (new ThreadPool(coreThreadNum, maxPoolSize, 30L, queueSize, threadPoolExecutorName)).getExecutor();
                            threadPoolExecutorMap.put(threadPoolExecutorName, executor);
                            logger.info("thread name: {} executor created", threadPoolExecutorName);
                        }
                    }
                }
    
                return (ThreadPoolExecutor)threadPoolExecutorMap.get(threadPoolExecutorName);
            }
        }
    
        public  void submit(T t) {
            ThreadPoolExecutor defaultExecutor = this.getThreadPoolExecutor();
            defaultExecutor.submit(t);
        }
    
        public  void submit(String poolName, T t) {
            ThreadPoolExecutor executor = this.getThreadPoolExecutorByName(poolName);
            if (executor == null) {
                logger.error("thread name: {} executor not exist.", poolName);
                throw new IllegalArgumentException("thread name:" + poolName + " executor not exist.");
            } else {
                executor.submit(t);
            }
        }
    
        public > Future submit(T t) {
            ThreadPoolExecutor defaultExecutor = this.getThreadPoolExecutor();
            return defaultExecutor.submit(t);
        }
    
        public > Future submit(String poolName, T t) {
            ThreadPoolExecutor executor = this.getThreadPoolExecutorByName(poolName);
            if (executor == null) {
                logger.error("thread poolName: {} executor not exist.", poolName);
                throw new IllegalArgumentException("thread poolName:" + poolName + " executor not exist.");
            } else {
                return executor.submit(t);
            }
        }
    
        public ThreadPoolExecutor getThreadPoolExecutor() {
            return this.getThreadPoolExecutor("default-executor", 1000, 1, 100);
        }
    }

    3.多线程配置类

    package com.visy.threadpool;
    
    import javax.validation.constraints.NotNull;
    import org.springframework.boot.context.properties.ConfigurationProperties;
    import org.springframework.context.annotation.Configuration;
    import org.springframework.validation.annotation.Validated;
    
    @Validated
    @Configuration
    @ConfigurationProperties(prefix = "visy.threadpool")
    public class TheadPoolProperties {
        // 执行并行任务时,等待多久时间超时(单位:秒)
        @NotNull
        private Integer timeOut;
        // 队列大小
        @NotNull
        private Integer queueSize; 
        // 核心线程数量
        @NotNull
        private Integer coreThreadNum;
        // 线程池最大线程数量
        @NotNull
        private Integer maxPoolSize;
        // 并行执行每组大小
        private Integer groupSize = 20;
    
        public TheadPoolProperties() {
        }
    
        public Integer getTimeOut() {
            return this.timeOut;
        }
    
        public Integer getQueueSize() {
            return this.queueSize;
        }
    
        public Integer getCoreThreadNum() {
            return this.coreThreadNum;
        }
    
        public Integer getMaxPoolSize() {
            return this.maxPoolSize;
        }
    
        public Integer getGroupSize() {
            return this.groupSize;
        }
    
        public void setTimeOut(Integer timeOut) {
            this.timeOut = timeOut;
        }
    
        public void setQueueSize(Integer queueSize) {
            this.queueSize = queueSize;
        }
    
        public void setCoreThreadNum(Integer coreThreadNum) {
            this.coreThreadNum = coreThreadNum;
        }
    
        public void setMaxPoolSize(Integer maxPoolSize) {
            this.maxPoolSize = maxPoolSize;
        }
    
        public void setGroupSize(Integer groupSize) {
            this.groupSize = groupSize;
        }
    
        public boolean equals(Object o) {
            if (o == this) {
                return true;
            } else if (!(o instanceof TheadPoolProperties)) {
                return false;
            } else {
                TheadPoolProperties other = (TheadPoolProperties)o;
                if (!other.canEqual(this)) {
                    return false;
                } else {
                    label71: {
                        Object this$timeOut = this.getTimeOut();
                        Object other$timeOut = other.getTimeOut();
                        if (this$timeOut == null) {
                            if (other$timeOut == null) {
                                break label71;
                            }
                        } else if (this$timeOut.equals(other$timeOut)) {
                            break label71;
                        }
    
                        return false;
                    }
    
                    Object this$queueSize = this.getQueueSize();
                    Object other$queueSize = other.getQueueSize();
                    if (this$queueSize == null) {
                        if (other$queueSize != null) {
                            return false;
                        }
                    } else if (!this$queueSize.equals(other$queueSize)) {
                        return false;
                    }
    
                    label57: {
                        Object this$coreThreadNum = this.getCoreThreadNum();
                        Object other$coreThreadNum = other.getCoreThreadNum();
                        if (this$coreThreadNum == null) {
                            if (other$coreThreadNum == null) {
                                break label57;
                            }
                        } else if (this$coreThreadNum.equals(other$coreThreadNum)) {
                            break label57;
                        }
    
                        return false;
                    }
    
                    Object this$maxPoolSize = this.getMaxPoolSize();
                    Object other$maxPoolSize = other.getMaxPoolSize();
                    if (this$maxPoolSize == null) {
                        if (other$maxPoolSize != null) {
                            return false;
                        }
                    } else if (!this$maxPoolSize.equals(other$maxPoolSize)) {
                        return false;
                    }
    
                    Object this$groupSize = this.getGroupSize();
                    Object other$groupSize = other.getGroupSize();
                    if (this$groupSize == null) {
                        if (other$groupSize == null) {
                            return true;
                        }
                    } else if (this$groupSize.equals(other$groupSize)) {
                        return true;
                    }
    
                    return false;
                }
            }
        }
    
        protected boolean canEqual(Object other) {
            return other instanceof TheadPoolProperties;
        }
    
        public int hashCode() {
            int PRIME = true;
            int result = 1;
            Object $timeOut = this.getTimeOut();
            int result = result * 59 + ($timeOut == null ? 43 : $timeOut.hashCode());
            Object $queueSize = this.getQueueSize();
            result = result * 59 + ($queueSize == null ? 43 : $queueSize.hashCode());
            Object $coreThreadNum = this.getCoreThreadNum();
            result = result * 59 + ($coreThreadNum == null ? 43 : $coreThreadNum.hashCode());
            Object $maxPoolSize = this.getMaxPoolSize();
            result = result * 59 + ($maxPoolSize == null ? 43 : $maxPoolSize.hashCode());
            Object $groupSize = this.getGroupSize();
            result = result * 59 + ($groupSize == null ? 43 : $groupSize.hashCode());
            return result;
        }
    
        public String toString() {
            return "TheadPoolProperties(timeOut=" + this.getTimeOut() + ", queueSize=" + this.getQueueSize() + ", coreThreadNum=" + this.getCoreThreadNum() + ", maxPoolSize=" + this.getMaxPoolSize() + ", groupSize=" + this.getGroupSize() + ")";
        }
    }

    4.列表拆分工具类

    package com.visy.utils;
    
    import java.util.ArrayList;
    import java.util.Arrays;
    import java.util.List;
    import java.util.jar.Attributes;
    
    /**
     * 列表或数组按指定大小分组,用于批量取一部分数据循环处理
     *
     */
    public class ArraySplitUtil {
        /**
         * 按指定大小对列表分组
         * @param list
         * @param splitSize
         * @return
         */
        public List> splistList(List list, int splitSize) {
            if (null == list || list.size() == 0) {
                return null;
            }
            int listSize = list.size();
            List> newList = new ArrayList<>();
            if (listSize < splitSize) {
                newList.add(list);
                return newList;
            }
            int addLength = splitSize;
            int times = listSize / splitSize;
            if (listSize % splitSize != 0) {
                times += 1;
            }
            int start = 0;
            int end = 0;
            int last = times - 1;
            for (int i = 0; i < times; i++) {
                start = i * splitSize;
                if (i < last) {
                    end = start + addLength;
                } else {
                    end = listSize;
                }
                newList.add(list.subList(start, end));
            }
            return newList;
        }
    
        /**
         * 按指定大小对数组分组
         * @param array
         * @param splitSize
         * @return
         */
        public List splistArray(T[] array, int splitSize) {
            if (null == array) {
                return null;
            }
            int listSize = array.length;
            List newList = new ArrayList<>();
            if (listSize < splitSize) {
                newList.add(array);
                return newList;
            }
            int addLength = splitSize;
            int times = listSize / splitSize;
            if (listSize % splitSize != 0) {
                times += 1;
            }
            int start = 0;
            int end = 0;
            int last = times - 1;
            for (int i = 0; i < times; i++) {
                start = i * splitSize;
                if (i < last) {
                    end = start + addLength;
                } else {
                    end = listSize;
                }
                newList.add(Arrays.copyOfRange(array, start, end));
            }
            return newList;
        }
    
        public static  ArraySplitUtil build(){
            return new ArraySplitUtil<>();
        }
    }

    5.多任务执行助手类

    package com.visy.helper;
    
    import com.baomidou.mybatisplus.toolkit.CollectionUtils;
    import com.google.common.collect.Lists;
    import com.visy.utils.ArraySplitUtil;
    import com.visy.threadpool.ThreadPoolConfig;
    import org.springframework.beans.factory.annotation.Autowired;
    import org.springframework.stereotype.Service;
    
    import java.util.List;
    import java.util.Map;
    import java.util.Objects;
    import java.util.concurrent.Callable;
    import java.util.concurrent.ConcurrentHashMap;
    import java.util.function.Consumer;
    import java.util.function.Function;
    import java.util.stream.Collectors;
    
    /**
     * 多任务助手
     * @author visy.wang
     * @date 2022/5/9 14:38
     */
    @Service
    public class MultiTaskHelper {
        @Autowired
        private ThreadPoolConfig threadPoolConfig;
        private static final Map> ArraySplitUtilCache = new ConcurrentHashMap<>();
    
        public  List> createAndRunListTask(List list, Function handler){
            return createAndRunListTask(list, null, handler);
        }
    
        public  List> createAndRunListTaskV2(List list, Function, List> handler){
            return createAndRunListTask(list, handler, null);
        }
    
        public  void createAndRunListTaskWithoutReturn(List list, Consumer handler){
            createAndRunListTaskWithoutReturn(list, null, handler);
        }
    
        public  void createAndRunListTaskWithoutReturnV2(List list, Consumer> handler){
            createAndRunListTaskWithoutReturn(list, handler, null);
        }
    
        /**
         * 把列表按线程数分组
         * @param list 列表
         * @return 分组后的列表
         */
        @SuppressWarnings("unchecked")
        private  List> listSplit(List list){
            String key = list.get(0).getClass().getName();
            int groupSize = threadPoolConfig.getTheadPoolProperties().getGroupSize();
            ArraySplitUtil arraySplitUtil = (ArraySplitUtil)ArraySplitUtilCache.get(key);
            if(Objects.isNull(arraySplitUtil)){
                arraySplitUtil = ArraySplitUtil.build();
                ArraySplitUtilCache.put(key, arraySplitUtil);
            }
            return arraySplitUtil.splistList(list, groupSize);
        }
    
        /**
         * 创建并运行多任务
         * @param list 输入数据列表
         * @param handler1 处理器1 (优先级使用)
         * @param handler2 处理器2
         * @param  输入数据类型
         * @param  输出数据类型
         * @return 执行结果分组列表
         */
        private  List> createAndRunListTask(List list,  Function, List> handler1, Function handler2){
            List> listGroup = listSplit(list);
            //设定每个组的任务
            List>> taskList = Lists.newArrayListWithExpectedSize(listGroup.size());
            listGroup.stream().filter(CollectionUtils::isNotEmpty).forEach(subList -> {
                taskList.add(() -> {
                    if(Objects.nonNull(handler1)){
                        return handler1.apply(subList);
                    }else if(Objects.nonNull(handler2)){
                        return subList.stream().map(handler2).collect(Collectors.toList());
                    }else{
                        return null;
                    }
                });
            });
            return threadPoolConfig.doConcurrentTask(taskList);
        }
    
        /**
         * 创建并运行多任务(无返回结果)
         * @param list 输入数据列表
         * @param handler1 处理器1 (优先级更高)
         * @param handler2 处理器2
         * @param  输入数据类型
         */
        private  void createAndRunListTaskWithoutReturn(List list, Consumer> handler1, Consumer handler2){
            List> listGroup = listSplit(list);
            //设定每个组的任务
            List>> taskList = Lists.newArrayListWithExpectedSize(listGroup.size());
            listGroup.stream().filter(CollectionUtils::isNotEmpty).forEach(subList -> {
                taskList.add(() -> {
                    if(Objects.nonNull(handler1)){
                        handler1.accept(subList);
                    }else if(Objects.nonNull(handler2)){
                        subList.forEach(handler2);
                    }
                    return null;
                });
            });
            threadPoolConfig.doConcurrentTask(taskList);
        }
    }

    6.多任务助手使用:

    @Autowired
    package com.zoom.fleet.schedule.service;
    
    import com.visy.helper.MultiTaskHelper;
    import org.springframework.beans.factory.annotation.Autowired;
    import org.springframework.stereotype.Service;
    
    import java.util.ArrayList;
    import java.util.List;
    import java.util.stream.Collectors;
    
    /**
     * 多任务助手使用示例
     * @author visy.wang
     * @date 2022/5/13 14:11
     */
    @Service
    public class MultiTaskTest {
        @Autowired
        private MultiTaskHelper multiTaskHelper;
    
        private void test(){
    
            //待多任务执行的数据列表
            List idList = new ArrayList<>();
    
            //1.有返回结果的执行方式一, 定义单个数据的处理逻辑,返回多任务执行结果和合集
            List> resultList = multiTaskHelper.createAndRunListTask(idList, id->{
                //每一项数据的业务代码
                return Long.valueOf(id);
            });
    
            //2.有返回结果的执行方式二, 定义单个数线程的处理逻辑,返回多任务执行结果和合集
            resultList = multiTaskHelper.createAndRunListTaskV2(idList, subIdList->{
                //每一个线程下列表操作的业务代码
                return subIdList.stream().map(id->{
                    //每一项数据的业务代码
                    return Long.valueOf(id);
                }).collect(Collectors.toList());
            });
    
            //3.无返回结果的执行方式一, 定义单个数据的处理逻辑
            multiTaskHelper.createAndRunListTaskWithoutReturn(idList, id->{
                //每一项数据的业务代码...
            });
    
            //3.无返回结果的执行方式一, 定义单个数据的处理逻辑
            multiTaskHelper.createAndRunListTaskWithoutReturnV2(idList, subIdList->{
                subIdList.forEach(id->{
                    //每一项数据的业务代码...
                });
                //继续操作subIdList...
            });
        }
    }
    本站声明:本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系bd@zhengruan.com
    作者最新文章
    编程开发 Java
    相关文章 更多
    精品专题 更多
    装机必备

    正软商城装机必备专区,精选办公、浏览器、安全防护、影音播放、压缩解压、设计创作和系统工具等电脑常用正版软件,帮助用户快速完成新电脑软件配置。

    Windows

    正软商城Windows软件专区,汇集适用于Windows电脑的办公、设计、安全防护、影音播放、开发工具和系统优化软件,提供软件介绍、系统要求、正版授权及购买下载服务。

    PDF教程

    正软商城PDF教程频道提供PDF编辑、转换、合并、拆分、压缩及格式处理方法,同时介绍常用PDF软件和工具的使用技巧。

    macOS软件

    正软商城macOS软件专区,精选适用于Mac电脑的办公、设计、影音、效率、开发和系统工具,提供软件功能介绍、macOS兼容版本、正版授权及购买下载服务。

    IOS软件

    正软商城iOS软件专区,精选适用于iPhone和iPad的办公、学习、影音、设计、效率及AI应用,提供功能介绍、适用设备、系统要求和正版获取方式等信息。

    AI

    正软商城AI软件专区,汇集AI写作、AI绘画、AI视频、AI办公、AI编程、AI翻译、智能客服和数据分析等人工智能工具,提供功能介绍、适用平台、收费方式及正版购买信息。

    Mac软件 更多
    Postman macOS版
    Postman macOS版

    Postman是一套面向API全生命周期的开发与测试平台,可在Mac上发送和调试多种协议请求,管理集合、环境及认证信息,并完成脚本测试、模拟服务、监控、文档发布和团队协作。它适合开发、测试及运维人员使用,提供个人免费方案。

    Docker Desktop macOS版
    Docker Desktop macOS版

    Docker Desktop 是 Docker 官方为 Mac 提供的容器开发环境,集成 Docker Engine、命令行工具、Compose、Build、Kubernetes 与图形化管理界面。

    Android Studio macOS版
    Android Studio macOS版

    Android Studio 是 Google 面向安卓应用开发提供的官方集成开发环境,基于 IntelliJ IDEA 构建。它整合智能代码编辑、Gradle 构建、界面预览、设备模拟、性能分析、调试测试及 APK 分析等工具。

    Xcode macOS版
    Xcode macOS版

    Xcode 是苹果面向 Mac 提供的官方集成开发环境,将代码编辑、项目构建、SwiftUI 实时预览、设备模拟、自动化测试、断点调试、性能分析和应用分发整合在同一套工作流中,适合开发与维护 iPhone、iPad、Mac、Apple Wa

    JetBrains WebStorm macOS版
    JetBrains WebStorm macOS版

    JetBrains WebStorm 是面向 JavaScript、TypeScript 和现代 Web 技术的专业集成开发环境,可智能理解项目结构,提供代码补全、重构、错误检查、运行调试、测试及 Git 工具。

    PhpStorm macOS版
    PhpStorm macOS版

    PhpStorm 是 JetBrains 推出的专业 PHP 集成开发环境,可在 Mac 上完成代码编写、智能检查、重构、调试、测试和数据库管理。它支持主流 PHP 框架、Composer、Git、Docker 与远程解释器。

    JetBrains PyCharm macOS版
    JetBrains PyCharm macOS版

    JetBrains PyCharm 是面向 Python 开发者的集成开发环境,提供智能补全、代码检查、重构、调试、测试、版本控制及虚拟环境管理功能。Mac 版兼容 Intel 与 Apple 芯片,核心功能可免费使用。

    JetBrains IntelliJ IDEA macOS版
    JetBrains IntelliJ IDEA macOS版

    IntelliJ IDEA 是 JetBrains 推出的专业集成开发环境,重点服务于 Java、Kotlin 与 JVM 项目开发。软件集成代码补全、静态检查、重构、调试、测试、版本控制及构建工具,并可借助插件扩展语言和框架支持。

    Visual Studio Code macOS版
    Visual Studio Code macOS版

    Visual Studio Code 是微软提供的免费代码编辑器,支持 macOS,并为 Intel 与 Apple 芯片 Mac 提供适配版本。软件集代码编辑、调试、Git 源代码管理、集成终端和扩展市场于一体。

    REAPER macOS版
    REAPER macOS版

    REAPER是Cockos开发的数字音频工作站,提供多轨音频与MIDI录制、剪辑、处理、混音和母带制作工具。Mac版兼容Intel与Apple芯片,支持AU、VST、VST3、CLAP等插件格式,并提供高度可定制的工作流程。

    Adobe Audition macOS版
    Adobe Audition macOS版

    Adobe Audition 是面向播客、影视后期、音乐制作及内容创作者的专业音频工作站,提供波形精修、多轨录制与混音、频谱编辑、降噪修复、响度匹配和效果处理工具,并可与 Adobe Premiere 协同完成视频声音制作。

    Pro Tools macOS版
    Pro Tools macOS版

    Pro Tools 是 Avid 推出的专业数字音频工作站,覆盖多轨录音、无损剪辑、MIDI 编曲、插件处理、自动化混音及声音与画面同步等工作。它拥有 Intro、Artist、Studio 和 Ultimate 等方案。

    WINDOWS 更多
    PixPix 网页版
    PixPix 网页版

    PixPix 是面向品牌、卖家和内容团队的在线 AI 图片视频创作平台,提供图视频 Agent、无限画布、图片生成、视频生成、自然语言编辑及商品套图、产品精修和带货视频等电商工具。

    Postman Windows版
    Postman Windows版

    Postman 是面向 API 全生命周期的开发与协作平台。Windows 桌面版可用于构建和发送 HTTP、GraphQL、gRPC、WebSocket、MQTT 等请求,并提供环境变量、集合、脚本测试、模拟服务、监控、文档及团队工作区等

    Docker Desktop Windows版
    Docker Desktop Windows版

    Docker Desktop 为 Windows 开发者提供集成式容器环境,内置 Docker Engine、命令行工具、Compose、Build 与 Kubernetes 等组件,可在本机完成镜像构建、容器运行、日志查看和资源管理。

    Android Studio Windows版
    Android Studio Windows版

    Android Studio 是 Google 面向 Android 应用开发提供的官方集成开发环境,以 IntelliJ IDEA 为基础,集成智能代码编辑、Gradle 构建、设备模拟、界面预览、调试测试及性能分析工具,

    JetBrains WebStorm Windows版
    JetBrains WebStorm Windows版

    WebStorm 是 JetBrains 面向 JavaScript、TypeScript 和现代 Web 技术打造的集成开发环境。它提供项目级代码分析、智能补全、安全重构、导航搜索,并集成调试、测试、终端、Git 与常用前端工具,

    JetBrains PhpStorm Windows版
    JetBrains PhpStorm Windows版

    PhpStorm 是 JetBrains 面向 PHP 与现代 Web 开发打造的专业集成开发环境,提供代码补全、静态检查、重构、调试、测试、数据库、版本控制及前端语言支持。Windows 用户可直接下载安装程序,

    JetBrains PyCharm Windows版
    JetBrains PyCharm Windows版

    PyCharm 是 JetBrains 推出的 Python 集成开发环境,提供智能代码补全、错误检查、重构、调试、测试、Git、终端及 Jupyter Notebook 支持。统一版安装后可体验 30 天 Pro 功能,

    JetBrains IntelliJ IDEA Windows版
    JetBrains IntelliJ IDEA Windows版

    JetBrains IntelliJ IDEA 是以 Java、Kotlin 和 JVM 项目为核心的专业集成开发环境,提供智能补全、代码检查、安全重构、调试、测试、版本控制及构建工具集成。统一发行版的核心功能可免费用于商业和非商业项目,

    Visual Studio Code Windows版
    Visual Studio Code Windows版

    Visual Studio Code 是微软推出的免费代码编辑器,Windows 版集成智能补全、代码导航、调试、终端和版本控制,并可通过扩展添加语言、格式化及远程开发能力。它启动较快、配置灵活,

    REAPER Windows版
    REAPER Windows版

    REAPER 是 Cockos 推出的数字音频工作站,适用于录音、MIDI 编曲、音频编辑、混音、母带制作及声音设计。软件安装包小巧,支持多轨录制、灵活路由、自动化、第三方插件和脚本扩展,并提供完整功能的 60 天免费评估期。

    Adobe Audition Windows版
    Adobe Audition Windows版

    Adobe Audition 是面向播客、影视后期、广播与音乐制作的专业音频工作站,提供波形编辑、多轨混音、频谱分析、录音、降噪修复和效果处理等功能。Windows 版通过 Adobe Creative Cloud 安装和管理,

    Pro Tools Windows版
    Pro Tools Windows版

    Pro Tools 是 Avid 推出的专业数字音频工作站,提供多轨录音、音频剪辑、MIDI编曲、插件处理、自动化混音及影视声音制作能力。它适合音乐人、录音师、制作人和音频后期团队使用,并提供免费入门版、订阅方案及永久授权选择。

    网站备案号:苏ICP备2026018738号-1 联系邮箱:bd@zhengruan.com

    Copyright ©2018-2026