Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
T
Thick-Common
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
潘栩锋
Thick-Common
Commits
22f07d8c
Commit
22f07d8c
authored
Jan 26, 2019
by
潘栩锋
🚴
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加检测 FObjSys 添加检测 OBJ ID 是否唯一功能
parent
d2745d61
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
241 additions
and
998 deletions
+241
-998
FObjSys.cs
Project.FLY.FObjSys/FObjSys/FObjSys.cs
+21
-0
IFObj.cs
Project.FLY.FObjSys/FObjSys/IFObj.cs
+5
-0
StringResource.zh-CN.xaml
....Base/FLY.Thick.Base.UI/Culture/StringResource.zh-CN.xaml
+1
-1
GetSampleService.cs
....FLY.Thick.Base/FLY.Thick.Base/Client/GetSampleService.cs
+102
-314
InitParamService.cs
....FLY.Thick.Base/FLY.Thick.Base/Client/InitParamService.cs
+49
-339
FLY.Thick.Base.csproj
Project.FLY.Thick.Base/FLY.Thick.Base/FLY.Thick.Base.csproj
+6
-6
FodyWeavers.xml
Project.FLY.Thick.Base/FLY.Thick.Base/FodyWeavers.xml
+3
-3
GetSample.cs
Project.FLY.Thick.Base/FLY.Thick.Base/Server/GetSample.cs
+52
-333
packages.config
Project.FLY.Thick.Base/FLY.Thick.Base/packages.config
+2
-2
No files found.
Project.FLY.FObjSys/FObjSys/FObjSys.cs
View file @
22f07d8c
...
@@ -66,6 +66,26 @@ namespace FObjBase
...
@@ -66,6 +66,26 @@ namespace FObjBase
Objs
.
Add
(
obj
,
new
List
<
Sense
>());
Objs
.
Add
(
obj
,
new
List
<
Sense
>());
}
}
/// <summary>
/// <summary>
/// 检测 全部Obj 的ID 是否都唯一
/// </summary>
/// <returns></returns>
public
bool
CheckObjIDUnique
()
{
for
(
int
i
=
0
;
i
<
Objs
.
Count
();
i
++)
{
var
kv1
=
Objs
.
ElementAt
(
i
);
for
(
int
j
=
i
+
1
;
j
<
Objs
.
Count
();
j
++)
{
var
kv2
=
Objs
.
ElementAt
(
j
);
if
(
kv1
.
Key
.
ID
==
kv2
.
Key
.
ID
)
{
return
false
;
}
}
}
return
true
;
}
/// <summary>
/// 对外发送消息
/// 对外发送消息
/// </summary>
/// </summary>
/// <param name="s1">远端对应的连接代理 </param>
/// <param name="s1">远端对应的连接代理 </param>
...
@@ -620,6 +640,7 @@ namespace FObjBase
...
@@ -620,6 +640,7 @@ namespace FObjBase
{
{
try
try
{
{
KeyValuePair
<
IFObj
,
List
<
Sense
>>
obj_kv
=
Objs
.
First
(
obj
=>
obj
.
Key
.
ID
==
objid
);
KeyValuePair
<
IFObj
,
List
<
Sense
>>
obj_kv
=
Objs
.
First
(
obj
=>
obj
.
Key
.
ID
==
objid
);
return
obj_kv
.
Key
;
return
obj_kv
.
Key
;
}
}
...
...
Project.FLY.FObjSys/FObjSys/IFObj.cs
View file @
22f07d8c
...
@@ -105,6 +105,7 @@ namespace FObjBase
...
@@ -105,6 +105,7 @@ namespace FObjBase
/// </summary>
/// </summary>
public
class
FObj
:
IFObj
public
class
FObj
:
IFObj
{
{
public
FObj
()
public
FObj
()
{
{
ID
=
0
;
ID
=
0
;
...
@@ -116,6 +117,10 @@ namespace FObjBase
...
@@ -116,6 +117,10 @@ namespace FObjBase
this
.
objsys_idx
=
objsys_idx
;
this
.
objsys_idx
=
objsys_idx
;
CurrObjSys
.
ObjAdd
(
this
);
CurrObjSys
.
ObjAdd
(
this
);
}
}
public
override
string
ToString
()
{
return
$@"[
{
ID
}
]
{
GetType
().
Name
}
"
;
}
#
region
IFObj
成员
#
region
IFObj
成员
private
int
objsys_idx
=
0
;
private
int
objsys_idx
=
0
;
...
...
Project.FLY.Thick.Base/FLY.Thick.Base.UI/Culture/StringResource.zh-CN.xaml
View file @
22f07d8c
...
@@ -307,7 +307,7 @@
...
@@ -307,7 +307,7 @@
<sys:String x:Key="strCSCorr">机架修正</sys:String>
<sys:String x:Key="strCSCorr">机架修正</sys:String>
<sys:String x:Key="strCSGetSample">获取样品</sys:String>
<sys:String x:Key="strCSGetSample">获取样品</sys:String>
<sys:String x:Key="strCSRunning">运行至..</sys:String>
<sys:String x:Key="strCSRunning">运行至..</sys:String>
<sys:String x:Key="strCSDisconne
tc
ed">连接断开</sys:String>
<sys:String x:Key="strCSDisconne
ct
ed">连接断开</sys:String>
<sys:String x:Key="strCSGageInfo">机架信息</sys:String>
<sys:String x:Key="strCSGageInfo">机架信息</sys:String>
<sys:String x:Key="strCSPause">暂停</sys:String>
<sys:String x:Key="strCSPause">暂停</sys:String>
<sys:String x:Key="strCSAutoScan">自动扫描</sys:String>
<sys:String x:Key="strCSAutoScan">自动扫描</sys:String>
...
...
Project.FLY.Thick.Base/FLY.Thick.Base/Client/GetSampleService.cs
View file @
22f07d8c
This diff is collapsed.
Click to expand it.
Project.FLY.Thick.Base/FLY.Thick.Base/Client/InitParamService.cs
View file @
22f07d8c
This diff is collapsed.
Click to expand it.
Project.FLY.Thick.Base/FLY.Thick.Base/FLY.Thick.Base.csproj
View file @
22f07d8c
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<Project
ToolsVersion=
"4.0"
DefaultTargets=
"Build"
xmlns=
"http://schemas.microsoft.com/developer/msbuild/2003"
>
<Project
ToolsVersion=
"4.0"
DefaultTargets=
"Build"
xmlns=
"http://schemas.microsoft.com/developer/msbuild/2003"
>
<Import
Project=
"..\..\..\Project.FLY.Thick.Normal\packages\PropertyChanged2.Fody.2.
5.13\build\PropertyChanged2.Fody.props"
Condition=
"Exists('..\..\..\Project.FLY.Thick.Normal\packages\PropertyChanged2.Fody.2.5.13
\build\PropertyChanged2.Fody.props')"
/>
<Import
Project=
"..\..\..\Project.FLY.Thick.Normal\packages\PropertyChanged2.Fody.2.
6.0\build\PropertyChanged2.Fody.props"
Condition=
"Exists('..\..\..\Project.FLY.Thick.Normal\packages\PropertyChanged2.Fody.2.6.0
\build\PropertyChanged2.Fody.props')"
/>
<PropertyGroup>
<PropertyGroup>
<Configuration
Condition=
" '$(Configuration)' == '' "
>
Debug
</Configuration>
<Configuration
Condition=
" '$(Configuration)' == '' "
>
Debug
</Configuration>
<Platform
Condition=
" '$(Platform)' == '' "
>
AnyCPU
</Platform>
<Platform
Condition=
" '$(Platform)' == '' "
>
AnyCPU
</Platform>
...
@@ -39,8 +39,8 @@
...
@@ -39,8 +39,8 @@
</ApplicationIcon>
</ApplicationIcon>
</PropertyGroup>
</PropertyGroup>
<ItemGroup>
<ItemGroup>
<Reference
Include=
"PropertyChanged2, Version=2.
5.13
.0, Culture=neutral, PublicKeyToken=ee3ee20bcf148ddd, processorArchitecture=MSIL"
>
<Reference
Include=
"PropertyChanged2, Version=2.
6.0
.0, Culture=neutral, PublicKeyToken=ee3ee20bcf148ddd, processorArchitecture=MSIL"
>
<HintPath>
..\..\..\Project.FLY.Thick.Normal\packages\PropertyChanged2.Fody.2.
5.13
\lib\net40\PropertyChanged2.dll
</HintPath>
<HintPath>
..\..\..\Project.FLY.Thick.Normal\packages\PropertyChanged2.Fody.2.
6.0
\lib\net40\PropertyChanged2.dll
</HintPath>
</Reference>
</Reference>
<Reference
Include=
"System"
/>
<Reference
Include=
"System"
/>
<Reference
Include=
"System.Core"
/>
<Reference
Include=
"System.Core"
/>
...
@@ -203,13 +203,13 @@
...
@@ -203,13 +203,13 @@
<None
Include=
"packages.config"
/>
<None
Include=
"packages.config"
/>
</ItemGroup>
</ItemGroup>
<Import
Project=
"$(MSBuildToolsPath)\Microsoft.CSharp.targets"
/>
<Import
Project=
"$(MSBuildToolsPath)\Microsoft.CSharp.targets"
/>
<Import
Project=
"..\..\..\Project.FLY.Thick.Normal\packages\Fody.3.
2.13\build\Fody.targets"
Condition=
"Exists('..\..\..\Project.FLY.Thick.Normal\packages\Fody.3.2.13
\build\Fody.targets')"
/>
<Import
Project=
"..\..\..\Project.FLY.Thick.Normal\packages\Fody.3.
3.5\build\Fody.targets"
Condition=
"Exists('..\..\..\Project.FLY.Thick.Normal\packages\Fody.3.3.5
\build\Fody.targets')"
/>
<Target
Name=
"EnsureNuGetPackageBuildImports"
BeforeTargets=
"PrepareForBuild"
>
<Target
Name=
"EnsureNuGetPackageBuildImports"
BeforeTargets=
"PrepareForBuild"
>
<PropertyGroup>
<PropertyGroup>
<ErrorText>
这台计算机上缺少此项目引用的 NuGet 程序包。使用“NuGet 程序包还原”可下载这些程序包。有关更多信息,请参见 http://go.microsoft.com/fwlink/?LinkID=322105。缺少的文件是 {0}。
</ErrorText>
<ErrorText>
这台计算机上缺少此项目引用的 NuGet 程序包。使用“NuGet 程序包还原”可下载这些程序包。有关更多信息,请参见 http://go.microsoft.com/fwlink/?LinkID=322105。缺少的文件是 {0}。
</ErrorText>
</PropertyGroup>
</PropertyGroup>
<Error
Condition=
"!Exists('..\..\..\Project.FLY.Thick.Normal\packages\Fody.3.
2.13\build\Fody.targets')"
Text=
"$([System.String]::Format('$(ErrorText)', '..\..\..\Project.FLY.Thick.Normal\packages\Fody.3.2.13
\build\Fody.targets'))"
/>
<Error
Condition=
"!Exists('..\..\..\Project.FLY.Thick.Normal\packages\Fody.3.
3.5\build\Fody.targets')"
Text=
"$([System.String]::Format('$(ErrorText)', '..\..\..\Project.FLY.Thick.Normal\packages\Fody.3.3.5
\build\Fody.targets'))"
/>
<Error
Condition=
"!Exists('..\..\..\Project.FLY.Thick.Normal\packages\PropertyChanged2.Fody.2.
5.13\build\PropertyChanged2.Fody.props')"
Text=
"$([System.String]::Format('$(ErrorText)', '..\..\..\Project.FLY.Thick.Normal\packages\PropertyChanged2.Fody.2.5.13
\build\PropertyChanged2.Fody.props'))"
/>
<Error
Condition=
"!Exists('..\..\..\Project.FLY.Thick.Normal\packages\PropertyChanged2.Fody.2.
6.0\build\PropertyChanged2.Fody.props')"
Text=
"$([System.String]::Format('$(ErrorText)', '..\..\..\Project.FLY.Thick.Normal\packages\PropertyChanged2.Fody.2.6.0
\build\PropertyChanged2.Fody.props'))"
/>
</Target>
</Target>
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
Other similar extension points exist, see Microsoft.Common.targets.
...
...
Project.FLY.Thick.Base/FLY.Thick.Base/FodyWeavers.xml
View file @
22f07d8c
<?xml version="1.0" encoding="utf-8"
?>
<?xml version="1.0" encoding="utf-8"?>
<Weavers>
<Weavers
xmlns:xsi=
"http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation=
"FodyWeavers.xsd"
>
<PropertyChanged2
/>
<PropertyChanged2
/>
</Weavers>
</Weavers>
\ No newline at end of file
Project.FLY.Thick.Base/FLY.Thick.Base/Server/GetSample.cs
View file @
22f07d8c
This diff is collapsed.
Click to expand it.
Project.FLY.Thick.Base/FLY.Thick.Base/packages.config
View file @
22f07d8c
<?
xml
version
=
"1.0"
encoding
=
"utf-8"
?>
<?
xml
version
=
"1.0"
encoding
=
"utf-8"
?>
<
packages
>
<
packages
>
<
package
id
=
"Fody"
version
=
"3.
2.13
"
targetFramework
=
"net40"
developmentDependency
=
"true"
/>
<
package
id
=
"Fody"
version
=
"3.
3.5
"
targetFramework
=
"net40"
developmentDependency
=
"true"
/>
<
package
id
=
"PropertyChanged2.Fody"
version
=
"2.
5.13
"
targetFramework
=
"net40"
/>
<
package
id
=
"PropertyChanged2.Fody"
version
=
"2.
6.0
"
targetFramework
=
"net40"
/>
</
packages
>
</
packages
>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment