国产 无码 综合区,色欲AV无码国产永久播放,无码天堂亚洲国产AV,国产日韩欧美女同一区二区

我的Office Outlook插件開(kāi)發(fā)之旅(一)

這篇具有很好參考價(jià)值的文章主要介紹了我的Office Outlook插件開(kāi)發(fā)之旅(一)。希望對(duì)大家有所幫助。如果存在錯(cuò)誤或未考慮完全的地方,請(qǐng)大家不吝賜教,您也可以點(diǎn)擊"舉報(bào)違法"按鈕提交疑問(wèn)。

目的

開(kāi)發(fā)一款可以同步Outlook郵件通訊錄信息的插件。

方案

  1. VSTO 外接程序
  2. COM 加載項(xiàng)

VSTO 外接程序?qū)utlook的支持,是從2010版本之后開(kāi)始的。
VSTO 4.0 支持Outlook 2010以后的版本,所以編寫(xiě)一次代碼,就可以在不同的版本上運(yùn)行。

COM 加載項(xiàng)十分依賴于.NET Framework框架和Office的版本,之后講到的時(shí)候你就明白。

VSTO 外接程序

VSTO,全稱是Visual Studio Tools for Office,在微軟的Visual Studio平臺(tái)中進(jìn)行Office專業(yè)開(kāi)發(fā)。VSTO是VBA的替代產(chǎn)品,使用該工具包使開(kāi)發(fā)Office應(yīng)用程序變得更簡(jiǎn)單,VSTO還能使用Visual Studio開(kāi)發(fā)環(huán)境中的眾多功能。
VSTO依賴于.NET Framework框架,并且不能在.net core或者.net 5+以上的平臺(tái)運(yùn)行。

創(chuàng)建VSTO程序

使用Visual Studio 2013的新建項(xiàng)目,如果你使用更新版本的話,那么你大概率找不到。因?yàn)楸灰瞥?。比如Visual Studio 2019最低創(chuàng)建的Outlook 2013 外接程序
我的Office Outlook插件開(kāi)發(fā)之旅(一)
Office/SharePoint -> .Net Framework 4 -> Outlook 2010 外接程序

之后我們會(huì)得到,這樣的項(xiàng)目結(jié)構(gòu)
我的Office Outlook插件開(kāi)發(fā)之旅(一)

我的Office Outlook插件開(kāi)發(fā)之旅(一)

打開(kāi)ThisAddIn.cs

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Linq;
using Outlook = Microsoft.Office.Interop.Outlook;
using Office = Microsoft.Office.Core;
using Microsoft.Office.Interop.Outlook;
using System.Windows.Forms;
using System.Data;
using System.Data.SqlClient;
using System.IO;
using System.Threading;
using System.Collections;

namespace ContactsSynchronization
{
    public partial class ThisAddIn
    {
        
        private void ThisAddIn_Startup(object sender, System.EventArgs e)
        {
            // Outlook啟動(dòng)時(shí)執(zhí)行
            MessageBox.Show("Hello VSTO!");
        }

        private void ThisAddIn_Shutdown(object sender, System.EventArgs e)
        {
            // Outlook關(guān)閉時(shí)執(zhí)行
        }

        #region VSTO 生成的代碼

        /// <summary>
        /// 設(shè)計(jì)器支持所需的方法 - 不要
        /// 使用代碼編輯器修改此方法的內(nèi)容。
        /// </summary>
        private void InternalStartup()
        {
            // 綁定聲明周期函數(shù)
            this.Startup += new System.EventHandler(ThisAddIn_Startup);
            this.Shutdown += new System.EventHandler(ThisAddIn_Shutdown);
        }

        #endregion
    }
}

啟動(dòng)試試看

到這里我們就已經(jīng)把項(xiàng)目搭建起來(lái)了,但在寫(xiě)代碼之前不如再認(rèn)識(shí)認(rèn)識(shí)Outlook的個(gè)個(gè)對(duì)象吧。

認(rèn)識(shí)VSTO中常用對(duì)象

微軟文檔
https://learn.microsoft.com/zh-cn/dotnet/api/microsoft.office.interop.outlook.application?view=outlook-pia

常用類型

  • MAPIFolder表示Outlook中的一個(gè)文件夾
  • ContactItem 表示一個(gè)聯(lián)系人
  • DistListItem 表示一個(gè)聯(lián)系人文件夾中的群組
  • OlDefaultFolders 獲取默認(rèn)文件類型的枚舉
  • OlItemType 獲取文件夾子項(xiàng)類型的枚舉

全局實(shí)例Application上掛載了我們用到大多數(shù)函數(shù)和屬性。

Application.Session;// 會(huì)話實(shí)例
Application.Version;// DLL動(dòng)態(tài)鏈接庫(kù)版本
Application.Name;// 應(yīng)用名稱

Application.Session會(huì)話實(shí)例,可以獲取Outlook的大多數(shù)狀態(tài),數(shù)據(jù)。如文件夾、聯(lián)系人、郵件等。

Outlook文件夾結(jié)構(gòu)

Outlook 按照郵件賬號(hào)區(qū)分用戶數(shù)據(jù),即每個(gè)郵件賬號(hào)都有獨(dú)立的收件箱,聯(lián)系人等。
我的Office Outlook插件開(kāi)發(fā)之旅(一)
Outlook 默認(rèn)情況下的文件夾結(jié)構(gòu)
我的Office Outlook插件開(kāi)發(fā)之旅(一)
獲取第一個(gè)郵箱賬號(hào)的默認(rèn)聯(lián)系人文件夾

Application.Session.Stores.Cast<Outlook.Store()>.First().GetDefaultFolder(OlDefaultFolders.olFolderContacts);

獲取Outlook的狀態(tài)信息

獲取聯(lián)系人信息

MAPIFolder folder = Application.Session.GetDefaultFolder(OlDefaultFolders.olFolderContacts);//獲取默認(rèn)的通訊錄文件夾
IEnumerable<ContactItem> contactItems = folder.Items.OfType<ContactItem>(); // 獲取文件夾下的子項(xiàng),OfType<ContactItem>只拿聯(lián)系人的
foreach (ContactItem it in contactItems)
{
    // 拿聯(lián)系人的各種信息
    string fullName = it.FullName;
    // 注意在此處修改聯(lián)系人信息,再Save()是不生效的
}

添加聯(lián)系人

MAPIFolder folder = Application.Session.GetDefaultFolder(OlDefaultFolders.olFolderContacts);// 獲取默認(rèn)的聯(lián)系人文件夾
ContactItem contact = folder.Items.Add(OlItemType.olContactItem);// 新增聯(lián)系人子項(xiàng)
// 設(shè)置各種信息
contact.FirstName = "三";
contact.LastName = "張";
contact.Email1Address = "zhangsan@163.com";
// 存儲(chǔ)聯(lián)系人
contact.Save();

刪除聯(lián)系人

Microsoft.Office.Interop.Outlook.MAPIFolder deletedFolder = application.Session.GetDefaultFolder(OlDefaultFolders.olFolderDeletedItems);// 默認(rèn)的聯(lián)系人文件夾
int count = deletedFolder.Items.Count;// 獲取子項(xiàng)數(shù),包含聯(lián)系人和群組
for (int i = count; i > 0; i--)// 遍歷刪除
{
    deletedFolder.Items.Remove(i);
}

成品代碼

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Linq;
using Outlook = Microsoft.Office.Interop.Outlook;
using Office = Microsoft.Office.Core;
using Microsoft.Office.Interop.Outlook;
using System.Windows.Forms;
using System.Data;
using System.Data.SqlClient;
using System.IO;
using System.Threading;
using System.Collections;

namespace ContactsSynchronization
{
    public partial class ThisAddIn
    {
        

        private void ThisAddIn_Startup(object sender, System.EventArgs e)
        {
            OperatorContact operatorInstance = new OperatorContact(this.Application);
            operatorInstance.Task();
        }

        private void ThisAddIn_Shutdown(object sender, System.EventArgs e)
        {
        }

        #region VSTO 生成的代碼

        /// <summary>
        /// 設(shè)計(jì)器支持所需的方法 - 不要
        /// 使用代碼編輯器修改此方法的內(nèi)容。
        /// </summary>
        private void InternalStartup()
        {
            this.Startup += new System.EventHandler(ThisAddIn_Startup);
            this.Shutdown += new System.EventHandler(ThisAddIn_Shutdown);
        }

        #endregion
    }

    class OperatorContact
    {
        public OperatorContact(Microsoft.Office.Interop.Outlook.Application application)
        {
            this.application = application;
        }

        Microsoft.Office.Interop.Outlook.Application application = null; // outlook程序?qū)嵗?
        private static string addressBookName = "湯石集團(tuán)通訊錄";// 通訊錄名稱

        private Microsoft.Office.Interop.Outlook.MAPIFolder addressBookFolder = null; // 通訊錄文件夾實(shí)例

        public void Task()
        {
            new Thread(Run).Start();
        }

        /// <summary>
        /// 開(kāi)個(gè)新線程執(zhí)行任務(wù),不要堵塞原來(lái)的線程
        /// </summary>
        private void Run()
        {
            try
            {
                if (NeedUpdate())
                {
                    addressBookFolder = getAddressBookFolder();// 覆蓋式創(chuàng)建通訊錄
                    List<Contact> remoteContacts = readRemoteContacts();// 讀取遠(yuǎn)程郵箱通訊錄
                    if (remoteContacts == null) return;
                    Adjust(remoteContacts);// 調(diào)整聯(lián)系人和群組
                    updateClientVersion();// 更新本地通訊錄版本號(hào)
                } 
            }
            catch (System.Exception ex)
            {
                const string path = @"C:\TONS\email-plugin-error.log";
                FileInfo fileInfo = new FileInfo(path);
                long length = 0;
                if (fileInfo.Exists && fileInfo.Length != 0) length = fileInfo.Length / 1024 / 1024;
                if (length <= 3) File.AppendAllText(path, ex.Message + "\r\n");
                else File.WriteAllText(path, ex.Message + "\r\n");
            }
        }

        /// <summary>
        /// 覆蓋式創(chuàng)建通訊錄
        /// </summary>
        /// <returns>通訊錄文件夾實(shí)例</returns>
        private Microsoft.Office.Interop.Outlook.MAPIFolder getAddressBookFolder()
        {
            // 獲取用戶第一個(gè)PST檔的通訊錄文件夾的枚舉器
            IEnumerator en = application.Session.Stores.Cast<Outlook.Store>().First()
                .GetDefaultFolder(OlDefaultFolders.olFolderContacts)
                .Folders.GetEnumerator();
            bool exits = false;
            Microsoft.Office.Interop.Outlook.MAPIFolder folder = null;

            // 遍歷文件夾
            while (en.MoveNext()) {
                Microsoft.Office.Interop.Outlook.MAPIFolder current = (Microsoft.Office.Interop.Outlook.MAPIFolder)en.Current;
                if (current.Name == addressBookName) {
                    exits = true;
                    folder = current;
                }
            }

            if (!exits)
             {
                 // 創(chuàng)建湯石集團(tuán)通訊錄,并映射成通訊錄格式
                 Microsoft.Office.Interop.Outlook.MAPIFolder newFolder = application.Session.Stores.Cast<Outlook.Store>().First()
                          .GetDefaultFolder(OlDefaultFolders.olFolderContacts)
                          .Folders.Add(addressBookName);
                 newFolder.ShowAsOutlookAB = true;// 設(shè)置成“聯(lián)系人”文件夾
                 return newFolder;
             }
             else {
                // 返回已經(jīng)存在的同時(shí)集團(tuán)通訊錄文件夾,并刪除里面的內(nèi)容
                int count = folder.Items.Count;
                for (int i = count; i > 0; i--)
                {
                    folder.Items.Remove(i);
                }
                Microsoft.Office.Interop.Outlook.MAPIFolder deletedFolder = application.Session.GetDefaultFolder(OlDefaultFolders.olFolderDeletedItems);
                count = deletedFolder.Items.Count;
                for (int i = count; i > 0; i--)
                {
                    deletedFolder.Items.Remove(i);
                }
                return folder;
             }
        }



        /// <summary>
        /// 更新本地的銅須錄版本
        /// </summary>
        private void updateClientVersion()
        {
            String path = @"C:\TONS\email-plugin-version.conf";
            string version = getRemoteVersion();
            if (!File.Exists(path))
            {
                File.WriteAllText(path,version);
            }
            else {
                File.WriteAllText(path, version);
            }
        }

        /// <summary>
        /// 判斷是否需要更新
        /// </summary>
        /// <returns>boolean值</returns>
        private bool NeedUpdate()
        {
            string remoteVersion = getRemoteVersion();
            if (remoteVersion == null) return false;
            string clientVersion = getClientVersion();
            return !(clientVersion == remoteVersion);
        }

        /// <summary>
        /// 讀取服務(wù)器的通訊錄版本
        /// </summary>
        /// <returns>通訊錄版本</returns>
        private string getRemoteVersion()
        {
            List<Dictionary<string, object>> items = SelectList(
                "SELECT TOP(1) [version] FROM TonsOfficeA..VersionControl WHERE applicationID = N'EmailContact'"
                , "Server=192.168.2.1;Database=TonsOfficeA;uid=sa;pwd=dsc");
            if (items == null) return null;
            return items[0]["version"].ToString();
        }

        /// <summary>
        /// 獲取本地的通訊錄版本
        /// </summary>
        /// <returns>通訊錄版本</returns>
        private string getClientVersion()
        {
            String path = @"C:\TONS\email-plugin-version.conf";
            if (!File.Exists(path)) return null;
            return File.ReadAllText(path);
        }

        /// <summary>
        /// 讀取遠(yuǎn)程的通訊錄
        /// </summary>
        /// <returns>聯(lián)系人實(shí)例集合</returns>
        private List<Contact> readRemoteContacts()
        {
            List<Contact> remoteContacts = new List<Contact>();
            List<Dictionary<string, object>> items =
                SelectList(
                    "select [emailAddress],[firstName],[lastName],[companyName],[department],[_group] as 'group',[jobTitle] from [TonsOfficeA].[dbo].[EmailContacts]",
                    "Server=192.168.2.1;Database=TonsOfficeA;uid=sa;pwd=dsc");
            items.ForEach(it =>
            {
                Contact contact = new Contact();
                contact.email1Address = it["emailAddress"].ToString();
                contact.firstName = it["firstName"].ToString();
                contact.lastName = it["lastName"].ToString();
                contact.companyName = it["companyName"].ToString();
                contact.department = it["department"].ToString();
                if (it["jobTitle"] != null) contact.jobTitle = it["jobTitle"].ToString();
                contact.groups = it["group"].ToString().Split(',').ToList();
                remoteContacts.Add(contact);
            });
            return remoteContacts;
        }

        /// <summary>
        /// 執(zhí)行select語(yǔ)句
        /// </summary>
        /// <param name="sql">select語(yǔ)句</param>
        /// <param name="connection">數(shù)據(jù)庫(kù)鏈接語(yǔ)句</param>
        /// <returns>List<Dictionary<string, object>>結(jié)果</returns>
        /// <exception cref="System.Exception"></exception>
        public List<Dictionary<string, object>> SelectList(string sql, string connection)
        {
            if (sql == null || connection == null || sql == "" || connection == "")
                throw new System.Exception("未傳入SQL語(yǔ)句或者Connection鏈接語(yǔ)句");
            List<Dictionary<string, object>> list = new List<Dictionary<string, object>>();
            SqlConnection conn = new SqlConnection(connection);
            SqlCommand cmd = new SqlCommand(sql, conn);
            try
            {
                conn.Open();
                SqlDataReader sqlDataReader = cmd.ExecuteReader(CommandBehavior.CloseConnection);
                if (sqlDataReader == null) return null;
                while (sqlDataReader.Read())
                {
                    int count = sqlDataReader.FieldCount;
                    if (count <= 0) continue;
                    Dictionary<string, object> map = new Dictionary<string, object>();
                    for (int i = 0; i < count; i++)
                    {
                        string name = sqlDataReader.GetName(i);
                        object value = sqlDataReader.GetValue(i);
                        map.Add(name, value);
                    }
                    list.Add(map);
                }

                conn.Close();
                return list;
            }
            catch (System.Exception)
            {
                conn.Close();
                return null;
            }
        }

        /// <summary>
        /// 調(diào)整通訊錄聯(lián)系人
        /// </summary>
        /// <param name="remoteContacts">數(shù)據(jù)庫(kù)導(dǎo)入的聯(lián)系人信息的源</param>
        private void Adjust(List<Contact> remoteContacts)
        {            
            // copy一份以來(lái)做群組
            List<Contact> distListItems = new List<Contact>();
            Contact[] tempItems = new Contact[remoteContacts.Count];
            remoteContacts.CopyTo(tempItems);
            tempItems.ToList().ForEach(it =>
            {
                it.groups.ForEach(g =>
                {
                    Contact con = new Contact
                    {
                        firstName = it.firstName,
                        lastName = it.lastName,
                        email1Address = it.email1Address,
                        companyName = it.companyName,
                        department = it.department,
                        group = g
                    };
                    distListItems.Add(con);
                });
            });
           
            // 添加聯(lián)系人
            remoteContacts.ForEach(it =>
            {

                ContactItem contact = addressBookFolder.Items.Add();
                contact.FirstName = it.firstName;
                contact.LastName = it.lastName;
                contact.Email1Address = it.email1Address;
                contact.CompanyName = it.companyName;
                contact.Department = it.department;
                if (it.jobTitle != null) contact.JobTitle = it.jobTitle;
                contact.Save();
            });

            // 按群組分組,并創(chuàng)建群組保存
            List<ContactStore> contactStores = distListItems
                .GroupBy(it => it.group)
                .Select(it => new ContactStore { group = it.Key, contacts = it.ToList() })
                .ToList();
            contactStores.ForEach(it =>
            {
                DistListItem myItem = addressBookFolder.Items.Add(OlItemType.olDistributionListItem);
                it.contacts.ForEach(contact =>
                {
                    string id = String.Format("{0}{1}({2})", contact.lastName, contact.firstName,
                        contact.email1Address);
                    Recipient recipient = application.Session.CreateRecipient(id);
                    recipient.Resolve();
                    myItem.AddMember(recipient);
                });
                myItem.DLName = it.group;
                myItem.Save();
            });
        }

        struct Contact
        {
            public string email1Address; // 郵箱
            public string firstName; // 姓氏
            public string lastName; // 姓名
            public string companyName; // 公司名稱
            public string department; // 部門名稱
            public List<string> groups; // 分組集合
            public string group; // 分組
            public string jobTitle; // 職稱
        }

        struct ContactStore
        {
            public string group;
            public List<Contact> contacts;
        }
    }
}

打包、安裝和卸載

右鍵項(xiàng)目 -> 發(fā)布
我的Office Outlook插件開(kāi)發(fā)之旅(一)
發(fā)布后你會(huì)看到這樣的結(jié)構(gòu)
我的Office Outlook插件開(kāi)發(fā)之旅(一)
點(diǎn)擊setup.exe即可安裝了
卸載需要使用VSTOInstaller.exe文章來(lái)源地址http://www.zghlxwxcb.cn/news/detail-711339.html

"C:\Program Files (x86)\Common Files\microsoft shared\VSTO\10.0\VSTOInstaller.exe" /u "你的.vsto文件目錄"

到了這里,關(guān)于我的Office Outlook插件開(kāi)發(fā)之旅(一)的文章就介紹完了。如果您還想了解更多內(nèi)容,請(qǐng)?jiān)谟疑辖撬阉鱐OY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!

本文來(lái)自互聯(lián)網(wǎng)用戶投稿,該文觀點(diǎn)僅代表作者本人,不代表本站立場(chǎng)。本站僅提供信息存儲(chǔ)空間服務(wù),不擁有所有權(quán),不承擔(dān)相關(guān)法律責(zé)任。如若轉(zhuǎn)載,請(qǐng)注明出處: 如若內(nèi)容造成侵權(quán)/違法違規(guī)/事實(shí)不符,請(qǐng)點(diǎn)擊違法舉報(bào)進(jìn)行投訴反饋,一經(jīng)查實(shí),立即刪除!

領(lǐng)支付寶紅包贊助服務(wù)器費(fèi)用

相關(guān)文章

  • Office如何通過(guò)VSTO進(jìn)行WORD插件開(kāi)發(fā)?

    Office如何通過(guò)VSTO進(jìn)行WORD插件開(kāi)發(fā)?

    ??VSTO(Visual Studio Tools for Office )是VBA的替代,是一套用于創(chuàng)建自定義Office應(yīng)用程序的Visual Studio工具包。VSTO可以用Visual Basic 或者Visual C#擴(kuò)展Office應(yīng)用程序(例如Word、Excel、PPT)。本文通過(guò)VSTO進(jìn)行Word插件開(kāi)發(fā)總結(jié),并進(jìn)行記錄。 ?? (1)安裝Visual Studio ??在百度等瀏覽器

    2024年02月16日
    瀏覽(21)
  • Office如何通過(guò)VSTO進(jìn)行EXCEL插件開(kāi)發(fā)?

    Office如何通過(guò)VSTO進(jìn)行EXCEL插件開(kāi)發(fā)?

    ??VSTO(Visual Studio Tools for Office )是VBA的替代,是一套用于創(chuàng)建自定義Office應(yīng)用程序的Visual Studio工具包。VSTO可以用Visual Basic 或者Visual C#擴(kuò)展Office應(yīng)用程序(例如Word、Excel、PPT)。本文通過(guò)VSTO進(jìn)行Excel插件開(kāi)發(fā)總結(jié),并進(jìn)行記錄。 ?? (1)安裝Visual Studio ??在百度等瀏覽器

    2024年02月16日
    瀏覽(24)
  • Dell筆記本更換系統(tǒng)主板后出現(xiàn)Microsoft Office Outlook Exchange 錯(cuò)誤 80090016

    原因:由于**更換系統(tǒng)主板 **,Outlook Exchange 驗(yàn)證失敗。 解決方法: 注銷受影響的用戶賬號(hào),登錄具有管理員權(quán)限的賬號(hào)。也可以使用網(wǎng)絡(luò)共享操作。 進(jìn)入 C:users\\\"username\\\"AppDataLocalPackages 文件夾。 將 Microsoft.AAD.BrokerPlugin_cw5n1h2txyewy 修改為 Microsoft.AAD.BrokerPlugin_cw5n1h2txyewy.old

    2024年02月11日
    瀏覽(33)
  • 我的AI之旅開(kāi)始了

    我的AI之旅開(kāi)始了

    知道重要,但是就是不動(dòng)。 今天告訴自己,必須開(kāi)始學(xué)習(xí)了。 用這篇博文作為1月份AI學(xué)習(xí)之旅的起跑點(diǎn)吧。 從此,無(wú)懼AI,無(wú)懼編程。 AI之路就在腳下。 AI,在我理解,就是讓機(jī)器變得更加智能,能夠以人思考和行為的方式去實(shí)行某種操作,更大更快更強(qiáng)。 編程和AI的關(guān)系

    2024年01月16日
    瀏覽(21)
  • 我的單片機(jī)入門之旅

    單片機(jī)作為現(xiàn)代電子技術(shù)的重要組成部分,廣泛應(yīng)用于各個(gè)領(lǐng)域。而作為一個(gè)初學(xué)者,我對(duì)單片機(jī)一無(wú)所知。但是,通過(guò)不斷的學(xué)習(xí)和實(shí)踐,我逐漸掌握了單片機(jī)的基本概念和使用方法。在我的單片機(jī)入門之旅中,經(jīng)歷了許多困難和挑戰(zhàn),但也取得了很大的進(jìn)步和收獲。 在開(kāi)

    2024年03月22日
    瀏覽(21)
  • 我的蘋(píng)果手機(jī)的越獄之旅

    我的蘋(píng)果手機(jī)的越獄之旅

    最近因?yàn)闃I(yè)務(wù)需要,需要一臺(tái)越獄手機(jī);就把測(cè)試機(jī)6plus拿來(lái)做越獄使用,在此之前先大致說(shuō)明一下越獄的原理、應(yīng)用、流程以及可能存在的問(wèn)題: 越獄是指通過(guò)一些技術(shù)手段,使iOS設(shè)備可以訪問(wèn)到iOS系統(tǒng)的全部控制權(quán),從而可以實(shí)現(xiàn)更多的自定義和操作。以下是蘋(píng)果手機(jī)越

    2024年02月11日
    瀏覽(29)
  • 我的世界Bukkit插件開(kāi)發(fā)-第一章-初始環(huán)境搭建-搭建基于spigot核心的服務(wù)器-并連接客戶端......

    我的世界Bukkit插件開(kāi)發(fā)-第一章-初始環(huán)境搭建-搭建基于spigot核心的服務(wù)器-并連接客戶端......

    基于Spigot核心的插件開(kāi)發(fā) 本章實(shí)現(xiàn)本地成功搭建私服并連接客戶端 前置開(kāi)發(fā)工具:IDEA JDK環(huán)境-JKD-17 構(gòu)建工具:maven 必備idea插件:Minecraft Development 服務(wù)器核心: Spigot-1.20.jar mc客戶端 小部分內(nèi)容來(lái)自AI大模型,如需深入,請(qǐng)聯(lián)系博主或自行了解 手工不易,且看且珍惜 首次開(kāi)始

    2024年03月21日
    瀏覽(31)
  • 我的C++奇跡之旅相遇:支持函數(shù)重載的原理

    我的C++奇跡之旅相遇:支持函數(shù)重載的原理

    函數(shù)重載概念 函數(shù)重載:是函數(shù)的一種特殊情況, C++ 允許在同一作用域中聲明幾個(gè)功能類似的同名函數(shù),這些同名函數(shù)的形參列表( 參數(shù)個(gè)數(shù) 或 類型 或 類型順序 )不同,常用來(lái)處理實(shí)現(xiàn)功能類似數(shù)據(jù)類型不同的問(wèn)題。 為什么C++支持函數(shù)重載,而C語(yǔ)言不支持函數(shù)重載呢?

    2024年04月15日
    瀏覽(23)
  • 三秒繪畫(huà)!我的AI繪畫(huà)之旅——Adobe體驗(yàn)

    三秒繪畫(huà)!我的AI繪畫(huà)之旅——Adobe體驗(yàn)

    首發(fā)于微信公眾號(hào):AI執(zhí)劍人(微信號(hào): AISwordholder ),歡迎大家訂閱關(guān)注! 你敢相信下面這幅圖只用了三秒就畫(huà)出來(lái)了嗎? 畫(huà)畫(huà)如此簡(jiǎn)單,這都是源于AIGC的快速發(fā)展,所謂AIGC,就是使用人工智能來(lái)生成內(nèi)容,是現(xiàn)在人工智能中最為火熱的領(lǐng)域之一!你只需要告訴人工智能

    2024年02月09日
    瀏覽(26)
  • 從數(shù)字圖像到音視頻學(xué)習(xí):我的學(xué)習(xí)之旅

    從數(shù)字圖像到音視頻學(xué)習(xí):我的學(xué)習(xí)之旅

    數(shù)字圖像是一門廣泛應(yīng)用于計(jì)算機(jī)視覺(jué)、圖像處理和計(jì)算機(jī)圖形學(xué)等領(lǐng)域的學(xué)科,而音視頻學(xué)習(xí)則涵蓋了音頻和視頻的處理、分析和應(yīng)用。 如果你最開(kāi)始接觸數(shù)字圖像,可能會(huì)學(xué)習(xí)一些基本概念,例如像素、分辨率、色彩空間和圖像處理算法等。這可能涉及到使用編程語(yǔ)言(

    2024年02月11日
    瀏覽(24)

覺(jué)得文章有用就打賞一下文章作者

支付寶掃一掃打賞

博客贊助

微信掃一掃打賞

請(qǐng)作者喝杯咖啡吧~博客贊助

支付寶掃一掃領(lǐng)取紅包,優(yōu)惠每天領(lǐng)

二維碼1

領(lǐng)取紅包

二維碼2

領(lǐng)紅包